/*
 * base.css — the shared design system behind every *designed* mini-site template
 * (atelier, marquee, bento, ledger, brutal, split, orbit, journey, postcard, index).
 *
 * Why this file exists: public/css/salon.css is the *panel* stylesheet and it also
 * wraps the public mini-site in a 760px column with 14px text. Inside that column
 * ten structurally different layouts all collapse into the same narrow stack, which
 * is exactly what a salon owner complained about. This sheet breaks the mini-site
 * out of the panel: a full-bleed wide shell, a real type scale, section rhythm,
 * bands, buttons and defaults for the shared section partials.
 *
 * Load order matters and is enforced by public/layout.blade.php:
 *   salon.css → (panel theme) → base.css → <template>.css → inline palette
 * so a template can always re-skin anything defined here, and the owner's colours
 * always win over both.
 *
 * Scope: every rule is gated on `.ms` (a salon that picked a designed template) and,
 * where the composition must not leak into the booking/account pages, on
 * `.ms.is-home`. `classic` never loads this file and cannot regress.
 */

/* ── 1. Token contract ─────────────────────────────────────────────────────
 * A template stylesheet may override any of these on `body.tpl-<key>`; because
 * `body.tpl-x` (0,1,1) outranks `:root` (0,1,0) a template can re-declare the
 * rhythm, container or radius without fighting specificity anywhere else.
 *
 * The colours and faces below are different: they are declared on
 * `.public-shell.ms`, a *descendant* of <body>, because they are derived from
 * the owner's `--tpl-*` palette. A template alias that reads them —
 * `body.tpl-x { --x-hair: color-mix(… var(--ms-accent) …) }` — is therefore
 * invalid at computed-value time and resolves to nothing. A template that
 * wants such an alias must declare it on the shell too:
 *     body.tpl-x, body.tpl-x .public-shell.ms { --x-hair: … }
 */
:root {
    --ms-maxw: 1200px;
    --ms-narrow: 760px;
    --ms-gutter: clamp(18px, 4.4vw, 46px);
    --ms-rhythm: clamp(58px, 8.5vw, 120px);
    --ms-gap: clamp(16px, 2.2vw, 26px);
    --ms-radius: 22px;
    --ms-radius-sm: 14px;
    --ms-ease: cubic-bezier(.22, .61, .36, 1);
    --ms-hero: clamp(440px, 76vh, 760px);
}

.public-shell.ms {
    --ms-accent: var(--tpl-accent, #0f766e);
    --ms-secondary: var(--tpl-secondary, var(--tpl-accent, #0f766e));
    --ms-ink: var(--tpl-ink, #16202a);
    --ms-paper: var(--tpl-paper, #f5f7fa);
    --ms-card: var(--tpl-card, #ffffff);
    --ms-muted: var(--tpl-muted, #6b7280);
    --ms-on-accent: #fff;
    --ms-head: var(--tpl-head-font, 'Vazirmatn', ui-sans-serif, system-ui, sans-serif);
    --ms-body: 'Vazirmatn', ui-sans-serif, system-ui, sans-serif;

    /* The face for heads that are read rather than seen — wordmark, price,
       contact labels, buttons. It follows the display face by default, but a
       template whose display face is calligraphic (nastaliq, katibeh) points it
       back at the body face, because those faces turn to noise below ~20px. */
    --ms-ui-head: var(--ms-head);

    /* Derived: one accent plus its tints, hairline edges from the ink itself. */
    --ms-edge: color-mix(in srgb, var(--ms-ink) 13%, transparent);
    --ms-edge-soft: color-mix(in srgb, var(--ms-ink) 7%, transparent);
    --ms-tint: color-mix(in srgb, var(--ms-accent) 8%, var(--ms-paper));
    --ms-tint-deep: color-mix(in srgb, var(--ms-accent) 18%, var(--ms-paper));
    --ms-shadow: 0 26px 54px -26px color-mix(in srgb, var(--ms-ink) 48%, transparent);
    --ms-shadow-soft: 0 12px 28px -16px color-mix(in srgb, var(--ms-ink) 34%, transparent);

    /* The closing plate (footer, ink bands). On a light template it is the ink;
       `is-dark` below makes it deeper than the paper instead, so a dark site
       never ends in a blinding white strip. */
    --ms-plate: var(--ms-ink);
    --ms-plate-ink: var(--ms-paper);

    /* A readable error hue that survives a light or dark paper (the templates'
       accents are often too light for a validation message). */
    --ms-danger: #e0566a;

    /* A template may declare an extreme global radius for its signature shape
       (orbit's --ms-radius: 999px turns the salon into a disc). That must not
       leak onto large surfaces elsewhere: a 999px login/booking card reads as a
       broken ellipse. Big shared surfaces read this clamped token instead, so a
       sharp template (brutal/ledger: 0) stays sharp and a soft one stays soft,
       while the pill case is capped at a card-sized radius. */
    --ms-radius-big: min(var(--ms-radius), 30px);

    max-width: none;
    width: 100%;
    font-family: var(--ms-body);
    font-size: 16px;
    line-height: 1.9;
    color: var(--ms-ink);
}

/* Paper and ink for the whole designed site, including its booking pages. */
body.tpl-atelier, body.tpl-marquee, body.tpl-bento, body.tpl-ledger, body.tpl-brutal,
body.tpl-split, body.tpl-orbit, body.tpl-journey, body.tpl-postcard, body.tpl-index,
body.tpl-luxe, body.tpl-neo, body.tpl-mag, body.tpl-noir, body.tpl-zen,
body.tpl-deco, body.tpl-bloom, body.tpl-nova, body.tpl-pop, body.tpl-rose {
    background: var(--tpl-paper);
    color: var(--tpl-ink);
    font-size: 16px;
    line-height: 1.9;
}

/* The utility pages (booking, account, auth) stay a readable column. */
.public-shell.ms:not(.is-home) { max-width: 960px; }

/* Dark templates: hairlines and shadows are the one thing that must invert. */
.public-shell.ms.is-dark {
    --ms-shadow: 0 30px 60px -28px rgba(0, 0, 0, .8);
    --ms-shadow-soft: 0 14px 30px -18px rgba(0, 0, 0, .7);
    --ms-plate: color-mix(in srgb, var(--ms-paper) 55%, #000);
    --ms-plate-ink: var(--ms-ink);
}

/* ── 2. Shell, bands and containers ─────────────────────────────────────── */
/* In-page tables of contents (the «فهرست» layout) rely on it; the motion block
   at the end of this sheet turns it back off when the visitor asks for that. */
html { scroll-behavior: smooth; }

.ms .public-main { flex: 1; }
.ms.is-home .public-main { padding: 0; gap: 0; }
.ms:not(.is-home) .public-main { padding: 26px var(--ms-gutter) 40px; gap: 22px; }

.ms-band { position: relative; padding-block: var(--ms-rhythm); }
.ms-band--tight { padding-block: clamp(34px, 5vw, 66px); }
.ms-band--card { background: var(--ms-card); }
.ms-band--tint { background: var(--ms-tint); }
.ms-band--deep { background: var(--ms-tint-deep); }
.ms-band--ink { background: var(--ms-plate); color: var(--ms-plate-ink); }
.ms-band--accent { background: var(--ms-accent); color: var(--ms-on-accent); }

.ms-inner {
    width: min(100% - (var(--ms-gutter) * 2), var(--ms-maxw));
    margin-inline: auto;
}
.ms-inner--narrow { width: min(100% - (var(--ms-gutter) * 2), var(--ms-narrow)); }
.ms-inner--wide { width: min(100% - (var(--ms-gutter) * 2), 1440px); }

/* ── 3. Typography ─────────────────────────────────────────────────────────
 * Persian is cursive: no letter-spacing and no text-transform on this script.
 * Hierarchy comes from size, weight and colour only.
 */
.ms-kicker {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 12px;
    font-family: var(--ms-ui-head);
    font-size: 15px;
    font-weight: 700;
    color: var(--ms-accent);
}
.ms-kicker::before {
    content: "";
    width: 28px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    flex: none;
}
.ms-kicker--center { justify-content: center; }
.ms-kicker--center::after {
    content: "";
    width: 28px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
}

.ms-title {
    margin: 0 0 14px;
    font-family: var(--ms-head);
    font-size: clamp(28px, 4.4vw, 48px);
    font-weight: 700;
    line-height: 1.25;
}
.ms-title--center { text-align: center; }
.ms-display {
    margin: 0 0 16px;
    font-family: var(--ms-head);
    font-size: clamp(38px, 8vw, 96px);
    font-weight: 700;
    line-height: 1.08;
}
.ms-lede {
    margin: 0 0 26px;
    max-width: 62ch;
    font-size: clamp(15.5px, 1.7vw, 19px);
    color: var(--ms-muted);
}
.ms-lede--center { margin-inline: auto; text-align: center; }
.ms-head-block { margin-bottom: clamp(26px, 4vw, 46px); }
.ms-head-block--center { text-align: center; }
.ms-head-block--split { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.ms-head-block--split .ms-lede { margin-bottom: 0; }
.ms-body { margin: 0 0 14px; color: color-mix(in srgb, var(--ms-ink) 86%, var(--ms-paper)); }
.ms-body--just { text-align: justify; }
.ms-note { margin: 0; font-size: 14px; color: var(--ms-muted); }
.ms-rule { height: 1px; background: var(--ms-edge-soft); border: 0; margin: 0; }

/* ── 4. Buttons ──────────────────────────────────────────────────────────── */
.ms-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px 30px;
    border: 0;
    border-radius: 999px;
    background: var(--ms-accent);
    color: var(--ms-on-accent);
    font-family: var(--ms-ui-head);
    font-size: 17px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
    cursor: pointer;
    box-shadow: var(--ms-shadow-soft);
    transition: transform .32s var(--ms-ease), box-shadow .32s var(--ms-ease), background .25s, color .25s;
}
.ms-btn:hover { transform: translateY(-3px); box-shadow: var(--ms-shadow); }
.ms-btn--quiet { background: var(--ms-card); color: var(--ms-ink); box-shadow: none; border: 1px solid var(--ms-edge); }
.ms-btn--quiet:hover { color: var(--ms-accent); border-color: var(--ms-accent); }
.ms-btn--ghost { background: transparent; color: inherit; border: 1.5px solid currentColor; box-shadow: none; }
.ms-btn--ghost:hover { background: color-mix(in srgb, var(--ms-on-accent) 14%, transparent); transform: translateY(-3px); box-shadow: none; }
.ms-btn--block { width: 100%; }
.ms-btn--sm { padding: 11px 20px; font-size: 15px; }
.ms-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 0; }
.ms-actions--center { justify-content: center; }

/* ── 5. Cards, media and the "no photo yet" art layers ─────────────────────
 * A new salon has no images uploaded. Rather than an empty grey box, every
 * designed template gets procedural art built only from its own palette, so an
 * empty mini-site still looks composed.
 */
.ms-card {
    background: var(--ms-card);
    border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-big);
    box-shadow: var(--ms-shadow-soft);
}
.ms-pad { padding: clamp(20px, 2.6vw, 30px); }

.ms-media { position: relative; overflow: hidden; border-radius: var(--ms-radius-big); background: var(--ms-tint-deep); }
.ms-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ms-media--tall { aspect-ratio: 3 / 4; }
.ms-media--wide { aspect-ratio: 16 / 9; }
.ms-media--sq { aspect-ratio: 1 / 1; }

.ms-art {
    position: relative;
    overflow: hidden;
    border-radius: var(--ms-radius-big);
    background:
        radial-gradient(120% 90% at 100% 0%, var(--ms-tint-deep) 0%, transparent 62%),
        linear-gradient(155deg, var(--ms-plate) 0%, color-mix(in srgb, var(--ms-plate) 62%, var(--ms-accent)) 100%);
}
.ms-art::after {
    content: "";
    position: absolute;
    inset: -18% -6% auto auto;
    width: 62%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--ms-accent) 55%, transparent), transparent 68%);
}
.ms-art__word {
    position: absolute;
    inset-inline: 22px;
    bottom: 20px;
    font-family: var(--ms-head);
    font-size: clamp(24px, 3.4vw, 40px);
    font-weight: 700;
    color: var(--ms-plate-ink);
    opacity: .92;
}

/* initial monogram, used wherever a person has no photo */
.ms-mono {
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--ms-tint-deep);
    color: var(--ms-accent);
    font-family: var(--ms-head);
    font-weight: 700;
}

.ms-grid { display: grid; gap: var(--ms-gap); }
.ms-grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.ms-grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr)); }
.ms-grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }

/* ── 5b. Commercial composition (opt-in) ───────────────────────────────────
 * The shared skeleton for the photo-driven flagship layouts: a full-bleed hero,
 * a centred section head, the price list read as package cards, the crew read as
 * team cards, a booking CTA band, and elegant themed placeholder tiles for a
 * salon that has no photos uploaded yet. Every class here is opt-in — only a
 * template whose view actually uses it is affected, so the seven editorial
 * layouts and `classic` stay exactly as they were. Each flagship skin still
 * re-skins radius, art and type on top, which is what keeps the three distinct.
 */
.ms-hero { position: relative; isolation: isolate; display: grid; align-items: center;
    min-height: var(--ms-hero); overflow: hidden; }
.ms-hero__bg { position: absolute; inset: 0; z-index: -2; }
.ms-hero__bg img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ms-hero__scrim { position: absolute; inset: 0; z-index: -1;
    background: linear-gradient(to left,
        color-mix(in srgb, var(--ms-plate) 86%, transparent),
        color-mix(in srgb, var(--ms-plate) 46%, transparent) 55%,
        color-mix(in srgb, var(--ms-plate) 12%, transparent)); }
.ms-hero__inner { width: min(100% - (var(--ms-gutter) * 2), var(--ms-maxw)); margin-inline: auto;
    padding-block: clamp(72px, 14vh, 150px); color: var(--ms-plate-ink); }
.ms-hero__title { margin: 0 0 14px; font-family: var(--ms-head);
    font-size: clamp(34px, 6.5vw, 76px); font-weight: 700; line-height: 1.06; }
.ms-hero__lede { margin: 0 0 26px; max-width: 52ch; font-size: clamp(16px, 1.9vw, 21px);
    color: color-mix(in srgb, var(--ms-plate-ink) 84%, transparent); }
.ms-hero .ms-kicker { color: var(--ms-accent); }
.ms-hero__cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.ms-hero__facts { display: flex; flex-wrap: wrap; gap: 12px 30px; margin: 30px 0 0;
    padding-top: 22px; border-top: 1px solid color-mix(in srgb, var(--ms-plate-ink) 22%, transparent); }
.ms-hero__fact { margin: 0; }
.ms-hero__fact span { display: block; font-size: 13px; opacity: .72; }
.ms-hero__fact b { font-family: var(--ms-head); font-size: 18px; }

.ms-sec__head { margin: 0 auto clamp(26px, 4vw, 46px); text-align: center; max-width: 62ch; }
.ms-sec__title { margin: 0 0 10px; font-family: var(--ms-head);
    font-size: clamp(26px, 4vw, 44px); font-weight: 700; line-height: 1.2; }
.ms-sec__lede { margin: 0; color: var(--ms-muted); }

/* Packages: the shared price list read as cards rather than a dotted ledger.
 * Prefixed with `.ms` so they outrank the neutral `.ms .svc` partial defaults
 * further down (§6), which otherwise bleed ledger padding onto the cards. */
.ms .ms-packages .svc-list { display: grid; gap: var(--ms-gap); list-style: none; margin: 0; padding: 0;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.ms .ms-packages .svc { display: flex; flex-direction: column; align-items: stretch; gap: 10px;
    padding: clamp(20px, 2.4vw, 28px); border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-big); background: var(--ms-card); box-shadow: var(--ms-shadow-soft); }
.ms .ms-packages .svc__name { font-family: var(--ms-head); font-size: 19px; }
.ms .ms-packages .svc__meta { flex: none; justify-content: space-between; margin-top: auto; }
.ms .ms-packages .svc__leader { display: none; }
.ms .ms-packages .svc__price { font-size: 20px; }

/* Team: the crew list read as cards. The partial emits `ul.crew` inside the
 * wrapper, so the grid lives on `.crew`, not the wrapper, or the two grids
 * collapse the cards into a single narrow column. */
.ms .ms-teamcards .crew { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--ms-gap);
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); }
.ms .ms-teamcards .crew__item { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px;
    padding: clamp(20px, 2.4vw, 30px) 16px; border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-big); background: var(--ms-card); box-shadow: var(--ms-shadow-soft); }
.ms .ms-teamcards .crew__badge { width: 78px; height: 78px; font-size: 30px; }
.ms .ms-teamcards .crew__name { font-family: var(--ms-head); font-size: 18px; }

/* The closing booking call-to-action band. */
.ms-bookband { text-align: center; }
.ms-bookband__title { margin: 0 0 12px; font-family: var(--ms-head);
    font-size: clamp(26px, 4.4vw, 46px); font-weight: 700; }
.ms-bookband__lede { margin: 0 auto 26px; max-width: 52ch; opacity: .85; }

/* A gallery that still reads composed before any photo is uploaded. auto-fit (not
   auto-fill) so a short placeholder row fills the band instead of leaving an empty
   trailing track. */
.ms-shots { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.ms-ph { position: relative; display: grid; place-items: center; overflow: hidden; aspect-ratio: 4 / 5;
    border: 1px solid var(--ms-edge); border-radius: var(--ms-radius-big); box-shadow: var(--ms-shadow-soft);
    background:
        radial-gradient(120% 90% at 100% 0%, color-mix(in srgb, var(--ms-accent) 30%, var(--ms-card)) 0%, transparent 60%),
        linear-gradient(155deg, var(--ms-card) 0%, color-mix(in srgb, var(--ms-accent) 22%, var(--ms-card)) 100%); }
.ms-ph::after { content: ""; position: absolute; inset: -18% -6% auto auto; width: 60%; aspect-ratio: 1;
    border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--ms-accent) 40%, transparent), transparent 68%); }
.ms-ph svg { width: 44px; height: 44px; stroke: color-mix(in srgb, var(--ms-accent) 72%, var(--ms-ink)); fill: none; stroke-width: 1.6; opacity: .82; }

/* ── 6. Shared section partials: the default reading of each ───────────────
 * public/sections/{services,staff,gallery,visit}.blade.php are the same markup
 * for all ten templates; a template stylesheet restyles them into poster rails,
 * index rows, dotted ledgers, tiles or planets. This is the neutral version.
 */
.ms .svc-list { list-style: none; margin: 0; padding: 0; }
.ms .svc {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 12px;
    padding: clamp(12px, 1.5vw, 17px) 2px;
    border-bottom: 1px solid var(--ms-edge-soft);
}
.ms .svc:last-child { border-bottom: 0; }
.ms .svc__name { font-weight: 700; font-size: 17px; }
.ms .svc__meta { display: flex; align-items: baseline; gap: 10px; flex: 1 1 220px; }
.ms .svc__time { font-size: 13.5px; color: var(--ms-muted); white-space: nowrap; }
.ms .svc__leader { flex: 1 1 auto; border-bottom: 1px dashed var(--ms-edge); transform: translateY(-4px); }
.ms .svc__price { font-family: var(--ms-ui-head); font-weight: 700; color: var(--ms-accent); white-space: nowrap; }
.ms .svc__cat { font-size: 12.5px; color: var(--ms-muted); }
.ms .svc__no { display: none; }
.ms .svc__desc { flex: 1 1 100%; margin: 0; font-size: 14px; color: var(--ms-muted); }

.ms .crew { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.ms .crew__item { display: flex; align-items: center; gap: 14px; }
.ms .crew__badge {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    flex: none;
    border-radius: 50%;
    background: var(--ms-tint-deep);
    color: var(--ms-accent);
    font-family: var(--ms-ui-head);
    font-size: 19px;
    font-weight: 700;
}
.ms .crew__text { display: flex; flex-direction: column; }
.ms .crew__name { font-weight: 700; font-size: 16.5px; }
.ms .crew__role { font-size: 13.5px; color: var(--ms-muted); }
.ms .crew__when { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; font-size: 12.5px; color: var(--ms-muted); }

.ms .shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 14px; }
.ms .shot { margin: 0; overflow: hidden; border-radius: var(--ms-radius-big); background: var(--ms-tint-deep); }
.ms .shot img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; display: block; transition: transform .7s var(--ms-ease); }
.ms .shot:hover img { transform: scale(1.06); }

.ms .visit { display: grid; gap: 14px; }
.ms .visit__row { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; align-items: baseline; }
.ms .visit__key { font-family: var(--ms-ui-head); font-size: 14px; font-weight: 700; color: var(--ms-accent); min-width: 96px; }
.ms .visit__val { flex: 1 1 240px; margin: 0; color: color-mix(in srgb, var(--ms-ink) 88%, var(--ms-paper)); white-space: pre-line; }
.ms .visit__map { overflow: hidden; border-radius: var(--ms-radius-big); border: 1px solid var(--ms-edge-soft); }
.ms .visit__map iframe { display: block; width: 100%; height: 280px; border: 0; }
.ms .visit__route {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    padding: 12px 22px;
    border-radius: 999px;
    background: var(--ms-accent);
    color: var(--ms-on-accent);
    font-weight: 700;
    text-decoration: none;
    transition: transform .3s var(--ms-ease);
}
.ms .visit__route:hover { transform: translateY(-2px); }
.ms .visit__social { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; }
.ms .visit__social a {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid var(--ms-edge);
    font-size: 14px;
    text-decoration: none;
    color: inherit;
    transition: border-color .25s, color .25s;
}
.ms .visit__social a:hover { border-color: var(--ms-accent); color: var(--ms-accent); }

/* The phone row is a link, so it needs a reading that belongs to the palette
   instead of the panel's default anchor colour. */
.ms .visit__tel {
    color: inherit;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 1px solid var(--ms-edge);
    transition: color .25s, border-color .25s;
}
.ms .visit__tel:hover { color: var(--ms-accent); border-color: var(--ms-accent); }

.ms-empty {
    padding: clamp(26px, 4vw, 44px);
    border: 1px dashed var(--ms-edge);
    border-radius: var(--ms-radius-big);
    color: var(--ms-muted);
    text-align: center;
    margin: 0;
}

/* ── 7. Header chrome ──────────────────────────────────────────────────────
 * The panel bar (white, pink gradient CTA) is replaced by a token-driven bar.
 * On the home page it is wide, translucent and sits over the page itself.
 */
.ms .public-header {
    background: color-mix(in srgb, var(--ms-paper) 88%, transparent);
    border-bottom: 1px solid var(--ms-edge-soft);
    box-shadow: none;
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
}
.ms .public-header__inner { padding: 15px var(--ms-gutter); gap: 16px; }
.ms.is-home .public-header__inner {
    width: min(100% - (var(--ms-gutter) * 2), var(--ms-maxw));
    margin-inline: auto;
    padding: 15px 0;
}
.ms .public-brand { gap: 12px; }
.ms .public-brand h1 { font-family: var(--ms-ui-head); font-size: 21px; font-weight: 700; }
.ms .public-brand__logo { height: 44px; width: auto; border-radius: 0; background: none; object-fit: contain; }
.ms .public-logo { background: var(--ms-accent); color: var(--ms-on-accent); border-radius: 12px; box-shadow: none; font-family: var(--ms-ui-head); }
.ms .public-nav { gap: 6px; }
.ms .public-nav a {
    color: var(--ms-muted);
    font-size: 15px;
    font-weight: 600;
    border-radius: 999px;
    padding: 9px 15px;
    transition: background .25s, color .25s;
}
.ms .public-nav a:hover { background: var(--ms-tint); color: var(--ms-ink); }
.ms .public-nav a.public-nav__cta { background: var(--ms-accent); color: var(--ms-on-accent); }
.ms .public-nav a.public-nav__cta:hover { filter: brightness(1.06); color: var(--ms-on-accent); }
.ms .public-nav__cta {
    /* salon.css forces `color:#fff !important` here; matched importance plus a
       higher specificity is the only way a dark template (gold on ink) can keep
       a readable button label. */
    background: var(--ms-accent) !important;
    color: var(--ms-on-accent) !important;
    box-shadow: none;
    font-family: var(--ms-ui-head);
    padding: 10px 22px;
}
.ms .public-nav__form button { color: var(--ms-muted); font-size: 15px; }
.ms .public-phone { color: var(--ms-ink); font-size: 15.5px; font-weight: 700; }
.ms .public-menu-btn { background: var(--ms-card); border-color: var(--ms-edge); color: var(--ms-ink); }

/* The mobile sheet follows the palette, including on dark templates. */
.ms .public-sheet { background: var(--ms-card); color: var(--ms-ink); }
.ms .public-sheet__grabber, .ms .public-sheet__brand { border-color: var(--ms-edge-soft); }
.ms .public-sheet__links a { color: var(--ms-ink); }
.ms .public-sheet__links a:hover { background: var(--ms-tint); color: var(--ms-ink); }
.ms .public-sheet__close { background: var(--ms-tint); color: var(--ms-ink); }

/* ── 8. Footer chrome: a closing plate rather than a panel strip ─────────── */
.ms .public-footer {
    margin-top: 0;
    border-top: 0;
    background: var(--ms-plate);
    color: color-mix(in srgb, var(--ms-plate-ink) 78%, var(--ms-plate));
}
.ms .public-footer__grid {
    width: min(100% - (var(--ms-gutter) * 2), var(--ms-maxw));
    margin-inline: auto;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
    gap: clamp(22px, 3vw, 40px);
    padding: clamp(40px, 6vw, 76px) 0 clamp(22px, 3vw, 34px);
}
.ms .public-footer__col h4 {
    font-family: var(--ms-ui-head);
    font-size: 17px;
    color: var(--ms-plate-ink);
    margin-bottom: 12px;
}
.ms .public-footer__ico { stroke: var(--ms-accent); }
.ms .public-footer__col p { font-size: 14.5px; line-height: 2; color: color-mix(in srgb, var(--ms-plate-ink) 72%, var(--ms-plate)); }
.ms .public-footer__col a { color: var(--ms-plate-ink); text-decoration: none; }
.ms .public-footer__col a:hover { color: var(--ms-accent); }
.ms .public-social__link { background: color-mix(in srgb, var(--ms-plate-ink) 12%, transparent); color: var(--ms-plate-ink); border-radius: 50%; }
.ms .public-social__link:hover { background: var(--ms-accent); color: var(--ms-on-accent); }
.ms .public-footer__base {
    border-top: 1px solid color-mix(in srgb, var(--ms-plate-ink) 16%, transparent);
    color: color-mix(in srgb, var(--ms-plate-ink) 58%, var(--ms-plate));
    padding: 18px var(--ms-gutter);
    font-size: 13.5px;
}

/* ── 9. Utility pages: booking, auth, account ──────────────────────────────
 * These screens are built from the *panel* primitives in salon.css (.card,
 * .field, .control, .btn, .alert, .badge), whose identity is a hardcoded pink
 * (#c76b85) and gold gradient. Left alone they sit as an off-brand panel inside
 * a themed header/footer, which an owner rightly read as "only the home page
 * follows the template". Here those primitives are re-skinned onto the design
 * system, so the chosen template's palette and display face carry all the way
 * through a booking. `.ms .x` (two-class) outranks salon.css's `.x` (one-class)
 * and this sheet loads last, so nothing needs `!important`. A template skin may
 * still override any of it.
 */
.ms .public-main { font-size: 16px; }
.ms .public-main a:not(.btn):not(.ms-btn):not(.visit__route) { color: var(--ms-accent); text-decoration: none; }
.ms .public-main a:not(.btn):not(.ms-btn):not(.visit__route):hover { text-decoration: underline; }
.ms .muted { color: var(--ms-muted); }
.ms .error { color: var(--ms-danger); }

/* The card a form or a list lives in. */
.ms .card {
    background: var(--ms-card);
    border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-big);
    box-shadow: var(--ms-shadow-soft);
    padding: clamp(20px, 3vw, 34px);
}
.ms .card-head {
    margin: 0 0 clamp(18px, 2.4vw, 26px);
    padding-bottom: 14px;
    border-bottom: 1px solid var(--ms-edge-soft);
}
.ms .card-head h2 {
    font-family: var(--ms-ui-head);
    font-size: clamp(20px, 2.6vw, 28px);
    font-weight: 700;
    color: var(--ms-ink);
}
.ms .card-head p { color: var(--ms-muted); font-size: 14px; }

/* Fields and controls. */
.ms .field > span, .ms .field > label {
    color: var(--ms-muted);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 8px;
}
.ms .control,
.ms .field input, .ms .field select, .ms .field textarea {
    width: 100%;
    padding: 13px 16px;
    border: 1.5px solid var(--ms-edge);
    border-radius: var(--ms-radius-sm);
    background: color-mix(in srgb, var(--ms-ink) 3%, var(--ms-card));
    color: var(--ms-ink);
    font-family: var(--ms-body);
    font-size: 16px;
    outline: none;
    transition: border-color .2s, box-shadow .2s, background .2s;
}
.ms .control:focus,
.ms .field input:focus, .ms .field select:focus, .ms .field textarea:focus {
    border-color: var(--ms-accent);
    background: var(--ms-card);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--ms-accent) 18%, transparent);
}
.ms .control::placeholder,
.ms .field input::placeholder, .ms .field textarea::placeholder {
    color: color-mix(in srgb, var(--ms-muted) 66%, var(--ms-paper));
}
.ms .field .error { color: var(--ms-danger); }

/* Buttons: the accent, not the panel's pink gradient. */
.ms .btn {
    border-radius: 999px;
    font-family: var(--ms-head);
    font-size: 16px;
    font-weight: 700;
    padding: 13px 26px;
    gap: 8px;
    transition: transform .28s var(--ms-ease), box-shadow .28s var(--ms-ease), background .2s, color .2s, border-color .2s;
}
.ms .btn-primary {
    background: var(--ms-accent);
    color: var(--ms-on-accent);
    box-shadow: var(--ms-shadow-soft);
}
.ms .btn-primary:hover { transform: translateY(-2px); box-shadow: var(--ms-shadow); }
.ms .btn-outline {
    background: transparent;
    border: 1.5px solid var(--ms-edge);
    color: var(--ms-ink);
    box-shadow: none;
}
.ms .btn-outline:hover { border-color: var(--ms-accent); color: var(--ms-accent); background: var(--ms-tint); }
.ms .btn-sm { padding: 9px 16px; font-size: 14px; }

/* Booking: the service/staff/date chooser and the free-slot grid. */
.ms .public-picker { display: grid; gap: 14px; }
.ms .public-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; }
.ms .public-slots .btn { padding: 12px 8px; }

/* The customer's booking list and the printed receipt. */
.ms .public-bookings { display: grid; gap: 12px; }
.ms .public-booking-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px;
    border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-sm);
    background: color-mix(in srgb, var(--ms-ink) 3%, var(--ms-card));
}
.ms .public-receipt, .ms .public-receipt-item { display: grid; gap: 2px; }
.ms .public-receipt-item { margin-top: 12px; padding: 16px; border: 1px solid var(--ms-edge-soft); border-radius: var(--ms-radius-sm); }
.ms .public-receipt > div, .ms .public-receipt-item > div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 0;
    border-bottom: 1px dashed var(--ms-edge);
}
.ms .public-receipt > div:last-child, .ms .public-receipt-item > div:last-child { border-bottom: 0; }
.ms .public-receipt .label, .ms .public-receipt-item .label { color: var(--ms-muted); }

/* Alerts follow the palette instead of the panel's tinted fills. */
.ms .alert {
    border-radius: var(--ms-radius-sm);
    border: 1px solid var(--ms-edge-soft);
    background: var(--ms-tint);
    color: var(--ms-ink);
    font-size: 15px;
}
.ms .alert.ok { background: color-mix(in srgb, var(--ms-accent) 14%, var(--ms-card)); border-color: color-mix(in srgb, var(--ms-accent) 34%, transparent); }

@media (min-width: 720px) {
    .ms .public-picker { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; }
    .ms .public-picker .btn { grid-column: 1 / -1; justify-self: start; }
}

/* The Jalali date and 24h time pickers pop open *inside* the booking form. They
 * are the most visible leftover: salon.css paints their toggle, popup and the
 * selected day/hour in the panel's lavender/pink, so an otherwise-themed form
 * sprouts an off-brand calendar the moment it is opened. Re-skin them onto the
 * design system the same way as the primitives above.
 */
.ms .jp-toggle, .ms .tp-toggle {
    border: 1.5px solid var(--ms-edge);
    background: color-mix(in srgb, var(--ms-ink) 3%, var(--ms-card));
    color: var(--ms-muted);
}
.ms .jp-toggle:hover, .ms .tp-toggle:hover {
    border-color: var(--ms-accent);
    color: var(--ms-accent);
    background: var(--ms-tint);
}
.ms .jp-pop, .ms .tp-pop {
    background: var(--ms-card);
    border: 1px solid var(--ms-edge-soft);
    border-radius: var(--ms-radius-sm);
    box-shadow: var(--ms-shadow);
    color: var(--ms-ink);
    font-family: var(--ms-body);
}
.ms .jp-title, .ms .tp-col-title { color: var(--ms-ink); }
.ms .jp-nav, .ms .tp-foot button, .ms .jp-foot button {
    border: 1px solid var(--ms-edge);
    background: color-mix(in srgb, var(--ms-ink) 3%, var(--ms-card));
    color: var(--ms-ink);
}
.ms .jp-nav:hover { border-color: var(--ms-accent); color: var(--ms-accent); background: var(--ms-tint); }
.ms .jp-dow { color: var(--ms-muted); }
.ms .jp-day { color: var(--ms-ink); }
.ms .jp-day:hover, .ms .tp-cell:hover { background: var(--ms-tint); }
.ms .jp-day.is-today { box-shadow: inset 0 0 0 1.5px var(--ms-accent); }
.ms .jp-day.is-selected, .ms .tp-cell.is-selected {
    background: var(--ms-accent);
    color: var(--ms-on-accent);
}
.ms .tp-cell { color: var(--ms-ink); }
.ms .tp-readout { color: var(--ms-accent); }
.ms .jp-foot button.jp-clear, .ms .tp-foot button {
    background: color-mix(in srgb, var(--ms-ink) 5%, var(--ms-card));
    color: var(--ms-muted);
}

/* ── 10. Motion ──────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .ms *, .ms *::before, .ms *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
        scroll-behavior: auto !important;
    }
}
