/* Base styles retained for existing components; brand.css loads last and
   defines the current colour and typography system. See DESIGN.md. */
/* ==========================================================================
   YA — Design System
   --------------------------------------------------------------------------
   "The Studio Index": everything YA makes is an entry in one catalogue.
   The system is monochrome by design — there is no brand accent color.
   Attention is carried by contrast, light and motion instead, which is why
   the whole interface still reads correctly in grayscale.

   The one deliberate chromatic idea is a temperature split: light surfaces
   are cool neutrals (photographic paper), the dark shell is a warm neutral
   (ink). Never mix the two scales on one surface.

   Loaded by BOTH layouts, after tailwind.css and before the skin:
       tailwind.css  →  ya.css  →  site.css (public) | theme.css (admin)

   This file owns tokens + primitives only. Page chrome (hero, shell,
   sidebar, dashboard furniture) belongs to the skin files.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tokens
   -------------------------------------------------------------------------- */

:root {
    /* -- Neutral scale (cool) — the light side of the system --------------- */
    --ya-n-0:  #FFFFFF;
    --ya-n-25: #FBFBFC;   /* Paper — page background */
    --ya-n-50: #F6F6F8;
    --ya-n-100:#F0F0F3;   /* Chalk — recessed surface */
    --ya-n-200:#E4E4E9;
    --ya-n-300:#D2D2DA;
    --ya-n-400:#A8A8B3;
    --ya-n-500:#8A8A96;
    --ya-n-600:#5B5B66;   /* Slate — body copy, 6.4:1 on Paper */
    --ya-n-700:#3F3F49;
    --ya-n-800:#26262E;
    --ya-n-900:#111114;   /* Ink */

    /* -- Shell scale (warm) — the dark side of the system ------------------ */
    --ya-s-900:#0B0A09;   /* Obsidian — the shell itself */
    --ya-s-800:#131110;   /* raised */
    --ya-s-700:#1C1917;   /* raised further */
    --ya-s-600:#2A2622;   /* hairlines on the shell */
    --ya-s-100:#EDEAE6;   /* Kiln — the light on the shell */

    /* -- Semantic aliases -------------------------------------------------
       Existing markup addresses these directly via Tailwind arbitrary
       values (bg-[--ya-accent], text-[--ya-ink] …), so they are part of the
       public API of this file — rename with care. */
    --ya-bg:          var(--ya-n-25);
    --ya-surface:     var(--ya-n-0);
    --ya-surface-sunk:var(--ya-n-100);
    --ya-card:        var(--ya-n-0);
    --ya-ink:         var(--ya-n-900);
    --ya-ink-soft:    var(--ya-n-600);
    /* Checked against the *recessed* surface, not the page: meta text lands
       on Chalk inside sunk panels and on table row hover, which is the
       tightest pairing in the system. 4.6:1 there, 5.1:1 on Paper. */
    --ya-ink-faint:   #6B6B77;
    --ya-border:      rgba(15, 23, 42, .09);
    --ya-border-2:    rgba(15, 23, 42, .16);
    --ya-accent:      var(--ya-n-900);  /* primary action = ink */
    --ya-accent-dark: #000004;
    --ya-accent-ink:  var(--ya-n-0);    /* text on a primary action */
    --ya-stage:       var(--ya-s-900);
    --ya-house:       var(--ya-s-700);
    --ya-gold:        var(--ya-s-100);
    --ya-marquee:     var(--ya-s-100);

    /* -- Functional status tones ------------------------------------------
       Desaturated on purpose: they must sit inside a monochrome page
       without becoming the loudest thing on it. */
    --ya-ok:      #2F6B4F;
    --ya-ok-bg:   rgba(47, 107, 79, .10);
    --ya-warn:    #8A6A2F;
    --ya-warn-bg: rgba(138, 106, 47, .11);
    --ya-danger:  #9B3B33;
    --ya-danger-bg:rgba(155, 59, 51, .10);
    --ya-info:    #3D5570;
    --ya-info-bg: rgba(61, 85, 112, .10);

    /* -- Radius ------------------------------------------------------------ */
    --ya-r-xs: .375rem;
    --ya-r-sm: .5rem;
    --ya-r-md: .75rem;
    --ya-r-lg: 1rem;
    --ya-r-xl: 1.25rem;
    --ya-r-2xl:1.75rem;
    --ya-r-pill: 999px;

    /* -- Elevation ---------------------------------------------------------
       Three layered stops, tinted with the ink hue rather than pure black,
       so shadows read as depth on paper instead of dirt. */
    --ya-elevation-0: 0 0 0 1px var(--ya-border);
    --ya-elevation-1: 0 1px 2px rgba(15, 23, 42, .05),
                      0 4px 12px -6px rgba(15, 23, 42, .10);
    --ya-elevation-2: 0 1px 2px rgba(15, 23, 42, .05),
                      0 8px 20px -8px rgba(15, 23, 42, .14),
                      0 24px 48px -24px rgba(15, 23, 42, .18);
    --ya-elevation-3: 0 2px 4px rgba(15, 23, 42, .06),
                      0 16px 32px -12px rgba(15, 23, 42, .18),
                      0 48px 80px -32px rgba(15, 23, 42, .26);
    /* Elevation on the dark shell — light can't fall the same way, so depth
       comes from a rim highlight plus a deeper void beneath. */
    --ya-elevation-shell: 0 0 0 1px rgba(248, 250, 252, .07),
                          inset 0 1px 0 rgba(248, 250, 252, .06),
                          0 32px 64px -32px rgba(15, 23, 42, .9);

    /* -- Blur --------------------------------------------------------------- */
    --ya-blur-sm: 8px;
    --ya-blur-md: 16px;
    --ya-blur-lg: 28px;

    /* -- Motion -------------------------------------------------------------
       One easing family. --ya-ease-out is the workhorse (Apple's settle);
       --ya-ease-inout is for things that travel both ways. */
    --ya-ease-out:   cubic-bezier(.16, 1, .3, 1);
    --ya-ease-inout: cubic-bezier(.65, 0, .35, 1);
    --ya-ease-spring:cubic-bezier(.34, 1.56, .64, 1);
    --ya-duration-instant: .1s;
    --ya-duration-fast:    .18s;
    --ya-duration-base:    .32s;
    --ya-duration-slow:    .6s;
    --ya-duration-curtain: .9s;

    /* Kept for backwards compatibility with markup written against the
       previous token names. */
    --ya-ease-cinematic: var(--ya-ease-out);
    --ya-ease-standard:  var(--ya-ease-inout);

    /* -- Type ---------------------------------------------------------------
       The display face is used sparingly and always large; below ~1.5rem the
       sans takes over, which is why there are two heading tiers rather than
       one ramp. */
    --ya-font-display: "Instrument Serif", "Markazi Text", Georgia, serif;
    --ya-font-sans: "Instrument Sans", "IBM Plex Sans Arabic", ui-sans-serif,
                    system-ui, -apple-system, "Segoe UI", sans-serif;
    --ya-font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo,
                    monospace;

    /* Capped at 4.25rem rather than something larger: the hero headline shares
       its band with the contact sheet, so the text column is about half the
       plate. A bigger size only buys uglier line breaks. */
    --ya-display-1: clamp(2.5rem, 1.2rem + 4.2vw, 4.25rem);
    --ya-display-2: clamp(2.125rem, 1.4rem + 2.9vw, 3.5rem);
    --ya-display-3: clamp(1.625rem, 1.25rem + 1.5vw, 2.25rem);

    /* -- Atmosphere ---------------------------------------------------------- */
    --ya-grain-opacity: .04;
    --ya-vignette-strength: .5;

    color-scheme: light;
}

/* Dark theme — the light side inverts toward the warm shell scale so the
   page and the shell finally share one temperature, while the shell's own
   chrome (nav, hero, footer) is unchanged: it was already dark. */
[data-theme="dark"] {
    --ya-bg:          var(--ya-s-900);
    --ya-surface:     var(--ya-s-800);
    --ya-surface-sunk:#0F0D0C;
    --ya-card:        var(--ya-s-800);
    --ya-ink:         #F4F2EF;
    --ya-ink-soft:    #A9A29B;
    --ya-ink-faint:   #8E877F;
    --ya-border:      rgba(248, 250, 252, .10);
    --ya-border-2:    rgba(248, 250, 252, .18);
    --ya-accent:      #F4F2EF;         /* action inverts to light */
    --ya-accent-dark: #FFFFFF;
    --ya-accent-ink:  var(--ya-s-900);

    --ya-elevation-0: 0 0 0 1px var(--ya-border);
    --ya-elevation-1: 0 1px 2px rgba(15, 23, 42, .5),
                      0 4px 12px -6px rgba(15, 23, 42, .6);
    --ya-elevation-2: 0 1px 2px rgba(15, 23, 42, .5),
                      0 10px 24px -10px rgba(15, 23, 42, .7),
                      0 28px 56px -28px rgba(15, 23, 42, .8);
    --ya-elevation-3: 0 2px 6px rgba(15, 23, 42, .55),
                      0 20px 40px -16px rgba(15, 23, 42, .75),
                      0 56px 96px -40px rgba(15, 23, 42, .9);

    --ya-ok:      #7FBF9B;
    --ya-ok-bg:   rgba(127, 191, 155, .14);
    --ya-warn:    #D8B678;
    --ya-warn-bg: rgba(216, 182, 120, .14);
    --ya-danger:  #E09189;
    --ya-danger-bg:rgba(224, 145, 137, .14);
    --ya-info:    #9DB4CC;
    --ya-info-bg: rgba(157, 180, 204, .14);

    color-scheme: dark;
}

/* Tailwind theme-color compatibility ------------------------------------
   `ink` has to stay a fixed hex in tailwind.config.js: it is used throughout
   the app with opacity modifiers (bg-ink/5, border-ink/8 …) and Tailwind v3
   cannot alpha a var(). That means those compiled utilities do not follow
   the theme on their own, so the dark theme re-points them here. A light
   warm tint reads on a dark surface exactly the way an ink tint reads on
   paper. Shell colors (stage/house/gold/cream) are intentionally absent:
   they are fixed in both themes because the shell is always dark. */
[data-theme="dark"] .text-ink { color: var(--ya-ink); }
[data-theme="dark"] .bg-ink\/5    { background-color: rgba(248, 250, 252, .05); }
[data-theme="dark"] .bg-ink\/8    { background-color: rgba(248, 250, 252, .07); }
[data-theme="dark"] .bg-ink\/10   { background-color: rgba(248, 250, 252, .09); }
[data-theme="dark"] .border-ink\/5  { border-color: rgba(248, 250, 252, .07); }
[data-theme="dark"] .border-ink\/8  { border-color: rgba(248, 250, 252, .10); }
[data-theme="dark"] .border-ink\/10 { border-color: rgba(248, 250, 252, .12); }
[data-theme="dark"] .border-ink\/15 { border-color: rgba(248, 250, 252, .16); }
[data-theme="dark"] .divide-ink\/5 > :not([hidden]) ~ :not([hidden]) { border-color: rgba(248, 250, 252, .07); }
[data-theme="dark"] .divide-ink\/8 > :not([hidden]) ~ :not([hidden]) { border-color: rgba(248, 250, 252, .10); }
[data-theme="dark"] .text-ink\/15 { color: rgba(248, 250, 252, .2); }

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */

html { -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--ya-font-sans);
    background: var(--ya-bg);
    color: var(--ya-ink);
    font-size: 1rem;
    line-height: 1.6;
    letter-spacing: -.006em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: "cv05" 1, "ss01" 1;
    transition: background-color var(--ya-duration-base) var(--ya-ease-inout),
                color var(--ya-duration-base) var(--ya-ease-inout);
}

/* Numerals line up in tables, prices and stat tiles without opting in
   per-component. */
table, .tabular, [data-counter], .ya-price { font-variant-numeric: tabular-nums; }

::selection { background: var(--ya-ink); color: var(--ya-bg); }

:focus-visible {
    outline: 2px solid var(--ya-ink);
    outline-offset: 3px;
    border-radius: var(--ya-r-xs);
}
/* On the dark shell the ink outline would vanish. */
.stage :focus-visible, .ya-on-shell :focus-visible {
    outline-color: var(--ya-s-100);
}

/* Hidden until focused — using the clip technique rather than parking it at
   left: -9999px.

   Off-screen-left is only harmless in a left-to-right document. Under
   dir="rtl" the left edge is the inline *end*, so those 9999px become real
   scrollable overflow: the page grows by 9999px and opens on empty space,
   which blanked every Arabic page. Clipping takes the element out of the
   layout in both directions. */
.ya-skip-link {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}
.ya-skip-link:focus {
    position: fixed;
    inset-inline-start: 1rem;
    top: .75rem;
    width: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    clip: auto;
    clip-path: none;
    z-index: 100;
    padding: .625rem 1rem;
    border-radius: var(--ya-r-sm);
    background: var(--ya-ink);
    color: var(--ya-bg);
    font-size: .875rem;
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   3. Typography
   -------------------------------------------------------------------------- */

.font-display, .ya-display {
    font-family: var(--ya-font-display);
    font-weight: 400;
    letter-spacing: -.022em;
    line-height: 1.06;
}
/* Instrument Serif ships a single weight; asking for 600/700 triggers a
   synthetic bold that ruins the letterforms. Neutralize it. */
.font-display, .ya-display,
.font-display strong, .ya-display strong { font-synthesis-weight: none; }

h1, h2, h3, h4, h5, h6 { font-weight: 600; letter-spacing: -.018em; line-height: 1.2; }

.ya-display-1 { font-family: var(--ya-font-display); font-weight: 400; font-size: var(--ya-display-1); line-height: .98; letter-spacing: -.028em; }
.ya-display-2 { font-family: var(--ya-font-display); font-weight: 400; font-size: var(--ya-display-2); line-height: 1.04; letter-spacing: -.024em; }
.ya-display-3 { font-family: var(--ya-font-display); font-weight: 400; font-size: var(--ya-display-3); line-height: 1.12; letter-spacing: -.02em; }

/* The display face has a genuine italic — reserved for the one emphasised
   phrase in a headline, never for whole blocks. */
.ya-em { font-style: italic; }

/* Eyebrow / catalogue label. The mono face is the "spec sheet" voice: it
   marks metadata, never prose. */
.eyebrow, .ya-eyebrow {
    align-items: center;
    gap: .6em;
    font-family: var(--ya-font-mono);
    font-size: .6875rem;
    font-weight: 500;
    letter-spacing: .16em;
    text-transform: uppercase;
    line-height: 1;
}
[dir="rtl"] .eyebrow, [dir="rtl"] .ya-eyebrow { letter-spacing: .02em; }

.ya-meta {
    font-family: var(--ya-font-mono);
    font-size: .75rem;
    letter-spacing: .01em;
    color: var(--ya-ink-faint);
}

/* Catalogue index number — real position in a list, set as a plate number. */
.ya-index {
    font-family: var(--ya-font-mono);
    font-size: .6875rem;
    font-weight: 500;
    letter-spacing: .1em;
    color: var(--ya-ink-faint);
    font-variant-numeric: tabular-nums;
}

/* Comfortable reading measure for long-form prose. */
.ya-prose { max-width: 68ch; }
.ya-prose p { margin-bottom: 1.25em; line-height: 1.75; color: var(--ya-ink-soft); }
.ya-prose h2 { font-family: var(--ya-font-display); font-weight: 400; font-size: 1.875rem; letter-spacing: -.02em; margin: 2.25em 0 .6em; color: var(--ya-ink); }
.ya-prose h3 { font-size: 1.1875rem; font-weight: 600; margin: 2em 0 .5em; color: var(--ya-ink); }
.ya-prose ul, .ya-prose ol { margin: 0 0 1.25em; padding-inline-start: 1.35em; color: var(--ya-ink-soft); }
.ya-prose li { margin-bottom: .5em; }
.ya-prose ul { list-style: disc; }
.ya-prose ol { list-style: decimal; }
.ya-prose a { color: var(--ya-ink); text-decoration: underline; text-underline-offset: .18em; text-decoration-thickness: 1px; text-decoration-color: var(--ya-border-2); transition: text-decoration-color var(--ya-duration-fast) var(--ya-ease-out); }
.ya-prose a:hover { text-decoration-color: currentColor; }
.ya-prose blockquote {
    margin: 1.75em 0;
    padding-inline-start: 1.25rem;
    border-inline-start: 2px solid var(--ya-ink);
    font-family: var(--ya-font-display);
    font-size: 1.375rem;
    line-height: 1.4;
    color: var(--ya-ink);
}
.ya-prose code { font-family: var(--ya-font-mono); font-size: .875em; background: var(--ya-surface-sunk); padding: .12em .4em; border-radius: var(--ya-r-xs); }
.ya-prose pre { background: var(--ya-s-900); color: var(--ya-s-100); padding: 1.15rem 1.25rem; border-radius: var(--ya-r-md); overflow-x: auto; margin-bottom: 1.5em; }
.ya-prose pre code { background: none; padding: 0; }
.ya-prose img { border-radius: var(--ya-r-md); margin: 1.75em 0; }
.ya-prose hr { border: 0; border-top: 1px solid var(--ya-border); margin: 2.5em 0; }

/* --------------------------------------------------------------------------
   4. Layout helpers
   -------------------------------------------------------------------------- */

.ya-container { width: 100%; max-width: 76rem; margin-inline: auto; padding-inline: 1.25rem; }
@media (min-width: 1024px) { .ya-container { padding-inline: 2rem; } }
.ya-container-narrow { width: 100%; max-width: 52rem; margin-inline: auto; padding-inline: 1.25rem; }

/* Section rhythm — one scale, so every page breathes at the same tempo.
   These are per-section values, and sections stack: the gap a reader
   actually sees between two of them is the sum of both, which is why the
   numbers look conservative on their own. */
.ya-section { padding-block: clamp(2.75rem, 1.5rem + 3.5vw, 4.5rem); }
.ya-section-tight { padding-block: clamp(1.75rem, 1rem + 2.5vw, 3rem); }
.ya-section-lead { padding-block: clamp(3.5rem, 2rem + 5vw, 6rem); }

/* A rule that means "new chapter", not decoration. */
.ya-rule { height: 1px; background: var(--ya-border); border: 0; }

/* Section header: eyebrow + title + optional trailing link, used everywhere
   so section openings are identical across ~20 pages. */
.ya-section-head { align-items: flex-end; justify-content: space-between; gap: 2rem; margin-bottom: 2.5rem; flex-wrap: wrap; }
.ya-section-head h2 { margin: 0; }

/* --------------------------------------------------------------------------
   4b. Display, declared so utilities still win
   --------------------------------------------------------------------------
   ya.css loads after tailwind.css, so a component rule setting `display`
   would out-rank `hidden` / `lg:hidden` on the same element — a button that
   is supposed to disappear on desktop simply would not. Wrapping the
   selector in :where() drops it to zero specificity for this property, so
   any display utility in the markup beats it while everything else about
   the component still applies. */
:where(.btn-accent, .btn-ghost, .btn-subtle, .btn-danger, .ya-btn,
       .ya-link, .badge, .ya-tag, .eyebrow, .ya-eyebrow) { display: inline-flex; }
:where(.ya-icon-btn) { display: inline-grid; }
:where(.ya-live, .ya-check-mark) { display: inline-block; }
:where(.ya-empty) { display: flex; }
:where(.ya-toolbar, .ya-page-head, .ya-section-head, .ya-form-actions) { display: flex; }
:where(.ya-fieldset, .ya-form-grid) { display: grid; }
.ya-form-grid { grid-template-columns: minmax(0, 1fr); }
/* Same reason: `.btn-block sm:w-auto` has to be able to narrow again. */
:where(.btn-block) { display: flex; width: 100%; }

/* --------------------------------------------------------------------------
   5. Buttons
   --------------------------------------------------------------------------
   .btn-accent / .btn-ghost keep their established names — they are used in
   ~50 places — and gain size + tone siblings. Every button is the same
   shape and settles on the same curve. */

.btn-accent, .btn-ghost, .btn-subtle, .btn-danger, .ya-btn {
    align-items: center;
    justify-content: center;
    gap: .5rem;
    font-family: var(--ya-font-sans);
    font-size: .875rem;
    font-weight: 600;
    letter-spacing: -.006em;
    line-height: 1;
    padding: .6875rem 1.125rem;
    border-radius: var(--ya-r-sm);
    white-space: nowrap;
    cursor: pointer;
    user-select: none;
    transition: background-color var(--ya-duration-fast) var(--ya-ease-out),
                border-color var(--ya-duration-fast) var(--ya-ease-out),
                color var(--ya-duration-fast) var(--ya-ease-out),
                box-shadow var(--ya-duration-fast) var(--ya-ease-out),
                transform var(--ya-duration-instant) var(--ya-ease-out);
}
.btn-accent:disabled, .btn-ghost:disabled, .btn-subtle:disabled, .ya-btn:disabled,
.btn-accent[aria-disabled="true"] { opacity: .45; pointer-events: none; }

.btn-accent {
    background: var(--ya-accent);
    color: var(--ya-accent-ink);
    border: 1px solid transparent;
    box-shadow: var(--ya-elevation-1), inset 0 1px 0 rgba(248, 250, 252, .09);
}
.btn-accent:hover { box-shadow: var(--ya-elevation-2), inset 0 1px 0 rgba(248, 250, 252, .12); }
.btn-accent:active { transform: translateY(1px) scale(.995); box-shadow: var(--ya-elevation-1); }

.btn-ghost {
    background: transparent;
    color: var(--ya-ink);
    border: 1px solid var(--ya-border-2);
}
.btn-ghost:hover { border-color: var(--ya-ink); background: var(--ya-surface-sunk); }
.btn-ghost:active { transform: translateY(1px); }

.btn-subtle {
    background: var(--ya-surface-sunk);
    color: var(--ya-ink);
    border: 1px solid transparent;
}
.btn-subtle:hover { background: var(--ya-n-200); }
[data-theme="dark"] .btn-subtle:hover { background: var(--ya-s-700); }
.btn-subtle:active { transform: translateY(1px); }

.btn-danger {
    background: transparent;
    color: var(--ya-danger);
    border: 1px solid var(--ya-danger-bg);
}
.btn-danger:hover { background: var(--ya-danger-bg); border-color: var(--ya-danger); }

.btn-sm { padding: .5rem .8125rem; font-size: .8125rem; border-radius: var(--ya-r-xs); }
.btn-lg { padding: .875rem 1.5rem; font-size: .9375rem; border-radius: var(--ya-r-md); }
.btn-icon { padding: .5rem; }

/* Buttons sitting on the dark shell invert, so a primary action stays the
   brightest thing on any background. `.ya-plate` is listed alongside
   `.stage` because a plate is the shell — just inset into the page. */
.stage .btn-accent, .ya-plate .btn-accent, .ya-on-shell .btn-accent {
    background: var(--ya-s-100);
    color: var(--ya-s-900);
}
.stage .btn-ghost, .ya-plate .btn-ghost, .ya-on-shell .btn-ghost {
    color: var(--ya-s-100);
    border-color: rgba(248, 250, 252, .24);
}
.stage .btn-ghost:hover, .ya-plate .btn-ghost:hover, .ya-on-shell .btn-ghost:hover {
    border-color: var(--ya-s-100);
    background: rgba(248, 250, 252, .08);
}

/* A filled mark in the action colour — avatars, selected chips, step
   markers, the current page in a pager.

   It exists because `bg-ink text-paper` cannot follow the theme: `ink` and
   `paper` are fixed hexes in tailwind.config.js (they have to be, so
   opacity modifiers compile), so in dark mode that pair renders a dark chip
   on a dark page. These two tokens invert. */
.ya-fill { background: var(--ya-accent); color: var(--ya-accent-ink); }

/* Icon button — the nav/toolbar affordance. */
.ya-icon-btn {
    place-items: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: var(--ya-r-sm);
    color: var(--ya-ink-soft);
    transition: background-color var(--ya-duration-fast) var(--ya-ease-out),
                color var(--ya-duration-fast) var(--ya-ease-out);
}
.ya-icon-btn:hover { background: var(--ya-surface-sunk); color: var(--ya-ink); }

/* Quiet inline link with an arrow that steps forward on hover. */
.ya-link {
    align-items: center;
    gap: .375rem;
    font-size: .875rem;
    font-weight: 600;
    color: var(--ya-ink);
}
.ya-link .ya-link-arrow {
    transition: transform var(--ya-duration-base) var(--ya-ease-out);
}
.ya-link:hover .ya-link-arrow { transform: translateX(3px); }
[dir="rtl"] .ya-link .ya-link-arrow { transform: scaleX(-1); }
[dir="rtl"] .ya-link:hover .ya-link-arrow { transform: scaleX(-1) translateX(3px); }

/* --------------------------------------------------------------------------
   6. Surfaces
   -------------------------------------------------------------------------- */

.card {
    background: var(--ya-card);
    border: 1px solid var(--ya-border);
    border-radius: var(--ya-r-lg);
    box-shadow: var(--ya-elevation-1);
    transition: box-shadow var(--ya-duration-base) var(--ya-ease-out),
                border-color var(--ya-duration-base) var(--ya-ease-out),
                transform var(--ya-duration-base) var(--ya-ease-out),
                background-color var(--ya-duration-base) var(--ya-ease-inout);
}
a.card, .card.is-interactive { will-change: transform; }
a.card:hover, .card.is-interactive:hover {
    border-color: var(--ya-border-2);
    box-shadow: var(--ya-elevation-2);
    transform: translateY(-3px);
}
a.card:active, .card.is-interactive:active { transform: translateY(-1px); }

/* Flat variant for dense areas (tables, list rows) where a lifted card
   would create visual noise. */
.card-flat {
    background: var(--ya-card);
    border: 1px solid var(--ya-border);
    border-radius: var(--ya-r-lg);
}

/* Recessed well — filters, summaries, anything that reads as "inside". */
.card-sunk {
    background: var(--ya-surface-sunk);
    border: 1px solid var(--ya-border);
    border-radius: var(--ya-r-md);
}

/* Frosted glass. Used for the object that floats on the dark shell (hero
   panel, login rail) — it belongs to the shell, so it does not invert with
   the page theme. */
.card-feature, .ya-glass {
    background: rgba(28, 25, 23, .5);
    backdrop-filter: blur(var(--ya-blur-lg)) saturate(1.1);
    -webkit-backdrop-filter: blur(var(--ya-blur-lg)) saturate(1.1);
    border: 1px solid rgba(248, 250, 252, .12);
    border-radius: var(--ya-r-xl);
    box-shadow: var(--ya-elevation-shell);
}
@supports not (backdrop-filter: blur(1px)) {
    .card-feature, .ya-glass { background: rgba(15, 23, 42, .93); }
}

/* Light frosted glass for surfaces floating over the page. */
.ya-glass-light {
    background: color-mix(in srgb, var(--ya-surface) 72%, transparent);
    backdrop-filter: blur(var(--ya-blur-md)) saturate(1.6);
    -webkit-backdrop-filter: blur(var(--ya-blur-md)) saturate(1.6);
    border: 1px solid var(--ya-border);
    box-shadow: var(--ya-elevation-2);
}

/* The dark shell itself. Always dark in both themes — it is a room, not a
   page surface. */
.stage { background: var(--ya-stage); color: var(--ya-s-100); }
/* Alpha values chosen for contrast, not for looks: .45 composites to 3.95:1
   on the shell, which fails AA for body-sized text. */
.stage .text-ink-soft, .ya-on-shell .text-ink-soft { color: rgba(248, 250, 252, .62); }
.stage .text-ink-faint, .ya-on-shell .text-ink-faint { color: rgba(248, 250, 252, .52); }

/* --------------------------------------------------------------------------
   7. Depth & atmosphere
   --------------------------------------------------------------------------
   Four ingredients, each subtle enough to be felt rather than seen. Never
   stack more than two on one element. */

/* Note: .ya-grain and .ya-vignette both style ::after, so they cannot be
   applied to the same element — the second one wins and the first vanishes.
   Put them on nested elements, or use a scrim instead. */

/* Film grain — a tiling SVG turbulence, no asset request. */
.ya-grain { position: relative; isolation: isolate; }
.ya-grain::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    opacity: var(--ya-grain-opacity);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Vignette — pulls the eye to the centre of a dark band. */
.ya-vignette::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(120% 100% at 50% 45%, transparent 45%,
                rgba(15, 23, 42, var(--ya-vignette-strength)) 100%);
}

/* Pointer-reactive highlight. ya-motion.js writes --ya-mx/--ya-my on hover;
   with no JS the element simply has no highlight. */
.ya-spotlight { position: relative; isolation: isolate; overflow: hidden; }
.ya-spotlight::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0;
    background: radial-gradient(16rem 16rem at var(--ya-mx, 50%) var(--ya-my, 50%),
                rgba(15, 23, 42, .07), transparent 70%);
    transition: opacity var(--ya-duration-base) var(--ya-ease-out);
}
.ya-spotlight:hover::before { opacity: 1; }
.ya-spotlight > * { position: relative; z-index: 1; }
[data-theme="dark"] .ya-spotlight::before,
.stage .ya-spotlight::before {
    background: radial-gradient(16rem 16rem at var(--ya-mx, 50%) var(--ya-my, 50%),
                rgba(248, 250, 252, .09), transparent 70%);
}

/* Hairline that catches the light along a top edge — the cheapest way to
   make a dark surface read as a physical object. */
.ya-rim { box-shadow: inset 0 1px 0 rgba(248, 250, 252, .09); }

/* Mesh gradient, grayscale. Slow enough to register as ambience. */
.ya-mesh {
    background-color: var(--ya-s-900);
    background-image:
        radial-gradient(42% 52% at 18% 22%, rgba(248, 250, 252, .10), transparent 60%),
        radial-gradient(38% 48% at 82% 18%, rgba(248, 250, 252, .07), transparent 62%),
        radial-gradient(50% 60% at 62% 88%, rgba(248, 250, 252, .06), transparent 65%);
}
@media (prefers-reduced-motion: no-preference) {
    .ya-mesh { animation: ya-mesh-drift 28s var(--ya-ease-inout) infinite alternate; }
    @keyframes ya-mesh-drift {
        from { background-position: 0% 0%, 0% 0%, 0% 0%; }
        to   { background-position: 6% 4%, -5% 3%, 3% -5%; }
    }
}

/* --------------------------------------------------------------------------
   8. Badges & pills
   -------------------------------------------------------------------------- */

.badge {
    align-items: center;
    gap: .375rem;
    font-size: .6875rem;
    font-weight: 600;
    letter-spacing: .02em;
    line-height: 1;
    padding: .3125rem .625rem;
    border-radius: var(--ya-r-pill);
    white-space: nowrap;
}
.badge-neutral { background: var(--ya-surface-sunk); color: var(--ya-ink-soft); }
.badge-solid   { background: var(--ya-ink); color: var(--ya-bg); }
.badge-outline { border: 1px solid var(--ya-border-2); color: var(--ya-ink-soft); }
.badge-ok      { background: var(--ya-ok-bg); color: var(--ya-ok); }
.badge-warn    { background: var(--ya-warn-bg); color: var(--ya-warn); }
.badge-danger  { background: var(--ya-danger-bg); color: var(--ya-danger); }
.badge-info    { background: var(--ya-info-bg); color: var(--ya-info); }

/* Catalogue type tag — mono, uppercase, the same voice as .eyebrow. */
.ya-tag {
    align-items: center;
    font-family: var(--ya-font-mono);
    font-size: .625rem;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
    line-height: 1;
    padding: .375rem .5625rem;
    border-radius: var(--ya-r-xs);
    background: var(--ya-surface-sunk);
    color: var(--ya-ink-soft);
    border: 1px solid var(--ya-border);
}
.stage .ya-tag, .ya-on-shell .ya-tag {
    background: rgba(248, 250, 252, .08);
    color: rgba(248, 250, 252, .8);
    border-color: rgba(248, 250, 252, .12);
}

/* Live marker — the only thing in the system allowed to pulse. */
.ya-live { position: relative; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
@media (prefers-reduced-motion: no-preference) {
    .ya-live::after {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: 50%;
        background: currentColor;
        animation: ya-ping 2.4s var(--ya-ease-out) infinite;
    }
    @keyframes ya-ping {
        0%   { transform: scale(1); opacity: .7; }
        70%, 100% { transform: scale(3); opacity: 0; }
    }
}

/* --------------------------------------------------------------------------
   9. Forms
   -------------------------------------------------------------------------- */

.ya-label {
    display: block;
    font-size: .8125rem;
    font-weight: 600;
    color: var(--ya-ink);
    margin-bottom: .4375rem;
}
.ya-hint { font-size: .75rem; color: var(--ya-ink-faint); margin-top: .375rem; }
.ya-error { font-size: .75rem; color: var(--ya-danger); margin-top: .375rem; }

.ya-input, .ya-select, .ya-textarea,
input[type="text"], input[type="email"], input[type="password"],
input[type="search"], input[type="number"], input[type="url"],
input[type="date"], input[type="datetime-local"], input[type="tel"],
textarea, select {
    width: 100%;
    font-family: inherit;
    font-size: .875rem;
    color: var(--ya-ink);
    background: var(--ya-surface);
    border: 1px solid var(--ya-border-2);
    border-radius: var(--ya-r-sm);
    padding: .625rem .8125rem;
    transition: border-color var(--ya-duration-fast) var(--ya-ease-out),
                box-shadow var(--ya-duration-fast) var(--ya-ease-out),
                background-color var(--ya-duration-fast) var(--ya-ease-out);
}
textarea { line-height: 1.6; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--ya-ink-faint); }

input:focus, textarea:focus, select:focus,
.ya-input:focus, .ya-select:focus, .ya-textarea:focus {
    outline: none;
    border-color: var(--ya-ink);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ya-ink) 12%, transparent);
}
input[aria-invalid="true"], .ya-input-error {
    border-color: var(--ya-danger);
}
input[aria-invalid="true"]:focus, .ya-input-error:focus {
    box-shadow: 0 0 0 3px var(--ya-danger-bg);
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%236E6E7A' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='4 6.5 8 10.5 12 6.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right .6875rem center;
    padding-inline-end: 2.25rem;
}
[dir="rtl"] select { background-position: left .6875rem center; padding-inline-start: .8125rem; padding-inline-end: 2.25rem; }

input[type="checkbox"], input[type="radio"] {
    width: 1rem;
    height: 1rem;
    accent-color: var(--ya-ink);
    border-radius: var(--ya-r-xs);
}
input[type="file"] {
    box-sizing: border-box;
    max-width: 100%;
    padding: .5rem;
    font-size: .8125rem;
    color: var(--ya-ink-soft);
    background: var(--ya-surface-sunk);
    border-style: dashed;
}

/* Search field with a leading icon slot. */
.ya-search { position: relative; display: block; }
.ya-search > svg, .ya-search > .ya-search-icon {
    position: absolute;
    inset-inline-start: .75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--ya-ink-faint);
    pointer-events: none;
}
.ya-search input { padding-inline-start: 2.375rem; }

/* Form validation summary emitted by ASP.NET tag helpers. */
.validation-summary-valid.ya-notice, .validation-summary-valid { display: none; }
.validation-summary-errors { color: var(--ya-danger); font-size: .8125rem; }
.validation-summary-errors ul { list-style: none; padding: 0; margin: 0; }
.field-validation-error, .text-danger { color: var(--ya-danger); font-size: .75rem; }
.input-validation-error { border-color: var(--ya-danger) !important; }

/* --------------------------------------------------------------------------
   10. Tables
   -------------------------------------------------------------------------- */

.ya-table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.ya-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
/* Padding is set per-edge rather than with the shorthand, and never on the
   inline-start edge: a cell's leading padding is the page's business (the
   first column usually wants to line up with the card's own padding via
   `ps-5`), and a shorthand here would silently zero that utility out. */
.ya-table th {
    text-align: start;
    font-family: var(--ya-font-mono);
    font-size: .6875rem;
    font-weight: 500;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ya-ink-faint);
    padding-block: 0 .75rem;
    padding-inline-end: 1rem;
    white-space: nowrap;
    border-bottom: 1px solid var(--ya-border);
}
.ya-table th:last-child, .ya-table td:last-child { padding-inline-end: 0; }
.ya-table td {
    padding-block: .875rem;
    padding-inline-end: 1rem;
    border-bottom: 1px solid var(--ya-border);
    vertical-align: middle;
}
.ya-table tbody tr { transition: background-color var(--ya-duration-fast) var(--ya-ease-out); }
.ya-table tbody tr:hover { background: var(--ya-surface-sunk); }
.ya-table tbody tr:last-child td { border-bottom: 0; }
.ya-table .ya-td-end { text-align: end; }

/* --------------------------------------------------------------------------
   11. States — empty, loading, flash
   -------------------------------------------------------------------------- */

.ya-empty {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: clamp(2.5rem, 6vw, 4.5rem) 1.5rem;
}
.ya-empty-mark {
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    border-radius: var(--ya-r-md);
    background: var(--ya-surface-sunk);
    color: var(--ya-ink-faint);
    border: 1px solid var(--ya-border);
    margin-bottom: 1.125rem;
}
@media (prefers-reduced-motion: no-preference) {
    .ya-empty-mark { animation: ya-float 5s var(--ya-ease-inout) infinite; }
    @keyframes ya-float {
        0%, 100% { transform: translateY(0); }
        50%      { transform: translateY(-5px); }
    }
}
.ya-empty-title { font-size: 1rem; font-weight: 600; color: var(--ya-ink); margin-bottom: .375rem; }
.ya-empty-body { font-size: .875rem; color: var(--ya-ink-faint); max-width: 30rem; margin-bottom: 1.25rem; }

/* Success mark. Reserved for the confirmation of something irreversible —
   an order placed, a message sent — so it is allowed to draw itself. Under
   reduced motion it is simply already drawn. */
.ya-check-mark {
    width: 4rem;
    height: 4rem;
    color: var(--ya-ink);
}
@media (prefers-reduced-motion: no-preference) {
    .ya-check-ring {
        stroke-dasharray: 151;
        stroke-dashoffset: 151;
        animation: ya-draw .7s var(--ya-ease-out) forwards;
    }
    .ya-check-tick {
        stroke-dasharray: 36;
        stroke-dashoffset: 36;
        animation: ya-draw .35s var(--ya-ease-out) .5s forwards;
    }
    @keyframes ya-draw { to { stroke-dashoffset: 0; } }
}

.ya-skeleton {
    background: var(--ya-surface-sunk);
    border-radius: var(--ya-r-sm);
    position: relative;
    overflow: hidden;
}
@media (prefers-reduced-motion: no-preference) {
    .ya-skeleton::after {
        content: "";
        position: absolute;
        inset: 0;
        transform: translateX(-100%);
        background: linear-gradient(90deg, transparent,
                    color-mix(in srgb, var(--ya-ink) 6%, transparent), transparent);
        animation: ya-shimmer 1.6s var(--ya-ease-inout) infinite;
    }
    @keyframes ya-shimmer { to { transform: translateX(100%); } }
}

/* Flash / inline notice. */
.ya-notice {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: .875rem 1rem;
    border-radius: var(--ya-r-md);
    border: 1px solid var(--ya-border);
    background: var(--ya-surface);
    box-shadow: var(--ya-elevation-1);
    font-size: .875rem;
    border-inline-start: 3px solid var(--ya-ink);
}
.ya-notice-ok     { border-inline-start-color: var(--ya-ok); }
.ya-notice-warn   { border-inline-start-color: var(--ya-warn); }
.ya-notice-danger { border-inline-start-color: var(--ya-danger); }

/* Determinate progress. */
.ya-progress { height: 4px; border-radius: var(--ya-r-pill); background: var(--ya-surface-sunk); overflow: hidden; }
.ya-progress > span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--ya-ink);
    transform-origin: left center;
    transition: width var(--ya-duration-slow) var(--ya-ease-out);
}
[dir="rtl"] .ya-progress > span { transform-origin: right center; }

/* --------------------------------------------------------------------------
   12. Menus & overlays
   -------------------------------------------------------------------------- */

.ya-menu {
    min-width: 12rem;
    padding: .375rem;
    border-radius: var(--ya-r-md);
    background: var(--ya-surface);
    border: 1px solid var(--ya-border);
    box-shadow: var(--ya-elevation-3);
}
.ya-menu-item {
    display: flex;
    align-items: center;
    gap: .625rem;
    width: 100%;
    text-align: start;
    padding: .5rem .625rem;
    border-radius: var(--ya-r-xs);
    font-size: .875rem;
    color: var(--ya-ink-soft);
    transition: background-color var(--ya-duration-instant) var(--ya-ease-out),
                color var(--ya-duration-instant) var(--ya-ease-out);
}
.ya-menu-item:hover { background: var(--ya-surface-sunk); color: var(--ya-ink); }
.ya-menu-item.is-active { color: var(--ya-ink); font-weight: 600; }
.ya-menu-label {
    padding: .5rem .625rem .375rem;
    font-family: var(--ya-font-mono);
    font-size: .625rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ya-ink-faint);
}
.ya-menu-sep { height: 1px; background: var(--ya-border); margin: .375rem 0; }

/* <details> menus open with a short drop — restarting automatically because
   the panel goes from display:none to visible, so no JS is involved. */
@media (prefers-reduced-motion: no-preference) {
    details[open] > .ya-menu, details[open] > .card { animation: ya-drop .18s var(--ya-ease-out); }
    @keyframes ya-drop {
        from { opacity: 0; transform: translateY(-6px) scale(.985); }
        to   { opacity: 1; transform: translateY(0) scale(1); }
    }
}
summary::-webkit-details-marker { display: none; }
summary { list-style: none; }

/* --------------------------------------------------------------------------
   13. Motion utilities
   --------------------------------------------------------------------------
   ya-motion.js adds .is-in when an element enters the viewport. Elements
   start hidden ONLY when JS has marked the document ready for it, so a
   failed script can never leave the page blank. */

html.ya-motion [data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity var(--ya-duration-slow) var(--ya-ease-out),
                transform var(--ya-duration-slow) var(--ya-ease-out);
    transition-delay: var(--ya-delay, 0ms);
    will-change: opacity, transform;
}
html.ya-motion [data-reveal="fade"]  { transform: none; }
html.ya-motion [data-reveal="left"]  { transform: translateX(-24px); }
html.ya-motion [data-reveal="right"] { transform: translateX(24px); }
html.ya-motion [data-reveal="scale"] { transform: scale(.965); }
html.ya-motion [data-reveal].is-in {
    opacity: 1;
    transform: none;
}

/* Line-by-line mask reveal for the hero headline — the one orchestrated
   entrance in the product.

   Two things this has to get right:

   1. The mask must clip above and below the line without eating ascenders
      and descenders, which a plain overflow:hidden on a display-tight
      line-height does. Padding gives the glyphs room; an equal negative
      margin gives the space back to the layout, so the type sits exactly
      where it would unmasked.

   2. It is driven by the same .is-in class as every other reveal rather
      than by a keyframe with a fill mode. A keyframe that stalls leaves
      the headline permanently unreadable; a transition to a resting state
      the failsafe in ya-motion.js can force cannot. */
.ya-line {
    display: block;
    overflow: hidden;
    padding: .06em 0 .2em;
    margin: -.06em 0 -.2em;
}
.ya-line > span { display: block; }
html.ya-motion .ya-line > span {
    transform: translateY(110%);
    transition: transform .95s var(--ya-ease-out);
    transition-delay: var(--ya-delay, 0ms);
    will-change: transform;
}
html.ya-motion .ya-line.is-in > span { transform: translateY(0); }

/* A single deliberate entrance for above-the-fold content that must not
   wait for an observer. */
@media (prefers-reduced-motion: no-preference) {
    .reveal { animation: ya-rise .8s var(--ya-ease-out) both; }
    .reveal-delay-1 { animation-delay: .08s; }
    .reveal-delay-2 { animation-delay: .16s; }
    .reveal-delay-3 { animation-delay: .24s; }
    @keyframes ya-rise {
        from { opacity: 0; transform: translateY(14px); }
        to   { opacity: 1; transform: translateY(0); }
    }
}

/* Image that settles as it loads. */
.ya-img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ya-zoom { overflow: hidden; }
.ya-zoom .ya-img { transition: transform var(--ya-duration-slow) var(--ya-ease-out); }
.ya-zoom:hover .ya-img, a:hover > .ya-zoom .ya-img, .group:hover .ya-zoom .ya-img { transform: scale(1.045); }

/* Reading progress bar for long-form pages. */
.ya-scroll-progress {
    position: fixed;
    inset-block-start: 0;
    inset-inline: 0;
    height: 2px;
    z-index: 60;
    background: var(--ya-ink);
    transform: scaleX(var(--ya-progress, 0));
    transform-origin: left center;
    pointer-events: none;
}
[dir="rtl"] .ya-scroll-progress { transform-origin: right center; }

/* --------------------------------------------------------------------------
   14. Reduced motion
   --------------------------------------------------------------------------
   Everything degrades to its finished state rather than disappearing. */

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
    html.ya-motion [data-reveal] { opacity: 1 !important; transform: none !important; }
    html.ya-motion .ya-line > span { transform: none !important; }
}

/* Theme toggle — both icons stay in the DOM and CSS picks one, so the
   correct glyph is painted on the first frame without waiting for script
   (data-theme is already set by _HeadBoot). */
.theme-icon-sun { display: none; }
[data-theme="dark"] .theme-icon-sun { display: block; }
[data-theme="dark"] .theme-icon-moon { display: none; }

/* --------------------------------------------------------------------------
   15. Scrollbar & print
   -------------------------------------------------------------------------- */

@supports selector(::-webkit-scrollbar) {
    ::-webkit-scrollbar { width: 11px; height: 11px; }
    ::-webkit-scrollbar-track { background: transparent; }
    ::-webkit-scrollbar-thumb {
        background: var(--ya-n-300);
        border-radius: var(--ya-r-pill);
        border: 3px solid var(--ya-bg);
    }
    ::-webkit-scrollbar-thumb:hover { background: var(--ya-n-400); }
    [data-theme="dark"] ::-webkit-scrollbar-thumb { background: var(--ya-s-600); }
}

@media print {
    .ya-no-print, header, footer, nav { display: none !important; }
    body { background: #fff; color: #000; }
    .card { box-shadow: none; border: 1px solid #ddd; }
}

/* Feature-specific category filters, shared by public and admin lists. */
.ya-category-filter { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem; margin-bottom: 1.5rem; }
.ya-category-filter-form { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; min-width: 0; }
.ya-category-filter-form .ya-label { margin: 0; }
.ya-category-filter-form select { width: auto; min-width: 12rem; max-width: 100%; }
.ya-category-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.5rem; }
.ya-category-tabs [aria-current="page"] { color: var(--ya-accent-ink); background: var(--ya-accent); border-color: var(--ya-accent); }
@media (max-width: 480px) { .ya-category-filter-form { width: 100%; } .ya-category-filter-form select { flex: 1; min-width: 0; } }
