/* =====================================================================
   Public website: navbar, hero, home sections, page headers, footer.
   Loaded after style.css and Bootstrap, so these rules win.
   Booking is by WhatsApp (first) or phone: see templates/partials/book_buttons.html.
   ===================================================================== */

:root {
    /* Azimi brand: deep evergreen, muted gold, warm ivory (brand/logo).
       --brand and --brand-deep are background colours (navbar, hero, footer);
       --brand-ink is the evergreen used for text, links and borders, and it
       turns light in dark mode so it stays readable. */
    --brand: #1E3B33;
    --brand-dark: #142A23;
    --brand-deep: #10221C;
    --brand-ink: #24574A;
    --brand-soft: #E6EEE9;
    --accent: #C8A96A;
    --gold: #C8A96A;
    --gold-dark: #B3924F;
    --gold-ink: #14261F;
    /* the booking button is gold, so it stands out on evergreen and on ivory */
    --wa: #C8A96A;
    --wa-dark: #B3924F;

    --surface: #F6F2EC;
    --card: #FFFFFF;
    --ink: #17241F;
    --muted: #5C6964;
    --line: #E0D9CE;
    --shadow: 0 10px 30px rgba(20, 42, 35, 0.08);
    --radius: 18px;

    --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --font-script: "Dancing Script", cursive;

    /* the older stylesheets read these */
    --primary-color: #F6F2EC;
    --inverse-primary-color: #17241F;
}

html[lang="fa"] {
    --font: "Vazirmatn", Tanha, Tahoma, sans-serif;
    --font-script: "Vazirmatn", Tanha, sans-serif;
}

html.dark-mood {
    --surface: #0E1714;
    --card: #15221E;
    --ink: #E8EEEA;
    --muted: #9DAEA7;
    --line: #253731;
    --brand-ink: #8CCBB1;
    --brand-soft: #1A3129;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    --primary-color: #0E1714;
    --inverse-primary-color: #E8EEEA;
    --secondary-color: #9DAEA7;
    color-scheme: dark;
}

* {
    font-family: var(--font);
}

.fa, .fa-solid, .fas, .fa-regular, .far {
    font-family: "Font Awesome 6 Free";
}

.fa-brands, .fab {
    font-family: "Font Awesome 6 Brands";
}

html {
    overflow-x: clip;
}

body {
    background: var(--surface);
    color: var(--ink);
    line-height: 1.6;
}

img {
    max-width: 100%;
}

.site-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.tabular {
    font-variant-numeric: tabular-nums;
}

/* ---------- Buttons ---------- */
.btn-wa,
.btn-call,
.btn-soft {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.8rem 1.4rem;
    border-radius: 999px;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-decoration: none;
    border: 2px solid transparent;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
    white-space: nowrap;
}

.btn-wa {
    background: var(--wa);
    color: var(--gold-ink);
    box-shadow: 0 8px 20px rgba(168, 138, 79, 0.3);
}

.btn-wa:hover,
.btn-wa:focus-visible {
    background: var(--wa-dark);
    color: var(--gold-ink);
    transform: translateY(-1px);
}

.btn-wa i {
    font-size: 1.3em;
}

.btn-call {
    background: transparent;
    color: var(--brand-ink);
    border-color: var(--brand-ink);
}

.btn-call:hover,
.btn-call:focus-visible {
    background: var(--brand);
    color: #fff;
}

.on-dark .btn-call {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.7);
}

.on-dark .btn-call:hover {
    background: #fff;
    color: var(--brand-dark);
}

.btn-soft {
    background: var(--brand-soft);
    color: var(--brand-ink);
}

.btn-soft:hover {
    background: var(--brand);
    color: #fff;
}

.btn-sm-pill {
    white-space: nowrap;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.book-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
}

.book-buttons.is-center {
    justify-content: center;
}

.book-note {
    width: 100%;
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: var(--muted);
}

.on-dark .book-note {
    color: rgba(255, 255, 255, 0.85);
}

.book-buttons.is-center .book-note {
    text-align: center;
}

/* ---------- Navbar ---------- */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--brand);
    box-shadow: 0 4px 18px rgba(15, 30, 25, 0.18);
}

.site-nav .nav-inner {
    max-width: 1360px;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-height: 72px;
}

.nav-brand img {
    height: 48px;
    width: auto;
    display: block;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-inline-start: auto;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.88);
    text-decoration: none;
    font-weight: 500;
    white-space: nowrap;
    padding: 0.5rem 0.8rem;
    border-radius: 999px;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-links a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
}

.nav-links a.is-active {
    color: var(--brand-dark);
    background: #fff;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-inline-start: 0.75rem;
}

.nav-icon {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.nav-icon:hover {
    background: rgba(255, 255, 255, 0.24);
    color: #fff;
}

/* Log out is a small form (POST), laid out like the icon links beside it. */
.nav-logout {
    display: contents;
}

.nav-lang select {
    appearance: none;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 0.5rem 0.9rem;
    font-weight: 500;
    cursor: pointer;
}

.nav-lang select option {
    color: #14202e;
}

.nav-login {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    white-space: nowrap;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    border: 1.5px solid rgba(255, 255, 255, 0.6);
}

.nav-login:hover {
    background: #fff;
    color: var(--brand-dark);
}

.nav-toggle {
    display: none;
    margin-inline-start: auto;
}

@media (max-width: 1180px) {
    .nav-toggle {
        display: inline-flex;
    }

    .nav-menu {
        position: absolute;
        inset-inline: 0;
        top: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 1rem 20px 1.5rem;
        background: var(--brand);
        box-shadow: 0 18px 30px rgba(15, 30, 25, 0.25);
        display: none;
    }

    .site-nav.is-open .nav-menu {
        display: flex;
    }

    .nav-links {
        flex-direction: column;
        align-items: stretch;
    }

    .nav-links a {
        padding: 0.75rem 1rem;
        border-radius: 12px;
    }

    .nav-actions {
        margin: 0;
        flex-wrap: wrap;
    }
}

/* ---------- Home hero ---------- */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: min(78vh, 720px);
    padding: 4rem 0;
    color: #fff;
    background-color: var(--brand);
    background-image: linear-gradient(90deg, rgba(20, 42, 35, 0.95) 0%, rgba(30, 59, 51, 0.75) 45%, rgba(30, 59, 51, 0) 75%), var(--hero-img);
    background-size: cover;
    background-position: right center;
    overflow: hidden;
}

html[dir="rtl"] .hero {
    background-image: linear-gradient(270deg, rgba(20, 42, 35, 0.95) 0%, rgba(30, 59, 51, 0.75) 45%, rgba(30, 59, 51, 0) 75%), var(--hero-img);
    background-position: left center;
}

.hero-content {
    max-width: 600px;
}

.hero-eyebrow {
    display: inline-block;
    padding: 0.35rem 0.9rem;
    margin-bottom: 1.25rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.04em;
}

.hero h1 {
    font-size: clamp(2.3rem, 5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.12;
    margin: 0 0 1rem;
    color: #fff;
}

.hero-lead {
    font-size: clamp(1.15rem, 2.2vw, 1.5rem);
    margin: 0 0 2rem;
    color: rgba(255, 255, 255, 0.92);
}

.hero-lead span {
    color: var(--gold);
    font-family: var(--font-script);
    font-weight: 700;
    font-size: 1.25em;
}

.hero .social-links {
    margin-top: 2rem;
}

@media (max-width: 760px) {
    .hero,
    html[dir="rtl"] .hero {
        min-height: auto;
        padding: 3rem 0 3.5rem;
        background-image: linear-gradient(180deg, rgba(20, 42, 35, 0.92) 0%, rgba(30, 59, 51, 0.88) 100%), var(--hero-img);
        background-position: center;
    }
}

/* ---------- Social links ---------- */
.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.social-links.is-center {
    justify-content: center;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.1rem;
    text-decoration: none;
    color: #fff;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.35);
    transition: background-color 0.2s ease, color 0.2s ease;
}

.social-links a:hover {
    background: #fff;
    color: var(--brand-ink);
}

/* ---------- Sections ---------- */
.section {
    padding: 5rem 0;
}

.section-alt {
    background: var(--card);
}

.section-head {
    max-width: 680px;
    margin: 0 auto 3rem;
    text-align: center;
}

.section-eyebrow {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--brand-ink);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

html[lang="fa"] .section-eyebrow {
    letter-spacing: 0;
}

.section-head h2,
.section-title {
    font-size: clamp(1.75rem, 3.5vw, 2.4rem);
    font-weight: 700;
    line-height: 1.25;
    color: var(--ink);
    margin: 0;
}

.section-head p {
    margin: 0.9rem 0 0;
    color: var(--muted);
}

/* About the doctor */
.split {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 3.5rem;
    align-items: center;
}

.split-media {
    position: relative;
}

.split-media img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.split-media::before {
    content: "";
    position: absolute;
    inset: 24px -24px -24px 24px;
    border-radius: 24px;
    background: var(--brand-soft);
    z-index: -1;
}

html[dir="rtl"] .split-media::before {
    inset: 24px 24px -24px -24px;
}

.split-body p {
    color: var(--muted);
    font-size: 1.05rem;
    margin: 1rem 0 1.75rem;
}

.check-list {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem;
    display: grid;
    gap: 0.6rem;
}

.check-list li {
    display: flex;
    gap: 0.65rem;
    align-items: baseline;
}

.check-list i {
    color: var(--accent);
}

@media (max-width: 900px) {
    .split {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .split-media {
        max-width: 420px;
        margin: 0 auto;
    }
}

/* Service cards */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.5rem;
}

.card-grid.is-fit {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.svc-card {
    display: flex;
    flex-direction: column;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.svc-card:hover {
    transform: translateY(-4px);
}

.svc-media {
    position: relative;
    aspect-ratio: 4 / 3;
    background: var(--brand-soft);
}

.svc-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.svc-media .svc-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--brand-ink);
}

.svc-price {
    position: absolute;
    top: 12px;
    inset-inline-end: 12px;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--brand-dark);
    font-weight: 700;
    font-size: 0.85rem;
}

.svc-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 1.25rem 1.35rem 1.4rem;
}

.svc-body h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--ink);
}

.svc-body p {
    color: var(--muted);
    font-size: 0.95rem;
    margin: 0 0 1.25rem;
    flex: 1;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--brand-ink);
    font-weight: 600;
    text-decoration: none;
}

.text-link:hover {
    color: var(--brand-dark);
    gap: 0.6rem;
}

html[dir="rtl"] .text-link .fa-arrow-right-long {
    transform: scaleX(-1);
}

/* Experience band */
.band {
    background: linear-gradient(135deg, var(--brand-dark), var(--brand));
    color: #fff;
}

.band .section-eyebrow {
    color: var(--gold);
}

.band .section-title {
    color: #fff;
}

.band p {
    color: rgba(255, 255, 255, 0.88);
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.stat {
    padding: 1.25rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.stat strong {
    display: block;
    font-size: 2.2rem;
    line-height: 1.1;
    font-weight: 700;
}

.stat span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.85);
}

.photo-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: start;
}

.photo-pair img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.25);
}

.photo-pair img:last-child {
    margin-top: 2.5rem;
}

/* Feature cards */
.feature {
    padding: 1.75rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.feature-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 1rem;
    border-radius: 14px;
    background: var(--brand-soft);
    color: var(--brand-ink);
    font-size: 1.35rem;
}

.feature h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 0.35rem;
    color: var(--ink);
}

.feature p {
    margin: 0;
    color: var(--muted);
}

/* Videos */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    max-width: 960px;
    margin: 0 auto;
}

.video-grid .video-card {
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.video-grid .video-card-image-container {
    position: relative;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    border-radius: 0;
    cursor: pointer;
    overflow: hidden;
    background: #000;
}

.video-grid .video-card-image-container img,
.video-grid .video-card-image-container iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 0;
    display: block;
}

.video-play {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.95);
    color: var(--brand-ink);
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-inline-start: 4px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}

.video-card-image-container:hover .video-play {
    transform: scale(1.08);
}

/* Booking call-to-action band */
.cta {
    position: relative;
    padding: 3rem;
    border-radius: 28px;
    background: linear-gradient(135deg, var(--brand-dark), var(--brand));
    color: #fff;
    text-align: center;
    overflow: hidden;
}

.cta h2 {
    color: #fff;
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 700;
    margin: 0 0 0.6rem;
}

.cta p {
    max-width: 560px;
    margin: 0 auto 1.75rem;
    color: rgba(255, 255, 255, 0.9);
}

@media (max-width: 600px) {
    .section {
        padding: 3.5rem 0;
    }

    .cta {
        padding: 2.25rem 1.25rem;
    }

    .photo-pair img:last-child {
        margin-top: 1.5rem;
    }
}

/* ---------- Inner page header (About, Before & After, Contact) ---------- */
#page-header {
    position: relative;
    height: auto;
    min-height: 300px;
    padding: 4rem 20px;
    align-items: center;
    background-color: var(--brand);
    background-position: center;
    background-size: cover;
}

#page-header::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(20, 42, 35, 0.55), rgba(20, 42, 35, 0.75));
}

#page-header > * {
    position: relative;
}

#page-header h2 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    color: #fff;
    margin: 0 0 0.5rem;
}

#page-header p {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 1.5rem;
}

#page-header .social-links a {
    width: 42px;
    height: 42px;
    margin: 0;
    font-size: 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.35);
}

/* ---------- Before & After ---------- */
.results-grid .modern-card {
    background: var(--card);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.results-grid .card-body h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 0.35rem;
}

.results-grid .card-body {
    padding: 1.1rem 1.25rem 1.3rem;
}

.results-grid .card-meta {
    color: var(--muted);
    font-size: 0.9rem;
}

.empty-state {
    max-width: 520px;
    margin: 2rem auto 0;
    padding: 2.5rem 1.5rem;
    text-align: center;
    background: var(--card);
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    color: var(--muted);
}

.empty-state i {
    font-size: 2rem;
    color: var(--brand-ink);
    margin-bottom: 0.75rem;
}

.pager {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 2.5rem;
}

.pager a,
.pager span {
    min-width: 42px;
    height: 42px;
    padding: 0 0.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    background: var(--card);
    border: 1px solid var(--line);
    color: var(--ink);
}

.pager .is-current {
    background: var(--brand);
    border-color: var(--brand-ink);
    color: #fff;
}

/* ---------- Book-by-WhatsApp page ---------- */
.book-page {
    max-width: 640px;
    margin: 0 auto;
    padding: 4rem 20px 5rem;
    text-align: center;
}

.book-card {
    padding: 2.5rem 1.75rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.book-card .book-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(168, 138, 79, 0.12);
    color: var(--wa);
    font-size: 2.2rem;
}

.book-card h1 {
    font-size: clamp(1.6rem, 4vw, 2.1rem);
    font-weight: 700;
    margin: 0 0 0.75rem;
}

.book-card > p {
    color: var(--muted);
    margin: 0 0 1.75rem;
}

.book-steps {
    list-style: none;
    padding: 0;
    margin: 2rem 0 0;
    display: grid;
    gap: 0.75rem;
    text-align: start;
}

.book-steps li {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
    color: var(--muted);
}

.book-steps b {
    flex: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--brand-soft);
    color: var(--brand-ink);
    font-size: 0.85rem;
}

/* ---------- Floating WhatsApp button ---------- */
.wa-float {
    position: fixed;
    bottom: 22px;
    inset-inline-end: 22px;
    z-index: 990;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--wa);
    color: var(--gold-ink);
    font-size: 1.8rem;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.wa-float:hover {
    color: var(--gold-ink);
    background: var(--wa-dark);
    transform: scale(1.06);
}

/* ---------- Footer ---------- */
.site-footer {
    display: block;
    margin-top: 0;
    padding: 4rem 0 0;
    background: var(--brand-deep);
    color: rgba(255, 255, 255, 0.82);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.3fr 1.2fr 0.8fr;
    gap: 2.5rem;
}

.site-footer .logo {
    height: 52px;
    width: auto;
    margin-bottom: 1rem;
}

.footer-tagline {
    font-family: var(--font-script);
    font-size: 1.9rem;
    line-height: 1.2;
    color: #fff;
    margin: 0 0 1.5rem;
}

.footer-tagline span {
    color: var(--gold);
    font-family: inherit;
}

.site-footer h4 {
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 1.1rem;
}

.footer-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 0.8rem;
}

.footer-list li {
    display: flex;
    gap: 0.75rem;
    align-items: baseline;
}

.footer-list i {
    width: 1.1rem;
    flex: none;
    color: var(--accent);
}

.site-footer a {
    color: rgba(255, 255, 255, 0.82);
    text-decoration: none;
}

.site-footer a:hover {
    color: #fff;
    text-decoration: underline;
}

.footer-bottom {
    margin-top: 3rem;
    padding: 1.25rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.875rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
}

@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .footer-grid > :first-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 560px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* Messages under the navbar */
.site-messages .alert {
    margin: 0;
    border-radius: 0;
    text-align: center;
}

/* ---------- Contact page ---------- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 2rem;
    align-items: stretch;
}

.contact-card {
    padding: 2.25rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.contact-card .section-title {
    margin-bottom: 0.75rem;
}

.text-muted-site {
    color: var(--muted);
    margin: 0 0 1.5rem;
}

.contact-list {
    margin-top: 2rem;
    color: var(--ink);
}

.contact-list a {
    color: var(--brand-ink);
    text-decoration: none;
}

.contact-map {
    min-height: 360px;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.contact-map iframe {
    width: 100%;
    height: 100%;
    min-height: 360px;
    border: 0;
    display: block;
}

/* No branch has a map: the contact card takes the whole width. */
.contact-grid.is-single {
    grid-template-columns: 1fr;
}

/* More than one branch with a map: name buttons above the map switch it. */
.contact-map.has-tabs {
    display: flex;
    flex-direction: column;
    background: var(--surface);
}

.contact-map.has-tabs iframe {
    flex: 1;
}

.branch-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem;
}

.branch-tabs .chip {
    cursor: pointer;
}

.contact-list .branch-line small {
    color: var(--muted);
}

@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

.inquiry-form {
    max-width: 820px;
    margin: 0 auto;
    padding: 2rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.inquiry-form .form-label {
    font-weight: 600;
    color: var(--ink);
}

.inquiry-form .form-control {
    padding: 0.75rem 1rem;
    border-radius: 12px;
    border-color: var(--line);
    background: var(--card);
    color: var(--ink);
}

.inquiry-form .form-control:focus {
    border-color: var(--brand-ink);
    box-shadow: 0 0 0 3px rgba(30, 59, 51, 0.15);
}

.inquiry-form textarea.form-control {
    min-height: 140px;
}

.field-error {
    margin-top: 0.35rem;
    color: #c62828;
    font-size: 0.875rem;
}

@media (max-width: 600px) {
    .inquiry-form {
        padding: 1.25rem;
    }
}

/* ---------- Wave under the hero and page headers ----------
   The clinic's wave image is used as a mask and filled with the page
   background colour, so the hero flows into the page in light and dark mode. */
.wave-divider {
    position: absolute;
    inset-inline: 0;
    bottom: -1px;
    height: 90px;
    pointer-events: none;
    overflow: hidden;
    z-index: 1;
}

.wave-divider span {
    position: absolute;
    inset: 0;
    background: var(--surface);
    -webkit-mask-image: url("../images/hero/wave.png");
    mask-image: url("../images/hero/wave.png");
    -webkit-mask-size: 1000px 100%;
    mask-size: 1000px 100%;
    -webkit-mask-repeat: repeat-x;
    mask-repeat: repeat-x;
    -webkit-mask-position: 0 bottom;
    mask-position: 0 bottom;
    animation: wave-flow 22s linear infinite;
}

.wave-divider span:nth-child(1) {
    opacity: 0.3;
    bottom: 22px;
    animation-duration: 16s;
    animation-direction: reverse;
}

.wave-divider span:nth-child(2) {
    opacity: 0.55;
    bottom: 10px;
    animation-duration: 26s;
}

.wave-divider span:nth-child(3) {
    opacity: 1;
    animation-duration: 20s;
    animation-direction: reverse;
}

@keyframes wave-flow {
    from {
        -webkit-mask-position: 0 bottom;
        mask-position: 0 bottom;
    }

    to {
        -webkit-mask-position: 1000px bottom;
        mask-position: 1000px bottom;
    }
}

@media (prefers-reduced-motion: reduce) {
    .wave-divider span {
        animation: none;
    }
}

.hero {
    padding-bottom: 7rem;
}

#page-header {
    padding-bottom: 6rem;
    overflow: hidden;
}

#page-header > .wave-divider {
    position: absolute;
}

@media (max-width: 600px) {
    .wave-divider {
        height: 60px;
    }

    .wave-divider span {
        -webkit-mask-size: 700px 100%;
        mask-size: 700px 100%;
    }
}

/* ---------- Before & After: filter card and results ---------- */
.filter-card {
    max-width: 880px;
    margin: 0 auto 2.5rem;
    padding: 1.5rem 1.75rem;
    display: grid;
    gap: 1.25rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 22px;
    box-shadow: var(--shadow);
}

.filter-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.filter-row + .filter-row {
    padding-top: 1.25rem;
    border-top: 1px solid var(--line);
}

.filter-title {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

html[lang="fa"] .filter-title {
    letter-spacing: 0;
}

.filter-title i {
    color: var(--brand-ink);
}

.segmented {
    display: inline-flex;
    padding: 4px;
    gap: 4px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--line);
}

.segmented a {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 1.15rem;
    border-radius: 999px;
    color: var(--ink);
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.segmented a:hover {
    background: var(--brand-soft);
    color: var(--brand-ink);
}

.segmented a.is-on {
    background: var(--brand);
    color: #fff;
    box-shadow: 0 4px 12px rgba(30, 59, 51, 0.3);
}

.chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.chip {
    padding: 0.45rem 1rem;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink);
    font-size: 0.92rem;
    font-weight: 500;
    text-decoration: none;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.chip:hover {
    border-color: var(--brand-ink);
    color: var(--brand-ink);
}

.chip.is-on {
    background: var(--brand);
    border-color: var(--brand-ink);
    color: #fff;
}

@media (max-width: 480px) {
    .filter-card {
        padding: 1.25rem 1rem;
    }

    .segmented a {
        padding: 0.5rem 0.8rem;
        font-size: 0.92rem;
    }
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.result-card {
    display: flex;
    flex-direction: column;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    color: var(--ink);
    text-decoration: none;
    transition: transform 0.25s ease;
}

.result-card:hover {
    transform: translateY(-4px);
    color: var(--ink);
}

.result-media {
    position: relative;
    aspect-ratio: 4 / 3;
    background: var(--brand-soft);
}

.result-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.result-badge {
    position: absolute;
    top: 12px;
    inset-inline-start: 12px;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--brand-dark);
    font-size: 0.8rem;
    font-weight: 700;
}

.result-body {
    display: grid;
    gap: 0.35rem;
    padding: 1.1rem 1.25rem 1.3rem;
}

.result-body h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
}

.result-meta {
    display: inline-flex;
    gap: 0.4rem;
    align-items: center;
    color: var(--muted);
    font-size: 0.9rem;
}

/* ---------- About page ----------
   Light mode uses only light backgrounds, dark mode only dark ones:
   every colour below is a theme token. */
.immersive-details,
.immersive-section,
.membership-activity-section {
    padding: 5rem 0;
    background: var(--surface);
    color: var(--ink);
}

.about-alt {
    background: var(--card) !important;
}

.detail-block {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.detail-block.reverse .detail-image {
    order: 0;
}

.detail-image {
    position: relative;
}

.detail-image img {
    position: relative;
    z-index: 1;
    width: 100%;
    max-height: 520px;
    object-fit: cover;
    border-radius: 22px;
    box-shadow: var(--shadow);
}

.image-accent-overlay,
.image-accent-overlay-right {
    position: absolute;
    inset: 0;
    border: 2px solid var(--brand);
    border-radius: 22px;
    opacity: 0.35;
    pointer-events: none;
    transform: translate(-18px, -18px);
}

.image-accent-overlay-right {
    transform: translate(18px, 18px);
}

.detail-label {
    display: block;
    margin-bottom: 0.6rem;
    color: var(--brand-ink);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

html[lang="fa"] .detail-label {
    letter-spacing: 0;
}

.detail-title {
    margin: 0 0 1rem;
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 700;
    line-height: 1.25;
    color: var(--ink);
}

.detail-text,
.detail-text-small,
.activity-desc,
.cert-info p {
    color: var(--muted);
    line-height: 1.75;
}

.detail-text {
    font-size: 1.05rem;
    margin: 0 0 1.5rem;
}

.detail-text-small {
    margin: 1.25rem 0 0;
}

.detail-text.italic {
    font-style: italic;
}

.article-title {
    font-style: normal;
    font-weight: 600;
    color: var(--ink);
}

.detail-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 0.6rem;
}

.detail-list li {
    display: flex;
    gap: 0.6rem;
    align-items: baseline;
    color: var(--ink);
}

.detail-list i {
    color: var(--accent);
}

.trust-badge,
.location-item {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.7rem 1rem;
    border-radius: 14px;
    background: var(--brand-soft);
    color: var(--ink);
    font-weight: 500;
}

.trust-badge i,
.location-item i {
    color: var(--brand-ink);
}

.training-locations {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.research-status {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.status-tag {
    padding: 0.35rem 0.9rem;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--ink);
    font-size: 0.85rem;
    font-weight: 600;
}

.publication-highlight {
    padding: 1.25rem 1.4rem;
    margin-bottom: 1.25rem;
    border-inline-start: 4px solid var(--brand-ink);
    border-radius: 12px;
    background: var(--surface);
}

.about-alt .publication-highlight {
    background: var(--surface);
}

.publication-highlight .detail-text {
    margin: 0;
}

/* Publications list */
.immersive-header {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 2rem;
}

.section-number {
    color: var(--brand-ink);
    font-weight: 700;
    font-size: 1rem;
}

.huge-title,
.main-title {
    margin: 0 0 2rem;
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 700;
    line-height: 1.2;
    color: var(--ink);
}

.immersive-header .huge-title {
    margin: 0;
}

.publication-giant-list {
    display: grid;
    gap: 1rem;
}

.pub-entry {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.25rem 1.25rem;
    padding: 1.25rem 1.4rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.pub-entry:hover {
    border-color: var(--brand-ink);
    transform: translateY(-2px);
}

.pub-date {
    grid-row: span 2;
    align-self: start;
    padding: 0.3rem 0.7rem;
    border-radius: 10px;
    background: var(--brand-soft);
    color: var(--brand-ink);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.pub-link {
    color: var(--ink);
    font-weight: 600;
    font-size: 1.05rem;
    text-decoration: none;
}

.pub-link:hover {
    color: var(--brand-ink);
}

.pub-journal {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
}

/* Experience */
.experience-counter-box {
    margin: 0.5rem 0 1.5rem;
}

.experience-counter {
    display: block;
    font-size: clamp(3rem, 7vw, 4.5rem);
    font-weight: 800;
    line-height: 1;
    color: var(--brand-ink);
}

.stat-desc {
    margin: 0.4rem 0 0;
    color: var(--muted);
}

.procedure-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.procedure-grid span {
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    background: var(--brand-soft);
    color: var(--ink);
    font-size: 0.9rem;
    font-weight: 500;
}

/* Certifications */
.certification-path {
    display: grid;
    gap: 1rem;
    margin-top: 1.5rem;
}

.cert-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--card);
}

.cert-icon {
    flex: none;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--brand);
    color: #fff;
    font-weight: 800;
}

.cert-info h4 {
    margin: 0 0 0.15rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--ink);
}

.cert-info p {
    margin: 0;
}

/* Memberships */
.activity-list {
    position: relative;
    padding-inline-start: 2rem;
    border-inline-start: 2px solid var(--line);
}

.activity-item {
    position: relative;
    margin-bottom: 2.5rem;
}

.activity-item::before {
    content: "";
    position: absolute;
    top: 0.35rem;
    inset-inline-start: calc(-2rem - 9px);
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--card);
    border: 3px solid var(--brand);
}

.activity-subtitle,
.achievement-subtitle {
    margin: 0 0 0.4rem;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ink);
}

.activity-media {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: flex-start;
    margin-top: 1.25rem;
}

.activity-img {
    max-width: 460px;
    width: 100%;
    border-radius: 14px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.activity-logo {
    height: 80px;
    width: auto;
    border-radius: 12px;
    background: #fff;
    padding: 6px;
}

@media (max-width: 900px) {
    .detail-block {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .detail-block .detail-image {
        order: -1;
        max-width: 520px;
        margin: 0 auto;
        width: 100%;
    }

    .image-accent-overlay,
    .image-accent-overlay-right {
        display: none;
    }

    .immersive-details,
    .immersive-section,
    .membership-activity-section {
        padding: 3.5rem 0;
    }
}

@media (max-width: 520px) {
    .pub-entry {
        grid-template-columns: 1fr;
    }

    .pub-date {
        grid-row: auto;
        justify-self: start;
    }
}

/* ---------- Service detail ---------- */
.svc-detail {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 3rem;
    align-items: start;
    padding: 2rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.svc-detail-media {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: 18px;
    overflow: hidden;
    background: var(--brand-soft);
}

.svc-detail-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.svc-detail-media .svc-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--brand-ink);
}

.svc-facts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.svc-facts > div {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0 0.75rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: var(--surface);
    border: 1px solid var(--line);
}

.svc-facts i {
    grid-row: span 2;
    align-self: center;
    color: var(--brand-ink);
    font-size: 1.2rem;
}

.svc-facts span {
    font-size: 0.82rem;
    color: var(--muted);
}

.svc-facts strong {
    color: var(--ink);
}

.svc-subtitle {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--ink);
}

.svc-text {
    color: var(--muted);
    margin-bottom: 1.75rem;
}

.msg-header .form-icon {
    font-weight: 700;
}

@media (max-width: 900px) {
    .svc-detail {
        grid-template-columns: 1fr;
        gap: 1.75rem;
        padding: 1.25rem;
    }
}

/* Long slogans (Farsi) must wrap inside the footer column on phones */
.footer-grid > * {
    min-width: 0;
}

.footer-tagline {
    font-size: clamp(1.4rem, 5vw, 1.9rem);
    overflow-wrap: anywhere;
}

/* Live lists (static/js/live-lists.js) */
[data-live].is-loading .results-grid,
[data-live].is-loading .empty-state {
    opacity: 0.45;
    transition: opacity 0.15s ease;
    pointer-events: none;
}

/* ---------- Animated blob (static/styles/components/blob.css) ---------- */
.hero .site-container {
    position: relative;
    z-index: 2;
}

.hero .hero-blob {
    top: 14%;
    inset-inline-start: 20%;
    margin: 0;
    width: 380px;
    height: 380px;
    z-index: 0;
    mix-blend-mode: screen;
    opacity: 0.75;
}

#form-section.has-blobs {
    overflow: hidden;
}

#form-section .auth-blob {
    margin: 0;
    top: 8%;
    inset-inline-start: 12%;
    width: 360px;
    height: 360px;
    z-index: 0;
    mix-blend-mode: normal;
    opacity: 0.35;
    filter: blur(6px);
}

#form-section .auth-blob.is-second {
    top: auto;
    bottom: 4%;
    inset-inline-start: auto;
    inset-inline-end: 10%;
    width: 300px;
    height: 300px;
    animation-delay: -45s;
    animation-direction: reverse;
}

html.dark-mood #form-section .auth-blob {
    opacity: 0.25;
}

#form-section.has-blobs .form-card {
    z-index: 1;
}

@media (max-width: 650px) {
    .hero .hero-blob {
        width: 200px;
        height: 200px;
        opacity: 0.45;
    }

    #form-section .auth-blob {
        width: 200px;
        height: 200px;
    }

    #form-section .auth-blob.is-second {
        width: 170px;
        height: 170px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .blob-rotate {
        animation: none;
    }
}

/* ---------- About: research cards with the first page ---------- */
.pub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(440px, 1fr));
    gap: 1.25rem;
}

.pub-card {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 1.25rem;
    padding: 1.1rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 18px;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.pub-card:hover {
    border-color: var(--brand-ink);
    transform: translateY(-2px);
}

.pub-page {
    display: block;
    aspect-ratio: 3 / 4;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: 0 6px 16px rgba(10, 37, 64, 0.12);
}

.pub-page img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

.pub-page-blank {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    background: var(--brand-soft);
    color: var(--brand-ink);
}

.pub-page-blank i {
    font-size: 2rem;
}

.pub-card-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.45rem;
    min-width: 0;
}

.pub-card-body .pub-date {
    grid-row: auto;
}

.pub-summary {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.6;
}

.pub-card-body .text-link {
    margin-top: auto;
    font-size: 0.92rem;
}

@media (max-width: 560px) {
    .pub-grid {
        grid-template-columns: 1fr;
    }

    .pub-card {
        grid-template-columns: 92px 1fr;
        gap: 0.9rem;
        padding: 0.9rem;
    }
}

/* ---------- Wave: seamless loop at every screen size ----------
   Each animation moves the wave by exactly one image width, so the end of a
   loop lines up with its start. On phones the image is 700px wide, so the
   phone animation moves 700px (it used to move 1000px and visibly jumped). */
@media (max-width: 600px) {
    .wave-divider span {
        -webkit-mask-size: 700px 100%;
        mask-size: 700px 100%;
        animation-name: wave-flow-700;
    }
}

@keyframes wave-flow-700 {
    from {
        -webkit-mask-position: 0 bottom;
        mask-position: 0 bottom;
    }

    to {
        -webkit-mask-position: 700px bottom;
        mask-position: 700px bottom;
    }
}

/* ---------- Brand logo ---------- */
.nav-brand img {
    height: 46px;
    width: auto;
}

.site-footer .logo {
    height: 58px;
}

.auth-logo img {
    height: 64px;
    width: auto;
}

.logo-on-dark {
    display: none;
}

html.dark-mood .logo-on-light {
    display: none;
}

html.dark-mood .logo-on-dark {
    display: inline;
}

/* Soft blobs in brand colours: gold and sage instead of the old cyan and lime */
.hero .hero-blob,
#form-section .auth-blob {
    background: linear-gradient(180deg, rgba(200, 169, 106, 0.55) 20%, rgba(140, 203, 177, 0.45) 100%);
}

/* Old lime accents left in older stylesheets */
.check-list i,
.footer-list i,
.detail-list i {
    color: var(--gold);
}

/* Hero photo in brand tones: the photo's light and shade, coloured evergreen
   (a duotone), so the old blue tint in the image no longer clashes. */
.hero,
html[dir="rtl"] .hero {
    background-color: #2A5446;
    background-blend-mode: normal, luminosity;
}

@media (max-width: 760px) {
    .hero,
    html[dir="rtl"] .hero {
        background-blend-mode: normal, luminosity;
    }
}

.nav-brand img {
    height: 54px;
}

html[dir="rtl"] .btn-soft .fa-arrow-right-long {
    transform: scaleX(-1);
}

/* ---------- Booking page: online, or WhatsApp and phone ---------- */
.book-page { max-width: 860px; }
.book-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
    text-align: start;
}
.book-option {
    padding: 1.4rem;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--surface);
}
.book-option h2 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: var(--ink);
}
.book-option h2 i { color: var(--brand-ink); }
.book-option > p { color: var(--muted); font-size: 0.95rem; }
.book-option .book-buttons { justify-content: flex-start; }
.book-option-note { margin: 0.9rem 0 0; font-size: 0.85rem; color: var(--muted); }
.book-note a { color: inherit; font-weight: 600; }
@media (max-width: 700px) { .book-options { grid-template-columns: 1fr; } }

/* ---------- Blog ---------- */
html[dir="rtl"] .flip-rtl { transform: scaleX(-1); }
.blog-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 2rem; }
.blog-cats { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.blog-search { position: relative; flex: 0 1 280px; }
.blog-search i { position: absolute; top: 50%; inset-inline-start: 14px; transform: translateY(-50%); color: var(--muted); font-size: 0.9rem; }
.blog-search input { width: 100%; padding: 0.6rem 1rem; padding-inline-start: 2.4rem; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font: inherit; }
.blog-search input:focus { outline: 2px solid var(--brand-soft); border-color: var(--brand-ink); }
.blog-featured { display: grid; grid-template-columns: 1.2fr 1fr; gap: 0; margin-bottom: 2rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; color: var(--ink); transition: transform 0.25s ease; }
.blog-featured:hover { transform: translateY(-4px); }
.blog-featured-media { min-height: 280px; background: var(--brand-soft); position: relative; }
.blog-featured-media > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.blog-featured-body { padding: 2rem; display: flex; flex-direction: column; justify-content: center; }
.blog-featured-body h3 { font-size: clamp(1.4rem, 2.5vw, 1.9rem); font-weight: 700; margin: 0.25rem 0 0.75rem; }
.blog-featured-body p { color: var(--muted); margin: 0 0 1rem; }
.blog-card { text-decoration: none; color: var(--ink); }
.blog-card .svc-body p { margin-bottom: 0.9rem; }
.blog-cat { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--brand-ink); margin-bottom: 0.35rem; }
.blog-noimg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--brand-dark), var(--brand)); }
.blog-noimg img, .svc-media .blog-noimg img { position: static; width: 64px; height: 64px; object-fit: contain; opacity: 0.55; }
.blog-meta { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; font-size: 0.85rem; color: var(--muted); }
.blog-meta i { margin-inline-end: 0.35rem; }
.blog-empty { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.blog-empty i { font-size: 2.5rem; color: var(--brand-ink); margin-bottom: 1rem; }
.blog-preview-bar { position: sticky; top: 0; z-index: 20; padding: 0.7rem 20px; text-align: center; background: var(--gold); color: var(--gold-ink); font-weight: 600; }
.blog-preview-bar i { margin-inline-end: 0.4rem; }
.blog-preview-bar a { color: inherit; margin-inline-start: 0.5rem; }
.blog-article { padding: 3.5rem 0 1rem; }
.blog-article-head, .blog-body { max-width: 760px; }
.blog-article-head h1 { font-size: clamp(1.9rem, 4.5vw, 2.8rem); font-weight: 700; line-height: 1.2; margin: 0.6rem 0 0.9rem; color: var(--ink); }
.blog-eyebrow { display: block; margin-top: 1.5rem; text-decoration: none; }
.blog-lead { font-size: 1.15rem; color: var(--muted); margin: 0 0 1rem; }
.blog-cover { max-width: 1000px; margin: 2rem auto; }
.blog-cover img { width: 100%; max-height: 520px; object-fit: cover; border-radius: var(--radius); }
.blog-body { font-size: 1.07rem; line-height: 1.8; color: var(--ink); padding-top: 1rem; }
.blog-body h2 { font-size: 1.55rem; font-weight: 700; margin: 2.2rem 0 0.8rem; }
.blog-body h3 { font-size: 1.25rem; font-weight: 700; margin: 1.8rem 0 0.6rem; }
.blog-body p { margin: 0 0 1.2rem; }
.blog-body ul, .blog-body ol { margin: 0 0 1.2rem; padding-inline-start: 1.4rem; }
.blog-body li { margin-bottom: 0.4rem; }
.blog-body a { color: var(--brand-ink); text-decoration: underline; }
.blog-doctor { display: flex; align-items: center; gap: 1rem; margin: 2.5rem 0 1.5rem; padding: 1.1rem 1.25rem; border-radius: var(--radius); background: var(--brand-soft); line-height: 1.5; }
.blog-doctor a { color: var(--ink); text-decoration: none; }
.blog-doctor a:hover { text-decoration: underline; }
.blog-doctor .small { color: var(--muted); font-size: 0.85rem; }
.blog-doctor-avatar { flex: none; width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--brand); color: #fff; font-size: 1.2rem; }
.blog-note { font-size: 0.9rem; color: var(--muted); border-inline-start: 3px solid var(--gold); padding-inline-start: 0.9rem; }
.blog-note i { margin-inline-end: 0.4rem; color: var(--gold-dark); }
.blog-share { display: flex; align-items: center; gap: 0.5rem; margin: 1.5rem 0 0; }
.blog-share span { font-weight: 600; margin-inline-end: 0.4rem; }
.blog-share a, .blog-share button { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--brand-ink); text-decoration: none; cursor: pointer; }
.blog-share a:hover, .blog-share button:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.blog-share button.is-done { background: var(--brand); color: #fff; }
@media (max-width: 760px) {
    .blog-featured { grid-template-columns: 1fr; }
    .blog-featured-media { min-height: 200px; }
    .blog-featured-body { padding: 1.4rem; }
    .blog-search { flex-basis: 100%; }
}

/* Page heroes: the photo is set on each page (editable in Website content). */
#page-header.befor-header,
#page-header.contact-header,
#page-header.blog-header,
#page-header.about-header { background-position: center; }

/* ---------- Services ---------- */
.svc-link { text-decoration: none; color: var(--ink); }
.svc-link:hover h3 { color: var(--brand-ink); }
.svc-link .text-link { margin-top: auto; }

/* A picture for a service without a photo: its category colour, a soft pattern and an icon. */
.svc-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.14) 0 18%, transparent 19%),
        radial-gradient(circle at 85% 80%, rgba(200, 169, 106, 0.22) 0 24%, transparent 25%),
        radial-gradient(circle at 70% 15%, rgba(255, 255, 255, 0.08) 0 9%, transparent 10%),
        linear-gradient(135deg, var(--c1), var(--c2));
}
.svc-cover-icon {
    width: 92px;
    height: 92px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid rgba(200, 169, 106, 0.85);
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 2.4rem;
    box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.06);
}
.svc-detail-media .svc-cover-icon { width: 130px; height: 130px; font-size: 3.4rem; }
.cat-face { --c1: #142A23; --c2: #3D6B5C; }
.cat-eyes { --c1: #17312F; --c2: #4B7F86; }
.cat-nose { --c1: #1B2E27; --c2: #66784B; }
.cat-breast { --c1: #2F2529; --c2: #8A5D64; }
.cat-body { --c1: #252C24; --c2: #7A6A48; }
.cat-recon { --c1: #2E211B; --c2: #9A5F3C; }
.cat-inject { --c1: #182A33; --c2: #4F7A8C; }
.cat-hair { --c1: #1F2A1A; --c2: #6F8A46; }
.cat-consult { --c1: #142A23; --c2: #A88C55; }
.cat-other { --c1: #142A23; --c2: #1E3B33; }

#page-header.services-header {
    background-image:
        radial-gradient(circle at 15% 30%, rgba(200, 169, 106, 0.25) 0 14%, transparent 15%),
        radial-gradient(circle at 88% 70%, rgba(255, 255, 255, 0.1) 0 20%, transparent 21%),
        linear-gradient(135deg, var(--brand-dark), var(--brand));
}
.svc-jump {
    position: sticky;
    top: 80px;
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    margin-bottom: 2.5rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    backdrop-filter: blur(8px);
}
.svc-jump-n { margin-inline-start: 0.3rem; color: var(--muted); font-size: 0.8rem; }
.svc-group { margin-bottom: 3.5rem; scroll-margin-top: 150px; }
.svc-group-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: clamp(1.35rem, 2.5vw, 1.7rem);
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 1.25rem;
}
.svc-group-icon {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--c1), var(--c2));
}
@media (max-width: 760px) {
    .svc-jump { position: static; border-radius: var(--radius); justify-content: flex-start; }
}

/* Sections added in Website content (partials/page_section.html) */
.section-follow {
    padding-top: 0;
}

.page-section-head {
    margin-bottom: 0;
}

.page-section-text {
    white-space: normal;
}

.page-section-split.is-reversed {
    grid-template-columns: 1.1fr 1fr;
}

.page-section-split.is-reversed .split-media {
    order: 2;
}

.page-section-split .split-media img {
    aspect-ratio: 4 / 3;
}

.page-section-top {
    max-width: 880px;
    margin: 0 auto 2.5rem;
}

.page-section-top img,
.page-section-box .page-section-photo {
    display: block;
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.page-section-box .page-section-photo {
    max-width: 560px;
    max-height: 320px;
    margin: 0 auto 1.75rem;
}

.page-section-button {
    margin: 0 0 1rem;
}

.page-section-head .book-buttons,
.page-section-split .book-buttons {
    margin-top: 0.5rem;
}

.band.page-section .section-head h2 {
    color: #fff;
}

.band.page-section .btn-soft,
.page-section-box .btn-soft {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

@media (max-width: 900px) {
    .page-section-split.is-reversed {
        grid-template-columns: 1fr;
    }

    .page-section-split.is-reversed .split-media {
        order: 0;
    }
}

/* *word* highlights in added sections */
.page-section h2 span,
.page-section .page-section-text span {
    color: var(--brand-ink);
}

.page-section.on-dark h2 span,
.page-section.on-dark .page-section-text span,
.page-section-box h2 span,
.page-section-box p span {
    color: var(--gold);
}

/* Home: a short guide to every page */
.guide-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.guide-card {
    display: flex;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
    transition: transform 0.25s ease, border-color 0.25s ease;
}

.guide-card p {
    flex: 1;
    margin-bottom: 1rem;
}

.guide-card:hover,
.guide-card:focus-visible {
    transform: translateY(-4px);
    border-color: var(--brand);
    color: inherit;
}

@media (prefers-reduced-motion: reduce) {
    .guide-card,
    .guide-card:hover {
        transition: none;
        transform: none;
    }
}

/* Video cards with a title and text (partials/video_grid.html) */
.video-grid.is-wide {
    max-width: none;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.video-grid .video-card {
    display: flex;
    flex-direction: column;
}

.video-card-body {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    flex: 1;
    padding: 1.1rem 1.25rem 1.25rem;
}

.video-card-body h3 {
    margin: 0;
    font-size: 1.08rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--ink);
}

.video-card-body p {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.video-cat {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    align-self: flex-start;
    color: var(--brand-ink);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
}

html[lang="fa"] .video-cat {
    letter-spacing: 0;
}

.video-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1rem;
    margin-top: auto;
    padding-top: 0.4rem;
    font-size: 0.85rem;
    color: var(--muted);
}

.video-meta span,
.video-meta a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.video-meta a {
    color: var(--brand-ink);
    font-weight: 600;
    text-decoration: none;
}

.video-cat:hover,
.video-meta a:hover {
    text-decoration: underline;
}

.video-card-image-container:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: -3px;
}

.video-group-intro {
    margin: -0.5rem 0 1.5rem;
    color: var(--muted);
}

.video-cat-icon {
    background: var(--brand-soft);
    color: var(--brand-ink);
}
