/* =========================================================
   العوافي الطبية — Al-Awafi Medical
   خط ثمانية: ضع ملفات الخط داخل مجلد fonts بالأسماء أدناه
   ========================================================= */
@font-face { font-family: "Thmanyah Sans"; font-weight: 400; font-display: swap;
  src: url("fonts/thmanyahsans-Regular.woff2") format("woff2"), url("fonts/thmanyahsans-Regular.otf") format("opentype"), url("fonts/thmanyahsans-Regular.ttf") format("truetype"); }
@font-face { font-family: "Thmanyah Sans"; font-weight: 500; font-display: swap;
  src: url("fonts/thmanyahsans-Medium.woff2") format("woff2"), url("fonts/thmanyahsans-Medium.otf") format("opentype"), url("fonts/thmanyahsans-Medium.ttf") format("truetype"); }
@font-face { font-family: "Thmanyah Sans"; font-weight: 700; font-display: swap;
  src: url("fonts/thmanyahsans-Bold.woff2") format("woff2"), url("fonts/thmanyahsans-Bold.otf") format("opentype"), url("fonts/thmanyahsans-Bold.ttf") format("truetype"); }

:root {
  --cyan: #01CFCF;
  --cyan-soft: #E3FAFA;
  --blue: #005CB1;
  --blue-mid: #0A7BC4;
  --navy: #07213F;
  --ink: #0E1B2C;
  --muted: #5B6B7E;
  --line: #E3EAF1;
  --bg: #FFFFFF;
  --tint: #F3F8FB;
  --grad: linear-gradient(135deg, var(--cyan) 0%, var(--blue) 100%);
  --radius: 22px;
  --shadow: 0 18px 50px -20px rgba(0, 60, 120, .28);
  --font: "Thmanyah Sans", "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
}

* { box-sizing: border-box; }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.75; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; }
.container { width: min(1160px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(820px, 100% - 32px); }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; padding: .85em 1.6em; border-radius: 999px; font: inherit; font-weight: 700; border: 0; cursor: pointer; transition: transform .2s, box-shadow .2s, background .2s; white-space: nowrap; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 10px 26px -10px rgba(0, 92, 177, .6); }
.btn-primary:hover { box-shadow: 0 14px 30px -10px rgba(0, 92, 177, .75); }
.btn-ghost { background: #fff; color: var(--blue); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--cyan); }
.btn-sm { padding: .55em 1.15em; font-size: .92rem; }
.btn-block { width: 100%; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .82); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid transparent; transition: border-color .3s, box-shadow .3s; }
.nav.scrolled { border-color: var(--line); box-shadow: 0 6px 24px -18px rgba(0, 40, 90, .4); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { width: 40px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 1.05rem; color: var(--blue); }
.brand-text small { font-size: .72rem; color: var(--muted); letter-spacing: .02em; }
.nav-links { display: flex; gap: 28px; }
.nav-links a { font-weight: 500; color: var(--muted); position: relative; transition: color .2s; }
.nav-links a:hover { color: var(--blue); }
.nav-links a::after { content: ""; position: absolute; inset-inline: 0; bottom: -6px; height: 2px; border-radius: 2px; background: var(--grad); transform: scaleX(0); transition: transform .25s; }
.nav-links a:hover::after { transform: scaleX(1); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.lang-btn { font: inherit; font-weight: 700; font-size: .85rem; width: 44px; height: 38px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; color: var(--blue); cursor: pointer; transition: border-color .2s, background .2s; }
.lang-btn:hover { border-color: var(--cyan); background: var(--cyan-soft); }
.menu-btn { display: none; width: 42px; height: 38px; border: 0; background: transparent; cursor: pointer; flex-direction: column; justify-content: center; gap: 5px; padding: 0 9px; }
.menu-btn span { height: 2px; background: var(--ink); border-radius: 2px; transition: transform .25s, opacity .25s; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; padding: 72px 0 96px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: -1; overflow: hidden; background: linear-gradient(180deg, #F2FBFC 0%, #fff 100%); }
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .45; }
.b1 { width: 460px; height: 460px; background: var(--cyan); top: -160px; inset-inline-end: -120px; animation: float 14s ease-in-out infinite; }
.b2 { width: 380px; height: 380px; background: #4FA3E8; bottom: -180px; inset-inline-start: -120px; opacity: .25; animation: float 18s ease-in-out infinite reverse; }
.hero-mark { position: absolute; width: 520px; opacity: .05; inset-inline-start: -80px; top: 40px; }
@keyframes float { 50% { transform: translate(30px, 40px) scale(1.06); } }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.5rem); letter-spacing: -.01em; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 54ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 40px; }
.status-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: .88rem; font-weight: 500; margin-bottom: 18px; box-shadow: 0 6px 18px -12px rgba(0, 60, 120, .4); }
.status-pill .dot { width: 9px; height: 9px; border-radius: 50%; background: #9AA8B6; }
.status-pill.open .dot { background: #19C37D; box-shadow: 0 0 0 0 rgba(25, 195, 125, .6); animation: pulse 2s infinite; }
.status-pill.closed .dot { background: #F0A33B; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(25, 195, 125, 0); } 100% { box-shadow: 0 0 0 0 rgba(25, 195, 125, 0); } }
.hero-stats { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 14px; }
.hero-stats li { flex: 1 1 150px; padding: 14px 16px; border-radius: 16px; background: rgba(255, 255, 255, .7); border: 1px solid var(--line); }
.hero-stats strong { display: block; font-size: 1.6rem; line-height: 1.1; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-stats span { font-size: .86rem; color: var(--muted); }
.hero-card { background: rgba(255, 255, 255, .78); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid rgba(255, 255, 255, .9); border-radius: 28px; padding: 34px; box-shadow: var(--shadow); }
.hero-logo { width: 72%; margin: 0 auto 26px; }
.hero-card-rows { display: grid; gap: 10px; }
.hero-card-rows div { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 14px; background: var(--tint); font-size: .93rem; }
.hero-card-rows span { color: var(--muted); }
.hero-card-rows strong { color: var(--navy); text-align: end; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-tint { background: var(--tint); }
.section-dark { background: radial-gradient(1200px 500px at 85% -10%, rgba(1, 207, 207, .22), transparent 60%), var(--navy); color: #fff; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 52px; }
.section-head h2, .doctor-copy h2, .book-copy h2, .hours-grid h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
.section-head p { color: var(--muted); }
.eyebrow { display: inline-block; font-size: .85rem; font-weight: 700; color: var(--blue-mid); background: var(--cyan-soft); padding: 4px 14px; border-radius: 999px; margin-bottom: 14px; }
.eyebrow-light { background: rgba(1, 207, 207, .15); color: var(--cyan); }
.muted-light { color: #A9BCD0; }

/* ---------- Service cards ---------- */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; max-width: 920px; margin-inline: auto; }
.card { position: relative; padding: 36px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); transition: transform .3s, box-shadow .3s, border-color .3s; }
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.card-featured { background: linear-gradient(#fff, #fff) padding-box, var(--grad) border-box; border: 1.5px solid transparent; }
.card-icon { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; background: var(--grad); color: #fff; margin-bottom: 22px; box-shadow: 0 10px 22px -10px rgba(0, 92, 177, .6); }
.card-icon svg { width: 28px; height: 28px; }
.card h3 { font-size: 1.35rem; }
.card p { color: var(--muted); }
.tag { position: absolute; top: 28px; inset-inline-end: 28px; font-size: .78rem; font-weight: 700; padding: 3px 12px; border-radius: 999px; background: var(--cyan-soft); color: var(--blue); }
.card-link { font-weight: 700; color: var(--blue); }
.card-link:hover { color: var(--cyan); }
html[dir="ltr"] .card-link { direction: ltr; }

/* ---------- Steps ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.step { position: relative; padding: 28px 24px; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); }
.step-n { display: inline-block; font-size: 2.2rem; font-weight: 700; line-height: 1; margin-bottom: 14px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.step h3 { font-size: 1.12rem; }
.step p { color: var(--muted); font-size: .95rem; margin: 0; }

/* ---------- Doctor ---------- */
.doctor { display: grid; grid-template-columns: .9fr 1.1fr; gap: 64px; align-items: center; }
.doctor-photo { position: relative; }
.doctor-placeholder, .doctor-photo > img { aspect-ratio: 4 / 5; border-radius: 32px; overflow: hidden; width: 100%; object-fit: cover; }
.doctor-placeholder { display: grid; place-items: center; background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, .35), transparent 50%), var(--grad); }
.doctor-placeholder img { width: 46%; filter: brightness(0) invert(1); opacity: .9; }
.exp-badge { position: absolute; bottom: 28px; inset-inline-end: -22px; background: #fff; border-radius: 20px; padding: 14px 22px; box-shadow: var(--shadow); text-align: center; }
.exp-badge strong { display: block; font-size: 2rem; line-height: 1; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.exp-badge span { font-size: .85rem; color: var(--muted); }
.doc-role { color: var(--blue-mid); font-weight: 500; margin-top: -.3em; }
.doctor-copy > p:not(.doc-role) { color: var(--muted); }
.checks { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 10px; }
.checks li { position: relative; padding-inline-start: 34px; font-weight: 500; }
.checks li::before { content: ""; position: absolute; inset-inline-start: 0; top: .35em; width: 22px; height: 22px; border-radius: 50%; background: var(--grad); }
.checks li::after { content: ""; position: absolute; inset-inline-start: 7px; top: calc(.35em + 6px); width: 8px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg); }

/* ---------- Hours ---------- */
.hours-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.hours-table { width: 100%; border-collapse: collapse; margin-top: 24px; }
.hours-table td { padding: 12px 4px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.hours-table td:last-child { text-align: end; color: #D5E3F0; }
.hours-table tr.today td { color: var(--cyan); font-weight: 700; }
.hours-table tr.off td:last-child { color: #F0A33B; }
.info-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.info-card { display: flex; align-items: center; gap: 14px; padding: 22px; border-radius: 20px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); transition: background .25s, transform .25s, border-color .25s; }
.info-card:hover { background: rgba(255, 255, 255, .11); transform: translateY(-3px); border-color: rgba(1, 207, 207, .5); }
.info-card svg { width: 26px; height: 26px; flex: none; color: var(--cyan); }
.info-card span { display: flex; flex-direction: column; line-height: 1.4; min-width: 0; }
.info-card small { color: #A9BCD0; }
.info-card strong { font-size: 1.02rem; overflow-wrap: anywhere; }
.info-card[hidden] { display: none; }

/* ---------- Booking ---------- */
.book { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: start; }
.book-copy > p { color: var(--muted); }
.book-form { background: #fff; border: 1px solid var(--line); border-radius: 28px; padding: 32px; box-shadow: var(--shadow); display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field label { font-weight: 500; font-size: .92rem; }
.field input, .field select, .field textarea { font: inherit; width: 100%; padding: .75em 1em; border: 1.5px solid var(--line); border-radius: 14px; background: var(--tint); color: var(--ink); transition: border-color .2s, background .2s, box-shadow .2s; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--cyan); background: #fff; box-shadow: 0 0 0 4px rgba(1, 207, 207, .15); }
.field .invalid { border-color: #E5484D; }
html[dir="rtl"] .field input[dir="ltr"] { text-align: right; }
.form-error { color: #E5484D; font-size: .9rem; margin: 0; min-height: 0; }
.form-error:empty { display: none; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 12px; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 0 24px; transition: border-color .25s, box-shadow .25s; }
.faq details[open] { border-color: rgba(1, 207, 207, .6); box-shadow: 0 10px 30px -22px rgba(0, 60, 120, .5); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 0; font-weight: 700; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--cyan-soft); color: var(--blue); font-size: 1.2rem; transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); padding-bottom: 20px; margin: 0; }

/* ---------- Footer ---------- */
.footer { background: #051A33; color: #B7C7D8; padding: 64px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer-logo { width: 160px; margin-bottom: 16px; }
.footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.footer-grid > div { display: flex; flex-direction: column; gap: 8px; }
.footer-grid a:hover { color: var(--cyan); }
.footer-bottom { margin-top: 44px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .08); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .85rem; color: #7F95AC; }

/* ---------- WhatsApp float ---------- */
.wa-float { position: fixed; bottom: 22px; inset-inline-end: 22px; z-index: 60; width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; background: #25D366; color: #fff; box-shadow: 0 12px 28px -8px rgba(37, 211, 102, .7); transition: transform .25s; }
.wa-float:hover { transform: scale(1.08); }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .blob, .status-pill.open .dot { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid, .doctor, .hours-grid, .book { grid-template-columns: 1fr; gap: 40px; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .doctor-photo { max-width: 420px; margin-inline: auto; width: 100%; }
  .exp-badge { inset-inline-end: 12px; }
}
@media (max-width: 860px) {
  .menu-btn { display: flex; }
  .nav-links { position: absolute; top: 72px; inset-inline: 0; flex-direction: column; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 16px 16px; box-shadow: 0 20px 30px -24px rgba(0, 40, 90, .5); transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; }
  .nav-links.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav-links a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .nav-links a:last-child { border-bottom: 0; }
  .nav-links a::after { display: none; }
}
@media (max-width: 640px) {
  .section { padding: 72px 0; }
  .hero { padding: 40px 0 72px; }
  .cards, .info-cards, .steps, .footer-grid, .field-row { grid-template-columns: 1fr; }
  .nav-actions .btn-sm { display: none; }
  .brand-text small { display: none; }
  .hero-card, .book-form, .card { padding: 24px; }
  .hero-cta .btn { flex: 1 1 100%; }
  .footer-bottom { flex-direction: column; }
}
