:root {
    color-scheme: light;
    --background: #f4f3ef;
    --foreground: #101216;
    --card: #ffffff;
    --card-foreground: #101216;
    --popover: #ffffff;
    --popover-foreground: #101216;
    --muted: #efeee9;
    --muted-foreground: #69717b;
    --primary: #cf2028;
    --primary-foreground: #ffffff;
    --accent: #f3e8e8;
    --accent-foreground: #a71920;
    --border: #deddd7;
    --input: #cecec8;
    --ring: #cf2028;
    --destructive: #b91c1c;
    --destructive-surface: #fff1f1;
    --sidebar: #101216;
    --sidebar-foreground: #f7f7f5;
    --sidebar-accent: #24272c;
    --sidebar-accent-foreground: #ffffff;
    --sidebar-border: rgb(255 255 255 / 10%);
    --radius: 0.875rem;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-synthesis: none;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    min-height: 100%;
    background: var(--background);
}

body {
    min-height: 100vh;
    min-height: 100svh;
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
    font: inherit;
}

button:not(:disabled) {
    cursor: pointer;
}

.auth-shell {
    display: grid;
    min-height: 100vh;
    min-height: 100svh;
    grid-template-columns: minmax(30rem, 0.88fr) minmax(0, 1.12fr);
    background: #101216;
}

.auth-main {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem clamp(2rem, 5vw, 5.5rem);
    overflow: hidden;
    background-color: #101216;
    background-image:
        linear-gradient(rgb(255 255 255 / 2.6%) 1px, transparent 1px),
        linear-gradient(90deg, rgb(255 255 255 / 2.6%) 1px, transparent 1px);
    background-position: center;
    background-size: 44px 44px;
}

.auth-main::after {
    position: absolute;
    right: -12rem;
    bottom: -12rem;
    width: 30rem;
    height: 30rem;
    border-radius: 50%;
    background: rgb(207 32 40 / 15%);
    content: "";
    filter: blur(100px);
    pointer-events: none;
}

.auth-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 31rem;
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    margin-bottom: 1.75rem;
    color: rgb(255 255 255 / 44%);
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.auth-brand img {
    display: block;
    width: 10.25rem;
    height: auto;
}

.auth-card {
    --foreground: #101216;
    --muted: #f3f2ee;
    --muted-foreground: #686f79;
    --primary: #cf2028;
    --primary-foreground: #ffffff;
    --input: rgb(16 18 22 / 15%);
    --destructive: #cf2028;
    --destructive-surface: #fff1f1;
    padding: clamp(2rem, 4vw, 3rem);
    border: 1px solid rgb(255 255 255 / 18%);
    border-radius: 1.875rem;
    background: #ffffff;
    box-shadow: 0 2rem 5rem rgb(0 0 0 / 28%);
    color: var(--foreground);
}

.auth-heading {
    margin-bottom: 2rem;
}

.auth-eyebrow {
    display: block;
    margin-bottom: 0.875rem;
    color: var(--primary);
    font-size: 0.625rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.auth-heading h1 {
    margin: 0 0 0.75rem;
    font-size: clamp(2.25rem, 4vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.06em;
    line-height: 0.98;
}

.auth-heading h1 span {
    color: var(--primary);
}

.auth-heading p {
    margin: 0;
    color: var(--muted-foreground);
    line-height: 1.65;
}

.auth-form {
    display: grid;
    gap: 1.125rem;
}

.auth-card .form-field label {
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-card .form-field input {
    height: 3.25rem;
    padding: 0 1rem;
    border-radius: 0.75rem;
    background: #f7f6f2;
}

.auth-card .password-input input {
    padding-right: 3rem;
}

.auth-card .button--primary {
    min-height: 3.375rem;
    margin-top: 0.375rem;
    border-radius: 1rem;
    font-weight: 800;
}

.form-field {
    display: grid;
    gap: 0.5rem;
}

.form-field label {
    font-weight: 500;
}

.form-field input {
    width: 100%;
    height: 2.5rem;
    padding: 0 0.75rem;
    border: 1px solid var(--input);
    border-radius: calc(var(--radius) - 2px);
    outline: none;
    background: transparent;
    color: var(--foreground);
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-field input::placeholder {
    color: #94a3b8;
}

.form-field input:focus {
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgb(148 163 184 / 22%);
}

.password-input {
    position: relative;
}

.password-input input {
    padding-right: 2.75rem;
}

.password-input__toggle {
    position: absolute;
    top: 50%;
    right: 0.375rem;
    display: grid;
    width: 2rem;
    height: 2rem;
    padding: 0;
    transform: translateY(-50%);
    place-items: center;
    border: 0;
    border-radius: 0.375rem;
    background: transparent;
    color: var(--muted-foreground);
}

.password-input__toggle:hover {
    background: var(--muted);
    color: var(--foreground);
}

.password-input__toggle:focus-visible {
    outline: 2px solid #94a3b8;
    outline-offset: 1px;
}

.password-input__toggle svg,
.button svg {
    width: 1rem;
    height: 1rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.is-hidden {
    display: none !important;
}

.button {
    display: inline-flex;
    min-height: 2.5rem;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid transparent;
    border-radius: calc(var(--radius) - 2px);
    font-weight: 500;
    text-decoration: none;
    transition: opacity 150ms ease, background-color 150ms ease;
}

.button--primary {
    margin-top: 0.125rem;
    background: var(--primary);
    color: var(--primary-foreground);
}

.button--primary:hover {
    opacity: 0.9;
}

.button--outline {
    border-color: var(--border);
    background: var(--background);
    color: var(--foreground);
}

.button--outline:hover {
    background: var(--muted);
}

.button--danger {
    border-color: var(--destructive);
    background: var(--destructive);
    color: #fff;
}

.button--danger:hover {
    opacity: 0.9;
}

.alert {
    margin-bottom: 1rem;
    padding: 0.75rem;
    border: 1px solid;
    border-radius: calc(var(--radius) - 2px);
}

.alert--error {
    border-color: #fecaca;
    background: var(--destructive-surface);
    color: var(--destructive);
}

.auth-preview {
    position: relative;
    min-height: 100%;
    overflow: hidden;
    background: #050708;
}

.auth-preview__image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 64% center;
    user-select: none;
}

.auth-preview::after {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, #101216 0%, transparent 22%),
        linear-gradient(0deg, rgb(5 7 8 / 82%) 0%, transparent 45%);
    content: "";
}

.auth-preview__caption {
    position: absolute;
    z-index: 1;
    right: clamp(2rem, 5vw, 5rem);
    bottom: clamp(2.5rem, 6vw, 5rem);
    left: clamp(2rem, 5vw, 5rem);
    display: grid;
    gap: 0.75rem;
    color: #ffffff;
}

.auth-preview__caption span {
    color: #cf2028;
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.18em;
}

.auth-preview__caption strong {
    max-width: 32rem;
    font-size: clamp(2rem, 4vw, 4.5rem);
    font-weight: 800;
    letter-spacing: -0.065em;
    line-height: 0.95;
}

.dashboard-shell {
    min-height: 100vh;
    background: #f8fafc;
}

.dashboard-header {
    display: flex;
    height: 4rem;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    border-bottom: 1px solid var(--border);
    background: var(--background);
}

.dashboard-content {
    max-width: 72rem;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.dashboard-content h1 {
    margin: 0 0 0.5rem;
    font-size: 2rem;
    letter-spacing: -0.035em;
}

.dashboard-content p {
    margin: 0;
    color: var(--muted-foreground);
}

.dashboard-eyebrow {
    margin-bottom: 0.5rem !important;
    color: var(--foreground) !important;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

html.dark {
    color-scheme: dark;
    --background: #121418;
    --foreground: #f7f7f5;
    --card: #191b20;
    --card-foreground: #f7f7f5;
    --popover: #202329;
    --popover-foreground: #f7f7f5;
    --muted: #282b31;
    --muted-foreground: #a0a5ad;
    --primary: #d62b33;
    --primary-foreground: #ffffff;
    --accent: #3b2529;
    --accent-foreground: #ffb4b8;
    --border: rgb(255 255 255 / 12%);
    --input: rgb(255 255 255 / 16%);
    --ring: #d62b33;
    --destructive: #f87171;
    --destructive-surface: rgb(127 29 29 / 20%);
    --sidebar: #080a0d;
    --sidebar-foreground: #f7f7f5;
    --sidebar-accent: #24272c;
    --sidebar-accent-foreground: #ffffff;
    --sidebar-border: rgb(255 255 255 / 10%);
}

html.dark .dashboard-shell {
    background: #0b1120;
}

@media (max-width: 1023px) {
    .auth-shell {
        display: block;
    }

    .auth-main {
        min-height: 100vh;
        min-height: 100svh;
        padding: 2rem;
    }

    .auth-preview {
        display: none;
    }
}

@media (max-width: 639px) {
    .auth-main {
        padding: 1.25rem;
    }

    .auth-brand {
        margin-bottom: 1.25rem;
    }

    .auth-brand img {
        width: 8.75rem;
    }

    .auth-card {
        padding: 1.75rem 1.5rem;
        border-radius: 1.5rem;
    }

    .dashboard-header,
    .dashboard-content {
        padding-right: 1.25rem;
        padding-left: 1.25rem;
    }
}

/* Admin layout — port of shadcn-admin's inset/default/ltr composition. */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.icon {
    width: 1rem;
    height: 1rem;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.admin-page {
    min-height: 100svh;
    background: var(--sidebar);
}

.admin-shell {
    display: flex;
    min-height: 100svh;
    width: 100%;
    background: var(--sidebar);
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: 0.75rem;
    left: 50%;
    padding: 0.5rem 0.75rem;
    transform: translate(-50%, -150%);
    border-radius: 0.375rem;
    background: var(--primary);
    color: var(--primary-foreground);
    font-weight: 500;
    transition: transform 150ms ease;
}

.skip-link:focus {
    transform: translate(-50%, 0);
}

.admin-sidebar {
    position: sticky;
    z-index: 30;
    top: 0;
    width: 16rem;
    height: 100svh;
    flex: 0 0 16rem;
    padding: 0.5rem;
    color: var(--sidebar-foreground);
    transition: width 200ms linear, flex-basis 200ms linear;
}

.sidebar-inner {
    display: flex;
    height: 100%;
    min-width: 0;
    flex-direction: column;
    overflow: visible;
}

.sidebar-header,
.sidebar-footer {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.5rem;
}

.sidebar-header {
    padding-top: 0.25rem;
}

.sidebar-brand {
    display: flex;
    min-width: 0;
    height: 3rem;
    align-items: center;
    gap: 0.625rem;
    padding: 0.375rem;
    border-radius: 0.5rem;
    color: inherit;
    text-decoration: none;
}

.sidebar-brand:hover {
    background: var(--sidebar-accent);
}

.sidebar-brand__mark {
    display: grid;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    place-items: center;
    border-radius: 0.5rem;
    background: var(--primary);
    color: var(--primary-foreground);
}

.sidebar-brand__mark .icon {
    width: 1rem;
    height: 1rem;
}

.sidebar-brand__copy,
.sidebar-user__copy,
.dropdown-user > span:last-child {
    display: grid;
    min-width: 0;
    flex: 1;
    line-height: 1.25;
}

.sidebar-brand__copy strong,
.sidebar-user__copy strong,
.dropdown-user strong {
    overflow: hidden;
    font-size: 0.875rem;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-brand__copy small,
.sidebar-user__copy small,
.dropdown-user small {
    overflow: hidden;
    color: var(--muted-foreground);
    font-size: 0.75rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-content {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
    gap: 0.5rem;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--sidebar-border) transparent;
}

.sidebar-group {
    display: flex;
    width: 100%;
    min-width: 0;
    flex-direction: column;
    padding: 0.5rem;
}

.sidebar-group--secondary {
    margin-top: 0.25rem;
}

.sidebar-group__label {
    display: flex;
    height: 2rem;
    align-items: center;
    padding: 0 0.5rem;
    color: color-mix(in srgb, var(--sidebar-foreground) 68%, transparent);
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    transition: opacity 200ms ease, margin 200ms ease;
}

.sidebar-menu,
.sidebar-submenu {
    display: flex;
    width: 100%;
    min-width: 0;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0;
    margin: 0;
    list-style: none;
}

.sidebar-menu > li {
    position: relative;
}

.sidebar-link {
    display: flex;
    width: 100%;
    min-width: 0;
    height: 2rem;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    overflow: hidden;
    border: 0;
    border-radius: 0.375rem;
    outline: none;
    background: transparent;
    color: var(--sidebar-foreground);
    font-size: 0.875rem;
    text-align: left;
    text-decoration: none;
    white-space: nowrap;
    transition: width 200ms ease, background-color 120ms ease;
}

.sidebar-link:hover,
.sidebar-link:focus-visible,
.sidebar-link.is-active {
    background: var(--sidebar-accent);
    color: var(--sidebar-accent-foreground);
}

.sidebar-link.is-active {
    font-weight: 500;
}

.sidebar-link > span {
    overflow: hidden;
    text-overflow: ellipsis;
}

summary {
    list-style: none;
}

summary::-webkit-details-marker {
    display: none;
}

.sidebar-collapsible > summary {
    cursor: pointer;
}

.sidebar-chevron {
    margin-left: auto;
    transition: transform 200ms ease;
}

.sidebar-collapsible[open] .sidebar-chevron {
    transform: rotate(90deg);
}

.sidebar-submenu {
    width: auto;
    margin: 0.125rem 0.875rem 0.25rem;
    padding: 0.125rem 0 0.125rem 0.625rem;
    border-left: 1px solid var(--sidebar-border);
}

.sidebar-submenu a {
    display: flex;
    min-width: 0;
    height: 1.75rem;
    align-items: center;
    padding: 0 0.5rem;
    border-radius: 0.375rem;
    color: var(--sidebar-foreground);
    font-size: 0.875rem;
    text-decoration: none;
    white-space: nowrap;
}

.sidebar-submenu a:hover,
.sidebar-submenu a.is-active {
    background: var(--sidebar-accent);
    color: var(--sidebar-accent-foreground);
}

.sidebar-footer {
    position: relative;
    margin-top: auto;
}

.user-menu,
.theme-menu,
.header-user-menu {
    position: relative;
}

.sidebar-user {
    display: flex;
    min-width: 0;
    height: 3rem;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem;
    border-radius: 0.5rem;
    cursor: pointer;
}

.sidebar-user:hover,
.user-menu[open] .sidebar-user {
    background: var(--sidebar-accent);
}

.sidebar-user__chevrons {
    margin-left: auto;
}

.avatar {
    display: inline-grid;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--muted);
    color: var(--foreground);
    font-size: 0.75rem;
    font-weight: 500;
}

.avatar--button {
    border-radius: 999px;
    cursor: pointer;
}

.sidebar-rail {
    position: absolute;
    z-index: 31;
    inset: 0 -0.5rem 0 auto;
    display: block;
    width: 1rem;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: w-resize;
}

.sidebar-rail::after {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 2px;
    background: transparent;
    content: "";
}

.sidebar-rail:hover::after {
    background: var(--sidebar-border);
}

.admin-shell.is-sidebar-collapsed .admin-sidebar {
    width: 4rem;
    flex-basis: 4rem;
}

.admin-shell.is-sidebar-collapsed .sidebar-brand__copy,
.admin-shell.is-sidebar-collapsed .sidebar-group__label,
.admin-shell.is-sidebar-collapsed .sidebar-link > span,
.admin-shell.is-sidebar-collapsed .sidebar-chevron,
.admin-shell.is-sidebar-collapsed .sidebar-submenu,
.admin-shell.is-sidebar-collapsed .sidebar-user__copy,
.admin-shell.is-sidebar-collapsed .sidebar-user__chevrons {
    display: none;
}

.admin-shell.is-sidebar-collapsed .sidebar-brand,
.admin-shell.is-sidebar-collapsed .sidebar-user,
.admin-shell.is-sidebar-collapsed .sidebar-link {
    justify-content: center;
}

.admin-shell.is-sidebar-collapsed .sidebar-group {
    padding-top: 0;
}

.admin-shell.is-sidebar-collapsed .sidebar-group--secondary {
    margin-top: 0;
}

.admin-shell.is-sidebar-collapsed .sidebar-rail {
    cursor: e-resize;
}

.admin-inset {
    position: relative;
    display: flex;
    width: calc(100% - 16rem - 0.5rem);
    min-width: 0;
    min-height: calc(100svh - 1rem);
    flex: 1;
    flex-direction: column;
    margin: 0.5rem 0.5rem 0.5rem 0;
    overflow: clip;
    border: 1px solid color-mix(in srgb, var(--border) 60%, transparent);
    border-radius: 0.75rem;
    background: var(--background);
    box-shadow: 0 1px 2px rgb(15 23 42 / 5%);
}

.admin-shell.is-sidebar-collapsed .admin-inset {
    width: calc(100% - 4rem - 1rem);
    margin-left: 0.5rem;
}

.admin-page-column {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
}

.admin-header {
    position: sticky;
    z-index: 20;
    top: 0;
    height: 4rem;
    flex: 0 0 4rem;
    transition: box-shadow 150ms ease;
}

.admin-header.is-scrolled {
    box-shadow: 0 1px 4px rgb(15 23 42 / 8%);
}

.admin-header__inner {
    position: relative;
    display: flex;
    height: 100%;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
}

.admin-header.is-scrolled .admin-header__inner::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    background: color-mix(in srgb, var(--background) 76%, transparent);
    backdrop-filter: blur(12px);
    content: "";
}

.icon-button {
    position: relative;
    display: inline-grid;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    padding: 0;
    place-items: center;
    border: 1px solid transparent;
    border-radius: 0.5rem;
    background: transparent;
    color: var(--foreground);
}

.icon-button--outline {
    border-color: var(--border);
    border-radius: 0.375rem;
}

.icon-button:hover {
    background: var(--accent);
}

.header-separator {
    width: 1px;
    height: 1.5rem;
    background: var(--border);
}

.top-nav {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-right: auto;
}

.top-nav a {
    color: var(--muted-foreground);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
}

.top-nav a:hover {
    color: var(--foreground);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    margin-left: auto;
}

.header-search {
    position: relative;
    display: flex;
    width: 13rem;
    height: 2rem;
    align-items: center;
    justify-content: flex-start;
    gap: 0.5rem;
    padding: 0 3rem 0 0.5rem;
    border: 1px solid var(--border);
    border-radius: 0.375rem;
    background: color-mix(in srgb, var(--muted) 25%, transparent);
    color: var(--muted-foreground);
    opacity: 1;
    font-size: 0.875rem;
    text-align: left;
}

.header-search kbd {
    position: absolute;
    top: 0.3rem;
    right: 0.3rem;
    display: inline-flex;
    height: 1.25rem;
    align-items: center;
    padding: 0 0.375rem;
    border: 1px solid var(--border);
    border-radius: 0.25rem;
    background: var(--muted);
    color: var(--foreground);
    font-family: ui-monospace, monospace;
    font-size: 0.625rem;
}

.theme-menu > summary,
.header-user-menu > summary,
.user-menu > summary {
    list-style: none;
}

.theme-icon {
    position: absolute;
    transition: transform 200ms ease, opacity 200ms ease;
}

.theme-icon--moon {
    transform: rotate(90deg) scale(0);
    opacity: 0;
}

html.dark .theme-icon--sun {
    transform: rotate(-90deg) scale(0);
    opacity: 0;
}

html.dark .theme-icon--moon {
    transform: rotate(0) scale(1);
    opacity: 1;
}

.dropdown-panel {
    position: absolute;
    z-index: 60;
    min-width: 10rem;
    padding: 0.25rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--popover);
    color: var(--popover-foreground);
    box-shadow: 0 10px 30px rgb(15 23 42 / 16%);
}

.theme-menu__panel,
.header-user-menu__panel {
    top: calc(100% + 0.5rem);
    right: 0;
}

.header-user-menu__panel {
    width: 14rem;
}

.theme-menu:not([open]) .dropdown-panel,
.header-user-menu:not([open]) .dropdown-panel,
.user-menu:not([open]) .dropdown-panel {
    display: none;
}

.dropdown-item {
    display: flex;
    width: 100%;
    min-height: 2rem;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.5rem;
    border: 0;
    border-radius: 0.375rem;
    background: transparent;
    color: inherit;
    font-size: 0.875rem;
    text-align: left;
    text-decoration: none;
}

.dropdown-item:hover,
.dropdown-item:focus-visible {
    background: var(--accent);
    outline: none;
}

.dropdown-item--danger {
    color: var(--destructive);
}

.theme-check {
    display: none;
    margin-left: auto;
}

.dropdown-item.is-selected .theme-check {
    display: block;
}

.dropdown-separator {
    height: 1px;
    margin: 0.25rem -0.25rem;
    background: var(--border);
}

.dropdown-user {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.25rem;
}

.dropdown-user--stacked {
    display: grid;
    gap: 0.25rem;
    padding: 0.5rem;
}

.dropdown-user--stacked small {
    color: var(--muted-foreground);
}

.user-menu__panel {
    right: calc(-100% - 0.25rem);
    bottom: 0;
    width: 14rem;
}

.admin-content {
    width: 100%;
    flex: 1;
    padding: 1.5rem 1rem;
    outline: none;
}

.admin-footer {
    flex: 0 0 auto;
    padding: 1rem;
    border-top: 1px solid var(--border);
    color: var(--muted-foreground);
    font-size: 0.875rem;
    text-align: center;
}

.page-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.page-heading h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.page-heading p,
.panel-card header p {
    margin: 0.25rem 0 0;
    color: var(--muted-foreground);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.metric-card,
.panel-card,
.form-card,
.empty-state {
    border: 1px solid var(--border);
    border-radius: 0.625rem;
    background: var(--card);
    color: var(--card-foreground);
}

.metric-card {
    display: grid;
    padding: 1.5rem;
}

.metric-card > span {
    font-weight: 500;
}

.metric-card > strong {
    margin-top: 1.5rem;
    font-size: 1.5rem;
}

.metric-card > small {
    color: var(--muted-foreground);
    font-size: 0.75rem;
}

.dashboard-panels {
    display: grid;
    grid-template-columns: minmax(0, 4fr) minmax(18rem, 3fr);
    gap: 1rem;
    margin-top: 1rem;
}

.panel-card {
    min-height: 22rem;
    padding: 1.5rem;
}

.panel-card h2 {
    margin: 0;
    font-size: 1rem;
}

.chart-placeholder {
    display: flex;
    height: 16rem;
    align-items: flex-end;
    gap: 0.75rem;
    padding: 2rem 1rem 0;
    border-bottom: 1px solid var(--border);
}

.chart-placeholder span {
    height: var(--bar-height);
    flex: 1;
    border-radius: 0.25rem 0.25rem 0 0;
    background: var(--primary);
    opacity: 0.88;
}

.panel-empty {
    display: grid;
    min-height: 15rem;
    place-items: center;
    color: var(--muted-foreground);
}

.empty-state {
    display: grid;
    min-height: 22rem;
    place-content: center;
    padding: 2rem;
    text-align: center;
}

.empty-state h2 {
    margin: 0;
    font-size: 1.125rem;
}

.empty-state p {
    margin: 0.375rem 0 0;
    color: var(--muted-foreground);
}

.flash {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border: 1px solid;
    border-radius: 0.5rem;
}

.flash--success {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.flash--error {
    border-color: #fecaca;
    background: var(--destructive-surface);
    color: var(--destructive);
}

html.dark .flash--success {
    border-color: #166534;
    background: rgb(20 83 45 / 25%);
    color: #86efac;
}

html.dark .flash--error {
    border-color: #991b1b;
    background: rgb(127 29 29 / 24%);
    color: #fca5a5;
}

.button--auto {
    width: auto;
    min-height: 2.25rem;
    margin-top: 0;
    white-space: nowrap;
}

.table-toolbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.table-search {
    position: relative;
    width: min(22rem, 100%);
}

.table-search .icon {
    position: absolute;
    top: 50%;
    left: 0.75rem;
    color: var(--muted-foreground);
    transform: translateY(-50%);
}

.table-search input {
    width: 100%;
    height: 2.25rem;
    padding: 0 0.75rem 0 2.25rem;
    border: 1px solid var(--input);
    border-radius: 0.375rem;
    outline: none;
    background: var(--background);
    color: var(--foreground);
}

.table-search input:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring) 20%, transparent);
}

.table-filter {
    height: 2.25rem;
    padding: 0 2rem 0 0.75rem;
    border: 1px solid var(--input);
    border-radius: 0.375rem;
    outline: none;
    background: var(--background);
    color: var(--foreground);
}

.table-filter:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring) 20%, transparent);
}

.toolbar-reset,
.back-link {
    color: var(--muted-foreground);
    font-size: 0.875rem;
    text-decoration: none;
}

.toolbar-reset:hover,
.back-link:hover {
    color: var(--foreground);
}

.data-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.data-table th,
.data-table td {
    height: 3rem;
    padding: 0 1rem;
    border-bottom: 1px solid var(--border);
    text-align: left;
    white-space: nowrap;
}

.data-table th {
    color: var(--muted-foreground);
    font-weight: 500;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr:hover {
    background: color-mix(in srgb, var(--muted) 65%, transparent);
}

.table-primary-link,
.table-contact {
    color: var(--foreground);
    font-weight: 600;
    text-decoration: none;
}

.table-primary-link:hover,
.table-contact:hover {
    text-decoration: underline;
}

.table-contact {
    display: block;
    font-weight: 400;
}

.table-secondary {
    display: block;
    margin-top: 0.125rem;
    color: var(--muted-foreground);
    font-size: 0.75rem;
}

.table-muted {
    color: var(--muted-foreground);
}

.type-badge {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--muted);
    color: var(--muted-foreground);
    font-size: 0.75rem;
    font-weight: 500;
}

.table-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.25rem;
}

.icon-button {
    display: grid;
    width: 2rem;
    height: 2rem;
    place-items: center;
    border-radius: 0.375rem;
    color: var(--muted-foreground);
}

.icon-button:hover {
    background: var(--accent);
    color: var(--accent-foreground);
}

.icon-button .icon {
    width: 1rem;
    height: 1rem;
}

.table-empty {
    height: 6rem !important;
    color: var(--muted-foreground);
    text-align: center !important;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    border: 1px solid;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-badge--active {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.status-badge--inactive {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

html.dark .status-badge--active {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .status-badge--inactive {
    border-color: #991b1b;
    background: rgb(127 29 29 / 24%);
    color: #fca5a5;
}

.dealer-status {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    border: 1px solid;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.dealer-status--created {
    border-color: #d1d5db;
    background: #f3f4f6;
    color: #4b5563;
}

.dealer-status--checkin {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.dealer-status--confirmed {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.dealer-status--blocked {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

html.dark .dealer-status--created {
    border-color: #4b5563;
    background: rgb(55 65 81 / 34%);
    color: #d1d5db;
}

html.dark .dealer-status--checkin {
    border-color: #92400e;
    background: rgb(120 53 15 / 24%);
    color: #fde68a;
}

html.dark .dealer-status--confirmed {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .dealer-status--blocked {
    border-color: #991b1b;
    background: rgb(127 29 29 / 24%);
    color: #fca5a5;
}

.pagination-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1rem;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

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

.pagination__button {
    display: grid;
    width: 2rem;
    height: 2rem;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 0.375rem;
    color: var(--foreground);
    text-decoration: none;
}

.pagination__button:hover,
.pagination__button.is-active {
    background: var(--accent);
}

.pagination__button.is-active {
    border-color: var(--foreground);
}

.pagination__button.is-disabled {
    pointer-events: none;
    opacity: 0.45;
}

.pagination__ellipsis {
    width: 2rem;
    text-align: center;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    margin-bottom: 0.75rem;
}

.form-card {
    max-width: 48rem;
    padding: 1.5rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.form-field--wide,
.checkbox-field {
    grid-column: 1 / -1;
}

.form-field select {
    width: 100%;
    height: 2.5rem;
    padding: 0 0.75rem;
    border: 1px solid var(--input);
    border-radius: calc(var(--radius) - 2px);
    outline: none;
    background: var(--background);
    color: var(--foreground);
}

.form-field textarea {
    width: 100%;
    min-height: 6rem;
    padding: 0.625rem 0.75rem;
    resize: vertical;
    border: 1px solid var(--input);
    border-radius: calc(var(--radius) - 2px);
    outline: none;
    background: var(--background);
    color: var(--foreground);
}

.form-field select:focus,
.form-field textarea:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring) 20%, transparent);
}

.form-field ul {
    padding: 0;
    margin: 0.25rem 0 0;
    color: var(--destructive);
    font-size: 0.75rem;
    list-style: none;
}

.checkbox-field {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.checkbox-field input {
    width: 1rem;
    height: 1rem;
    accent-color: var(--primary);
}

.checkbox-group {
    display: flex;
    grid-column: 1 / -1;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding-top: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.client-form-card {
    max-width: 64rem;
}

.client-form > ul {
    padding: 0.75rem 1rem;
    margin: 0 0 1.5rem;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    background: var(--destructive-surface);
    color: var(--destructive);
    list-style-position: inside;
}

.entity-form > ul {
    padding: 0.75rem 1rem;
    margin: 0 0 1.5rem;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    background: var(--destructive-surface);
    color: var(--destructive);
    list-style-position: inside;
}

.field-help {
    color: var(--muted-foreground);
    font-size: 0.75rem;
}

.form-section + .form-section {
    padding-top: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.form-section > header {
    margin-bottom: 1rem;
}

.form-section h2 {
    margin: 0;
    font-size: 1rem;
}

.form-section header p {
    margin: 0.25rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.heading-actions {
    display: flex;
    gap: 0.5rem;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.detail-card {
    padding: 1.5rem;
    border: 1px solid var(--border);
    border-radius: 0.625rem;
    background: var(--card);
}

.detail-card > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.detail-card h2,
.danger-zone h2 {
    margin: 0;
    font-size: 1rem;
}

.detail-card header p,
.danger-zone p {
    margin: 0.25rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.detail-list {
    margin: 0;
}

.detail-list > div {
    display: grid;
    grid-template-columns: minmax(8rem, 0.75fr) minmax(0, 1.25fr);
    gap: 1rem;
    padding: 0.875rem 0;
    border-bottom: 1px solid var(--border);
}

.detail-list > div:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.detail-list dt {
    color: var(--muted-foreground);
}

.detail-list dd {
    margin: 0;
    font-weight: 500;
    overflow-wrap: anywhere;
}

.detail-list a {
    color: var(--foreground);
}

.detail-card--notes {
    margin-top: 1rem;
}

.detail-card--notes > p {
    margin: 1rem 0 0;
    white-space: normal;
}

.danger-zone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem;
    margin-top: 1rem;
    border: 1px solid #fecaca;
    border-radius: 0.625rem;
    background: color-mix(in srgb, var(--destructive-surface) 50%, var(--card));
}

.stock-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.details-grid--spaced {
    margin-top: 1rem;
}

.detail-text {
    padding-top: 1rem;
    color: var(--muted-foreground);
    overflow-wrap: anywhere;
}

.list-card {
    margin-top: 1rem;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 0.625rem;
    background: var(--card);
}

.list-card > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
}

.list-card h2 {
    margin: 0;
    font-size: 1rem;
}

.list-card header p {
    margin: 0.25rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.data-table-wrap--embedded {
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
}

.stock-status {
    display: inline-flex;
    align-items: center;
    padding: 0.125rem 0.5rem;
    border: 1px solid;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.stock-status--available {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.stock-status--reserved {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.stock-status--sold {
    border-color: #bfdbfe;
    background: #eff6ff;
    color: #1e40af;
}

.stock-status--written_off {
    border-color: #d1d5db;
    background: #f3f4f6;
    color: #4b5563;
}

html.dark .stock-status--available {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .stock-status--reserved {
    border-color: #92400e;
    background: rgb(120 53 15 / 24%);
    color: #fde68a;
}

html.dark .stock-status--sold {
    border-color: #1e40af;
    background: rgb(30 64 175 / 24%);
    color: #bfdbfe;
}

html.dark .stock-status--written_off {
    border-color: #4b5563;
    background: rgb(55 65 81 / 34%);
    color: #d1d5db;
}

.serial-value,
.serial-heading {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    letter-spacing: 0.025em;
}

.reserve-form {
    display: grid;
    gap: 1rem;
    padding-top: 1rem;
}

.reserve-actions {
    padding-top: 1rem;
}

.detail-empty {
    padding-top: 1rem;
    color: var(--muted-foreground);
}

.info-zone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem;
    margin-top: 1rem;
    border: 1px solid var(--border);
    border-radius: 0.625rem;
    background: var(--card);
}

.info-zone h2 {
    margin: 0;
    font-size: 1rem;
}

.info-zone p {
    margin: 0.25rem 0 0;
    color: var(--muted-foreground);
    font-size: 0.875rem;
}

.document-form-card {
    max-width: 72rem;
}

.document-posted-field {
    margin-top: 1rem;
}

.checkout-zone {
    align-items: flex-end;
}

.checkout-form {
    display: flex;
    align-items: flex-end;
    gap: 0.75rem;
    min-width: min(100%, 30rem);
}

.checkout-form .form-field {
    flex: 1 1 auto;
}

.stat-card__date {
    font-size: 1.25rem !important;
}

.order-status {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    border: 1px solid;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.order-status--reserved {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.order-status--fulfilled {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.order-status--cancelled {
    border-color: #d1d5db;
    background: #f3f4f6;
    color: #4b5563;
}

html.dark .order-status--reserved {
    border-color: #92400e;
    background: rgb(120 53 15 / 24%);
    color: #fde68a;
}

html.dark .order-status--fulfilled {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .order-status--cancelled {
    border-color: #4b5563;
    background: rgb(55 65 81 / 34%);
    color: #d1d5db;
}

.serial-chip-list--table {
    padding: 0.5rem 0;
}

.serial-chip-list--table .serial-chip {
    padding: 0.2rem 0.4rem;
    font-size: 0.75rem;
}

.serial-picker-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.serial-picker-count {
    flex: 0 0 auto;
    padding: 0.25rem 0.625rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--muted);
    color: var(--muted-foreground);
    font-size: 0.75rem;
}

.serial-scanner {
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: color-mix(in srgb, var(--muted) 35%, transparent);
}

.serial-scanner > label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.serial-scanner__controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.serial-scanner__input {
    position: relative;
    flex: 1 1 auto;
}

.serial-scanner__input .icon {
    position: absolute;
    top: 50%;
    left: 0.75rem;
    width: 1rem;
    height: 1rem;
    color: var(--muted-foreground);
    pointer-events: none;
    transform: translateY(-50%);
}

.serial-scanner__input input {
    width: 100%;
    height: 2.5rem;
    padding: 0 0.75rem 0 2.25rem;
    border: 1px solid var(--input);
    border-radius: calc(var(--radius) - 2px);
    outline: none;
    background: var(--background);
    color: var(--foreground);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    letter-spacing: 0.025em;
    text-transform: uppercase;
}

.serial-scanner__input input:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring) 20%, transparent);
}

.serial-scanner .field-help {
    display: block;
    margin-top: 0.5rem;
}

.serial-scanner__feedback {
    padding: 0.625rem 0.75rem;
    margin: 0.75rem 0 0;
    border: 1px solid var(--border);
    border-radius: 0.375rem;
    background: var(--background);
    color: var(--muted-foreground);
    font-size: 0.8125rem;
}

.serial-scanner__feedback[data-state="success"] {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.serial-scanner__feedback[data-state="warning"] {
    border-color: #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.serial-scanner__feedback[data-state="error"] {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

html.dark .serial-scanner__feedback[data-state="success"] {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .serial-scanner__feedback[data-state="warning"] {
    border-color: #92400e;
    background: rgb(120 53 15 / 24%);
    color: #fde68a;
}

html.dark .serial-scanner__feedback[data-state="error"] {
    border-color: #991b1b;
    background: rgb(127 29 29 / 24%);
    color: #fca5a5;
}

.serial-picker-table {
    margin-top: 1rem;
}

.serial-picker-table td:last-child {
    width: 3.5rem;
}

.serial-picker-empty td {
    height: 6rem;
    color: var(--muted-foreground);
    text-align: center;
}

.serial-picker-remove {
    border: 0;
    background: transparent;
    color: var(--destructive);
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
}

.supply-lines {
    display: grid;
    gap: 0.75rem;
}

.supply-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 10rem 2.5rem;
    align-items: end;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: color-mix(in srgb, var(--muted) 45%, transparent);
}

.supply-line__remove {
    margin-bottom: 0.25rem;
    color: var(--destructive);
}

.collection-add {
    margin-top: 0.75rem;
}

.multi-select-field select {
    height: auto;
    min-height: 14rem;
    padding: 0.5rem;
}

.multi-select-field option {
    padding: 0.375rem 0.5rem;
    border-radius: 0.25rem;
}

.document-type {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--muted);
    color: var(--muted-foreground);
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
}

.document-type--supply {
    border-color: #86efac;
    background: #f0fdf4;
    color: #166534;
}

.document-type--transfer {
    border-color: #bfdbfe;
    background: #eff6ff;
    color: #1e40af;
}

.document-type--write_off {
    border-color: #fecaca;
    background: #fef2f2;
    color: #991b1b;
}

html.dark .document-type--supply {
    border-color: #166534;
    background: rgb(20 83 45 / 24%);
    color: #86efac;
}

html.dark .document-type--transfer {
    border-color: #1e40af;
    background: rgb(30 64 175 / 24%);
    color: #bfdbfe;
}

html.dark .document-type--write_off {
    border-color: #991b1b;
    background: rgb(127 29 29 / 24%);
    color: #fca5a5;
}

.serial-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0 1.5rem 1.5rem;
}

.serial-chip {
    padding: 0.375rem 0.625rem;
    border: 1px solid var(--border);
    border-radius: 0.375rem;
    color: var(--foreground);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    text-decoration: none;
}

.serial-chip:hover {
    background: var(--accent);
}

.table-toolbar--wrap {
    flex-wrap: wrap;
}

.table-toolbar--wrap .table-filter {
    max-width: 17rem;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.sidebar-overlay {
    display: none;
}

@media (max-width: 1199px) {
    .top-nav {
        display: none;
    }

    .dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .admin-sidebar,
    .admin-shell.is-sidebar-collapsed .admin-sidebar {
        position: fixed;
        z-index: 70;
        inset: 0 auto 0 0;
        width: 18rem;
        flex-basis: 18rem;
        height: 100svh;
        padding: 0;
        background: var(--sidebar);
        box-shadow: 0 20px 50px rgb(15 23 42 / 22%);
        transform: translateX(-105%);
        transition: transform 200ms ease;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-brand__copy,
    .admin-shell.is-sidebar-collapsed .sidebar-group__label,
    .admin-shell.is-sidebar-collapsed .sidebar-link > span,
    .admin-shell.is-sidebar-collapsed .sidebar-chevron,
    .admin-shell.is-sidebar-collapsed .sidebar-submenu,
    .admin-shell.is-sidebar-collapsed .sidebar-user__copy,
    .admin-shell.is-sidebar-collapsed .sidebar-user__chevrons {
        display: grid;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-group__label {
        display: flex;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-submenu {
        display: flex;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-brand,
    .admin-shell.is-sidebar-collapsed .sidebar-user,
    .admin-shell.is-sidebar-collapsed .sidebar-link {
        justify-content: flex-start;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-group {
        padding-top: 0.5rem;
    }

    .admin-shell.is-sidebar-collapsed .sidebar-group--secondary {
        margin-top: 0.25rem;
    }

    .admin-shell.is-mobile-sidebar-open .admin-sidebar {
        transform: translateX(0);
    }

    .sidebar-inner {
        padding: 0.5rem;
    }

    .sidebar-rail {
        display: none;
    }

    .sidebar-overlay {
        position: fixed;
        z-index: 60;
        inset: 0;
        display: block;
        border: 0;
        background: rgb(2 6 23 / 62%);
        opacity: 0;
        pointer-events: none;
        transition: opacity 200ms ease;
    }

    .admin-shell.is-mobile-sidebar-open .sidebar-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    body.has-open-sidebar {
        overflow: hidden;
    }

    .admin-inset,
    .admin-shell.is-sidebar-collapsed .admin-inset {
        width: 100%;
        min-height: 100svh;
        margin: 0;
        border: 0;
        border-radius: 0;
    }

    .admin-header__inner {
        gap: 0.75rem;
    }

    .sidebar-trigger {
        transform: scale(1.12);
    }

    .header-search {
        width: 2rem;
        padding: 0;
        justify-content: center;
        border-color: transparent;
        background: transparent;
    }

    .header-search span,
    .header-search kbd {
        display: none;
    }

    .dashboard-panels {
        grid-template-columns: 1fr;
    }

    .details-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 639px) {
    .admin-content {
        padding: 1.25rem 1rem;
    }

    .page-heading--actions {
        align-items: stretch;
        flex-direction: column;
    }

    .page-heading--actions .button {
        width: 100%;
    }

    .dashboard-grid,
    .form-grid,
    .stock-summary-grid {
        grid-template-columns: 1fr;
    }

    .form-field--wide,
    .checkbox-field {
        grid-column: auto;
    }

    .table-toolbar {
        align-items: stretch;
        flex-wrap: wrap;
    }

    .table-search {
        width: 100%;
    }

    .table-filter {
        width: 100%;
    }

    .table-toolbar--wrap .table-filter {
        max-width: none;
    }

    .pagination-bar {
        align-items: flex-start;
        flex-direction: column;
    }

    .chart-placeholder {
        gap: 0.375rem;
        padding-right: 0;
        padding-left: 0;
    }

    .heading-actions,
    .heading-actions .button {
        width: 100%;
    }

    .danger-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .info-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .danger-zone .button {
        width: 100%;
    }

    .list-card > header {
        align-items: stretch;
        flex-direction: column;
    }

    .supply-line {
        grid-template-columns: 1fr;
    }

    .supply-line__remove {
        width: 100%;
        margin: 0;
    }

    .serial-scanner__controls {
        align-items: stretch;
        flex-direction: column;
    }

    .serial-scanner__controls .button {
        width: 100%;
    }

    .checkout-zone,
    .checkout-form,
    .order-actions-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .checkout-form,
    .checkout-form .button,
    .order-actions-zone .button {
        width: 100%;
    }
}

/* ILM Admin visual system */

.admin-page {
    --admin-grid-line: rgb(16 18 22 / 3.5%);
    --admin-surface-shadow: 0 1rem 2.5rem rgb(16 18 22 / 6%);
    background: #101216;
}

html.dark .admin-page {
    --admin-grid-line: rgb(255 255 255 / 2.8%);
    --admin-surface-shadow: 0 1rem 2.5rem rgb(0 0 0 / 20%);
}

.admin-shell {
    background-color: var(--sidebar);
    background-image:
        linear-gradient(rgb(255 255 255 / 2.5%) 1px, transparent 1px),
        linear-gradient(90deg, rgb(255 255 255 / 2.5%) 1px, transparent 1px);
    background-size: 44px 44px;
}

.sidebar-inner {
    border-right: 1px solid var(--sidebar-border);
    background: linear-gradient(180deg, rgb(255 255 255 / 2%) 0%, transparent 38%);
}

.sidebar-header {
    padding-top: 0.625rem;
}

.sidebar-brand {
    height: 4rem;
    gap: 0.75rem;
    padding: 0.5rem 0.625rem;
    border: 1px solid transparent;
    border-radius: 0.875rem;
}

.sidebar-brand:hover {
    border-color: var(--sidebar-border);
    background: rgb(255 255 255 / 4%);
}

.sidebar-brand__mark {
    display: flex;
    width: 6.5rem;
    height: 2.5rem;
    flex: 0 0 6.5rem;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
    border-radius: 0;
    background: transparent;
    color: inherit;
    transition: width 200ms ease, flex-basis 200ms ease;
}

.sidebar-brand__mark img {
    display: block;
    width: 6.5rem;
    height: auto;
    transition: width 200ms ease;
}

.sidebar-brand__copy {
    align-content: center;
    padding-left: 0.75rem;
    border-left: 1px solid var(--sidebar-border);
}

.sidebar-brand__copy strong {
    color: #ffffff;
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.sidebar-brand__copy small,
.admin-sidebar .sidebar-user__copy small {
    color: rgb(255 255 255 / 44%);
}

.sidebar-group {
    padding: 0.75rem 0.5rem;
}

.sidebar-group__label {
    height: 2.25rem;
    color: rgb(255 255 255 / 38%);
    font-size: 0.625rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.sidebar-menu,
.sidebar-submenu {
    gap: 0.375rem;
}

.sidebar-link {
    height: 2.75rem;
    gap: 0.75rem;
    padding: 0.625rem 0.75rem;
    border-radius: 0.75rem;
    color: rgb(255 255 255 / 72%);
    font-weight: 600;
}

.sidebar-link .icon {
    color: rgb(255 255 255 / 46%);
}

.sidebar-link:hover,
.sidebar-link:focus-visible {
    background: rgb(255 255 255 / 7%);
    color: #ffffff;
}

.sidebar-link.is-active {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 0.625rem 1.5rem rgb(207 32 40 / 23%);
    font-weight: 700;
}

.sidebar-link:hover .icon,
.sidebar-link:focus-visible .icon,
.sidebar-link.is-active .icon {
    color: currentColor;
}

.sidebar-submenu {
    margin: 0.25rem 0.875rem 0.375rem 1.25rem;
    padding-left: 0.875rem;
    border-left-color: rgb(255 255 255 / 12%);
}

.sidebar-submenu a {
    height: 2.25rem;
    border-radius: 0.625rem;
    color: rgb(255 255 255 / 56%);
    font-size: 0.8125rem;
}

.sidebar-submenu a:hover,
.sidebar-submenu a.is-active {
    background: rgb(255 255 255 / 6%);
    color: #ffffff;
}

.sidebar-submenu a.is-active {
    box-shadow: inset 2px 0 0 var(--primary);
}

.sidebar-footer {
    padding-bottom: 0.75rem;
}

.sidebar-user {
    height: 3.5rem;
    padding: 0.5rem;
    border: 1px solid var(--sidebar-border);
    border-radius: 0.875rem;
    color: #ffffff;
}

.sidebar-user:hover,
.user-menu[open] .sidebar-user {
    background: rgb(255 255 255 / 6%);
}

.admin-sidebar .avatar {
    border-color: rgb(255 255 255 / 14%);
    background: #24272c;
    color: #ffffff;
    font-weight: 800;
}

.admin-shell.is-sidebar-collapsed .sidebar-brand__mark {
    width: 2rem;
    flex-basis: 2rem;
}

.admin-shell.is-sidebar-collapsed .sidebar-brand__mark img {
    width: 2rem;
}

.admin-shell.is-sidebar-collapsed .sidebar-brand {
    padding-right: 0.25rem;
    padding-left: 0.25rem;
}

.admin-inset {
    min-height: calc(100svh - 1.5rem);
    margin: 0.75rem 0.75rem 0.75rem 0;
    border-color: rgb(255 255 255 / 10%);
    border-radius: 1.5rem;
    background-color: var(--background);
    background-image:
        linear-gradient(var(--admin-grid-line) 1px, transparent 1px),
        linear-gradient(90deg, var(--admin-grid-line) 1px, transparent 1px);
    background-size: 44px 44px;
    box-shadow: 0 2rem 5rem rgb(0 0 0 / 24%);
}

.admin-shell.is-sidebar-collapsed .admin-inset {
    margin-top: 0.75rem;
    margin-right: 0.75rem;
    margin-bottom: 0.75rem;
}

.admin-header {
    height: 4.75rem;
    flex-basis: 4.75rem;
}

.admin-header__inner {
    padding: 1rem clamp(1rem, 2.2vw, 2rem);
    border-bottom: 1px solid color-mix(in srgb, var(--border) 80%, transparent);
    background: color-mix(in srgb, var(--background) 84%, transparent);
    backdrop-filter: blur(18px);
}

.admin-header.is-scrolled {
    box-shadow: 0 0.5rem 2rem rgb(16 18 22 / 8%);
}

.admin-header.is-scrolled .admin-header__inner::before {
    display: none;
}

.top-nav {
    gap: 0.5rem;
}

.top-nav a {
    padding: 0.5rem 0.75rem;
    border-radius: 0.625rem;
    font-size: 0.75rem;
    font-weight: 700;
}

.top-nav a:hover {
    background: var(--muted);
    color: var(--foreground);
}

.header-search {
    height: 2.5rem;
    border-radius: 0.75rem;
    background: color-mix(in srgb, var(--card) 72%, transparent);
}

.header-search kbd {
    top: 0.55rem;
    right: 0.5rem;
    border-radius: 0.375rem;
}

.icon-button {
    width: 2.5rem;
    height: 2.5rem;
    flex-basis: 2.5rem;
    border-radius: 0.75rem;
}

.icon-button--outline {
    border-color: var(--border);
    background: color-mix(in srgb, var(--card) 80%, transparent);
}

.avatar--button {
    width: 2.5rem;
    height: 2.5rem;
    flex-basis: 2.5rem;
    border-color: color-mix(in srgb, var(--primary) 24%, var(--border));
    background: color-mix(in srgb, var(--primary) 12%, var(--card));
    color: var(--primary);
    font-weight: 800;
}

.dropdown-panel {
    padding: 0.5rem;
    border-radius: 0.875rem;
    box-shadow: 0 1.25rem 3rem rgb(16 18 22 / 18%);
}

.dropdown-item {
    min-height: 2.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 0.625rem;
    font-weight: 600;
}

.admin-content {
    padding: clamp(1.5rem, 3vw, 2.75rem);
}

.admin-footer {
    padding: 1.25rem;
    border-top-color: color-mix(in srgb, var(--border) 75%, transparent);
    font-size: 0.75rem;
}

.page-heading {
    align-items: center;
    margin-bottom: 2rem;
}

.page-heading > div:first-child {
    position: relative;
    padding-left: 1.125rem;
}

.page-heading > div:first-child::before {
    position: absolute;
    top: 0.15rem;
    bottom: 0.15rem;
    left: 0;
    width: 3px;
    border-radius: 999px;
    background: var(--primary);
    content: "";
}

.page-heading h1 {
    font-size: clamp(1.75rem, 3vw, 2.375rem);
    font-weight: 800;
    letter-spacing: -0.05em;
    line-height: 1.05;
}

.page-heading p,
.panel-card header p {
    margin-top: 0.5rem;
    line-height: 1.55;
}

.metric-card,
.stat-card,
.panel-card,
.form-card,
.detail-card,
.list-card,
.info-zone,
.empty-state,
.data-table-wrap {
    border-color: color-mix(in srgb, var(--border) 82%, transparent);
    border-radius: 1rem;
    background: var(--card);
    box-shadow: var(--admin-surface-shadow);
}

.metric-card,
.stat-card {
    position: relative;
    overflow: hidden;
}

.metric-card::before,
.stat-card::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), color-mix(in srgb, var(--primary) 15%, transparent));
    content: "";
}

.metric-card {
    min-height: 10.5rem;
    padding: 1.5rem;
}

.metric-card > span,
.stat-card span {
    color: var(--muted-foreground);
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.metric-card > strong,
.stat-card strong {
    color: var(--card-foreground);
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.05em;
}

.metric-card > small {
    margin-top: 0.25rem;
}

.stat-card {
    display: flex;
    min-height: 7rem;
    align-items: center;
    padding: 1.5rem;
}

.stat-card > div {
    display: grid;
    gap: 0.375rem;
}

.panel-card {
    padding: 1.75rem;
}

.panel-card h2,
.form-section h2,
.detail-card h2,
.list-card h2,
.info-zone h2,
.danger-zone h2 {
    font-size: 1.0625rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.chart-placeholder {
    border-bottom-color: var(--border);
}

.chart-placeholder span {
    background: linear-gradient(180deg, #e8454d 0%, var(--primary) 100%);
    box-shadow: 0 -0.5rem 1.5rem rgb(207 32 40 / 12%);
}

.admin-page .button {
    min-height: 2.75rem;
    padding: 0.625rem 1.125rem;
    border-radius: 0.75rem;
    font-weight: 700;
    transition: transform 150ms ease, box-shadow 150ms ease, background-color 150ms ease, opacity 150ms ease;
}

.admin-page .button--primary {
    box-shadow: 0 0.625rem 1.25rem rgb(207 32 40 / 18%);
}

.admin-page .button--primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 0.75rem 1.5rem rgb(207 32 40 / 25%);
    opacity: 1;
}

.admin-page .button--outline {
    background: var(--card);
}

.admin-page .button--outline:hover {
    border-color: color-mix(in srgb, var(--primary) 35%, var(--border));
    background: color-mix(in srgb, var(--primary) 6%, var(--card));
    color: var(--primary);
}

.table-toolbar {
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.table-search input,
.table-filter,
.admin-page .form-field input,
.admin-page .form-field select,
.admin-page .form-field textarea,
.serial-scanner__input input {
    border-color: var(--input);
    border-radius: 0.75rem;
    background: var(--card);
}

.table-search input,
.table-filter,
.admin-page .form-field input,
.admin-page .form-field select,
.serial-scanner__input input {
    height: 2.875rem;
}

.admin-page .form-field textarea {
    min-height: 7rem;
    padding: 0.875rem 1rem;
}

.admin-page .form-field input,
.admin-page .form-field select {
    padding-right: 1rem;
    padding-left: 1rem;
}

.table-search input:focus,
.table-filter:focus,
.admin-page .form-field input:focus,
.admin-page .form-field select:focus,
.admin-page .form-field textarea:focus,
.serial-scanner__input input:focus {
    border-color: var(--ring);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--ring) 16%, transparent);
}

.admin-page .form-field > label {
    font-size: 0.75rem;
    font-weight: 700;
}

.form-card,
.detail-card {
    padding: 1.75rem;
}

.form-section + .form-section,
.form-actions,
.detail-card > header {
    border-color: color-mix(in srgb, var(--border) 78%, transparent);
}

.data-table-wrap {
    overflow: hidden;
    overflow-x: auto;
}

.data-table th,
.data-table td {
    height: 3.5rem;
    padding-right: 1.25rem;
    padding-left: 1.25rem;
}

.data-table th {
    background: color-mix(in srgb, var(--muted) 62%, var(--card));
    color: var(--muted-foreground);
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.data-table tbody tr:hover {
    background: color-mix(in srgb, var(--primary) 4%, var(--card));
}

.table-primary-link:hover,
.table-contact:hover {
    color: var(--primary);
    text-decoration: none;
}

.table-actions .icon-button {
    width: 2.25rem;
    height: 2.25rem;
    flex-basis: 2.25rem;
}

.pagination__button {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.625rem;
    background: var(--card);
    font-weight: 700;
}

.pagination__button.is-active {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--primary-foreground);
}

.back-link:hover,
.toolbar-reset:hover {
    color: var(--primary);
}

.list-card > header {
    padding: 1.5rem 1.75rem;
    border-bottom: 1px solid color-mix(in srgb, var(--border) 78%, transparent);
}

.data-table-wrap--embedded {
    border-radius: 0 0 1rem 1rem;
    box-shadow: none;
}

.detail-list > div {
    border-color: color-mix(in srgb, var(--border) 78%, transparent);
}

.danger-zone {
    border-radius: 1rem;
}

.flash,
.alert {
    border-radius: 0.875rem;
}

.type-badge,
.status-badge,
.dealer-status,
.stock-status,
.order-status,
.document-type,
.serial-picker-count {
    padding: 0.25rem 0.625rem;
    font-weight: 700;
}

.serial-scanner,
.supply-line {
    border-radius: 0.875rem;
}

html.dark .admin-header__inner {
    background: color-mix(in srgb, var(--background) 88%, transparent);
}

html.dark .admin-page .button--outline,
html.dark .table-search input,
html.dark .table-filter,
html.dark .admin-page .form-field input,
html.dark .admin-page .form-field select,
html.dark .admin-page .form-field textarea,
html.dark .serial-scanner__input input {
    background: color-mix(in srgb, var(--card) 88%, #ffffff 2%);
}

@media (max-width: 767px) {
    .admin-sidebar,
    .admin-shell.is-sidebar-collapsed .admin-sidebar {
        background: var(--sidebar);
    }

    .sidebar-inner {
        border-right: 0;
    }

    .admin-inset,
    .admin-shell.is-sidebar-collapsed .admin-inset {
        min-height: 100svh;
        margin: 0;
        border-radius: 0;
    }

    .admin-header__inner {
        padding-right: 1rem;
        padding-left: 1rem;
    }
}

@media (max-width: 639px) {
    .admin-content {
        padding: 1.5rem 1rem 2rem;
    }

    .page-heading {
        margin-bottom: 1.5rem;
    }

    .page-heading h1 {
        font-size: 1.75rem;
    }

    .metric-card,
    .stat-card,
    .panel-card,
    .form-card,
    .detail-card,
    .list-card,
    .info-zone,
    .empty-state,
    .data-table-wrap {
        border-radius: 0.875rem;
    }

    .metric-card,
    .panel-card,
    .form-card,
    .detail-card {
        padding: 1.25rem;
    }

    .list-card > header {
        padding: 1.25rem;
    }
}

/* Live application notifications */
.notification-center,
.notification-menu {
    position: relative;
}

.notification-menu > summary {
    list-style: none;
}

.notification-menu > summary::-webkit-details-marker {
    display: none;
}

.notification-menu:not([open]) .notification-menu__panel {
    display: none;
}

.notification-badge {
    position: absolute;
    top: -0.2rem;
    right: -0.2rem;
    display: grid;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.25rem;
    place-items: center;
    border: 2px solid var(--background);
    border-radius: 999px;
    background: var(--primary);
    color: var(--primary-foreground);
    font-size: 0.625rem;
    font-weight: 800;
    line-height: 1;
}

.notification-badge[hidden],
.notification-list[hidden],
.notification-empty[hidden] {
    display: none;
}

.notification-menu__panel {
    top: calc(100% + 0.65rem);
    right: 0;
    width: min(24rem, calc(100vw - 2rem));
    padding: 0;
    overflow: hidden;
}

.notification-menu__header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.notification-menu__header strong {
    font-size: 0.9375rem;
}

.notification-menu__header span {
    color: var(--muted-foreground);
    font-size: 0.6875rem;
    text-align: right;
}

.notification-list {
    display: grid;
    max-height: min(28rem, calc(100vh - 12rem));
    overflow-y: auto;
}

.notification-item {
    display: grid;
    gap: 0.25rem;
    padding: 0.875rem 1rem;
    border-bottom: 1px solid color-mix(in srgb, var(--border) 72%, transparent);
    color: var(--foreground);
    text-decoration: none;
}

.notification-item:hover,
.notification-item:focus-visible {
    background: color-mix(in srgb, var(--primary) 5%, var(--card));
    outline: none;
}

.notification-item__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    color: var(--muted-foreground);
    font-size: 0.6875rem;
}

.notification-item__kind {
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--primary) 10%, var(--card));
    color: var(--primary);
    font-weight: 800;
}

.notification-item__kind--dealer {
    background: color-mix(in srgb, #2563eb 10%, var(--card));
    color: #2563eb;
}

.notification-item strong {
    font-size: 0.8125rem;
}

.notification-item__description {
    overflow: hidden;
    color: var(--muted-foreground);
    font-size: 0.75rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.notification-empty {
    padding: 2rem 1rem;
    color: var(--muted-foreground);
    font-size: 0.8125rem;
    text-align: center;
}

.notification-menu__footer {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: color-mix(in srgb, var(--muted) 55%, var(--card));
}

.notification-menu__footer a {
    color: var(--muted-foreground);
    font-size: 0.6875rem;
    font-weight: 700;
    text-decoration: none;
}

.notification-menu__footer a:hover {
    color: var(--primary);
}

.notification-toast-region {
    position: fixed;
    z-index: 100;
    top: 5.75rem;
    right: 1.5rem;
    width: min(22rem, calc(100vw - 2rem));
    pointer-events: none;
}

.notification-toast {
    display: grid;
    gap: 0.25rem;
    padding: 1rem 1.125rem;
    border: 1px solid color-mix(in srgb, var(--primary) 25%, var(--border));
    border-radius: 0.875rem;
    background: var(--popover);
    box-shadow: 0 1.25rem 3rem rgb(16 18 22 / 20%);
    color: var(--popover-foreground);
    animation: notification-toast-in 180ms ease-out;
}

.notification-toast::before {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 0.25rem;
    border-radius: 0.875rem 0 0 0.875rem;
    background: var(--primary);
    content: "";
}

.notification-toast {
    position: relative;
    overflow: hidden;
}

.notification-toast span {
    color: var(--muted-foreground);
    font-size: 0.8125rem;
}

@keyframes notification-toast-in {
    from {
        transform: translateY(-0.5rem);
        opacity: 0;
    }
}

@media (max-width: 767px) {
    .notification-toast-region {
        top: 5rem;
        right: 1rem;
        left: 1rem;
        width: auto;
    }
}

@media (max-width: 639px) {
    .notification-menu__panel {
        position: fixed;
        top: 4.5rem;
        right: 1rem;
        left: 1rem;
        width: auto;
    }
}
