/* ==========================================================================
   شفاخانه حکیم سنائی افغان — سیستم طراحی
   Display: Lalezar (لاله)  |  Body: Vazirmatn (وزیری)
   Palette: آبی طبی تیره، آبی آسمانی روشن، سفید کلینیکی، قرمز مرجانی (نبض قلب)
   ========================================================================== */

:root{
  --pine-950: #050e1c;
  --pine-900: #0a1f38;
  --pine-800: #0f2f52;
  --pine-700: #154270;
  --sage-500: #3fa9dc;
  --sage-300: #9bd6f2;
  --sage-100: #e0f2fb;
  /* پس‌زمینه آرامش‌بخش شفاخانه‌ای — سبز-نعنایی ملایم */
  --mint-50:  #f4faf7;
  --mint-100: #eaf6f0;
  --mint-200: #dff1e8;
  --mist:     #eaf6f0;
  --sand:     #f4faf7;
  --sand-2:   #dff1e8;
  --paper:    #ffffff;
  --honey:    #ff6a6a;
  --honey-dark:#e14a58;
  --ink:      #0b1c2e;
  --ink-soft: #4d6478;
  --ink-faint:#8698a8;
  --line:     rgba(10,37,64,.10);
  --white:    #ffffff;

  --radius-lg: 30px;
  --radius-md: 20px;
  --radius-sm: 14px;

  --shadow-soft: 0 10px 30px -12px rgba(10,37,64,.20);
  --shadow-deep: 0 30px 70px -25px rgba(5,14,28,.50);
  --shadow-glow: 0 0 0 1px rgba(255,255,255,.5) inset, 0 20px 50px -20px rgba(10,37,64,.28);

  --ease: cubic-bezier(.22,1,.36,1);
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *,*::before,*::after{ animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; scroll-behavior:auto !important; }
}

body{
  margin:0;
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(160, 210, 190, 0.22), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(140, 200, 220, 0.14), transparent 50%),
    var(--mint-50);
  color:var(--ink);
  font-family:'Vazirmatn', 'Tahoma', sans-serif;
  font-size:16px;
  line-height:1.85;
  -webkit-font-smoothing:antialiased;
  overflow-x:hidden;
}

h1,h2,h3,.brand span,.logo-word{
  font-family:'Lalezar','Vazirmatn',sans-serif;
  font-weight:400;
  color:var(--pine-900);
  line-height:1.35;
  letter-spacing:.2px;
}

h1{ font-size:clamp(34px,5.4vw,60px); }
h2{ font-size:clamp(26px,3.4vw,38px); }
h3{ font-size:20px; font-family:'Vazirmatn',sans-serif; font-weight:700; }
h4{ font-size:16.5px; font-weight:700; margin:0 0 6px; }
p{ margin:0; }
a{ color:inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
button{ font-family:inherit; cursor:pointer; }
img{ max-width:100%; display:block; }

.container{ width:100%; max-width:1180px; margin:0 auto; padding:0 24px; }

/* ---------- Ambient background: soft breathing mesh ---------- */
.mesh-bg{
  position:absolute; inset:0; overflow:hidden; pointer-events:none; z-index:0;
}
.mesh-bg span{
  position:absolute; border-radius:50%; filter:blur(70px); opacity:.55;
  animation:drift 22s ease-in-out infinite;
}
.mesh-bg span:nth-child(1){ width:420px; height:420px; background:var(--sage-300); top:-120px; right:-80px; }
.mesh-bg span:nth-child(2){ width:360px; height:360px; background:var(--honey); opacity:.28; bottom:-140px; left:-60px; animation-delay:-7s; }
.mesh-bg span:nth-child(3){ width:280px; height:280px; background:var(--pine-700); opacity:.35; top:40%; left:38%; animation-delay:-14s; }
@keyframes drift{
  0%,100%{ transform:translate(0,0) scale(1); }
  33%{ transform:translate(30px,-25px) scale(1.08); }
  66%{ transform:translate(-20px,20px) scale(.95); }
}

/* ---------- Buttons ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  padding:14px 26px; border-radius:999px; font-weight:700; font-size:15px;
  border:1px solid transparent; transition:transform .35s var(--ease), box-shadow .35s var(--ease), background .3s, color .3s, border-color .3s;
  white-space:nowrap;
}
.btn-primary{ background:linear-gradient(160deg,var(--pine-800),var(--pine-950)); color:var(--sand); box-shadow:var(--shadow-soft); }
.btn-primary:hover{ transform:translateY(-3px); box-shadow:var(--shadow-deep); }
.btn-ghost{ background:rgba(255,255,255,.5); color:var(--pine-900); border-color:var(--line); backdrop-filter:blur(6px); }
.btn-ghost:hover{ background:var(--white); transform:translateY(-3px); box-shadow:var(--shadow-soft); }
.btn-gold{ background:linear-gradient(160deg,var(--honey),var(--honey-dark)); color:#fff; box-shadow:0 16px 34px -14px rgba(225,74,88,.55); }
.btn-gold:hover{ transform:translateY(-3px); }
.btn-block{ width:100%; }

/* ---------- Header ---------- */
.site-header{
  position:sticky; top:0; z-index:100;
  padding:18px 0;
  transition:padding .4s var(--ease), background .4s var(--ease), box-shadow .4s var(--ease);
}
.site-header::before{
  content:""; position:absolute; inset:0; z-index:-1;
  background:rgba(244,250,247,.72);
  backdrop-filter:blur(16px) saturate(140%);
  border-bottom:1px solid transparent;
  transition:border-color .4s;
}
.site-header.scrolled{ padding:10px 0; }
.site-header.scrolled::before{ box-shadow:0 10px 30px -18px rgba(5,14,28,.35); border-color:var(--line); }

.nav{ display:flex; align-items:center; justify-content:space-between; gap:20px; }
.brand{ display:flex; align-items:center; gap:12px; }
.brand-mark{
  width:46px; height:46px; border-radius:14px; flex:none;
  background:radial-gradient(circle at 35% 30%, #ffffff, var(--sage-100));
  display:flex; align-items:center; justify-content:center;
  box-shadow:var(--shadow-soft);
  transform-style:preserve-3d; transition:transform .5s var(--ease);
  padding:5px; overflow:hidden;
}
.brand:hover .brand-mark{ transform:rotateY(20deg) rotateX(-6deg); }
.brand-mark svg{ width:24px; height:24px; }
.logo-img{ width:100%; height:100%; object-fit:contain; display:block; }
.brand span{ display:flex; flex-direction:column; font-size:17.5px; color:var(--pine-900); }
.brand small{ font-family:'Vazirmatn',sans-serif; font-size:11.5px; font-weight:600; color:var(--ink-faint); margin-top:2px; }

.nav-links{ display:flex; align-items:center; gap:6px; }
.nav-links a{
  position:relative; padding:9px 15px; border-radius:999px; font-size:14.5px; font-weight:600; color:var(--ink-soft);
  transition:color .25s, background .25s;
}
.nav-links a:hover{ color:var(--pine-900); background:rgba(10,37,64,.06); }
.nav-links a.active{ color:var(--white); background:var(--pine-900); }

.nav-cta{ display:flex; align-items:center; gap:10px; }
.nav-toggle{
  display:none; width:44px; height:44px; border-radius:12px; border:1px solid var(--line);
  background:var(--white); position:relative;
}
.nav-toggle span,.nav-toggle span::before,.nav-toggle span::after{
  content:""; position:absolute; inset:auto; left:11px; right:11px; height:2px; background:var(--pine-900); transition:transform .3s;
}
.nav-toggle span{ top:21px; }
.nav-toggle span::before{ top:-7px; }
.nav-toggle span::after{ top:7px; }

/* ---------- Hero ---------- */
.hero{
  position:relative; overflow:hidden;
  padding:70px 0 110px;
  background:var(--pine-950);
  color:var(--sand);
  perspective:1400px;
}
.hero .mesh-bg span{ opacity:.4; }

/* ---------- عکس زمینه سه‌بعدی (پزشکی/آبی) ---------- */
.hero-media{
  position:absolute; inset:-60px; z-index:0; pointer-events:none;
  background-image:url('../assets/img/medical-hero.jpg');
  background-size:cover; background-position:center 42%;
  transform:scale(1.14) translateZ(0);
  filter:saturate(1.05) brightness(.62) contrast(1.05);
  transition:transform .5s var(--ease);
  will-change:transform;
}
/* ---------- صحنه WebGL سه‌بعدی هرو ---------- */
.hero-canvas{
  position:absolute; inset:0; z-index:1; pointer-events:none;
  opacity:0; transition:opacity 1.4s var(--ease);
}
.hero-canvas canvas{
  display:block; width:100% !important; height:100% !important;
}
.hero-canvas:not([data-reduced]){ opacity:1; animation:heroCanvasIn 1.4s var(--ease) both; }
.hero-canvas[data-reduced]{ display:none; }
@keyframes heroCanvasIn{
  from{ opacity:0; transform:scale(1.04); }
  to{ opacity:1; transform:scale(1); }
}
/* وینیت نرم دور صحنه برای تمرکز روی محتوا */
.hero-canvas::after{
  content:""; position:absolute; inset:0; pointer-events:none;
  background:
    radial-gradient(75% 70% at 50% 45%, transparent 40%, rgba(5,14,28,.55) 100%),
    linear-gradient(180deg, rgba(5,14,28,.25) 0%, transparent 20%, transparent 75%, rgba(5,14,28,.5) 100%);
}
@media (max-width:640px){
  .hero-canvas{ opacity:.9; }
  .hero-canvas::after{ background:radial-gradient(80% 70% at 50% 40%, transparent 30%, rgba(5,14,28,.6) 100%); }
}
.hero-media::after{
  content:""; position:absolute; inset:0;
  background:
    linear-gradient(115deg, rgba(5,14,28,.92) 0%, rgba(10,31,56,.72) 42%, rgba(5,14,28,.55) 70%, rgba(5,14,28,.9) 100%),
    radial-gradient(70% 90% at 80% 15%, rgba(63,169,220,.28), transparent 60%);
}
.page-hero .hero-media, .doc-hero .hero-media{ background-position:center 38%; }
.page-hero .hero-media::after, .doc-hero .hero-media::after{
  background:
    linear-gradient(120deg, rgba(5,14,28,.90) 0%, rgba(10,31,56,.68) 50%, rgba(5,14,28,.88) 100%),
    radial-gradient(60% 80% at 85% 10%, rgba(63,169,220,.24), transparent 60%);
}
.hero-grid{ position:relative; z-index:2; display:grid; grid-template-columns:1.15fr .95fr; gap:56px; align-items:center; }
.eyebrow{
  display:inline-flex; align-items:center; gap:8px; font-size:13.5px; font-weight:700; letter-spacing:.06em;
  color:var(--sage-300); margin-bottom:18px;
}
.eyebrow::before{ content:""; width:8px; height:8px; border-radius:50%; background:var(--honey); box-shadow:0 0 0 5px rgba(255,106,106,.22); }
.hero h1{ color:var(--sand); }
.hero h1 em{ font-style:normal; color:var(--sage-300); }
.hero-lede{ margin-top:20px; max-width:56ch; font-size:17.5px; color:rgba(244,248,252,.82); }
.hero-actions{ display:flex; gap:14px; margin-top:32px; flex-wrap:wrap; }
.hero-stats{ display:flex; gap:36px; margin-top:48px; flex-wrap:wrap; }
.hero-stats div{ display:flex; flex-direction:column; }
.hero-stats b{ font-family:'Lalezar'; font-size:34px; color:var(--honey); font-weight:400; }
.hero-stats span{ font-size:13.5px; color:rgba(244,248,252,.7); margin-top:2px; }

.hero-panel{
  position:relative; z-index:2;
  background:rgba(255,255,255,.92);
  border-radius:var(--radius-lg);
  padding:36px 32px;
  color:var(--ink);
  box-shadow:var(--shadow-deep);
  transform-style:preserve-3d;
  transition:transform .15s ease-out;
  border:1px solid rgba(255,255,255,.5);
}
.hero-panel .tag{
  display:inline-block; background:var(--mint-100); color:var(--pine-800); font-size:12.5px; font-weight:700;
  padding:6px 13px; border-radius:999px; margin-bottom:14px;
}
.hero-panel h3{ margin-bottom:18px; }
.hero-panel ul{ display:flex; flex-direction:column; gap:14px; }
.hero-panel li{ display:flex; align-items:flex-start; gap:12px; font-size:14.5px; color:var(--ink-soft); }
.hero-panel li svg{ width:20px; height:20px; flex:none; margin-top:2px; color:var(--pine-800); }
.contact-line{
  margin-top:24px; padding-top:22px; border-top:1px dashed var(--line);
  display:flex; flex-direction:column; gap:8px;
}
.contact-line span{ font-size:13px; color:var(--ink-faint); }
.contact-line a{ font-weight:800; font-size:19px; color:var(--pine-900); }

/* ---------- Sections ---------- */
main section{ position:relative; padding:96px 0; }
/* بخش‌های متناوب: گرادیان سبز-نعنایی آرامش‌بخش */
.section-alt{
  background:linear-gradient(180deg, var(--mint-100) 0%, var(--mint-50) 55%, var(--mint-200) 100%);
}
.section-head{ max-width:640px; margin-bottom:52px; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }
.section-head p{ margin-top:14px; color:var(--ink-soft); font-size:16.5px; }
.section-head .eyebrow{ color:var(--honey-dark); }
.section-head .eyebrow::before{ background:var(--pine-800); box-shadow:0 0 0 5px rgba(10,37,64,.12); }

.grid{ display:grid; gap:24px; }
.grid-3{ grid-template-columns:repeat(3,1fr); }
.grid-2{ grid-template-columns:repeat(2,1fr); }

/* ---------- 3D tilt cards (departments) ---------- */
.card{
  position:relative; display:block; padding:32px 28px; border-radius:var(--radius-md);
  background:var(--paper); border:1px solid var(--line);
  box-shadow:var(--shadow-soft);
  transform-style:preserve-3d; will-change:transform;
  transition:transform .25s var(--ease), box-shadow .35s var(--ease), border-color .35s;
  opacity:0; transform:translateY(28px);
}
.card.is-visible{ opacity:1; transform:translateY(0); transition:opacity .7s var(--ease), transform .7s var(--ease); }
.card:hover{ box-shadow:var(--shadow-deep); border-color:transparent; }
.card .icon{
  width:56px; height:56px; border-radius:16px; display:flex; align-items:center; justify-content:center;
  background:var(--mint-100); color:var(--pine-800); margin-bottom:20px;
  transform:translateZ(30px);
  transition:background .3s;
}
.card:hover .icon{ background:linear-gradient(155deg,var(--pine-800),var(--pine-950)); color:var(--sand); }
.card .icon svg{ width:26px; height:26px; }
.card h3{ transform:translateZ(20px); }
.card p{ margin-top:8px; color:var(--ink-soft); font-size:14.5px; transform:translateZ(15px); }
.card-foot{ display:inline-block; margin-top:16px; font-size:13.5px; font-weight:700; color:var(--honey-dark); transform:translateZ(15px); }

/* ---------- Doctor cards ---------- */
.doc-card{
  position:relative;
  display:flex; gap:18px; align-items:flex-start; padding:26px; border-radius:var(--radius-md);
  background:var(--paper); border:1px solid var(--line); box-shadow:var(--shadow-soft);
  opacity:0; transform:translateY(24px); transition:transform .4s var(--ease), box-shadow .4s var(--ease);
}
.doc-card.is-visible{ opacity:1; transform:translateY(0); transition:opacity .7s var(--ease), transform .7s var(--ease); }
.doc-card:hover{ box-shadow:var(--shadow-deep); transform:translateY(-4px); }
.doc-avatar{
  width:58px; height:58px; border-radius:50%; flex:none;
  background:linear-gradient(155deg,var(--sage-500),var(--pine-800));
  color:#fff; display:flex; align-items:center; justify-content:center; font-weight:800; font-size:15px;
  box-shadow:var(--shadow-soft);
}
.doc-card .role{ color:var(--honey-dark); font-size:13.5px; font-weight:700; margin-top:4px; }
.doc-card .desc{ color:var(--ink-soft); font-size:14px; margin-top:10px; }
.doc-card .depts{ display:flex; gap:8px; margin-top:14px; flex-wrap:wrap; }
.doc-more{
  display:inline-flex; align-items:center; gap:6px; margin-top:16px; font-size:13.5px; font-weight:700;
  color:var(--honey-dark); transition:gap .25s;
}
.doc-more:hover{ gap:10px; }
.chip{ font-size:12px; font-weight:700; background:var(--mint-100); color:var(--pine-800); padding:5px 12px; border-radius:999px; }

/* ---------- CTA band ---------- */
.cta-band{
  display:flex; align-items:center; justify-content:space-between; gap:26px; flex-wrap:wrap;
  background:linear-gradient(120deg,var(--pine-900),var(--pine-950));
  border-radius:var(--radius-lg); padding:48px 46px; color:var(--sand);
  position:relative; overflow:hidden;
}
.cta-band::after{
  content:""; position:absolute; width:280px; height:280px; border-radius:50%;
  background:var(--sage-500); opacity:.25; filter:blur(60px); top:-90px; left:-60px;
}
.cta-band h3{ color:var(--sand); font-size:24px; margin-bottom:8px; }
.cta-band p{ color:rgba(244,248,252,.75); font-size:15px; }

/* ---------- Footer ---------- */
.site-footer{ background:var(--pine-950); color:rgba(244,248,252,.75); padding:70px 0 26px; }
.footer-grid{ display:grid; grid-template-columns:1.4fr 1fr 1fr 1.2fr; gap:40px; padding-bottom:44px; border-bottom:1px solid rgba(255,255,255,.08); }
.footer-brand{ display:flex; align-items:center; gap:12px; font-family:'Lalezar'; font-size:19px; color:var(--sand); margin-bottom:14px; }
.footer-grid p{ font-size:14px; line-height:1.9; }
.footer-col h5{ color:var(--sand); font-size:14.5px; margin-bottom:16px; font-weight:700; }
.footer-col ul{ display:flex; flex-direction:column; gap:11px; }
.footer-col a{ font-size:14px; transition:color .25s; }
.footer-col a:hover{ color:var(--honey); }
.foot-contact{ display:flex; align-items:flex-start; gap:10px; font-size:13.5px; }
.foot-contact svg{ flex:none; margin-top:2px; }
.footer-bottom{ display:flex; justify-content:space-between; align-items:center; padding-top:24px; font-size:13px; flex-wrap:wrap; gap:10px; }

/* ---------- Page hero (inner pages) — هم‌سبک با هروی اصلی ---------- */
.page-hero{
  position:relative; overflow:hidden; padding:88px 0 96px;
  background:var(--pine-950);
  color:var(--sand);
  perspective:1400px;
  min-height:420px;
  display:flex; align-items:center;
}
.page-hero .mesh-bg span{ opacity:.35; }
.page-hero .hero-canvas{ z-index:1; }

/* کره‌های تزئینی شناور (شبیه هرو) */
.page-hero .mesh-bg::after,
.doc-hero .mesh-bg::after{
  content:""; position:absolute; width:280px; height:280px; border-radius:50%;
  background:radial-gradient(circle, rgba(63,169,220,.35), transparent 70%);
  top:15%; left:-80px; filter:blur(20px);
  animation:drift 18s ease-in-out infinite;
}
.page-hero .container,
.doc-hero .container{
  position:relative; z-index:2;
}

/* نان‌ریز شیشه‌ای */
.crumbs{
  display:inline-flex; align-items:center; gap:8px;
  font-size:13px; color:var(--sage-300);
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.14);
  backdrop-filter:blur(10px); -webkit-backdrop-filter:blur(10px);
  padding:8px 16px; border-radius:999px;
  margin-bottom:22px;
  box-shadow:0 8px 24px -12px rgba(0,0,0,.4);
}
.crumbs a{ color:var(--sage-300); transition:color .25s; }
.crumbs a:hover{ color:var(--white); text-decoration:none; }
.crumbs::before{ content:"⌂"; opacity:.7; font-size:12px; }

/* عنوان صفحه با گرادیان و ورود سه‌بعدی */
.page-hero h1{
  color:var(--sand); margin-top:8px; max-width:18ch;
  font-size:clamp(30px,4.5vw,52px);
  animation:heroTitleIn .9s var(--ease) both;
  text-shadow:0 8px 40px rgba(5,14,28,.5);
}
.page-hero .eyebrow{
  animation:heroTitleIn .7s var(--ease) both;
}
.page-hero p{
  margin-top:18px; max-width:60ch; color:rgba(244,248,252,.85); font-size:17px;
  animation:heroTitleIn .9s .1s var(--ease) both;
}
@keyframes heroTitleIn{
  from{ opacity:0; transform:translateY(28px) rotateX(10deg); }
  to{ opacity:1; transform:translateY(0) rotateX(0); }
}

/* خط تزئینی زیر eyebrow */
.page-hero .eyebrow::before{ box-shadow:0 0 0 6px rgba(255,106,106,.25); }

/* ---------- Doc hero — هم‌سبک ---------- */
.doc-hero{
  position:relative; overflow:hidden; padding:80px 0 90px;
  background:var(--pine-950);
  color:var(--sand);
  perspective:1400px;
  min-height:400px;
}
.doc-hero .mesh-bg span{ opacity:.35; }
.doc-hero .hero-canvas{ z-index:1; }
.doc-hero h1{
  animation:heroTitleIn .9s var(--ease) both;
  text-shadow:0 8px 40px rgba(5,14,28,.5);
}
.doc-hero .crumbs{ margin-bottom:18px; }
.doc-hero .doc-hero-grid{ position:relative; z-index:2; }

/* پروفایل داکتر: حلقه درخشان متحرک */
.doc-profile-photo::before{
  content:""; position:absolute; inset:-14px; z-index:-1; border-radius:50%;
  background:conic-gradient(from 0deg, var(--sage-500), var(--coral, #ff6a6a), var(--pine-700), var(--sage-500));
  animation:spinRing 8s linear infinite;
  opacity:.7; filter:blur(2px);
}
@keyframes spinRing{ to{ transform:rotate(360deg); } }
@media (prefers-reduced-motion: reduce){
  .doc-profile-photo::before{ animation:none; }
  .page-hero h1,.page-hero p,.page-hero .eyebrow,.doc-hero h1{ animation:none; }
}

/* ---------- About page ---------- */
.split{ display:grid; grid-template-columns:1.1fr .9fr; gap:56px; align-items:start; }
.value-list{ margin-top:30px; display:flex; flex-direction:column; gap:20px; }
.value-item{ display:flex; gap:16px; align-items:flex-start; }
.value-item .num{
  width:38px; height:38px; border-radius:12px; flex:none; display:flex; align-items:center; justify-content:center;
  background:var(--mint-100); color:var(--pine-800); font-weight:800; font-family:'Lalezar'; font-size:16px;
}
.value-item h4{ color:var(--pine-900); }
.value-item p{ color:var(--ink-soft); font-size:14.5px; margin-top:4px; }
.tile-divider{ margin-top:26px; opacity:.5; }
.tile-divider svg{ width:26px; height:26px; }

.timeline{ display:grid; grid-template-columns:repeat(4,1fr); gap:22px; counter-reset:step; }
.step{
  position:relative; padding:30px 22px 24px; background:var(--paper); border-radius:var(--radius-md);
  border:1px solid var(--line); box-shadow:var(--shadow-soft);
  opacity:0; transform:translateY(24px); transition:opacity .6s var(--ease), transform .6s var(--ease);
}
.step.is-visible{ opacity:1; transform:translateY(0); }
.step h4{ color:var(--pine-900); font-size:16px; }
.step p{ color:var(--ink-soft); font-size:14px; margin-top:8px; }

/* ---------- Departments listing ---------- */
.dept-block{
  display:grid; grid-template-columns:96px 1fr; gap:28px; padding:44px 0;
  border-bottom:1px solid var(--line); scroll-margin-top:110px;
  opacity:0; transform:translateY(20px); transition:opacity .6s var(--ease), transform .6s var(--ease);
}
.dept-block.is-visible{ opacity:1; transform:translateY(0); }
.dept-block:last-child{ border-bottom:none; }
.dept-icon{
  width:96px; height:96px; border-radius:24px; background:linear-gradient(155deg,var(--mint-100),var(--mint-200));
  display:flex; align-items:center; justify-content:center; flex:none; color:var(--pine-800);
  box-shadow:var(--shadow-soft);
}
.dept-icon svg{ width:42px; height:42px; }
.dept-num{ font-size:13px; font-weight:800; color:var(--honey-dark); letter-spacing:.05em; margin-bottom:6px; display:block; }
.dept-block h2{ font-size:24px; }
.dept-block .desc{ margin-top:10px; color:var(--ink-soft); font-size:16px; max-width:70ch; }
.dept-docs{ margin-top:18px; display:flex; flex-wrap:wrap; gap:10px; }
.dept-doc-pill{
  display:flex; align-items:center; gap:8px; padding:8px 14px 8px 8px; border-radius:999px;
  background:var(--paper); border:1px solid var(--line); font-size:13.5px; font-weight:700; color:var(--ink);
}
.dept-doc-pill .mini-avatar{
  width:26px; height:26px; border-radius:50%; background:var(--pine-800); color:#fff;
  display:flex; align-items:center; justify-content:center; font-size:11px; font-weight:800;
}

/* ---------- Doctors filter ---------- */
.filter-bar{ display:flex; flex-wrap:wrap; gap:10px; margin-bottom:40px; }
.filter-chip{
  padding:10px 18px; border-radius:999px; border:1px solid var(--line); background:var(--paper);
  font-size:13.5px; font-weight:700; color:var(--ink-soft); transition:all .3s var(--ease);
}
.filter-chip:hover{ border-color:#3da87a; color:var(--pine-900); }
.filter-chip.active{ background:var(--pine-900); color:var(--sand); border-color:var(--pine-900); }
.doc-card.hidden{ display:none; }

/* ---------- Contact page ---------- */
.contact-grid{ display:grid; grid-template-columns:1fr 1fr; gap:44px; align-items:start; }
.contact-card{
  background:var(--paper); border:1px solid var(--line); border-radius:var(--radius-md); padding:8px 30px;
  box-shadow:var(--shadow-soft); margin-bottom:26px;
}
.contact-row{ display:flex; gap:16px; align-items:flex-start; padding:22px 0; border-bottom:1px dashed var(--line); }
.contact-row:last-child{ border-bottom:none; }
.contact-row .icon{
  width:44px; height:44px; border-radius:13px; background:var(--mint-100); color:var(--pine-800);
  display:flex; align-items:center; justify-content:center; flex:none;
}
.contact-row .icon svg{ width:20px; height:20px; }
.contact-row h4{ color:var(--pine-900); }
.contact-row p{ color:var(--ink-soft); font-size:14.5px; margin-top:4px; }
.contact-row a{ display:block; font-weight:700; color:var(--pine-900); font-size:15px; margin-top:2px; }

.form-card{ background:var(--paper); border:1px solid var(--line); border-radius:var(--radius-md); padding:30px; box-shadow:var(--shadow-soft); }
.field-grid{ display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-top:20px; }
.field.full{ grid-column:1/-1; }
.field label{ display:block; font-size:13.5px; font-weight:700; color:var(--ink-soft); margin-bottom:8px; }
.field input,.field select,.field textarea{
  width:100%; padding:13px 16px; border-radius:12px; border:1px solid var(--line); background:var(--mint-50);
  font-family:inherit; font-size:14.5px; color:var(--ink); transition:border-color .3s, box-shadow .3s;
}
.field input:focus,.field select:focus,.field textarea:focus{
  outline:none; border-color:#5eb89a; box-shadow:0 0 0 4px #dff1e8;
}
.field textarea{ resize:vertical; }
.form-note{ display:flex; align-items:center; gap:8px; font-size:12.5px; color:var(--ink-faint); margin-top:14px; }
.form-success{
  display:none; align-items:center; gap:10px; margin-top:16px; padding:14px 18px; border-radius:12px;
  background:var(--mint-100); color:var(--pine-900); font-size:14px; font-weight:700;
  border:1px solid #c5e6d6;
}
.form-success.show{ display:flex; }
.map-frame{ border-radius:var(--radius-md); overflow:hidden; box-shadow:var(--shadow-deep); height:100%; min-height:460px; border:1px solid var(--line); }
.map-frame iframe{ width:100%; height:100%; min-height:460px; border:0; filter:saturate(.85) contrast(1.02); }

/* ---------- Scroll-cue ---------- */
.scroll-cue{
  position:absolute; bottom:26px; left:50%; transform:translateX(-50%); z-index:2;
  display:flex; flex-direction:column; align-items:center; gap:6px; color:rgba(244,248,252,.55); font-size:12px;
}
.scroll-cue span{ width:1px; height:34px; background:linear-gradient(var(--honey),transparent); animation:cueMove 1.8s ease-in-out infinite; }
@keyframes cueMove{ 0%{ opacity:0; transform:scaleY(.4);} 50%{opacity:1; transform:scaleY(1);} 100%{opacity:0; transform:scaleY(.4);} }

/* ---------- Reveal helper ---------- */
[data-reveal]{ opacity:0; transform:translateY(26px); }
[data-reveal].is-visible{ opacity:1; transform:translateY(0); transition:opacity .7s var(--ease), transform .7s var(--ease); }

/* ---------- Accessibility: skip link & focus ---------- */
.skip-link{
  position:fixed; top:-100px; right:16px; z-index:400;
  background:var(--pine-900); color:var(--white); padding:12px 20px;
  border-radius:0 0 14px 14px; font-weight:700; font-size:14px;
  transition:top .2s var(--ease); box-shadow:var(--shadow-deep);
}
.skip-link:focus{ top:0; }
:focus-visible{
  outline:3px solid #3da87a; outline-offset:3px; border-radius:4px;
}
main:focus{ outline:none; }

/* ---------- Floating action buttons ---------- */
.float-wa{
  position:fixed; z-index:150; bottom:24px; left:24px;
  width:56px; height:56px; border-radius:50%;
  background:#25d366; color:#fff;
  display:flex; align-items:center; justify-content:center;
  box-shadow:0 12px 30px -8px rgba(37,211,102,.55), 0 4px 0 rgba(0,0,0,.12);
  transition:transform .3s var(--ease), box-shadow .3s var(--ease);
}
.float-wa svg{ width:30px; height:30px; }
.float-wa:hover{ transform:translateY(-4px) scale(1.05); box-shadow:0 18px 40px -10px rgba(37,211,102,.7); }
.float-wa:active{ transform:translateY(-1px) scale(.98); }

.back-top{
  position:fixed; z-index:150; bottom:24px; left:96px;
  width:48px; height:48px; border-radius:50%;
  background:var(--pine-900); color:var(--sand); border:1px solid rgba(255,255,255,.15);
  display:flex; align-items:center; justify-content:center;
  box-shadow:var(--shadow-deep); cursor:pointer;
  opacity:0; visibility:hidden; transform:translateY(16px);
  transition:opacity .3s var(--ease), visibility .3s, transform .3s var(--ease), background .3s;
}
.back-top svg{ width:20px; height:20px; }
.back-top.show{ opacity:1; visibility:visible; transform:translateY(0); }
.back-top:hover{ background:var(--pine-700); transform:translateY(-4px); }

@media (max-width:640px){
  .float-wa{ width:52px; height:52px; bottom:20px; left:16px; }
  .float-wa svg{ width:28px; height:28px; }
  .back-top{ width:44px; height:44px; bottom:20px; left:78px; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns:1fr; }
  .split{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns:1fr 1fr; }
  .contact-grid{ grid-template-columns:1fr; }
  .timeline{ grid-template-columns:1fr 1fr; }
}
@media (max-width: 860px){
  .nav-links,.nav-cta{ display:none; }
  .nav-toggle{ display:flex; }
  .grid-3{ grid-template-columns:1fr 1fr; }
  .grid-2{ grid-template-columns:1fr; }

  body.nav-open .nav{ flex-wrap:wrap; row-gap:12px; }
  body.nav-open .nav-links{
    display:flex; flex-direction:column; order:3; width:100%;
    background:var(--paper); border-radius:18px; padding:14px;
    box-shadow:var(--shadow-deep); border:1px solid var(--line); gap:4px;
  }
  body.nav-open .nav-links a{ padding:12px 14px; }
  body.nav-open .nav-cta{
    display:flex; flex-direction:column; order:4; width:100%; gap:10px;
    background:var(--paper); border-radius:18px; padding:14px;
    box-shadow:var(--shadow-soft); border:1px solid var(--line);
  }
  body.nav-open .nav-cta .btn{ width:100%; }

  /* منوی باز: هدر بلندتر می‌شود */
  body.nav-open .site-header{ background:rgba(244,250,247,.96); }
}
@media (max-width: 640px){
  main section{ padding:64px 0; }
  .grid-3{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns:1fr; }
  .cta-band{ flex-direction:column; align-items:flex-start; padding:34px 26px; }
  .dept-block{ grid-template-columns:64px 1fr; gap:16px; padding:32px 0; }
  .dept-icon{ width:64px; height:64px; border-radius:18px; }
  .dept-icon svg{ width:30px; height:30px; }
  .timeline{ grid-template-columns:1fr; }
  .field-grid{ grid-template-columns:1fr; }
}

/* ==========================================================================
   مودال جزئیات خدمات/بخش‌ها (Department detail modal)
   ========================================================================== */
.dept-more{
  display:inline-flex; align-items:center; gap:8px; margin-top:16px;
  background:none; border:1px solid var(--line); color:var(--pine-800);
  font-family:inherit; font-weight:600; font-size:14.5px; cursor:pointer;
  padding:10px 20px; border-radius:999px; transition:background .25s var(--ease), box-shadow .25s var(--ease), transform .25s var(--ease);
}
.dept-more:hover{ background:var(--mint-100); box-shadow:var(--shadow-soft); transform:translateY(-2px); }
.dept-more svg{ width:16px; height:16px; transition:transform .25s var(--ease); }
.dept-more:hover svg{ transform:translateX(-4px); }

.card .card-foot{ cursor:pointer; }

body.modal-open{ overflow:hidden; }

.dept-modal-overlay{
  position:fixed; inset:0; z-index:200;
  background:rgba(5,14,28,.55); backdrop-filter:blur(6px); -webkit-backdrop-filter:blur(6px);
  display:flex; align-items:center; justify-content:center; padding:24px;
  opacity:0; visibility:hidden; transition:opacity .3s var(--ease), visibility 0s linear .3s;
}
.dept-modal-overlay.open{
  opacity:1; visibility:visible; transition:opacity .3s var(--ease), visibility 0s linear 0s;
}
.dept-modal{
  position:relative; width:100%; max-width:720px; max-height:86vh; overflow-y:auto;
  background:var(--paper); border-radius:var(--radius-lg); box-shadow:var(--shadow-deep);
  border:1px solid var(--line); padding:44px 40px 40px;
  transform:translateY(24px) scale(.97); opacity:0; transition:transform .35s var(--ease), opacity .35s var(--ease);
}
.dept-modal-overlay.open .dept-modal{ transform:translateY(0) scale(1); opacity:1; }

.dept-modal-close{
  position:absolute; top:18px; left:18px; width:38px; height:38px; border-radius:50%;
  border:1px solid var(--line); background:var(--mint-100); color:var(--ink); font-size:20px; line-height:1;
  cursor:pointer; display:flex; align-items:center; justify-content:center; transition:background .2s, transform .2s;
}
.dept-modal-close:hover{ background:var(--mint-200); transform:rotate(90deg); }

.dept-modal-head{ display:flex; align-items:flex-start; gap:20px; padding-inline-end:36px; }
.dept-modal-icon{
  flex:none; width:64px; height:64px; border-radius:18px; display:flex; align-items:center; justify-content:center;
  background:linear-gradient(160deg,var(--pine-800),var(--pine-950)); color:var(--sand);
}
.dept-modal-icon svg{ width:30px; height:30px; }
.dept-modal-num{ display:inline-block; font-size:13px; font-weight:700; color:var(--honey-dark); letter-spacing:.03em; margin-bottom:4px; }
.dept-modal-head h2{ margin:0; font-size:26px; }

.dept-modal-body{ margin-top:26px; }
.dept-modal-body p.lead{ font-size:16px; color:var(--ink-soft); line-height:1.9; }
.dept-modal-section{ margin-top:26px; }
.dept-modal-section h4{ font-size:15px; color:var(--pine-800); margin-bottom:12px; display:flex; align-items:center; gap:8px; }
.dept-modal-section h4::before{ content:""; width:6px; height:6px; border-radius:50%; background:var(--honey); flex:none; }
.dept-services{ list-style:none; padding:0; margin:0; display:grid; gap:10px; }
.dept-services li{
  display:flex; align-items:flex-start; gap:10px; font-size:14.5px; color:var(--ink); line-height:1.7;
  background:var(--mint-50); border:1px solid var(--line); border-radius:12px; padding:12px 16px;
}
.dept-services li svg{ flex:none; width:17px; height:17px; margin-top:2px; color:#3da87a; }
.dept-modal-docs{ display:flex; flex-wrap:wrap; gap:10px; }
.dept-modal-hours{ display:flex; align-items:center; gap:10px; font-size:14.5px; color:var(--ink-soft); }
.dept-modal-hours svg{ width:18px; height:18px; color:var(--honey-dark); flex:none; }
.dept-modal-actions{ margin-top:32px; display:flex; flex-wrap:wrap; gap:12px; }

@media (max-width:640px){
  .dept-modal{ padding:34px 22px 30px; max-height:90vh; }
  .dept-modal-head h2{ font-size:21px; }
  .dept-modal-icon{ width:52px; height:52px; }
  .dept-modal-icon svg{ width:24px; height:24px; }
}

/* ==========================================================================
   ارتقای عمق سه‌بعدی — پوسته‌های آیکون به‌صورت قرص‌های برجسته
   (3D depth upgrade — icons read as raised, extruded discs, not flat tiles)
   ========================================================================== */
.card{ perspective:900px; }
.dept-block{ perspective:700px; }
.doc-card{ perspective:700px; }

.brand-mark,
.card .icon,
.dept-icon,
.value-item .num,
.contact-row .icon,
.dept-modal-icon,
.doc-avatar{
  box-shadow:
    0 2px 0 rgba(5,14,28,.18),
    0 5px 0 rgba(5,14,28,.11),
    0 11px 20px -9px rgba(5,14,28,.38);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background .3s;
}
.dept-modal-icon{
  box-shadow:
    0 3px 0 rgba(5,14,28,.4),
    0 7px 0 rgba(5,14,28,.25),
    0 16px 26px -10px rgba(5,14,28,.5);
}
.card:hover .icon{
  transform: translateY(-4px) translateZ(30px);
  box-shadow:
    0 4px 0 rgba(5,14,28,.22),
    0 9px 0 rgba(5,14,28,.15),
    0 20px 30px -10px rgba(5,14,28,.48);
}
.dept-block:hover .dept-icon{
  transform: translateY(-4px) translateZ(24px) rotateX(6deg);
  box-shadow:
    0 4px 0 rgba(5,14,28,.22),
    0 9px 0 rgba(5,14,28,.15),
    0 20px 30px -10px rgba(5,14,28,.48);
}
.doc-card:hover .doc-avatar{
  transform: translateY(-3px) translateZ(20px);
  box-shadow:
    0 4px 0 rgba(5,14,28,.22),
    0 9px 0 rgba(5,14,28,.15),
    0 18px 26px -10px rgba(5,14,28,.45);
}

/* ---------- نشان معلق سه‌بعدی هرو (auto-rotating badge, home hero only) ---------- */
.hero-badge3d{
  position:absolute; z-index:3; width:108px; height:108px;
  top:-40px; inset-inline-start:-28px;
  animation:badgeFloat 4.5s ease-in-out infinite;
}
.hero-badge3d::before{
  content:""; position:absolute; inset:-26px; z-index:-1; border-radius:50%;
  background:radial-gradient(circle, rgba(255,106,106,.35), transparent 70%);
  filter:blur(18px);
}
.hero-badge3d .badge-spin{
  position:relative; width:100%; height:100%; perspective:800px;
  transform-style:preserve-3d; animation:badgeSpin 10s linear infinite;
}
.badge-face{
  position:absolute; inset:0; border-radius:50%; backface-visibility:hidden;
  display:flex; align-items:center; justify-content:center;
  border:2px solid rgba(255,255,255,.22);
  box-shadow:0 4px 0 rgba(5,14,28,.3), 0 18px 30px -10px rgba(5,14,28,.55);
}
.badge-face.front{ background:radial-gradient(circle at 35% 30%, #ffffff, var(--sage-100)); padding:14px; }
.badge-face.back{ background:linear-gradient(155deg,var(--honey),var(--honey-dark)); transform:rotateY(180deg); }
.badge-face svg{ width:44px; height:44px; }
.badge-face .logo-img{ width:100%; height:100%; object-fit:contain; }
@keyframes badgeSpin{ from{ transform:rotateY(0deg); } to{ transform:rotateY(360deg); } }
@keyframes badgeFloat{ 0%,100%{ transform:translateY(0); } 50%{ transform:translateY(-12px); } }
@media (max-width:980px){ .hero-badge3d{ display:none; } }

/* ---------- بخش ویدیوی تمام‌صفحه (صفحه اصلی، قبل از بخش‌های درمانی) ---------- */
.video-feature{
  position:relative; width:100%; height:100vh; min-height:520px; max-height:900px;
  overflow:hidden; background:var(--pine-950);
}
.video-feature-media{
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover; display:block;
}
.video-feature-overlay{
  position:absolute; inset:0;
  background:
    linear-gradient(180deg, rgba(5,14,28,.55) 0%, rgba(5,14,28,.15) 30%, rgba(5,14,28,.15) 70%, rgba(5,14,28,.75) 100%);
}
.video-feature-caption{
  position:relative; z-index:2; height:100%; display:flex; flex-direction:column;
  align-items:center; justify-content:center; text-align:center; gap:14px;
}
.video-feature-caption .eyebrow{ color:var(--sage-300); }
.video-feature-caption h2{ color:var(--sand); margin:0; }
.video-feature-sound{
  position:absolute; z-index:3; bottom:28px; inset-inline-end:28px;
  width:52px; height:52px; border-radius:50%; border:1px solid rgba(255,255,255,.35);
  background:rgba(5,14,28,.45); backdrop-filter:blur(8px); color:var(--sand);
  display:flex; align-items:center; justify-content:center; transition:background .3s, transform .3s;
}
.video-feature-sound:hover{ background:rgba(5,14,28,.7); transform:translateY(-3px); }
.video-feature-sound svg{ width:22px; height:22px; }
@media (max-width:640px){
  .video-feature{ height:70vh; min-height:380px; }
}

/* ==========================================================================
   لایه سه‌بعدی پیشرفته — عمق، تیلت و پارالاکس عمیق
   ========================================================================== */

/* دکمه‌ها: فشار سه‌بعدی */
.btn{ transform-style:preserve-3d; }
.btn:active{ transform:translateY(1px) scale(.97); }
.btn-primary:active{ box-shadow:0 4px 12px -6px rgba(5,14,28,.5); }

/* کارت‌های داکتر: عمق لایه‌ای */
.doc-card{ transform-style:preserve-3d; will-change:transform; }
.doc-card .doc-avatar{ transform-style:preserve-3d; }
.doc-card h3,
.doc-card .role,
.doc-card .desc,
.doc-card .depts,
.doc-card .doc-more{ transform:translateZ(12px); }

/* کارت‌های بخش‌ها: افزایش عمق hover */
.card::after{
  content:""; position:absolute; inset:0; border-radius:inherit; pointer-events:none;
  background:linear-gradient(145deg, rgba(255,255,255,.65), transparent 45%);
  opacity:0; transition:opacity .35s var(--ease);
}
.card:hover::after{ opacity:1; }

/* خط زمانی: ورود و هاور سه‌بعدی */
.step{ transform-style:preserve-3d; perspective:800px; transform:translateY(28px) rotateX(12deg); }
.step.is-visible{ transform:translateY(0) rotateX(0deg); }
.step:hover{
  transform:translateY(-6px) rotateX(0deg) translateZ(20px);
  box-shadow:var(--shadow-deep);
}

/* کارت‌های تماس و فرم */
.contact-card,.form-card{ transform-style:preserve-3d; perspective:900px; will-change:transform; }
.contact-card:hover,.form-card:hover{ box-shadow:var(--shadow-deep); }

/* چیپ‌های فیلتر: فشار سه‌بعدی */
.filter-chip{ transform-style:preserve-3d; transition:transform .2s var(--ease), background .3s, color .3s, border-color .3s; }
.filter-chip:active{ transform:translateY(2px); }
.filter-chip.active{
  transform:translateY(-2px);
  box-shadow:0 6px 0 rgba(5,14,28,.35), 0 14px 24px -10px rgba(5,14,28,.45);
}

/* پنل هرو: عمق بیشتر هنگام هاور */
.hero-panel{ transition:transform .15s ease-out, box-shadow .4s var(--ease); }
.hero-panel:hover{ box-shadow:0 40px 80px -30px rgba(5,14,28,.65); }

/* هدر: لایه شیشه‌ای با عمق */
.site-header{ transform-style:preserve-3d; }
.site-header.scrolled::before{ backdrop-filter:blur(20px) saturate(150%); }

/* آیتم‌های ارزشی: pop سه‌بعدی */
.value-item{
  transform-style:preserve-3d; transition:transform .35s var(--ease);
}
.value-item:hover{ transform:translateX(-6px) translateZ(16px); }
.value-item .num{ transition:transform .35s var(--ease), box-shadow .35s var(--ease); }
.value-item:hover .num{ transform:translateZ(30px) rotateY(-12deg); }

/* بلوک‌های بخش درمانی: عمق لایه‌ای */
.dept-block h2,.dept-block .desc,.dept-block .dept-docs{ transform:translateZ(8px); }
.dept-block:hover h2{ transform:translateZ(22px); }

/* فوتر */
.footer-brand{ transition:transform .4s var(--ease); }
.footer-brand:hover{ transform:translateY(-4px) translateZ(10px); }

/* ناوبری */
.nav-links a{ transform-style:preserve-3d; transition:color .25s, background .25s, transform .25s var(--ease); }
.nav-links a:hover{ transform:translateY(-2px); }
.nav-links a.active{ transform:translateY(-1px); box-shadow:0 4px 0 rgba(5,14,28,.35); }

/* تیلت سراسری */
.card,.doc-card,.contact-card,.form-card,.hero-panel,.step{
  transform-style:preserve-3d;
}

/* CTA */
.cta-band{ transform-style:preserve-3d; transition:transform .5s var(--ease), box-shadow .5s var(--ease); }
.cta-band:hover{ transform:translateY(-4px) rotateX(2deg); box-shadow:var(--shadow-deep); }

/* بج سه‌بعدی: توقف هنگام هاور */
.hero-badge3d:hover .badge-spin{ animation-play-state:paused; }

/* نور شناور روی کارت‌ها (متغیر از JS) */
.card{ --mx:50%; --my:50%; }
.card::before{
  content:""; position:absolute; inset:0; border-radius:inherit; pointer-events:none;
  background:radial-gradient(420px circle at var(--mx) var(--my), rgba(63,169,220,.16), transparent 55%);
  opacity:0; transition:opacity .35s var(--ease);
}
.card:hover::before{ opacity:1; }

.doc-card{ --mx:50%; --my:50%; }
.doc-card::before{
  content:""; position:absolute; inset:0; border-radius:inherit; pointer-events:none;
  background:radial-gradient(380px circle at var(--mx) var(--my), rgba(63,169,220,.12), transparent 55%);
  opacity:0; transition:opacity .35s var(--ease);
}
.doc-card:hover::before{ opacity:1; }

/* حالت کاهش حرکت */
@media (prefers-reduced-motion: reduce){
  .card::before,.doc-card::before,.card::after{ display:none !important; }
  .step,.value-item,.cta-band,.nav-links a,.filter-chip{ transform:none !important; }
  .hero-canvas{ display:none !important; }
}

/* ==========================================================================
   تصاویر بخش‌ها، آواتار داکتران و گالری درباره ما
   ========================================================================== */
.dept-photo{
  display:block; width:100%; max-height:280px; object-fit:cover;
  border-radius:var(--radius-md); margin-top:16px; border:1px solid var(--line);
  box-shadow:var(--shadow-soft);
}

.doc-avatar{ overflow:hidden; }
.doc-avatar-img img{
  width:100%; height:100%; object-fit:cover; display:block; border-radius:50%;
}

.gallery-grid{
  display:grid; grid-template-columns:repeat(3,1fr); gap:20px;
}
.gallery-card{
  margin:0; border-radius:var(--radius-md); overflow:hidden; background:var(--paper);
  border:1px solid var(--line); box-shadow:var(--shadow-soft);
  transition:transform .35s var(--ease), box-shadow .35s var(--ease);
}
.gallery-card:hover{ transform:translateY(-4px); box-shadow:var(--shadow-deep); }
.gallery-card img{
  width:100%; aspect-ratio:3/2; object-fit:cover; display:block;
}
.gallery-card figcaption{
  padding:12px 16px; font-size:13.5px; font-weight:600; color:var(--ink-soft);
  background:var(--paper); border-top:1px solid var(--line);
}

@media (max-width: 900px){
  .gallery-grid{ grid-template-columns:repeat(2,1fr); }
}
@media (max-width: 560px){
  .gallery-grid{ grid-template-columns:1fr; }
  .dept-photo{ max-height:220px; }
}
