:root {
    --zy-ink: #102a2a;
    --zy-muted: #627170;
    --zy-canvas: #f3f7f6;
    --zy-surface: #ffffff;
    --zy-surface-soft: #eaf4f1;
    --zy-surface-muted: #f6f9f8;
    --zy-border: #d8e3e0;
    --zy-control-border: #9ab0ac;
    --zy-primary: #0f766e;
    --zy-primary-dark: #0a554f;
    --zy-primary-light: #d5f2eb;
    --zy-primary-050: #d5f2eb;
    --zy-primary-700: #0f766e;
    --zy-primary-900: #073d39;
    --zy-accent: #f59e0b;
    --zy-danger: #b42318;
    --zy-danger-surface: #fff8f8;
    --zy-danger-border: #efc8c8;
    --zy-danger-muted: #795454;
    --zy-success: #13795b;
    --zy-shadow-sm: 0 1px 2px rgb(15 42 42 / 6%), 0 4px 12px rgb(15 42 42 / 5%);
    --zy-shadow-md: 0 10px 30px rgb(15 42 42 / 12%);
    --zy-shadow-lg: 0 20px 60px rgb(8 47 43 / 16%);
    --zy-radius-sm: 0.65rem;
    --zy-radius: 1rem;
    --zy-radius-lg: 1.5rem;
    --zy-sidebar-width: 17rem;
    --zy-topbar-height: 4.5rem;
    --zy-focus: 0 0 0 0.22rem rgb(15 118 110 / 22%);
    --bs-primary: #0f766e;
    --bs-primary-rgb: 15, 118, 110;
    --bs-success: #13795b;
    --bs-success-rgb: 19, 121, 91;
    --bs-danger: #b42318;
    --bs-danger-rgb: 180, 35, 24;
    --bs-info: #0e7490;
    --bs-info-rgb: 14, 116, 144;
}

html[data-zysales-ui] { max-width: 100%; overflow-x: clip; }

:root[data-theme="dark"] {
    color-scheme: dark;
    --zy-ink: #eefaf8;
    --zy-muted: #b2c8c4;
    --zy-canvas: #071512;
    --zy-surface: #10231f;
    --zy-surface-soft: #18312c;
    --zy-surface-muted: #142a25;
    --zy-border: #35534d;
    --zy-control-border: #607b75;
    --zy-primary: #5eead4;
    --zy-primary-dark: #99f6e4;
    --zy-primary-light: #173f38;
    --zy-primary-050: #173f38;
    --zy-primary-700: #0f766e;
    --zy-primary-900: #99f6e4;
    --zy-accent: #fbbf24;
    --zy-danger: #fda29b;
    --zy-danger-surface: #351716;
    --zy-danger-border: #81433f;
    --zy-danger-muted: #f4bbb5;
    --zy-success: #6ee7b7;
    --zy-shadow-sm: 0 1px 2px rgb(0 0 0 / 28%), 0 6px 18px rgb(0 0 0 / 18%);
    --zy-shadow-md: 0 12px 34px rgb(0 0 0 / 36%);
    --zy-shadow-lg: 0 24px 70px rgb(0 0 0 / 52%);
    --zy-focus: 0 0 0 0.22rem rgb(94 234 212 / 32%);
    --bs-primary: #5eead4;
    --bs-primary-rgb: 94, 234, 212;
    --bs-success: #6ee7b7;
    --bs-success-rgb: 110, 231, 183;
    --bs-danger: #fda29b;
    --bs-danger-rgb: 253, 162, 155;
    --bs-info: #67e8f9;
    --bs-info-rgb: 103, 232, 249;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.zy-ui {
    min-height: 100vh;
    margin: 0;
    color: var(--zy-ink);
    background: var(--zy-canvas);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 0.95rem;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

body.zy-ui h1, body.zy-ui h2, body.zy-ui h3,
body.zy-ui h4, body.zy-ui h5, body.zy-ui h6 {
    color: var(--zy-ink);
    font-weight: 720;
    letter-spacing: -0.025em;
}

body.zy-ui a { text-underline-offset: 0.18em; }
body.zy-ui a:not(.btn):not(.nav-link) { color: var(--zy-primary-dark); }

.zy-skip-link {
    position: fixed;
    z-index: 2000;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.65rem 1rem;
    color: #fff;
    background: var(--zy-primary-dark);
    border-radius: var(--zy-radius-sm);
    transform: translateY(-180%);
    transition: transform 150ms ease;
}

.zy-skip-link:focus { transform: translateY(0); }

/* Sign-in */
.zy-login-page { background: #e9f2f0 !important; }

.zy-login-shell {
    display: grid;
    grid-template-columns: minmax(22rem, 1.05fr) minmax(25rem, 0.95fr);
    min-height: 100vh;
}

.zy-login-story {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100%;
    overflow: hidden;
    padding: clamp(2rem, 5vw, 5rem);
    color: #effcf8;
    background:
        radial-gradient(circle at 85% 16%, rgb(245 158 11 / 30%), transparent 22rem),
        radial-gradient(circle at 8% 92%, rgb(45 212 191 / 22%), transparent 26rem),
        linear-gradient(145deg, #082f2b 0%, #0f5d56 48%, #0f766e 100%);
}

.zy-login-story::after {
    position: absolute;
    right: -8rem;
    bottom: -9rem;
    width: 28rem;
    height: 28rem;
    content: "";
    border: 1px solid rgb(255 255 255 / 13%);
    border-radius: 50%;
    box-shadow: 0 0 0 4rem rgb(255 255 255 / 3%), 0 0 0 8rem rgb(255 255 255 / 2%);
}

.zy-brand-lockup, .zy-mobile-brand {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 0.8rem;
    align-items: center;
}

.zy-brand-mark {
    display: inline-grid;
    width: 2.7rem;
    height: 2.7rem;
    color: #fff;
    font-size: 0.88rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    background: linear-gradient(145deg, #19a596, #0f766e);
    border: 1px solid rgb(255 255 255 / 25%);
    border-radius: 0.85rem;
    box-shadow: 0 8px 20px rgb(4 39 36 / 22%);
    place-items: center;
    object-fit: contain;
}

.zy-login-story .zy-brand-mark { background: rgb(255 255 255 / 15%); }
.zy-brand-name { font-size: 1.08rem; font-weight: 750; letter-spacing: -0.02em; }

.zy-story-copy { position: relative; z-index: 1; max-width: 38rem; }
.zy-eyebrow {
    margin: 0 0 0.85rem;
    color: var(--zy-primary);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.zy-login-story .zy-eyebrow { color: #8ee7d8; }
.zy-story-copy h1 {
    max-width: 12ch;
    margin: 0 0 1.25rem;
    color: #fff !important;
    font-size: clamp(2.6rem, 5vw, 5.25rem);
    line-height: 0.98;
}
.zy-story-copy > p:last-child { max-width: 46ch; margin: 0; color: #c9e5df; font-size: 1.08rem; }

.zy-trust-row {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem 1.5rem;
    color: #c9e5df;
    font-size: 0.82rem;
    font-weight: 650;
}

.zy-status-dot {
    display: inline-block;
    width: 0.48rem;
    height: 0.48rem;
    margin-right: 0.45rem;
    background: #2dd4bf;
    border-radius: 50%;
    box-shadow: 0 0 0 0.2rem rgb(45 212 191 / 15%);
}

.zy-login-panel {
    display: grid;
    min-height: 100%;
    padding: clamp(1.25rem, 4vw, 4rem);
    background:
        linear-gradient(rgb(255 255 255 / 68%), rgb(255 255 255 / 68%)),
        repeating-linear-gradient(45deg, transparent 0 26px, rgb(15 118 110 / 3%) 26px 27px);
    place-items: center;
}

.zy-login-card { width: min(100%, 31rem); padding: clamp(1.3rem, 3vw, 2.4rem); }
.zy-mobile-brand { display: none; margin-bottom: 2.5rem; }
.zy-login-heading { margin-bottom: 2rem; }
.zy-login-heading h2 { margin: 0 0 0.6rem; font-size: clamp(1.8rem, 3vw, 2.35rem); }
.zy-login-heading > p:last-child { margin: 0; color: var(--zy-muted); }

.zy-message-stack { display: grid; gap: 0.65rem; margin-bottom: 1.25rem; }
.zy-login-page .alert {
    margin: 0;
    padding: 0.85rem 1rem;
    border: 0;
    border-left: 3px solid currentColor;
    border-radius: var(--zy-radius-sm);
    font-size: 0.9rem;
}

.zy-field { margin-bottom: 1.2rem; }
.zy-field label, .zy-label-row {
    margin-bottom: 0.45rem;
    color: var(--zy-ink);
    font-size: 0.86rem;
    font-weight: 700;
}
.zy-label-row { display: flex; align-items: center; justify-content: space-between; }
.zy-label-row label { margin: 0; }
.zy-access-help { position: relative; color: var(--zy-muted); font-size: 0.78rem; font-weight: 600; }
.zy-access-help summary { color: var(--zy-primary); cursor: pointer; list-style: none; }
.zy-access-help summary::-webkit-details-marker { display: none; }
.zy-access-help > div {
    position: absolute;
    z-index: 10;
    top: calc(100% + 0.55rem);
    right: 0;
    width: min(19rem, 78vw);
    padding: 0.75rem 0.85rem;
    color: var(--zy-ink);
    line-height: 1.45;
    background: var(--zy-surface);
    border: 1px solid var(--zy-border);
    border-radius: 0.7rem;
    box-shadow: var(--zy-shadow-lg);
}
.zy-input-wrap { position: relative; }
.zy-input-wrap > svg {
    position: absolute;
    top: 50%;
    left: 1rem;
    width: 1.15rem;
    height: 1.15rem;
    fill: none;
    stroke: #68817e;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
    transform: translateY(-50%);
    pointer-events: none;
}
.zy-input-wrap input {
    width: 100%;
    min-height: 3.2rem;
    padding: 0.75rem 4.2rem 0.75rem 3rem;
    color: var(--zy-ink);
    background: var(--zy-surface);
    border: 1px solid #c8d7d4;
    border-radius: 0.85rem;
    outline: none;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}
.zy-input-wrap input:hover { border-color: #8ba9a5; }
.zy-input-wrap input:focus { border-color: var(--zy-primary); box-shadow: var(--zy-focus); }
.zy-password-toggle {
    position: absolute;
    top: 50%;
    right: 0.65rem;
    padding: 0.45rem 0.55rem;
    color: var(--zy-primary-dark);
    font-size: 0.78rem;
    font-weight: 750;
    background: transparent;
    border: 0;
    border-radius: 0.45rem;
    transform: translateY(-50%);
}

.zy-primary-action {
    display: flex;
    width: 100%;
    min-height: 3.25rem;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    margin-top: 1.65rem;
    color: #fff;
    font-weight: 760;
    background: linear-gradient(135deg, #0f766e, #0a5f58);
    border: 0;
    border-radius: 0.9rem;
    box-shadow: 0 10px 24px rgb(15 118 110 / 23%);
    transition: transform 140ms ease, box-shadow 140ms ease;
}
.zy-primary-action:hover { transform: translateY(-1px); box-shadow: 0 14px 30px rgb(15 118 110 / 28%); }
.zy-primary-action:active { transform: translateY(0); }
.zy-primary-action svg { width: 1.15rem; height: 1.15rem; fill: none; stroke: currentColor; stroke-width: 2; }
.zy-primary-action[disabled] { cursor: wait; opacity: 0.72; }

.zy-readiness-note {
    margin-top: 1.4rem;
    padding: 0.9rem 1rem;
    color: #35514e;
    background: var(--zy-surface-soft);
    border-radius: var(--zy-radius-sm);
    font-size: 0.78rem;
}
.zy-readiness-note strong { display: block; margin-bottom: 0.15rem; color: var(--zy-primary-dark); }
.zy-login-footer { margin-top: 2rem; color: var(--zy-muted); font-size: 0.76rem; text-align: center; }

/* Application shell */
body.zy-ui:not(.zy-login-page) { padding-top: var(--zy-topbar-height); }
body.zy-ui:not(.zy-login-page) > .navbar {
    position: fixed;
    z-index: 1040;
    top: 0;
    right: 0;
    left: 0;
    min-height: var(--zy-topbar-height);
    padding: 0 1.25rem;
    color: var(--zy-ink);
    background: color-mix(in srgb, var(--zy-surface) 94%, transparent) !important;
    border-bottom: 1px solid var(--zy-border);
    box-shadow: 0 4px 18px rgb(15 42 42 / 4%);
    backdrop-filter: blur(14px);
}
body.zy-ui .navbar .container-fluid { gap: 0.75rem; }
body.zy-ui .navbar-brand { display: flex; max-width: min(48vw, 31rem); align-items: center; color: var(--zy-ink) !important; font-weight: 780; }
body.zy-ui .zy-navbar-mark {
    display: block;
    flex: 0 0 auto;
    width: 2.35rem;
    height: 2.35rem;
    margin-right: 0.7rem;
}
body.zy-ui .navbar-logo { display: none; }
body.zy-ui .navbar .ms-auto { display: flex; align-items: center; color: var(--zy-muted) !important; font-size: 0.84rem; font-weight: 650; }
body.zy-ui .navbar .btn-outline-light {
    min-height: 2.4rem;
    color: var(--zy-ink);
    background: var(--zy-surface);
    border-color: var(--zy-border);
}

.zy-nav-toggle {
    display: none;
    width: 2.75rem;
    height: 2.75rem;
    flex: 0 0 auto;
    color: var(--zy-ink);
    background: var(--zy-surface);
    border: 1px solid var(--zy-border);
    border-radius: 0.75rem;
    place-items: center;
}
.zy-nav-toggle span, .zy-nav-toggle span::before, .zy-nav-toggle span::after {
    display: block;
    width: 1.15rem;
    height: 2px;
    content: "";
    background: currentColor;
    border-radius: 2px;
}
.zy-nav-toggle span { position: relative; }
.zy-nav-toggle span::before { position: absolute; top: -0.38rem; }
.zy-nav-toggle span::after { position: absolute; top: 0.38rem; }

body.zy-ui .sidebar {
    position: fixed;
    z-index: 1035;
    top: var(--zy-topbar-height);
    display: block;
    width: var(--zy-sidebar-width);
    height: calc(100vh - var(--zy-topbar-height));
    padding: 0.85rem;
    background: linear-gradient(180deg, #123b38, #092f2c) !important;
    border-right: 0;
    box-shadow: 12px 0 30px rgb(15 42 42 / 8%);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-color: #4e8e87 #092f2c;
    scrollbar-gutter: stable;
}
body.zy-ui .sidebar .nav { gap: 0.2rem; padding: 0 !important; }
body.zy-ui .sidebar .nav-link {
    display: flex;
    min-height: 2.85rem;
    align-items: center;
    padding: 0.7rem 0.9rem;
    color: #c5ddda;
    font-size: 0.88rem;
    font-weight: 620;
    border: 0;
    border-radius: 0.72rem;
    transition: color 130ms ease, background 130ms ease, transform 130ms ease;
}
body.zy-ui .sidebar .nav-link:hover { color: #fff; background: rgb(255 255 255 / 8%); transform: translateX(2px); }
body.zy-ui .sidebar .nav-link.active { color: #fff; background: linear-gradient(135deg, #16877d, #0f766e); box-shadow: 0 7px 16px rgb(1 25 23 / 25%); }
body.zy-ui .sidebar .nav-link i { width: 1.25rem; color: #78d7cb; text-align: center; }
body.zy-ui .sidebar .nav-link.active i { color: #fff; }

body.zy-ui .nav-tabs .nav-link.active,
body.zy-ui .nav-pills .nav-link.active,
body.zy-ui [role="tab"][aria-selected="true"] {
    color: #fff !important;
    background: #0f766e;
    border-color: #0f766e;
}
.zy-nav-search { position: sticky; z-index: 2; top: -0.85rem; margin: -0.85rem -0.1rem 0.7rem; padding: 0.85rem 0.1rem 0.15rem; background: #123b38; }
.zy-nav-search label { position: absolute; top: 50%; left: 0.8rem; color: #91b8b2; transform: translateY(-50%); }
.zy-nav-search input { width: 100%; min-height: 2.65rem; padding: 0.55rem 0.75rem 0.55rem 2.35rem; color: #f5fffd; background: rgb(255 255 255 / 8%); border: 1px solid rgb(255 255 255 / 12%); border-radius: 0.72rem; outline: 0; }
.zy-nav-search input::placeholder { color: #a9c6c1; }
.zy-nav-search input:focus { border-color: #72d8ca; box-shadow: 0 0 0 0.2rem rgb(114 216 202 / 18%); }
.zy-nav-empty { margin: 0.6rem; color: #a9c6c1; font-size: 0.78rem; }

.zy-sidebar-overlay { display: none; }
body.zy-ui .content-area {
    width: auto;
    max-width: 100%;
    min-height: calc(100vh - var(--zy-topbar-height));
    margin-left: var(--zy-sidebar-width);
    padding: clamp(1rem, 2.6vw, 2.25rem);
}
body.zy-ui .section > .d-flex:first-child { gap: 1rem; flex-wrap: wrap; }
body.zy-ui .section > h2, body.zy-ui .section > .d-flex:first-child h2 { font-size: clamp(1.45rem, 2.5vw, 2rem); }

.zy-section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.zy-section-heading h2 { margin: 0; font-size: clamp(1.45rem, 2.5vw, 2rem); }
.zy-section-kicker { margin: 0 0 0.25rem; color: var(--zy-primary); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.zy-product-search { position: relative; display: block; width: min(100%, 29rem); }
.zy-product-search > i { position: absolute; top: 1rem; left: 1rem; color: #66807c; pointer-events: none; }
.zy-product-search input {
    width: 100%;
    min-height: 3.15rem;
    padding: 0.7rem 6.5rem 0.7rem 2.85rem;
    color: var(--zy-ink);
    background: var(--zy-surface);
    border: 1px solid #cbd9d6;
    border-radius: 0.9rem;
    outline: none;
    box-shadow: var(--zy-shadow-sm);
}
.zy-product-search input:focus { border-color: var(--zy-primary); box-shadow: var(--zy-focus); }
.zy-product-search small { position: absolute; top: 50%; right: 0.8rem; color: var(--zy-muted); font-size: 0.7rem; font-weight: 700; transform: translateY(-50%); pointer-events: none; }
.zy-sale-product[hidden] { display: none !important; }
.zy-product-empty {
    width: calc(100% - 1.5rem);
    margin: 0 0.75rem;
    padding: 2.5rem 1rem;
    color: var(--zy-muted);
    text-align: center;
    background: var(--zy-surface);
    border: 1px dashed #afc6c1;
    border-radius: var(--zy-radius);
}
.zy-product-empty[hidden] { display: none !important; }

/* Components */
body.zy-ui .card {
    overflow: visible;
    background: var(--zy-surface);
    border: 1px solid var(--zy-border);
    border-radius: var(--zy-radius);
    box-shadow: var(--zy-shadow-sm);
}
body.zy-ui .card-header {
    padding: 1rem 1.15rem;
    color: var(--zy-ink) !important;
    background: var(--zy-surface-soft) !important;
    border-bottom-color: var(--zy-border);
    border-radius: var(--zy-radius) var(--zy-radius) 0 0 !important;
}
body.zy-ui .card-body { padding: clamp(1rem, 2vw, 1.35rem); }
body.zy-ui .stat-card { min-height: 8.25rem; box-shadow: var(--zy-shadow-sm); }
body.zy-ui .stat-card:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgb(15 42 42 / 9%); }
body.zy-ui .stat-card h6 { margin-bottom: 0.6rem; color: var(--zy-muted) !important; font-size: 0.78rem; letter-spacing: 0.03em; text-transform: uppercase; }
body.zy-ui .stat-card h3 { margin: 0; font-size: clamp(1.45rem, 2.3vw, 2rem); }
body.zy-ui .stat-card .fa-2x { font-size: 1.35rem; }

body.zy-ui .btn {
    min-height: 2.55rem;
    padding: 0.54rem 0.9rem;
    font-size: 0.86rem;
    font-weight: 680;
    border-radius: 0.72rem;
    transition: transform 120ms ease, box-shadow 120ms ease, background-color 120ms ease;
}
body.zy-ui .btn:hover { transform: translateY(-1px); }
body.zy-ui .btn-primary { background: var(--zy-primary); border-color: var(--zy-primary); }
body.zy-ui .btn-primary:hover { background: var(--zy-primary-dark); border-color: var(--zy-primary-dark); }
body.zy-ui .btn-success { background: var(--zy-success); border-color: var(--zy-success); }
body.zy-ui .btn-info { color: #fff; background: #0e7490; border-color: #0e7490; }
body.zy-ui .btn-danger { background: var(--zy-danger); border-color: var(--zy-danger); }
body.zy-ui .btn-sm { min-height: 2.2rem; }
body.zy-ui .table-actions { min-width: 10rem; }
body.zy-ui .table-actions .btn { display: inline-grid; min-width: 2.2rem; padding: 0.4rem; place-items: center; }

body.zy-ui .form-control, body.zy-ui .form-select {
    min-height: 2.8rem;
    color: var(--zy-ink);
    background-color: var(--zy-surface);
    border-color: var(--zy-control-border);
    border-radius: 0.72rem;
}
body.zy-ui .form-control:hover, body.zy-ui .form-select:hover { border-color: var(--zy-primary); }
body.zy-ui .form-control:focus, body.zy-ui .form-select:focus {
    border-color: var(--zy-primary);
    box-shadow: var(--zy-focus);
}
body.zy-ui .form-control::placeholder { color: var(--zy-muted); opacity: 1; }
:root[data-theme="dark"] body.zy-ui .form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23b2c8c4' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}
body.zy-ui label, body.zy-ui .form-label { color: var(--zy-ink); font-size: 0.84rem; font-weight: 680; }
body.zy-ui .input-group-text { color: var(--zy-muted); background: var(--zy-surface-soft); border-color: var(--zy-border); }

body.zy-ui .table-responsive {
    overflow-x: auto;
    border: 1px solid var(--zy-border);
    border-radius: 0.8rem;
    -webkit-overflow-scrolling: touch;
}
body.zy-ui .table { margin: 0; font-size: 0.86rem; }
body.zy-ui .table > :not(caption) > * > * { padding: 0.78rem 0.85rem; border-bottom-color: #e4ecea; vertical-align: middle; }
body.zy-ui .table thead th {
    color: var(--zy-muted);
    font-size: 0.72rem;
    font-weight: 790;
    letter-spacing: 0.045em;
    background: var(--zy-surface-soft);
    text-transform: uppercase;
    white-space: nowrap;
}
body.zy-ui .table tbody tr:last-child td { border-bottom: 0; }
body.zy-ui .table-hover tbody tr:hover > * { background-color: var(--zy-surface-soft); }
.zy-table-region {
    max-width: 100%;
    min-width: 0;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
}
.zy-table-region:focus-visible { outline: 3px solid var(--zy-primary); outline-offset: 3px; }
.zy-table-wide { min-width: 58rem; }
.zy-table-hint { margin: 0 0 0.6rem; color: var(--zy-muted); font-size: 0.78rem; }
.zy-table-hint[hidden] { display: none; }

.zy-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 10.5rem), 1fr));
    gap: 0.85rem;
    align-items: end;
}
.zy-filter-grid label { display: grid; gap: 0.3rem; }
.zy-filter-grid .zy-filter-search { grid-column: span 2; }
.zy-package-identity { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr)); gap: 0.75rem; margin-bottom: 1rem; }
.zy-package-identity > div { display: grid; gap: 0.15rem; padding: 0.8rem; background: var(--zy-surface-muted); border: 1px solid var(--zy-border); border-radius: 0.75rem; }
.zy-package-identity span, .zy-package-identity small { color: var(--zy-muted); font-size: 0.78rem; }
.zy-package-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-top: 1rem; }
.zy-package-columns > * { min-width: 0; }
.zy-package-columns h3 { font-size: 0.95rem; }
.zy-package-source { margin-bottom: 1rem; }
.zy-definition-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr)); gap: 0.7rem; margin: 0; }
.zy-definition-grid > div { min-width: 0; padding: 0.7rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.7rem; }
.zy-definition-grid dt { color: var(--zy-muted); font-size: 0.7rem; font-weight: 800; letter-spacing: 0.035em; text-transform: uppercase; }
.zy-definition-grid dd { margin: 0.15rem 0 0; color: var(--zy-ink); overflow-wrap: anywhere; }
.zy-subpanel { padding: 0.9rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.8rem; }
.zy-subpanel h2 { font-size: 1rem; }
.zy-help { color: var(--zy-muted); font-weight: 500; }
.zy-chip-list { display: flex; flex-wrap: wrap; gap: 0.45rem; margin-bottom: 0.75rem; }
.zy-chip { padding: 0.4rem 0.65rem; color: var(--zy-ink); background: var(--zy-primary-light); border: 1px solid var(--zy-border); border-radius: 999px; }
.zy-filter-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.zy-pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; margin-top: 1rem; color: var(--zy-muted); font-size: 0.82rem; }
.zy-pagination > div { display: flex; gap: 0.5rem; }

.zy-connectivity {
    position: sticky;
    z-index: 100;
    top: 0.5rem;
    display: flex;
    gap: 0.55rem;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.75rem 0.9rem;
    color: #5f3d00;
    background: #fff2bd;
    border: 1px solid #d99c10;
    border-radius: 0.8rem;
    box-shadow: var(--zy-shadow-sm);
}
.zy-connectivity[hidden] { display: none; }
:root[data-theme="dark"] .zy-connectivity { color: #fff1bd; background: #49340b; border-color: #c58a12; }

.zy-job-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 0.75rem; }
.zy-job-summary > div { padding: 0.85rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.75rem; }
.zy-job-summary span, .zy-job-summary strong { display: block; }
.zy-job-summary span { color: var(--zy-muted); font-size: 0.76rem; }
.zy-job-progress { height: 0.7rem; margin-top: 1rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); }
.zy-job-progress .progress-bar { background: var(--zy-primary); }
.zy-status-queued, .zy-status-retrying { color: #704b00; background: #fff0b8; }
.zy-status-running { color: #075985; background: #d9f2ff; }
.zy-status-succeeded { color: #0b5f48; background: #d9f7eb; }
.zy-status-failed { color: #8f1d16; background: #fde2e2; }
:root[data-theme="dark"] .zy-status-queued, :root[data-theme="dark"] .zy-status-retrying { color: #fff1bd; background: #4a350b; }
:root[data-theme="dark"] .zy-status-running { color: #c8efff; background: #12384b; }
:root[data-theme="dark"] .zy-status-succeeded { color: #c2f8e5; background: #124333; }
:root[data-theme="dark"] .zy-status-failed { color: #ffd4d0; background: #55211e; }

body.zy-ui .badge { padding: 0.42rem 0.62rem; font-size: 0.72rem; font-weight: 720; border-radius: 999px; }
body.zy-ui .alert {
    border: 0;
    border-left: 3px solid currentColor;
    border-radius: 0.8rem;
    box-shadow: var(--zy-shadow-sm);
}
body.zy-ui .modal-content { overflow: hidden; border: 0; border-radius: 1.15rem; box-shadow: var(--zy-shadow-lg); }
body.zy-ui .modal-header { padding: 1rem 1.25rem; color: var(--zy-ink); background: var(--zy-surface-soft) !important; border-bottom: 1px solid var(--zy-border); }
body.zy-ui .modal-header .modal-title { color: var(--zy-ink); }
body.zy-ui .modal-header .btn-close { filter: none !important; }
body.zy-ui .modal-body { padding: 1.25rem; }
body.zy-ui .modal-footer { padding: 0.9rem 1.25rem; background: var(--zy-surface-soft); border-top-color: var(--zy-border); }

/* Active workspace and store lifecycle */
.zy-store-pill {
    display: inline-flex;
    min-height: 2.25rem;
    align-items: center;
    gap: 0.45rem;
    padding: 0.42rem 0.72rem;
    color: var(--zy-primary-dark);
    font-size: 0.78rem;
    font-weight: 760;
    text-decoration: none;
    background: var(--zy-primary-light);
    border: 1px solid #b9e4da;
    border-radius: 999px;
}
.zy-store-pill:hover, .zy-store-pill:focus-visible { color: var(--zy-primary-dark); background: #c3ebe2; }
.zy-store-switcher { display: flex; max-width: min(26rem, 42vw); gap: 0.45rem; align-items: center; margin-left: 0.75rem; }
.zy-store-switcher .form-select { min-width: 12rem; color: #173f3a; background-color: #eefaf7; border-color: rgb(255 255 255 / 38%); }
.zy-page-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.zy-page-heading h1 { margin: 0; font-size: clamp(1.65rem, 3vw, 2.35rem); }
.zy-page-heading p:not(.zy-section-kicker) { max-width: 48rem; margin: 0.35rem 0 0; color: var(--zy-muted); }
.zy-page-header { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.zy-page-header h1 { margin: 0; font-size: clamp(1.65rem, 3vw, 2.35rem); }
.zy-page-header p:not(.zy-section-kicker) { max-width: 48rem; margin: 0.35rem 0 0; color: var(--zy-muted); }
.zy-report-date { display: flex; flex: 0 0 auto; gap: 0.55rem; align-items: end; }
.zy-report-date label { display: grid; gap: 0.25rem; color: var(--zy-muted); font-size: 0.74rem; font-weight: 750; }
.zy-section-kicker { margin: 0 0 0.25rem; color: var(--zy-primary); font-size: 0.74rem; font-weight: 800; letter-spacing: 0.09em; text-transform: uppercase; }
.zy-boundary-note { display: flex; gap: 0.85rem; align-items: flex-start; margin-bottom: 1.25rem; padding: 1rem; color: var(--zy-ink); background: var(--zy-primary-light); border: 1px solid var(--zy-border); border-radius: 0.9rem; }
.zy-boundary-note > i { margin-top: 0.15rem; color: var(--zy-primary); }
.zy-boundary-note strong, .zy-boundary-note span { display: block; }
.zy-boundary-note strong { color: var(--zy-ink); }
.zy-boundary-note span { margin-top: 0.2rem; color: var(--zy-muted); }
.zy-store-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: 1rem; }
.zy-store-card { padding: 1.1rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 1rem; box-shadow: var(--zy-shadow-sm); }
.zy-store-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.zy-store-icon { display: inline-grid; width: 2.7rem; height: 2.7rem; place-items: center; color: var(--zy-primary); background: var(--zy-primary-light); border-radius: 0.75rem; }
.zy-store-card h2 { margin: 0; font-size: 1.15rem; }
.zy-store-code { margin: 0.2rem 0 1rem; color: var(--zy-muted); font-size: 0.78rem; font-weight: 780; letter-spacing: 0.08em; }
.zy-store-card dl { display: grid; gap: 0.65rem; margin: 0; }
.zy-store-card dl > div { display: grid; grid-template-columns: 5.5rem 1fr; gap: 0.6rem; }
.zy-store-card dt { color: var(--zy-muted); font-size: 0.78rem; }
.zy-store-card dd { margin: 0; overflow-wrap: anywhere; }
.zy-store-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--zy-border); }
.zy-status-active { color: #0b5f48; background: #d9f7eb; }
.zy-status-planned { color: #36546d; background: #e7f0f8; }
.zy-status-suspended { color: #75520a; background: #fff1c2; }
.zy-status-locked { color: #7a2e2e; background: #fde2e2; }
.zy-status-invited { color: #5c3b85; background: #eee4fb; }
.zy-status-closed, .zy-status-archived { color: #5d6670; background: #eceff2; }
.zy-store-review-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(16rem, 0.7fr); gap: 1rem; align-items: start; }
.zy-readiness-list { display: grid; gap: 0.55rem; margin: 0; padding: 0; list-style: none; }
.zy-readiness-list li { display: flex; gap: 0.7rem; align-items: flex-start; padding: 0.75rem; border: 1px solid var(--zy-border); border-radius: 0.75rem; }
.zy-readiness-list i { margin-top: 0.22rem; }
.zy-readiness-list strong, .zy-readiness-list span { display: block; }
.zy-readiness-list span { margin-top: 0.1rem; color: var(--zy-muted); font-size: 0.76rem; }
.zy-readiness-list .is-ready { background: #f1fbf7; border-color: #c7e9dc; }
.zy-readiness-list .is-ready i { color: var(--zy-success); }
.zy-readiness-list .is-pending { background: #fffbeb; border-color: #f1dfaa; }
.zy-readiness-list .is-pending i { color: #946200; }
.zy-detail-list { display: grid; gap: 0.7rem; margin: 0; }
.zy-detail-list > div { padding-bottom: 0.65rem; border-bottom: 1px solid var(--zy-border); }
.zy-detail-list > div:last-child { padding-bottom: 0; border-bottom: 0; }
.zy-detail-list dt { color: var(--zy-muted); font-size: 0.72rem; }
.zy-detail-list dd { margin: 0.1rem 0 0; overflow-wrap: anywhere; }
.zy-success-note { margin: 0.9rem 0 0; padding: 0.75rem; color: #0b5f48; background: #e8f7f1; border-radius: 0.7rem; }
.zy-danger-panel { border-color: #efc8c8; background: #fffafa; }
.zy-responsive-table { max-width: 100%; overflow-x: auto; }
.content-area:has(.zy-item-nonstock) .zy-access-side > .zy-panel:first-child { display: none; }

/* Access administration */
.zy-subnav-shell { display: grid; grid-template-columns: minmax(11rem, 15rem) minmax(0, 1fr); gap: 0.5rem; margin: -0.25rem 0 1.35rem; padding: 0.3rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.8rem; }
.zy-subnav-search { position: relative; margin: 0; }
.zy-subnav-search > i { position: absolute; top: 50%; left: 0.7rem; color: var(--zy-muted); transform: translateY(-50%); }
.zy-subnav-search input { width: 100%; min-height: 2.45rem; padding: 0.45rem 0.65rem 0.45rem 2.05rem; color: var(--zy-ink); background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 0.58rem; outline: 0; }
.zy-subnav-search input:focus { border-color: var(--zy-primary); box-shadow: var(--zy-focus); }
.zy-subnav { display: flex; min-width: 0; flex-wrap: wrap; gap: 0.35rem; margin: 0; padding: 0; overflow: visible; }
.zy-subnav a { flex: 0 0 auto; padding: 0.55rem 0.85rem; color: var(--zy-muted); font-size: 0.82rem; font-weight: 750; text-decoration: none; border-radius: 0.58rem; }
.zy-subnav a:hover, .zy-subnav a:focus-visible { color: var(--zy-primary-dark); background: var(--zy-surface); }
body.zy-ui .zy-subnav a.active,
body.zy-ui .zy-subnav a.active:hover,
body.zy-ui .zy-subnav a.active:focus-visible {
    color: #fff;
    background: #0f766e;
    box-shadow: var(--zy-shadow-sm);
}
.zy-filter-bar { display: grid; grid-template-columns: minmax(15rem, 1fr) minmax(10rem, 14rem) auto; gap: 0.8rem; align-items: end; margin-bottom: 1rem; padding: 0.9rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 0.9rem; }
.zy-filter-bar label, .zy-stack-form label, .zy-inline-form label, .zy-narrow-panel label { display: block; margin-bottom: 0.32rem; color: var(--zy-muted); font-size: 0.76rem; font-weight: 760; }
.zy-access-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr)); gap: 0.9rem; }
.zy-access-card { display: block; min-width: 0; padding: 1rem; color: var(--zy-ink); text-decoration: none; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 1rem; box-shadow: var(--zy-shadow-sm); transition: transform 150ms ease, border-color 150ms ease, box-shadow 150ms ease; }
.zy-access-card:hover, .zy-access-card:focus-visible { color: var(--zy-ink); border-color: #83beb2; box-shadow: var(--zy-shadow-md); transform: translateY(-2px); }
.zy-access-card-head { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.zy-access-card h2 { margin: 0.8rem 0 0.2rem; font-size: 1.05rem; }
.zy-access-card p { min-height: 2.5rem; margin: 0; color: var(--zy-muted); font-size: 0.82rem; overflow-wrap: anywhere; }
.zy-access-card > small { display: block; margin-top: 0.75rem; color: var(--zy-muted); }
.zy-card-archived { opacity: 0.72; }
.zy-avatar { display: inline-grid; width: 2.55rem; height: 2.55rem; place-items: center; color: var(--zy-primary-dark); font-weight: 800; background: var(--zy-primary-light); border-radius: 0.78rem; }
.zy-avatar-large { width: 3.3rem; height: 3.3rem; margin-bottom: 1rem; font-size: 1.25rem; }
.zy-chip-row { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.75rem; }
.zy-chip { display: inline-flex; padding: 0.28rem 0.52rem; color: #31534e; font-size: 0.7rem; font-weight: 700; text-decoration: none; background: #e8f5f2; border-radius: 999px; }
.zy-chip-muted { color: var(--zy-muted); background: #eef1f1; }
.zy-large-badge { align-self: center; padding: 0.58rem 0.82rem !important; }
.zy-back-link { display: inline-block; margin-bottom: 0.65rem; color: var(--zy-primary); font-size: 0.8rem; font-weight: 750; text-decoration: none; }
.zy-access-layout { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(17rem, 0.7fr); gap: 1rem; align-items: start; }
.zy-access-main, .zy-access-side { display: grid; gap: 1rem; min-width: 0; }
.zy-panel { padding: 1rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 1rem; box-shadow: var(--zy-shadow-sm); }
.zy-panel h1, .zy-panel h2 { margin-top: 0; }
.zy-panel h2 { font-size: 1.05rem; }
.zy-panel-heading { display: flex; justify-content: space-between; gap: 1rem; align-items: end; margin-bottom: 0.85rem; }
.zy-panel-heading h2, .zy-panel-heading p { margin: 0; }
.zy-panel-heading p { margin-top: 0.2rem; color: var(--zy-muted); font-size: 0.8rem; }
.zy-permission-list { display: grid; gap: 0.55rem; }
.zy-permission-list details { overflow: hidden; border: 1px solid var(--zy-border); border-radius: 0.75rem; }
.zy-permission-list summary { display: flex; justify-content: space-between; gap: 1rem; padding: 0.72rem 0.85rem; font-weight: 760; cursor: pointer; background: #f6f9f8; }
.zy-permission-list summary small { color: var(--zy-muted); font-weight: 600; }
.zy-permission-row { display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 0.68rem 0.85rem; border-top: 1px solid var(--zy-border); }
.zy-permission-row span > small, .zy-decision small, .zy-record-list small { display: block; margin-top: 0.12rem; color: var(--zy-muted); font-size: 0.7rem; font-weight: 500; overflow-wrap: anywhere; }
.zy-decision { flex: 0 0 min(42%, 18rem); text-align: right; font-size: 0.77rem; font-weight: 800; }
.zy-decision.allowed { color: #087352; }
.zy-decision.denied { color: #a43a3a; }
.zy-record-list { display: grid; }
.zy-record-list > div { display: flex; justify-content: space-between; gap: 0.75rem; align-items: center; padding: 0.65rem 0; border-bottom: 1px solid var(--zy-border); }
.zy-record-list > div:last-child { border-bottom: 0; }
.zy-record-list form { flex: 0 0 auto; }
.zy-inline-form { display: grid; grid-template-columns: minmax(10rem, 1fr) minmax(10rem, 1fr) auto auto; gap: 0.65rem; align-items: end; margin-top: 0.9rem; padding-top: 0.9rem; border-top: 1px solid var(--zy-border); }
.zy-owner-confirm { display: flex !important; max-width: 12rem; min-height: 2.7rem; gap: 0.45rem; align-items: center; margin: 0 !important; color: #6b4a0a !important; }
.zy-stack-form { display: grid; gap: 0.8rem; margin-top: 0.85rem; }
.zy-stack-form .form-check { display: flex; gap: 0.5rem; align-items: center; margin: 0; }
.zy-stack-form .form-check input { margin: 0; }
.zy-action-stack { display: grid; gap: 0.5rem; }
.zy-action-stack .btn { width: 100%; }
.zy-muted { color: var(--zy-muted); font-size: 0.8rem; }
.zy-permission-picker { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: 0.8rem; margin-top: 1rem; }
.zy-permission-picker fieldset { min-width: 0; padding: 0.75rem; border: 1px solid var(--zy-border); border-radius: 0.8rem; }
.zy-permission-picker legend { float: none; width: auto; margin: 0; padding: 0 0.25rem; color: var(--zy-primary-dark); font-size: 0.75rem; font-weight: 800; }
.zy-check-card { display: flex; gap: 0.6rem; align-items: start; padding: 0.55rem; cursor: pointer; border-radius: 0.55rem; }
.zy-check-card:hover { background: var(--zy-primary-light); }
.zy-check-card input { flex: 0 0 auto; margin-top: 0.18rem; }
.zy-check-card strong, .zy-check-card small { display: block; }
.zy-check-card strong { font-size: 0.78rem; }
.zy-check-card small { color: var(--zy-muted); font-size: 0.67rem; }
.zy-form-actions { position: sticky; bottom: 0; padding: 0.75rem 0 0; background: linear-gradient(transparent, var(--zy-surface) 25%); }
.zy-danger-zone { display: flex; justify-content: space-between; gap: 1rem; align-items: center; margin-top: 1rem; padding: 1rem; background: var(--zy-danger-surface); border: 1px solid var(--zy-danger-border); border-radius: 0.9rem; }
.zy-danger-zone strong, .zy-danger-zone span { display: block; }
.zy-danger-zone span { margin-top: 0.15rem; color: var(--zy-danger-muted); font-size: 0.76rem; }
.zy-danger-zone-stack { display: grid; }
.zy-narrow-panel { max-width: 32rem; margin: 2rem auto; padding: clamp(1.1rem, 4vw, 2rem); }
.zy-narrow-panel form { display: grid; gap: 0.8rem; margin-top: 1.2rem; }
.zy-empty-state { grid-column: 1 / -1; padding: 2rem; color: var(--zy-muted); text-align: center; background: var(--zy-surface); border: 1px dashed var(--zy-border); border-radius: 1rem; }
.zy-empty-state > * { display: block; }
.zy-empty-state i { margin-bottom: 0.6rem; font-size: 1.5rem; }
.zy-empty-state h2 { color: var(--zy-ink); font-size: 1rem; }
.zy-notification-link { position: relative; display: inline-grid; place-items: center; width: 2.6rem; min-height: 2.6rem; margin-right: 0.4rem; color: #fff; border: 1px solid rgb(255 255 255 / 0.28); border-radius: 0.75rem; font-size: 1rem; line-height: 1; text-decoration: none; vertical-align: middle; }
.zy-notification-link:hover, .zy-notification-link:focus-visible { color: #fff; background: rgb(255 255 255 / 0.12); }
.zy-notification-count { position: absolute; top: -0.35rem; right: -0.35rem; min-width: 1.25rem; padding: 0.15rem 0.3rem; color: #fff; background: #b42318; border: 2px solid var(--zy-primary-900); border-radius: 999px; font-size: 0.65rem; font-weight: 800; line-height: 1; text-align: center; }
.zy-filter-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.zy-filter-tabs a { min-height: 2.65rem; padding: 0.65rem 1rem; color: var(--zy-ink); background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 0.75rem; font-weight: 700; text-decoration: none; }
.zy-filter-tabs a.active { color: #fff; background: var(--zy-primary-700); border-color: var(--zy-primary-700); }
.zy-surface-soft { color: var(--zy-ink) !important; background: var(--zy-surface-soft) !important; }
.zy-badge-neutral { color: var(--zy-ink); background: var(--zy-surface-soft); border: 1px solid var(--zy-border); }
.zy-badge-info { color: #075985; background: #d9f2ff; }
.zy-badge-warning { color: #704b00; background: #fff0b8; }
.zy-gradient-primary { color: #fff; background: linear-gradient(135deg, #0f766e, #0a554f); }
.zy-gradient-danger { color: #fff; background: linear-gradient(135deg, #b42318, #7a271a); }
.zy-notification-list { display: grid; gap: 0.75rem; }
.zy-notification { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 0.85rem; align-items: start; padding: 1rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-left: 0.3rem solid #718096; border-radius: 0.9rem; box-shadow: var(--zy-shadow-sm); }
.zy-notification.is-unread { box-shadow: 0 0 0 2px rgb(15 118 110 / 0.12), var(--zy-shadow-sm); }
.zy-notification-warning { border-left-color: #b7791f; }
.zy-notification-critical { border-left-color: #b42318; }
.zy-notification-success { border-left-color: #157f3f; }
.zy-notification-marker { display: grid; place-items: center; width: 2.35rem; min-height: 2.35rem; color: var(--zy-primary-700); background: var(--zy-primary-050); border-radius: 50%; }
.zy-notification-critical .zy-notification-marker { color: #b42318; background: #fff0ed; }
.zy-notification-warning .zy-notification-marker { color: #986515; background: #fff8df; }
.zy-notification-heading { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; }
.zy-notification-heading h2 { margin: 0; font-size: 1rem; }
.zy-notification-copy p { margin: 0.35rem 0; }
.zy-notification-copy small { color: var(--zy-muted); }
.zy-notification-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.45rem; }
.zy-preference-form { margin-top: 1.25rem; }
.zy-switch { display: inline-flex; gap: 0.5rem; align-items: center; min-height: 2.75rem; cursor: pointer; }
.zy-switch input { width: 1.2rem; height: 1.2rem; accent-color: var(--zy-primary-700); }
.zy-table-shell { min-width: 0; max-width: 100%; overflow-x: auto; contain: inline-size; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 1rem; box-shadow: var(--zy-shadow-sm); }
.zy-table-shell table { min-width: 58rem; margin: 0; }
.zy-table-shell td small { display: block; color: var(--zy-muted); }
.zy-table-shell code { display: block; max-width: 24rem; color: #3d5551; font-size: 0.68rem; white-space: normal; overflow-wrap: anywhere; }
.zy-metric-row { display: flex; justify-content: space-between; gap: 1rem; margin-top: 1rem; padding-top: 0.8rem; border-top: 1px solid var(--zy-border); }
.zy-metric-row span { min-width: 0; }
.zy-metric-row strong, .zy-metric-row small { display: block; }
.zy-metric-row strong { font-size: 0.9rem; }
.zy-metric-row small { color: var(--zy-muted); font-size: 0.68rem; }
.zy-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.75rem; margin-bottom: 1rem; }
.zy-two-column { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; align-items: start; }
.zy-two-column > * { min-width: 0; }
.zy-summary-card { padding: 1rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 0.9rem; box-shadow: var(--zy-shadow-sm); }
.zy-summary-card strong, .zy-summary-card span { display: block; }
.zy-summary-card strong { color: var(--zy-primary-dark); font-size: 1.45rem; }
.zy-summary-card span { color: var(--zy-muted); font-size: 0.75rem; font-weight: 700; }
.zy-chart-list {
    display: grid;
    gap: 0.75rem;
    margin: 0;
    padding: 0;
    list-style: none;
}
.zy-chart-row {
    display: grid;
    grid-template-columns: minmax(9rem, 0.9fr) minmax(12rem, 2fr) minmax(8rem, 0.8fr);
    gap: 1rem;
    align-items: center;
    padding: 0.85rem;
    border: 1px solid var(--zy-border);
    border-radius: 0.8rem;
    background: var(--zy-surface-soft);
}
.zy-chart-label,
.zy-chart-value,
.zy-chart-measure {
    min-width: 0;
}
.zy-chart-label strong,
.zy-chart-label small,
.zy-chart-value strong,
.zy-chart-value small,
.zy-chart-measure span {
    display: block;
}
.zy-chart-label small,
.zy-chart-value small,
.zy-chart-measure span {
    margin-top: 0.2rem;
    color: var(--zy-muted);
    font-size: 0.78rem;
}
.zy-chart-measure progress {
    display: block;
    width: 100%;
    height: 0.9rem;
    overflow: hidden;
    border: 1px solid var(--zy-border);
    border-radius: 999px;
    background: var(--zy-surface);
    color: var(--zy-primary);
    accent-color: var(--zy-primary);
}
.zy-chart-measure progress::-webkit-progress-bar {
    background: var(--zy-surface);
}
.zy-chart-measure progress::-webkit-progress-value {
    background: var(--zy-primary);
}
.zy-chart-measure progress::-moz-progress-bar {
    background: var(--zy-primary);
}
.zy-record-value { flex: 0 0 auto; font-weight: 800; text-align: right; }
.zy-positive { color: #087352; }
.zy-negative { color: #a43a3a; }
.zy-balance-number { margin: 0.4rem 0; color: var(--zy-primary-dark); font-size: clamp(2rem, 7vw, 3.4rem); font-weight: 850; line-height: 1; }
.zy-issue { display: block; max-width: 24rem; margin-top: 0.35rem; font-size: 0.68rem; line-height: 1.35; }
.zy-issue-warning { color: #75520a !important; }
.zy-issue-error { color: #a43a3a !important; }

/* Rich searchable select */
.zy-combobox { position: relative; }
.zy-native-select {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none;
}
.zy-combobox-control { position: relative; }
.zy-combobox-input {
    width: 100%;
    min-height: 3.05rem;
    padding: 0.68rem 3rem 0.68rem 0.9rem;
    color: var(--zy-ink);
    background: var(--zy-surface);
    border: 1px solid #cbd9d6;
    border-radius: 0.78rem;
    outline: none;
}
.zy-combobox-input:focus { border-color: var(--zy-primary); box-shadow: var(--zy-focus); }
.zy-combobox-chevron {
    position: absolute;
    top: 50%;
    right: 1rem;
    width: 0.55rem;
    height: 0.55rem;
    border-right: 2px solid #55706c;
    border-bottom: 2px solid #55706c;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
}
.zy-combobox-list {
    position: absolute;
    z-index: 1080;
    top: calc(100% + 0.45rem);
    right: 0;
    left: 0;
    display: none;
    max-height: min(20rem, 45vh);
    overflow-y: auto;
    padding: 0.45rem;
    background: var(--zy-surface);
    border: 1px solid var(--zy-border);
    border-radius: 0.85rem;
    box-shadow: var(--zy-shadow-lg);
}
.zy-combobox[data-open="true"] .zy-combobox-list { display: block; }
.zy-combobox-option {
    display: block;
    width: 100%;
    padding: 0.72rem 0.8rem;
    color: var(--zy-ink);
    text-align: left;
    background: transparent;
    border: 0;
    border-radius: 0.62rem;
}
.zy-combobox-option:hover, .zy-combobox-option[aria-selected="true"], .zy-combobox-option[data-active="true"] { background: var(--zy-primary-light); }
.zy-combobox-option strong { display: block; font-size: 0.9rem; }
.zy-combobox-option small { display: block; margin-top: 0.15rem; color: var(--zy-muted); font-size: 0.73rem; }
.zy-combobox-empty { padding: 1.25rem; color: var(--zy-muted); font-size: 0.85rem; text-align: center; }

.zy-submit-spinner {
    display: inline-block;
    width: 0.9rem;
    height: 0.9rem;
    margin-right: 0.45rem;
    border: 2px solid rgb(255 255 255 / 40%);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: zy-spin 650ms linear infinite;
}
.zy-inline-submit-status {
    display: flex;
    grid-column: 1 / -1;
    min-height: 2.5rem;
    align-items: center;
    gap: 0.5rem;
    margin: 0.25rem 0 0;
    padding: 0.65rem 0.75rem;
    color: var(--zy-muted);
    background: var(--zy-surface-soft);
    border: 1px solid var(--zy-border);
    border-radius: 0.7rem;
}
.zy-inline-submit-status[data-state="success"] { color: #0b5f48; border-color: #65bda0; }
.zy-inline-submit-status[data-state="error"] { color: var(--zy-danger); border-color: var(--zy-danger-border); background: var(--zy-danger-surface); }
.zy-inline-submit-status[hidden] { display: none; }
@keyframes zy-spin { to { transform: rotate(360deg); } }

.zy-mobile-fab { display: none; }
.zy-mobile-fab[hidden] { display: none !important; }
body.zy-ui .navbar .ms-auto > a:not(.zy-notification-link) { color: var(--zy-primary-dark) !important; text-decoration: none; }
body.zy-ui .navbar .zy-notification-link { color: var(--zy-primary-dark) !important; background: var(--zy-surface-soft); border-color: var(--zy-border); }
body.zy-ui .navbar .zy-notification-link:hover, body.zy-ui .navbar .zy-notification-link:focus-visible { color: #fff !important; background: var(--zy-primary); }

/* Theme control and accessible application dialogs */
.zy-theme-toggle {
    display: inline-flex;
    min-width: 2.65rem;
    min-height: 2.65rem;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.45rem 0.7rem;
    color: var(--zy-ink);
    font-size: 0.78rem;
    font-weight: 760;
    background: var(--zy-surface-soft);
    border: 1px solid var(--zy-border);
    border-radius: 0.75rem;
}
.zy-theme-toggle:hover { color: var(--zy-primary-dark); border-color: var(--zy-primary); }
.zy-theme-toggle:focus-visible { outline: 0; box-shadow: var(--zy-focus); }
.zy-theme-toggle-float { position: fixed; z-index: 1100; top: 1rem; right: 1rem; box-shadow: var(--zy-shadow-sm); }

.zy-dialog-layer {
    position: fixed;
    z-index: 2000;
    inset: 0;
    display: grid;
    padding: 1rem;
    background: rgb(2 15 13 / 72%);
    backdrop-filter: blur(5px);
    place-items: center;
}
.zy-dialog-layer[hidden] { display: none; }
body.zy-dialog-open { overflow: hidden; }
.zy-dialog {
    display: grid;
    width: min(100%, 31rem);
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.9rem 1rem;
    padding: clamp(1.15rem, 4vw, 1.6rem);
    color: var(--zy-ink);
    background: var(--zy-surface);
    border: 1px solid var(--zy-border);
    border-radius: 1.25rem;
    box-shadow: var(--zy-shadow-lg);
}
.zy-dialog-icon { display: grid; width: 2.75rem; height: 2.75rem; color: var(--zy-primary-dark); background: var(--zy-primary-light); border-radius: 0.85rem; place-items: center; }
.zy-dialog[data-tone="danger"] .zy-dialog-icon { color: #b42318; background: #fff0ed; }
.zy-dialog[data-tone="warning"] .zy-dialog-icon { color: #825500; background: #fff3ce; }
.zy-dialog[data-tone="success"] .zy-dialog-icon { color: #087352; background: #dbf5e9; }
.zy-dialog-copy { min-width: 0; }
.zy-dialog-kicker { margin: 0 0 0.2rem; color: var(--zy-muted); font-size: 0.7rem; font-weight: 800; letter-spacing: 0.09em; text-transform: uppercase; }
.zy-dialog h2 { margin: 0; font-size: 1.3rem; }
.zy-dialog #zyDialogMessage { margin: 0.5rem 0 0; color: var(--zy-muted); white-space: pre-line; }
.zy-dialog-actions { display: flex; grid-column: 1 / -1; justify-content: flex-end; gap: 0.65rem; margin-top: 0.35rem; }
.zy-dialog-cancel { color: var(--zy-ink); background: var(--zy-surface-soft); border-color: var(--zy-border); }

/* Dark palette: WCAG AA contrast for normal text and interactive controls. */
html[data-theme="dark"] body.zy-ui .zy-login-panel {
    background:
        linear-gradient(rgb(7 21 18 / 84%), rgb(7 21 18 / 84%)),
        repeating-linear-gradient(45deg, transparent 0 26px, rgb(94 234 212 / 7%) 26px 27px);
}
html[data-theme="dark"] body.zy-ui .zy-input-wrap input { color: var(--zy-ink); background: var(--zy-surface); border-color: var(--zy-border); }
html[data-theme="dark"] body.zy-ui .modal-content,
html[data-theme="dark"] body.zy-ui .dropdown-menu,
html[data-theme="dark"] body.zy-ui .list-group-item { color: var(--zy-ink); background: var(--zy-surface); border-color: var(--zy-border); }
html[data-theme="dark"] body.zy-ui .table {
    --bs-table-color: var(--zy-ink);
    --bs-table-bg: transparent;
    --bs-table-border-color: var(--zy-border);
    --bs-table-hover-color: var(--zy-ink);
    --bs-table-hover-bg: var(--zy-surface-soft);
    color: var(--zy-ink);
}
html[data-theme="dark"] body.zy-ui .text-muted { color: var(--zy-muted) !important; }
html[data-theme="dark"] body.zy-ui .text-primary { color: #5eead4 !important; }
html[data-theme="dark"] body.zy-ui .text-success { color: #6ee7b7 !important; }
html[data-theme="dark"] body.zy-ui .text-info { color: #67e8f9 !important; }
html[data-theme="dark"] body.zy-ui .text-warning { color: #ffd166 !important; }
html[data-theme="dark"] body.zy-ui .text-danger { color: #fda29b !important; }
body.zy-ui .text-warning { color: #825500 !important; }
html[data-theme="dark"] body.zy-ui .btn-primary { color: #fff; background: #0f766e; border-color: #2aa99c; }
html[data-theme="dark"] body.zy-ui .btn-outline-primary { color: #5eead4; border-color: #2dd4bf; }
html[data-theme="dark"] body.zy-ui .btn-outline-primary:hover,
html[data-theme="dark"] body.zy-ui .btn-outline-primary:focus-visible,
html[data-theme="dark"] body.zy-ui .btn-outline-primary:active { color: #062c28; background: #5eead4; border-color: #5eead4; }
html[data-theme="dark"] body.zy-ui .btn-success { color: #fff; background: #13795b; border-color: #2aa879; }
html[data-theme="dark"] body.zy-ui .btn-info { color: #fff; background: #0e7490; border-color: #22a8c7; }
html[data-theme="dark"] body.zy-ui .btn-outline-secondary { color: #d8e6e3; border-color: #718d88; }
html[data-theme="dark"] body.zy-ui .btn-close { filter: invert(1) grayscale(1) brightness(1.7) !important; }
html[data-theme="dark"] body.zy-ui .alert-success { color: #a7f3d0; background: #123c30; }
html[data-theme="dark"] body.zy-ui .alert-danger { color: #fecaca; background: #471d1d; }
html[data-theme="dark"] body.zy-ui .alert-warning { color: #fde68a; background: #49370f; }
html[data-theme="dark"] body.zy-ui .alert-info { color: #bae6fd; background: #123748; }
html[data-theme="dark"] body.zy-ui .zy-dialog[data-tone="danger"] .zy-dialog-icon { color: #fecaca; background: #471d1d; }
html[data-theme="dark"] body.zy-ui .zy-dialog[data-tone="warning"] .zy-dialog-icon { color: #fde68a; background: #49370f; }
html[data-theme="dark"] body.zy-ui .zy-dialog[data-tone="success"] .zy-dialog-icon { color: #a7f3d0; background: #123c30; }
html[data-theme="dark"] body.zy-ui .stat-card { color: var(--zy-ink); background: var(--zy-surface); }
html[data-theme="dark"] body.zy-ui .stat-label { color: var(--zy-muted) !important; }
html[data-theme="dark"] body.zy-ui .section-title { color: var(--zy-ink); border-bottom-color: var(--zy-primary); }
html[data-theme="dark"] body.zy-ui .table-secondary { --bs-table-bg: var(--zy-surface-soft); --bs-table-color: var(--zy-ink); }
html[data-theme="dark"] body.zy-ui .zy-status-active,
html[data-theme="dark"] body.zy-ui .zy-status-succeeded { color: #c2f8e5; background: #124333; }
html[data-theme="dark"] body.zy-ui .zy-status-planned,
html[data-theme="dark"] body.zy-ui .zy-status-running,
html[data-theme="dark"] body.zy-ui .zy-badge-info { color: #c8efff; background: #12384b; }
html[data-theme="dark"] body.zy-ui .zy-status-suspended,
html[data-theme="dark"] body.zy-ui .zy-badge-warning { color: #fff1bd; background: #4a350b; }
html[data-theme="dark"] body.zy-ui .zy-status-locked,
html[data-theme="dark"] body.zy-ui .zy-status-failed { color: #ffd4d0; background: #55211e; }
html[data-theme="dark"] body.zy-ui .zy-status-invited { color: #ead9ff; background: #3c2955; }
html[data-theme="dark"] body.zy-ui .zy-status-closed,
html[data-theme="dark"] body.zy-ui .zy-status-archived,
html[data-theme="dark"] body.zy-ui .zy-badge-neutral { color: #d7e5e2; background: #273d38; }
html[data-theme="dark"] body.zy-ui .zy-chip { color: #d8fff8; background: #173f38; }
html[data-theme="dark"] body.zy-ui .zy-chip-muted { color: var(--zy-muted); background: #273d38; }
html[data-theme="dark"] body.zy-ui .zy-readiness-list .is-ready,
html[data-theme="dark"] body.zy-ui .zy-success-note { color: #c2f8e5; background: #123c30; border-color: #2f705c; }
html[data-theme="dark"] body.zy-ui .zy-readiness-list .is-pending,
html[data-theme="dark"] body.zy-ui .zy-warning-panel { color: #fff1bd; background: #49370f; border-color: #7d641f; }
html[data-theme="dark"] body.zy-ui .zy-danger-panel { color: var(--zy-ink); background: var(--zy-danger-surface); border-color: var(--zy-danger-border); }
html[data-theme="dark"] body.zy-ui .zy-permission-list summary { color: var(--zy-ink); background: var(--zy-surface-soft); }
html[data-theme="dark"] body.zy-ui .zy-owner-confirm { color: #ffe6a3 !important; }
html[data-theme="dark"] body.zy-ui .zy-positive,
html[data-theme="dark"] body.zy-ui .zy-decision.allowed { color: #6ee7b7; }
html[data-theme="dark"] body.zy-ui .zy-negative,
html[data-theme="dark"] body.zy-ui .zy-decision.denied,
html[data-theme="dark"] body.zy-ui .zy-issue-error { color: #fda29b !important; }
html[data-theme="dark"] body.zy-ui .zy-issue-warning { color: #ffd166 !important; }
html[data-theme="dark"] body.zy-ui .zy-inline-submit-status[data-state="success"] { color: #a7f3d0; border-color: #2f705c; }
html[data-theme="dark"] body.zy-ui .navbar .zy-notification-link:hover,
html[data-theme="dark"] body.zy-ui .navbar .zy-notification-link:focus-visible { color: #062c28 !important; background: #5eead4; }

body.zy-report-page { padding-top: 0 !important; }
body.zy-report-page .report-header h1 { color: #fff !important; }

@media (max-width: 991.98px) {
    :root { --zy-topbar-height: 4.1rem; }
    .zy-login-shell { grid-template-columns: 1fr; }
    .zy-login-story { display: none; }
    .zy-login-panel { min-height: 100vh; padding: 1rem; }
    .zy-login-card { padding: 1.1rem; }
    .zy-mobile-brand { display: flex; }
    .zy-section-heading { align-items: stretch; flex-direction: column; }
    .zy-page-heading { align-items: stretch; flex-direction: column; }
    .zy-page-heading .btn { width: 100%; }
    .zy-product-search { width: 100%; }
    .zy-access-layout { grid-template-columns: 1fr; }

    body.zy-ui:not(.zy-login-page) > .navbar { padding: 0 0.75rem; }
    body.zy-ui .navbar-brand { max-width: calc(100vw - 11rem); font-size: 0.92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    body.zy-ui .zy-navbar-mark { width: 2.15rem; height: 2.15rem; }
    body.zy-ui .navbar .ms-auto > i, body.zy-ui .navbar .ms-auto > form .fa-sign-out-alt { display: none; }
    body.zy-ui .navbar .ms-auto { max-width: none; font-size: 0; }
    body.zy-ui .navbar .ms-auto > a:not(.zy-notification-link) { display: none; }
    body.zy-ui .navbar .ms-auto > form .btn { min-width: 2.45rem; margin-left: 0.45rem !important; font-size: 0; }
    body.zy-ui .navbar .ms-auto > form .btn::after { content: "Exit"; font-size: 0.76rem; }
    .zy-theme-toggle { width: 2.75rem; padding: 0; }
    .zy-theme-toggle span { display: none; }
    .zy-nav-toggle { display: inline-grid; }

    body.zy-ui .sidebar {
        top: var(--zy-topbar-height);
        height: calc(100vh - var(--zy-topbar-height));
        padding-top: 1rem;
        transform: translateX(-105%);
        transition: transform 180ms ease;
    }
    body.zy-ui.zy-nav-open { overflow: hidden; }
    body.zy-ui.zy-nav-open .sidebar { transform: translateX(0); }
    .zy-sidebar-overlay {
        position: fixed;
        z-index: 1030;
        inset: 0;
        display: block;
        visibility: hidden;
        background: rgb(4 25 23 / 55%);
        opacity: 0;
        transition: opacity 180ms ease, visibility 180ms ease;
    }
    body.zy-ui.zy-nav-open .zy-sidebar-overlay { visibility: visible; opacity: 1; }
    body.zy-ui .content-area { margin-left: 0; padding: 1rem; }
    body.zy-ui .section > .d-flex:first-child > div { display: flex; width: 100%; gap: 0.5rem; }
    body.zy-ui .section > .d-flex:first-child > div .btn { flex: 1; margin-right: 0 !important; }
    .zy-mobile-fab {
        position: fixed;
        z-index: 1020;
        right: 1rem;
        bottom: max(1rem, env(safe-area-inset-bottom));
        display: inline-flex;
        min-height: 3.25rem;
        align-items: center;
        gap: 0.55rem;
        padding: 0.8rem 1.05rem;
        color: #fff;
        font-weight: 760;
        background: var(--zy-success);
        border: 0;
        border-radius: 999px;
        box-shadow: 0 12px 28px rgb(8 65 52 / 30%);
    }
}

@media (max-width: 575.98px) {
    body.zy-ui:not(.zy-login-page) > .navbar .container-fluid { flex-wrap: nowrap; gap: 0.35rem; }
    body.zy-ui .navbar-brand { max-width: calc(100vw - 11.7rem); }
    body.zy-ui .navbar .ms-auto { flex: 0 0 auto; max-width: none; font-size: 0; }
    body.zy-ui .navbar .ms-auto > .zy-notification-link { display: none; }
    body.zy-ui .navbar .ms-auto > a:not(.zy-notification-link) { display: inline-grid; width: 2.75rem; min-height: 2.75rem; place-items: center; overflow: hidden; }
    body.zy-ui .navbar .ms-auto > a:not(.zy-notification-link) i { margin: 0 !important; font-size: 1.1rem; }
    body.zy-ui .navbar .ms-auto > form .btn { margin-left: 0.2rem !important; }
    .zy-theme-toggle-float { top: 0.75rem; right: 0.75rem; }
    .zy-dialog { grid-template-columns: 1fr; }
    .zy-dialog-icon { width: 2.55rem; height: 2.55rem; }
    .zy-dialog-actions { grid-column: 1; }
    .zy-dialog-actions .btn { flex: 1; }
    .zy-store-pill { display: none; }
    body.zy-ui .btn, body.zy-ui .form-control, body.zy-ui .form-select, body.zy-ui .navbar .btn-outline-light { min-height: 2.75rem; }
    .zy-store-switcher { max-width: 9.5rem; margin-left: 0.2rem; }
    .zy-store-switcher .form-select { min-width: 0; max-width: 6rem; }
    .zy-store-switcher .btn { padding-inline: 0.45rem; }
    .zy-subnav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.zy-ui .row.g-4 { --bs-gutter-y: 0.8rem; }
    body.zy-ui .stat-card { min-height: auto; }
    body.zy-ui .modal { overflow-y: auto; }
    body.zy-ui .modal-dialog { margin: 0; min-height: 100%; }
    body.zy-ui .modal-dialog-centered { align-items: flex-start; }
    body.zy-ui .modal-dialog-centered::before { display: none; }
    body.zy-ui .modal-content { min-height: 100vh; border-radius: 0; }
    body.zy-ui .modal-footer { position: sticky; bottom: 0; z-index: 2; }
    body.zy-ui .table > :not(caption) > * > * { padding: 0.7rem; }
    .zy-combobox-list { position: fixed; top: auto; right: 0.75rem; bottom: 0.75rem; left: 0.75rem; max-height: 60vh; }
    .zy-filter-bar, .zy-inline-form { grid-template-columns: 1fr; }
    .zy-filter-grid { grid-template-columns: 1fr; }
    .zy-package-columns { grid-template-columns: 1fr; }
    .zy-filter-grid > *, .zy-filter-grid .zy-filter-search { min-width: 0; grid-column: auto; }
    .zy-filter-grid .form-control, .zy-filter-grid .form-select { width: 100%; min-width: 0; }
    .zy-filter-actions { display: grid; grid-template-columns: 1fr 1fr; }
    .zy-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .zy-two-column { grid-template-columns: 1fr; }
    .zy-chart-row { grid-template-columns: 1fr; gap: 0.55rem; }
    .zy-filter-bar .btn, .zy-inline-form .btn { width: 100%; }
    .zy-panel-heading, .zy-permission-row, .zy-danger-zone { align-items: stretch; flex-direction: column; }
    .zy-page-header, .zy-report-date { align-items: stretch; flex-direction: column; }
    .zy-page-header .btn, .zy-report-date .btn { width: 100%; }
    .zy-store-review-grid { grid-template-columns: 1fr; }
    .zy-decision { flex-basis: auto; text-align: left; }
    .zy-card-table { overflow: visible; background: transparent; border: 0; box-shadow: none; }
    .zy-card-table table, .zy-card-table tbody { display: block; min-width: 0; }
    .zy-card-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
    .zy-card-table tbody { display: grid; gap: 0.75rem; }
    .zy-card-table tbody tr { display: grid; padding: 0.45rem 0.8rem; background: var(--zy-surface); border: 1px solid var(--zy-border); border-radius: 0.9rem; box-shadow: var(--zy-shadow-sm); }
    .zy-card-table tbody td[data-label] { display: flex; min-width: 0; justify-content: space-between; gap: 1rem; align-items: center; padding: 0.55rem 0 !important; text-align: right !important; border-bottom: 1px solid var(--zy-border); }
    .zy-card-table tbody td[data-label]:last-child { border-bottom: 0; }
    .zy-card-table tbody td[data-label]::before { content: attr(data-label); flex: 0 0 6.5rem; color: var(--zy-muted); font-size: 0.68rem; font-weight: 800; letter-spacing: 0.035em; text-align: left; text-transform: uppercase; }
    .zy-card-table tbody td[data-label] > :first-child { min-width: 0; }
    .zy-card-table tbody td[data-label="Product"], .zy-card-table tbody td[data-label="Legacy product"], .zy-card-table tbody td[data-label="Status and findings"] { align-items: flex-start; }
    .zy-card-table tbody td[data-label="Product"] a, .zy-card-table tbody td[data-label="Legacy product"] strong { overflow-wrap: anywhere; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}

@media print {
    body.zy-ui { padding: 0 !important; background: #fff; }
    body.zy-ui > .navbar, body.zy-ui .sidebar, .zy-mobile-fab, .zy-nav-toggle, .zy-sidebar-overlay, .zy-theme-toggle, .zy-dialog-layer { display: none !important; }
    body.zy-ui .content-area { margin: 0; padding: 0; }
    body.zy-ui .card { box-shadow: none; }
}

/* Phase 9 operational controls */
.zy-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.9rem; align-items: end; }
.zy-journal-lines { display: grid; gap: 0.75rem; }
.zy-journal-line { display: grid; grid-template-columns: minmax(13rem, 2fr) repeat(2, minmax(7rem, 0.8fr)) minmax(11rem, 1.2fr); gap: 0.75rem; align-items: end; padding: 0.85rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.8rem; }
.zy-journal-line label { display: grid; gap: 0.3rem; color: var(--zy-muted); font-size: 0.76rem; font-weight: 750; }
.zy-sticky-submit.zy-journal-submit { position: static; margin-top: 1rem; }
.zy-form-stack { display: grid; gap: 0.8rem; }
.zy-form-grid label, .zy-form-stack label, .zy-inline-price label, .zy-count-row label { display: grid; gap: 0.3rem; color: var(--zy-muted); font-size: 0.76rem; font-weight: 750; }
.zy-form-span { grid-column: 1 / -1; }
.zy-form-actions { display: flex; justify-content: flex-end; }
.zy-disclosure { margin-top: 1rem; }
.zy-disclosure > summary { cursor: pointer; color: var(--zy-primary-dark); font-weight: 780; }
.zy-disclosure[open] > summary { margin-bottom: 1rem; }
.zy-editable-record { align-items: flex-start !important; gap: 1rem; }
.zy-inline-price { display: grid; grid-template-columns: 7.5rem 7.5rem auto auto; gap: 0.5rem; align-items: end; }
.zy-check { display: flex !important; min-height: 2.65rem; align-items: center; gap: 0.45rem; color: var(--zy-ink) !important; }
.zy-count-grid { display: grid; gap: 0.65rem; margin-top: 1rem; }
.zy-count-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(9rem, 14rem); gap: 1rem; align-items: center; padding: 0.8rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.8rem; }
.zy-count-row span, .zy-count-row small { display: block; }
.zy-count-row small { color: var(--zy-muted); }

@media (max-width: 767.98px) {
    .zy-subnav-shell { grid-template-columns: 1fr; }
    .zy-subnav { display: grid; grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr)); }
    .zy-subnav a { display: grid; min-height: 2.75rem; place-items: center; padding: 0.5rem; text-align: center; }
    .zy-filter-bar { grid-template-columns: 1fr; }
    .zy-filter-bar > *, .zy-danger-zone > * { min-width: 0; }
    .zy-danger-zone { align-items: stretch; flex-direction: column; }
    .zy-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .zy-form-grid, .zy-inline-price, .zy-count-row, .zy-journal-line { grid-template-columns: 1fr; }
    .zy-form-span { grid-column: auto; }
    .zy-form-actions .btn, .zy-inline-price .btn { width: 100%; }
    .zy-notification { grid-template-columns: auto minmax(0, 1fr); }
    .zy-notification-actions { grid-column: 1 / -1; justify-content: stretch; }
    .zy-notification-actions form, .zy-notification-actions .btn { flex: 1; width: 100%; }
}

/* Core sales checkout */
.zy-checkout { display: grid; gap: 1rem; padding-bottom: 5rem; }
.zy-sale-lines { display: grid; gap: 0.8rem; }
.zy-sale-line { display: grid; grid-template-columns: minmax(16rem, 1fr) minmax(10rem, 13rem) auto; gap: 0.75rem; align-items: end; padding: 0.85rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.85rem; }
.zy-sale-line label, .zy-checkout label { display: block; margin: 0 0 0.3rem; font-size: 0.76rem; font-weight: 750; }
.zy-quantity-stepper { display: grid; grid-template-columns: 2.75rem minmax(5rem, 1fr) 2.75rem; gap: 0.35rem; }
.zy-quantity-stepper .btn { padding-inline: 0; }
.zy-sale-line-quote { grid-column: 1 / -1; min-height: 1.35rem; font-size: 0.82rem; }
.zy-sale-line-quote:empty { display: none; }
.zy-remove-line { min-width: 2.8rem; min-height: 2.8rem; }
.zy-checkout-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.zy-checkout-grid .zy-panel { display: grid; align-content: start; gap: 0.55rem; }
.zy-basket-summary { display: grid; grid-template-columns: minmax(14rem, 1fr) minmax(24rem, 1.35fr); gap: 1rem; align-items: center; }
.zy-basket-summary h2, .zy-basket-summary p { margin-bottom: 0.25rem; }
.zy-basket-summary dl { display: grid; grid-template-columns: repeat(4, minmax(6rem, 1fr)); gap: 0.55rem; margin: 0; }
.zy-basket-summary dl > div { min-width: 0; padding: 0.7rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.75rem; }
.zy-basket-summary dt { color: var(--zy-muted); font-size: 0.7rem; font-weight: 800; letter-spacing: 0.035em; text-transform: uppercase; }
.zy-basket-summary dd { margin: 0.15rem 0 0; color: var(--zy-ink); font-size: 1.05rem; font-weight: 800; overflow-wrap: anywhere; }
.zy-basket-summary .zy-basket-total { background: var(--zy-primary-light); border-color: var(--zy-primary); }
.zy-basket-summary .zy-basket-total dd { color: var(--zy-primary-dark); }
.zy-payment-options { display: grid; gap: 0.5rem; margin: 0 0 0.35rem; padding: 0; border: 0; }
.zy-payment-options legend { margin-bottom: 0.3rem; color: var(--zy-muted); font-size: 0.76rem; font-weight: 750; }
.zy-payment-options label { display: flex; min-height: 3.5rem; gap: 0.7rem; align-items: flex-start; margin: 0; padding: 0.65rem 0.75rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.75rem; cursor: pointer; }
.zy-payment-options label:has(input:checked) { background: var(--zy-primary-light); border-color: var(--zy-primary); }
.zy-payment-options label:has(input:focus-visible) { outline: 0; box-shadow: var(--zy-focus); }
.zy-payment-options input { flex: 0 0 auto; margin-top: 0.3rem; accent-color: var(--zy-primary); }
.zy-payment-options span, .zy-payment-options small { display: block; }
.zy-payment-options strong { color: var(--zy-ink); }
.zy-payment-options small { color: var(--zy-muted); font-size: 0.75rem; font-weight: 500; }
.zy-sticky-submit { position: fixed; z-index: 1010; right: 1.25rem; bottom: 1.25rem; left: calc(var(--zy-sidebar-width) + 1.25rem); display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 0.8rem 1rem; color: #eafff9; background: #0b443c; border-radius: 1rem; box-shadow: var(--zy-shadow-lg); }
.zy-sticky-submit span { font-size: 0.78rem; font-weight: 700; }
.zy-sale-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: 0.75rem; margin-bottom: 1rem; }
.zy-sale-summary .zy-panel { display: grid; gap: 0.25rem; }
.zy-sale-summary span { color: var(--zy-muted); font-size: 0.73rem; font-weight: 750; text-transform: uppercase; }
.zy-sale-summary strong { color: var(--zy-primary-dark); font-size: clamp(1rem, 2.5vw, 1.45rem); }
.zy-tax-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 25rem), 1fr)); gap: 1rem; }
.zy-tax-card { display: grid; align-content: start; gap: 0.8rem; }
.zy-tax-timeline { display: grid; gap: 0.5rem; }
.zy-tax-timeline > div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.7rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.7rem; }
.zy-tax-timeline span, .zy-tax-timeline small { display: block; }
.zy-tax-timeline small { margin-top: 0.15rem; color: var(--zy-muted); }
.zy-tax-version { padding-top: 0.6rem; border-top: 1px solid var(--zy-border); }

/* Phase 15.4 customer and generated-identifier workflows */
.zy-generated-field { display: grid; gap: 0.35rem; }
.zy-generated-field > label { color: var(--zy-muted); font-size: 0.76rem; font-weight: 750; }
.zy-generated-control { display: grid; grid-template-columns: minmax(12rem, 1fr) repeat(3, auto); gap: 0.45rem; }
.zy-generated-field small { color: var(--zy-muted); }
.zy-warning-panel { border-color: var(--zy-accent); }
.zy-remote-combobox { position: relative; display: grid; gap: 0.3rem; }
.zy-remote-combobox .zy-combobox-list { top: calc(100% - 1.35rem); right: 0; left: 0; }
.zy-remote-combobox .zy-combobox-list:not([hidden]) { display: block; }
.zy-remote-combobox .zy-combobox-option { display: grid; gap: 0.15rem; }
.zy-remote-combobox .zy-combobox-option small { color: var(--zy-muted); }
.zy-remote-combobox [aria-selected="true"] { background: var(--zy-primary-light); }
.zy-definition-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.7rem; }
.zy-definition-grid > div { min-width: 0; padding: 0.7rem; background: var(--zy-surface-soft); border: 1px solid var(--zy-border); border-radius: 0.7rem; }
.zy-definition-grid dt { color: var(--zy-muted); font-size: 0.7rem; font-weight: 800; text-transform: uppercase; }
.zy-definition-grid dd { margin: 0.2rem 0 0; overflow-wrap: anywhere; }
.zy-export-bar { display: flex; justify-content: flex-end; gap: 0.6rem; align-items: end; margin-top: 1rem; }
.zy-export-bar label { display: grid; gap: 0.3rem; color: var(--zy-muted); font-size: 0.76rem; font-weight: 750; }
body.zy-ui.zy-receipt { --zy-ink: #172e2a; --zy-muted: #58706b; --zy-primary-dark: #0a554f; margin: 0; padding: 1rem; color: #172e2a; background: #eef5f3; color-scheme: light; font-family: system-ui, sans-serif; }
body.zy-receipt > .zy-theme-toggle { display: none !important; }
.zy-receipt main { width: min(100%, 28rem); margin: auto; padding: 1.5rem; background: #fff; box-shadow: 0 10px 35px rgb(4 35 30 / 12%); }
.zy-receipt header { padding-bottom: 1rem; border-bottom: 2px solid #163f38; }
.zy-receipt h1 { margin: 0.2rem 0; }
.zy-receipt table { width: 100%; margin: 1rem 0; border-collapse: collapse; }
.zy-receipt th, .zy-receipt td { padding: 0.65rem 0.25rem; text-align: left; border-bottom: 1px solid #d9e4e1; }
.zy-receipt th:last-child, .zy-receipt td:last-child { text-align: right; }
.zy-receipt td small { display: block; color: #58706b; }
.zy-receipt main > button { width: 100%; padding: 0.8rem; color: #fff; background: #0f766e; border: 0; border-radius: 0.6rem; font-weight: 750; }

@media (max-width: 991.98px) {
    .zy-sticky-submit { left: 1rem; }
    .zy-basket-summary { grid-template-columns: 1fr; }
}

@media (max-width: 575.98px) {
    .zy-sale-line { grid-template-columns: 1fr auto; align-items: start; }
    .zy-sale-product { grid-column: 1 / -1; }
    .zy-sale-quantity { min-width: 0; }
    .zy-quantity-stepper { grid-template-columns: 2.75rem minmax(4.5rem, 1fr) 2.75rem; }
    .zy-sale-product { grid-column: 1 / -1; }
    .zy-checkout-grid, .zy-sale-summary { grid-template-columns: 1fr; }
    .zy-basket-summary dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .zy-sticky-submit { right: 0.75rem; bottom: 0.75rem; left: 0.75rem; }
    .zy-sticky-submit span { display: none; }
    .zy-sticky-submit .btn { width: 100%; }
    .zy-generated-control { grid-template-columns: repeat(3, 1fr); }
    .zy-generated-control input { grid-column: 1 / -1; }
    .zy-generated-control .btn { width: 100%; padding-inline: 0.45rem; }
    .zy-definition-grid { grid-template-columns: 1fr; }
    .zy-export-bar { align-items: stretch; flex-direction: column; }
    .zy-export-bar .btn, .zy-export-bar label { width: 100%; }
}

@media print {
    .zy-receipt { padding: 0; background: #fff; }
    .zy-receipt main { width: 100%; box-shadow: none; }
    .zy-receipt button { display: none; }
}
