/* ============================================================
   3D ENT SPECIALTIES — styles for the block inside "Medical Services Offered"
   Everything is scoped to #ent3d so it cannot affect the rest of the site.
   ============================================================ */
#ent3d {
  --e3-dark: #31144c; --e3-primary: #6610f2; --e3-primary-light: #8b44f7;
  --e3-border: #e5dff0; --e3-muted: #6b6b6b; --e3-text: #1a1a2e;
  background: #fff; border: 1px solid var(--e3-border); border-radius: 20px;
  box-shadow: 0 2px 10px rgba(49,20,76,.06);
  padding: 32px; margin: 0 0 32px; color: var(--e3-text); text-align: left;
}
#ent3d *, #ent3d *::before, #ent3d *::after { box-sizing: border-box; }
#ent3d .ent3d-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 36px; align-items: stretch; }

/* ---------- Stage (3D canvas area) ---------- */
#ent3d .ent3d-stage {
  position: relative; min-height: 600px; border-radius: 18px; overflow: hidden;
  background: radial-gradient(120% 90% at 50% 38%, #4a2178 0%, #2a1145 45%, #150726 100%);
  touch-action: pan-y; user-select: none; -webkit-user-select: none;
}
#ent3d .ent3d-stage canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; display: block; outline: none; cursor: grab; }
#ent3d .ent3d-stage canvas:active { cursor: grabbing; }
#ent3d .ent3d-stage.is-hovering canvas { cursor: pointer; }
#ent3d .ent3d-stage::after { content: ""; position: absolute; left: 15%; right: 15%; bottom: -40px; height: 120px; pointer-events: none;
  background: radial-gradient(closest-side, rgba(139,68,247,.35), transparent); filter: blur(6px); }
#ent3d .ent3d-loading { position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255,255,255,.7); font-size: 14px; letter-spacing: .04em; }
#ent3d .ent3d-loading span::before { content: ""; display: inline-block; width: 14px; height: 14px; margin-right: 10px; vertical-align: -2px;
  border: 2px solid rgba(255,255,255,.25); border-top-color: #fff; border-radius: 50%; animation: e3spin .8s linear infinite; }
@keyframes e3spin { to { transform: rotate(360deg); } }

#ent3d .ent3d-hint { position: absolute; left: 50%; bottom: 34px; transform: translateX(-50%); z-index: 4;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); backdrop-filter: blur(6px);
  color: #fff; font-size: 13px; padding: 8px 16px; border-radius: 999px; white-space: nowrap; transition: opacity .6s; pointer-events: none; }
#ent3d .ent3d-hint.is-hidden { opacity: 0; }
#ent3d .ent3d-reset { position: absolute; top: 16px; right: 16px; z-index: 4; opacity: 0; pointer-events: none;
  border: 1px solid rgba(255,255,255,.22); background: rgba(20,8,36,.35); backdrop-filter: blur(6px);
  color: #fff; font: 600 12px var(--font-body, 'Inter', sans-serif); padding: 8px 12px; border-radius: 999px; cursor: pointer; transition: opacity .3s, background .2s; }
#ent3d .ent3d-reset:hover { background: rgba(255,255,255,.16); }
#ent3d .ent3d-reset.is-visible { opacity: 1; pointer-events: auto; }
#ent3d .ent3d-skin { position: absolute; top: 16px; left: 16px; z-index: 4; display: flex; padding: 3px; gap: 2px; border-radius: 999px;
  background: rgba(20,8,36,.35); border: 1px solid rgba(255,255,255,.18); backdrop-filter: blur(6px); }
#ent3d .ent3d-skin button { border: 0; background: none; color: rgba(255,255,255,.75); font: 600 12px var(--font-body, 'Inter', sans-serif); padding: 6px 11px; border-radius: 999px; cursor: pointer; }
#ent3d .ent3d-skin button[aria-pressed="true"] { background: #fff; color: var(--e3-dark); }
#ent3d .ent3d-credit { position: absolute; left: 14px; right: 14px; bottom: 8px; z-index: 4; font-size: 10px; line-height: 1.4; color: rgba(255,255,255,.42); }
#ent3d .ent3d-credit a { color: inherit; text-decoration: underline; }
#ent3d .ent3d-status { position: absolute; left: 50%; top: 18px; transform: translateX(-50%); z-index: 4; color: #fff; font-size: 12px;
  background: rgba(20,8,36,.45); padding: 6px 12px; border-radius: 999px; opacity: 0; transition: opacity .3s; pointer-events: none; }
#ent3d .ent3d-status.is-visible { opacity: 1; }

/* ---------- Hotspots ---------- */
#ent3d .ent3d-hotspots, #ent3d .ent3d-labels { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
#ent3d .ent3d-labels { z-index: 3; }
#ent3d .ent3d-labels svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
#ent3d .ent3d-dot { position: absolute; left: 0; top: 0; width: 34px; height: 34px; margin: -17px 0 0 -17px; padding: 0; border: 0; background: none;
  cursor: pointer; pointer-events: auto; transition: opacity .25s; will-change: transform; }
#ent3d .ent3d-dot::before { content: ""; position: absolute; inset: 11px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px rgba(139,68,247,.9), 0 0 18px 4px rgba(190,150,255,.8); }
#ent3d .ent3d-dot::after { content: ""; position: absolute; inset: 5px; border-radius: 50%; border: 2px solid rgba(255,255,255,.7); animation: e3pulse 2.2s ease-out infinite; }
#ent3d .ent3d-dot.is-back, #ent3d .ent3d-dot.is-open { opacity: 0; pointer-events: none; }
#ent3d .ent3d-dot:focus-visible { outline: 2px solid #fff; outline-offset: 2px; border-radius: 50%; }
#ent3d .ent3d-dot-label { position: absolute; left: 30px; top: 50%; transform: translateY(-50%); white-space: nowrap; pointer-events: none;
  background: rgba(255,255,255,.95); color: var(--e3-dark); font: 700 12px var(--font-body, 'Inter', sans-serif); padding: 5px 10px; border-radius: 999px;
  opacity: 0; transition: opacity .2s; box-shadow: 0 4px 14px rgba(0,0,0,.2); }
#ent3d .ent3d-dot:hover .ent3d-dot-label, #ent3d .ent3d-dot:focus-visible .ent3d-dot-label { opacity: 1; }
#ent3d .ent3d-dot.flip .ent3d-dot-label { left: auto; right: 30px; }
@keyframes e3pulse { 0% { transform: scale(.6); opacity: .9; } 100% { transform: scale(1.5); opacity: 0; } }

/* ---------- Anatomy labels ---------- */
#ent3d .ent3d-callout { position: absolute; left: 0; top: 0; white-space: nowrap; font: 600 12px var(--font-body, 'Inter', sans-serif); color: #fff;
  background: rgba(24,10,44,.72); border: 1px solid rgba(214,190,255,.35); padding: 4px 9px 4px 4px; border-radius: 999px;
  display: flex; align-items: center; gap: 6px; opacity: 0; transition: opacity .25s; backdrop-filter: blur(4px); }
#ent3d .ent3d-callout b, #ent3d .ent3d-marker { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%;
  background: #e9dcff; color: var(--e3-dark); font: 800 10px var(--font-body, 'Inter', sans-serif); }
#ent3d .ent3d-marker { position: absolute; left: 0; top: 0; margin: -9px 0 0 -9px; opacity: 0; box-shadow: 0 0 0 2px rgba(24,10,44,.6); transition: opacity .25s; }
#ent3d .ent3d-labels polyline { stroke: rgba(233,220,255,.8); stroke-width: 1; fill: none; transition: opacity .25s; }
#ent3d .ent3d-labels circle { fill: #e9dcff; transition: opacity .25s; }

/* ---------- Panel ---------- */
#ent3d .ent3d-panel { display: flex; flex-direction: column; }
#ent3d .ent3d-eyebrow { color: var(--e3-primary); font-weight: 700; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; margin: 6px 0 10px; }
#ent3d .ent3d-title { font-size: 30px; line-height: 1.15; font-weight: 800; letter-spacing: -.02em; color: var(--e3-dark); margin: 0 0 12px; }
#ent3d .ent3d-lede { color: var(--e3-muted); font-size: 15px; line-height: 1.6; margin: 0 0 22px; }
#ent3d .ent3d-tabs { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
#ent3d .ent3d-tab { width: 100%; display: flex; align-items: center; gap: 10px; text-align: left; cursor: pointer;
  background: #f7f4fc; border: 1.5px solid var(--e3-border); border-radius: 14px; padding: 12px 14px;
  font: 600 14px var(--font-body, 'Inter', sans-serif); color: var(--e3-dark); transition: border-color .2s, background .2s, transform .2s; }
#ent3d .ent3d-tab:hover { border-color: var(--e3-primary-light); transform: translateY(-1px); }
#ent3d .ent3d-tab[aria-selected="true"] { background: var(--e3-dark); border-color: var(--e3-dark); color: #fff; }
#ent3d .ent3d-tab-num { font-size: 11px; font-weight: 800; color: var(--e3-primary); background: #ede8f8; border-radius: 8px; padding: 4px 7px; }
#ent3d .ent3d-tab[aria-selected="true"] .ent3d-tab-num { background: rgba(255,255,255,.15); color: #fff; }

#ent3d .ent3d-card { flex: 1; border: 1.5px solid var(--e3-border); border-radius: 18px; padding: 24px; background: linear-gradient(180deg, #fff 0%, #faf8fe 100%); }
#ent3d .ent3d-card-empty { flex: 1; display: grid; place-items: center; text-align: center; border: 1.5px dashed var(--e3-border); border-radius: 18px;
  padding: 24px; color: var(--e3-muted); font-size: 14px; line-height: 1.6; min-height: 230px; }
#ent3d .ent3d-card[hidden], #ent3d .ent3d-card-empty[hidden], #ent3d .ent3d-legend[hidden], #ent3d .ent3d-seeing[hidden],
#ent3d .ent3d-fallback[hidden], #ent3d .ent3d-hotspots[hidden], #ent3d .ent3d-labels[hidden] { display: none; }
#ent3d .ent3d-card-region { font-size: 12px; font-weight: 700; color: var(--e3-primary); text-transform: uppercase; letter-spacing: .1em; margin-bottom: 6px; }
#ent3d .ent3d-card-title { margin: 0 0 10px; font-size: 22px; font-weight: 800; color: var(--e3-dark); }
#ent3d .ent3d-card-text { margin: 0 0 16px; color: var(--e3-muted); font-size: 14.5px; line-height: 1.6; }
#ent3d .ent3d-chips { list-style: none; margin: 0 0 18px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
#ent3d .ent3d-chips li { font-size: 12.5px; font-weight: 600; color: var(--e3-dark); background: #ede8f8; padding: 6px 12px; border-radius: 999px; }
#ent3d .ent3d-seeing { margin: 0 0 20px; }
#ent3d .ent3d-seeing-title { margin: 0 0 8px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--e3-muted); }
#ent3d .ent3d-seeing ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; }
#ent3d .ent3d-seeing li { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--e3-text); }
#ent3d .ent3d-seeing li b { display: inline-grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--e3-dark); color: #fff; font-size: 10px; }
#ent3d .ent3d-card.is-swapping { animation: e3in .35s ease; }
@keyframes e3in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
#ent3d .ent3d-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 16px; font-size: 11.5px; color: var(--e3-muted); }
#ent3d .ent3d-legend span { display: inline-flex; align-items: center; gap: 6px; }
#ent3d .ent3d-legend i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }

/* ---------- No-WebGL fallback ---------- */
#ent3d .ent3d-fallback { position: absolute; inset: 0; }
#ent3d .ent3d-fallback img { width: 100%; height: 100%; object-fit: cover; display: block; max-width: none; }
#ent3d .ent3d-fallback p { position: absolute; left: 50%; bottom: 34px; transform: translateX(-50%); margin: 0; white-space: nowrap;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); color: #fff; font-size: 13px; padding: 8px 16px; border-radius: 999px; }

/* ---------- Tablet & phone: heading → model → tabs → details ---------- */
@media (max-width: 900px) {
  #ent3d { padding: 20px; }
  #ent3d .ent3d-grid { display: flex; flex-direction: column; gap: 18px; }
  #ent3d .ent3d-panel { display: contents; }
  #ent3d .ent3d-head { order: 1; }
  #ent3d .ent3d-stage { order: 2; min-height: 0; height: 100vw; max-height: 560px; }
  #ent3d .ent3d-tabs { order: 3; margin: 0; }
  #ent3d .ent3d-card, #ent3d .ent3d-card-empty { order: 4; min-height: 0; }
  #ent3d .ent3d-title { font-size: 26px; }
  #ent3d .ent3d-lede { margin-bottom: 0; }
  #ent3d .ent3d-tab { padding: 10px 12px; font-size: 13px; }
  #ent3d .ent3d-credit { font-size: 9px; }
}
@media (max-width: 640px) {
  #ent3d { padding: 14px; margin-left: -14px; margin-right: -14px; border-radius: 16px; }
  #ent3d .ent3d-stage { border-radius: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  #ent3d .ent3d-dot::after, #ent3d .ent3d-loading span::before { animation: none; }
  #ent3d .ent3d-card.is-swapping { animation: none; }
}
