@import "tailwindcss/theme" theme(static);
@import "tailwindcss/utilities";

@source "../../src/Bridge/Symfony/Bundle/Resources/views/admin/**/*.twig";

@theme {
    --font-sans: "Inter", "Helvetica Neue", Arial, sans-serif;

    --color-terra-background: #f7f2ea;
    --color-terra-surface: #fcfaf7;
    --color-terra-panel: #ffffff;
    --color-terra-border: #eadfcf;
    --color-terra-border-strong: #d9c7ae;
    --color-terra-accent: #9d7c47;
    --color-terra-gold: #ad9c76;
    --color-terra-nav: #383838;
    --color-terra-text: #201917;
    --color-terra-muted: #5d4b41;
    --color-terra-danger: #ba1a1a;
    --color-terra-success: #5cb85c;
}

:root {
    --admin-bg: #f7f2ea;
    --admin-surface: #fcfaf7;
    --admin-panel: #ffffff;
    --admin-border: #eadfcf;
    --admin-border-strong: #d9c7ae;
    --admin-accent: #9d7c47;
    --admin-gold: #ad9c76;
    --admin-nav: #383838;
    --admin-text: #201917;
    --admin-muted: #5d4b41;
    --admin-danger: #ba1a1a;
    --admin-success: #5cb85c;
    --admin-sidebar-width: 240px;
    --admin-shadow: 0 18px 45px rgba(61, 43, 23, 0.08);
}

[x-cloak] {
    display: none !important;
}

html,
body {
    min-height: 100%;
}

body.admin-shell {
    margin: 0;
    background: var(--admin-bg);
    color: var(--admin-text);
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.45;
}

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

.admin-shell a {
    color: inherit;
    text-decoration: none;
}

.admin-shell button:not(:disabled),
.admin-shell input[type="button"]:not(:disabled),
.admin-shell input[type="submit"]:not(:disabled),
.admin-shell input[type="reset"]:not(:disabled),
.admin-shell [role="button"] {
    cursor: pointer;
}

.admin-shell button:disabled,
.admin-shell input[type="button"]:disabled,
.admin-shell input[type="submit"]:disabled,
.admin-shell input[type="reset"]:disabled {
    cursor: not-allowed;
}

.admin-layout {
    display: grid;
    min-height: 100vh;
    grid-template-columns: var(--admin-sidebar-width) minmax(0, 1fr);
    background:
        radial-gradient(circle at 12% 0%, rgba(234, 223, 207, 0.5), transparent 34%),
        linear-gradient(180deg, rgba(252, 250, 247, 0.84), rgba(247, 242, 234, 0.96)),
        var(--admin-bg);
}

.admin-sidebar {
    position: sticky;
    top: 0;
    display: flex;
    height: 100vh;
    flex-direction: column;
    overflow-y: auto;
    border-right: 1px solid rgba(234, 223, 207, 0.12);
    background: var(--admin-nav);
    color: #f7f2ea;
}

.admin-sidebar-header {
    display: flex;
    min-height: 72px;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 1px solid rgba(234, 223, 207, 0.12);
}

.admin-brand {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: 10px;
}

.admin-brand-mark {
    display: inline-grid;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    place-items: center;
    border: 1px solid rgba(173, 156, 118, 0.36);
    border-radius: 4px;
    background: rgba(173, 156, 118, 0.14);
    color: #ffffff;
    font-weight: 700;
}

.admin-brand strong,
.admin-brand small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-brand strong {
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
}

.admin-brand small {
    margin-top: 1px;
    color: rgba(247, 242, 234, 0.64);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.admin-sidebar-close {
    display: none;
}

.admin-nav {
    display: grid;
    min-height: calc(100vh - 72px);
    gap: 16px;
    padding: 16px 12px 24px;
}

.admin-nav-section {
    display: grid;
    gap: 4px;
}

.admin-nav-section-bottom {
    align-self: end;
    margin-top: auto;
    border-top: 1px solid rgba(234, 223, 207, 0.12);
    padding-top: 12px;
}

.admin-nav-link-settings {
    min-height: 40px;
}

.admin-nav-label {
    margin: 12px 10px 6px;
    color: rgba(217, 199, 174, 0.74);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.admin-nav-link,
.admin-nav-group > summary,
.admin-nav-group a {
    display: flex;
    min-height: 36px;
    align-items: center;
    gap: 10px;
    border-radius: 4px;
    color: rgba(252, 250, 247, 0.78);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
}

.admin-nav-link,
.admin-nav-group > summary {
    padding: 8px 10px;
}

.admin-nav-link:hover,
.admin-nav-link:focus,
.admin-nav-group > summary:hover,
.admin-nav-group > summary:focus,
.admin-nav-group a:hover,
.admin-nav-group a:focus {
    background: rgba(173, 156, 118, 0.14);
    color: #ffffff;
    outline: none;
}

.admin-nav-link.is-active {
    border-left: 3px solid var(--admin-gold);
    background: rgba(173, 156, 118, 0.18);
    color: #ffffff;
    padding-left: 7px;
}

.admin-nav-dot {
    width: 7px;
    height: 7px;
    flex: 0 0 7px;
    border-radius: 50%;
    background: var(--admin-gold);
    opacity: 0.68;
}

.admin-nav-group {
    margin: 0;
}

.admin-nav-group > summary {
    cursor: pointer;
    list-style: none;
}

.admin-nav-group > summary::-webkit-details-marker {
    display: none;
}

.admin-nav-group > summary::before {
    width: 7px;
    height: 7px;
    flex: 0 0 7px;
    border-right: 2px solid var(--admin-gold);
    border-bottom: 2px solid var(--admin-gold);
    content: "";
    transform: rotate(-45deg);
    transition: transform 160ms ease;
}

.admin-nav-group[open] > summary::before {
    transform: rotate(45deg);
}

.admin-nav-group.is-active > summary {
    background: rgba(173, 156, 118, 0.12);
    color: #ffffff;
}

.admin-nav-group > div {
    display: grid;
    margin: 2px 0 8px 22px;
    gap: 2px;
    border-left: 1px solid rgba(173, 156, 118, 0.24);
    padding-left: 8px;
}

.admin-nav-group a {
    min-height: 30px;
    padding: 6px 8px;
    color: rgba(252, 250, 247, 0.66);
    font-size: 12px;
}

.admin-nav-group a.is-active {
    background: rgba(173, 156, 118, 0.16);
    box-shadow: inset 2px 0 0 var(--admin-gold);
    color: #ffffff;
}

.admin-mobile-scrim {
    display: none;
}

.admin-main {
    min-width: 0;
}

.admin-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    min-height: 72px;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--admin-border);
    background: rgba(252, 250, 247, 0.94);
    padding: 12px 24px;
    backdrop-filter: blur(18px);
}

.admin-heading {
    min-width: 0;
}

.admin-heading p,
.admin-heading h1 {
    margin: 0;
}

.admin-heading p {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.admin-heading h1 {
    overflow: hidden;
    color: var(--admin-text);
    font-size: 20px;
    font-weight: 720;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-topbar-actions {
    display: flex;
    min-width: 0;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-left: auto;
}

.admin-icon-button,
.admin-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-muted);
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.admin-icon-button {
    width: 38px;
    height: 38px;
    padding: 0;
}

.admin-icon-button:hover,
.admin-icon-button:focus,
.admin-button:hover,
.admin-button:focus {
    border-color: var(--admin-accent);
    color: var(--admin-text);
    outline: none;
}

.admin-button {
    min-height: 38px;
    padding: 0 14px;
}

.admin-button-primary {
    border-color: var(--admin-accent);
    background: var(--admin-accent);
    color: #ffffff;
}

.admin-button-primary:hover,
.admin-button-primary:focus {
    border-color: #80622f;
    background: #80622f;
    color: #ffffff;
}

.admin-icon-button:disabled,
.admin-button:disabled,
.admin-button[aria-disabled="true"] {
    cursor: not-allowed;
    opacity: 0.58;
}

.admin-menu-button {
    display: none;
}

.admin-menu-icon,
.admin-menu-icon::before,
.admin-menu-icon::after {
    display: block;
    width: 16px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    content: "";
}

.admin-menu-icon {
    position: relative;
}

.admin-menu-icon::before,
.admin-menu-icon::after {
    position: absolute;
    left: 0;
}

.admin-menu-icon::before {
    top: -5px;
}

.admin-menu-icon::after {
    top: 5px;
}

.admin-alert-button {
    position: relative;
}

.admin-alert-button::after {
    position: absolute;
    top: 8px;
    right: 9px;
    width: 7px;
    height: 7px;
    border: 2px solid var(--admin-panel);
    border-radius: 50%;
    background: var(--admin-danger);
    content: "";
}

.admin-alert-button svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.admin-account {
    position: relative;
}

.admin-account > summary {
    display: flex;
    min-height: 42px;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    padding: 4px 10px 4px 4px;
    cursor: pointer;
    list-style: none;
}

.admin-account > summary::-webkit-details-marker {
    display: none;
}

.admin-account-avatar {
    display: inline-grid;
    width: 32px;
    height: 32px;
    place-items: center;
    border-radius: 4px;
    background: var(--admin-nav);
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
}

.admin-account-copy {
    display: grid;
    max-width: 150px;
    min-width: 0;
}

.admin-account-copy strong,
.admin-account-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.admin-account-copy strong {
    color: var(--admin-text);
    font-size: 12px;
    font-weight: 800;
}

.admin-account-copy small {
    color: var(--admin-muted);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.admin-account-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 180px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    box-shadow: var(--admin-shadow);
    padding: 6px;
}

.admin-account-menu a {
    display: block;
    border-radius: 4px;
    color: var(--admin-muted);
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    padding: 8px 10px;
}

.admin-account-menu a:hover,
.admin-account-menu a:focus {
    background: var(--admin-surface);
    color: var(--admin-text);
    outline: none;
}

.admin-page {
    min-height: calc(100vh - 72px);
    padding: 24px;
}

.admin-workspace.has-settings-sidebar {
    display: grid;
    grid-template-columns: 224px minmax(0, 1fr);
    min-height: calc(100vh - 72px);
}

.admin-settings-sidebar {
    position: sticky;
    top: 72px;
    height: calc(100vh - 72px);
    overflow-y: auto;
    border-right: 1px solid var(--admin-border);
    background: rgba(252, 250, 247, 0.78);
    padding: 18px 14px;
}

.admin-settings-sidebar-header {
    margin-bottom: 14px;
    padding: 0 4px 12px;
    border-bottom: 1px solid var(--admin-border);
}

.admin-settings-sidebar-header p,
.admin-settings-sidebar-header strong {
    display: block;
    margin: 0;
}

.admin-settings-sidebar-header p {
    color: var(--admin-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-settings-sidebar-header strong {
    margin-top: 2px;
    color: var(--admin-text);
    font-size: 15px;
    font-weight: 760;
}

.admin-settings-nav {
    display: grid;
    gap: 4px;
}

.admin-settings-nav p {
    margin: 16px 8px 4px;
    color: var(--admin-muted);
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-settings-nav a {
    display: flex;
    min-height: 34px;
    align-items: center;
    border-radius: 4px;
    color: var(--admin-muted);
    font-size: 13px;
    font-weight: 700;
    padding: 8px 10px;
}

.admin-settings-nav a:hover,
.admin-settings-nav a:focus {
    background: var(--admin-panel);
    color: var(--admin-text);
    outline: none;
}

.admin-settings-nav a.is-active {
    background: var(--admin-panel);
    box-shadow: inset 3px 0 0 var(--admin-accent);
    color: var(--admin-text);
}

.admin-settings-home {
    display: grid;
    gap: 18px;
}

.admin-settings-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: var(--admin-shadow);
    padding: 20px;
}

.admin-settings-hero h2,
.admin-settings-hero p {
    margin: 0;
}

.admin-settings-hero h2 {
    color: var(--admin-text);
    font-size: 24px;
    font-weight: 720;
    line-height: 1.2;
}

.admin-settings-hero p:not(.admin-home-kicker) {
    max-width: 680px;
    margin-top: 6px;
    color: var(--admin-muted);
}

.admin-settings-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.admin-settings-card {
    display: grid;
    min-height: 148px;
    align-content: start;
    gap: 8px;
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: 0 10px 24px rgba(61, 43, 23, 0.05);
    padding: 16px;
    transition:
        border-color 160ms ease,
        transform 160ms ease,
        box-shadow 160ms ease;
}

.admin-settings-card:hover,
.admin-settings-card:focus {
    border-color: var(--admin-border-strong);
    box-shadow: var(--admin-shadow);
    outline: none;
    transform: translateY(-1px);
}

.admin-settings-card span {
    width: max-content;
    max-width: 100%;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-muted);
    font-size: 10px;
    font-weight: 800;
    padding: 4px 7px;
    text-transform: uppercase;
}

.admin-settings-card strong {
    color: var(--admin-text);
    font-size: 17px;
    font-weight: 760;
}

.admin-settings-card small {
    color: var(--admin-muted);
    font-size: 13px;
    line-height: 1.45;
}

.admin-live-form {
    display: grid;
    gap: 16px;
}

.admin-form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: 0 8px 20px rgba(61, 43, 23, 0.05);
    padding: 12px;
}

.admin-flashes {
    display: grid;
    gap: 8px;
    margin-bottom: 18px;
}

.admin-flash {
    border: 1px solid var(--admin-border);
    border-left: 4px solid var(--admin-accent);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    padding: 10px 12px;
    box-shadow: 0 8px 20px rgba(61, 43, 23, 0.05);
}

.admin-flash-success {
    border-left-color: var(--admin-success);
}

.admin-flash-error,
.admin-flash-danger {
    border-left-color: var(--admin-danger);
}

.admin-home {
    display: grid;
    gap: 18px;
}

.admin-home-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: var(--admin-shadow);
    padding: 20px;
}

.admin-home-kicker,
.admin-panel-heading p {
    margin: 0 0 4px;
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-home-hero h2,
.admin-home-hero p,
.admin-panel-heading h3 {
    margin: 0;
}

.admin-home-hero h2 {
    color: var(--admin-text);
    font-size: 24px;
    font-weight: 720;
    line-height: 1.2;
}

.admin-home-hero p:not(.admin-home-kicker) {
    max-width: 680px;
    margin-top: 6px;
    color: var(--admin-muted);
    font-size: 14px;
}

.admin-home-meta {
    display: grid;
    min-width: 132px;
    gap: 2px;
    border-left: 1px solid var(--admin-border);
    padding-left: 16px;
    text-align: right;
}

.admin-home-meta span {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-home-meta strong {
    color: var(--admin-text);
    font-size: 15px;
}

.admin-home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 320px);
    gap: 16px;
    align-items: start;
}

.admin-home-main,
.admin-home-aside {
    display: grid;
    gap: 16px;
}

.admin-quick-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.admin-quick-card {
    position: relative;
    display: grid;
    min-height: 112px;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    border: 1px solid var(--admin-border);
    border-left: 3px solid var(--admin-accent);
    border-radius: 6px;
    background: var(--admin-panel);
    padding: 14px;
    box-shadow: 0 8px 18px rgba(61, 43, 23, 0.04);
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.admin-quick-card:hover,
.admin-quick-card:focus {
    border-color: var(--admin-border-strong);
    border-left-color: var(--admin-gold);
    box-shadow: var(--admin-shadow);
    outline: none;
    transform: translateY(-1px);
}

.admin-quick-mark {
    display: inline-grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-accent);
    font-size: 11px;
    font-weight: 900;
}

.admin-quick-card strong,
.admin-quick-card small {
    display: block;
}

.admin-quick-card strong {
    color: var(--admin-text);
    font-size: 15px;
    font-weight: 800;
    line-height: 1.25;
}

.admin-quick-card small {
    margin-top: 5px;
    color: var(--admin-muted);
    font-size: 12px;
    line-height: 1.35;
}

.admin-dashboard-panel {
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    padding: 16px;
    box-shadow: 0 8px 18px rgba(61, 43, 23, 0.04);
}

.admin-panel-heading {
    margin-bottom: 12px;
}

.admin-panel-heading h3 {
    color: var(--admin-text);
    font-size: 16px;
    font-weight: 800;
}

.admin-action-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.admin-action-list a,
.admin-settings-list a {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--admin-border-strong);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-text);
    cursor: pointer;
    font-size: 13px;
    font-weight: 800;
    padding: 0 12px;
}

.admin-action-list a:hover,
.admin-action-list a:focus,
.admin-settings-list a:hover,
.admin-settings-list a:focus {
    border-color: var(--admin-accent);
    background: var(--admin-panel);
    outline: none;
}

.admin-check-list,
.admin-settings-list {
    display: grid;
    gap: 8px;
}

.admin-check-list a {
    display: flex;
    min-height: 44px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-text);
    cursor: pointer;
    padding: 10px 12px;
}

.admin-check-list a:hover,
.admin-check-list a:focus {
    border-color: var(--admin-accent);
    background: var(--admin-panel);
    outline: none;
}

.admin-check-list span {
    font-size: 13px;
    font-weight: 800;
}

.admin-check-list small {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-list-page {
    display: grid;
    gap: 16px;
}

.admin-filter-panel,
.admin-table-panel {
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: 0 8px 18px rgba(61, 43, 23, 0.04);
}

.admin-filter-panel {
    display: grid;
    gap: 16px;
    padding: 16px;
}

.admin-filter-toggle-input,
.admin-filter-toggle {
    display: none;
}

.admin-filter-body {
    display: grid;
    gap: 16px;
}

.admin-filter-header,
.admin-table-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.admin-filter-header p,
.admin-table-heading p {
    margin: 0 0 4px;
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-filter-header h2,
.admin-table-heading h2 {
    margin: 0;
    color: var(--admin-text);
    font-size: 18px;
    font-weight: 800;
}

.admin-filter-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.admin-filter-grid {
    display: grid;
    grid-template-columns: minmax(260px, 2fr) repeat(4, minmax(150px, 1fr));
    gap: 12px;
}

.admin-filter-grid label {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.admin-filter-grid span {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-filter-grid input,
.admin-filter-grid select {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    font: inherit;
    padding: 8px 10px;
}

.admin-filter-grid select {
    cursor: pointer;
}

.admin-filter-grid input:focus,
.admin-filter-grid select:focus {
    border-color: var(--admin-accent);
    box-shadow: 0 0 0 2px rgba(157, 124, 71, 0.1);
    outline: none;
}

.admin-table-panel {
    overflow: hidden;
}

.admin-table-actionbar {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    border-bottom: 1px solid var(--admin-border);
    background: var(--admin-surface);
    padding: 12px 16px;
}

.admin-table-heading {
    border-bottom: 1px solid var(--admin-border);
    padding: 16px;
}

.admin-table-tools {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.admin-table-tools > span {
    color: var(--admin-muted);
    font-size: 12px;
    font-weight: 800;
}

.admin-per-page-form label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.admin-per-page-form span {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-per-page-form select {
    min-height: 34px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    padding: 6px 28px 6px 10px;
}

.admin-per-page-form select:focus {
    border-color: var(--admin-accent);
    box-shadow: 0 0 0 2px rgba(157, 124, 71, 0.1);
    outline: none;
}

.admin-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.admin-data-table {
    width: 100%;
    min-width: 1120px;
    border-collapse: collapse;
    background: var(--admin-panel);
}

.admin-data-table th,
.admin-data-table td {
    border-bottom: 1px solid var(--admin-border);
    padding: 11px 12px;
    text-align: left;
    vertical-align: top;
}

.admin-data-table th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: var(--admin-surface);
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    white-space: nowrap;
}

.admin-sort-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
    cursor: pointer;
}

.admin-sort-icon {
    width: 14px;
    height: 14px;
    color: var(--admin-border-strong);
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.admin-sort-link.is-active {
    color: var(--admin-text);
}

.admin-sort-link.is-active .admin-sort-icon {
    color: var(--admin-accent);
}

.admin-data-table td {
    color: var(--admin-text);
    font-size: 13px;
}

.admin-data-table tbody tr:hover {
    background: rgba(252, 250, 247, 0.72);
}

.admin-data-table small {
    display: block;
    margin-top: 3px;
    color: var(--admin-muted);
    font-size: 11px;
    line-height: 1.35;
}

.admin-inline-link {
    color: var(--admin-accent);
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.admin-status-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-items: center;
}

.admin-status {
    display: inline-flex;
    min-height: 22px;
    align-items: center;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 7px;
}

.admin-status-success {
    background: rgba(92, 184, 92, 0.12);
    color: #2f6f32;
}

.admin-status-warning {
    background: rgba(157, 124, 71, 0.14);
    color: #745726;
}

.admin-status-danger {
    background: rgba(186, 26, 26, 0.1);
    color: var(--admin-danger);
}

.admin-status-info {
    background: rgba(61, 111, 142, 0.1);
    color: #315d76;
}

.admin-status-muted {
    background: var(--admin-surface);
    color: var(--admin-muted);
}

.admin-row-action {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--admin-border-strong);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    padding: 0 10px;
    white-space: nowrap;
}

.admin-row-action:hover,
.admin-row-action:focus {
    border-color: var(--admin-accent);
    background: var(--admin-surface);
    outline: none;
}

.admin-empty-cell {
    padding: 28px 12px !important;
    text-align: center !important;
    color: var(--admin-muted) !important;
}

.admin-payment-tracking-table {
    min-width: 1380px;
}

.admin-payload-details {
    max-width: 420px;
}

.admin-payment-webhook-panel {
    margin-top: 16px;
}

.admin-payment-webhook-grid {
    display: grid;
    grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
    gap: 16px;
}

.admin-payload-details-wide {
    max-width: none;
}

.admin-payload-details summary {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    border: 1px solid var(--admin-border-strong);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    padding: 0 10px;
}

.admin-payload-details pre {
    max-height: 320px;
    overflow: auto;
    margin: 8px 0 0;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: #201917;
    color: #fcfaf7;
    font-size: 11px;
    line-height: 1.5;
    padding: 12px;
    white-space: pre-wrap;
    word-break: break-word;
}

.admin-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid var(--admin-border);
    padding: 12px 16px;
}

.admin-pagination div {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}

.admin-pagination a,
.admin-pagination span,
.admin-pagination strong {
    display: inline-flex;
    min-width: 34px;
    min-height: 34px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    padding: 0 10px;
}

.admin-pagination a:hover,
.admin-pagination a:focus {
    border-color: var(--admin-accent);
    background: var(--admin-surface);
    outline: none;
}

.admin-pagination span {
    cursor: default;
    color: var(--admin-muted);
    opacity: 0.62;
}

.admin-pagination strong {
    border-color: var(--admin-accent);
    background: var(--admin-accent);
    color: #ffffff;
    cursor: default;
}

.admin-inline-form {
    margin: 0;
}

.admin-order-detail {
    display: grid;
    gap: 16px;
}

.admin-order-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: var(--admin-shadow);
    padding: 18px 20px;
}

.admin-order-hero p,
.admin-order-hero h2 {
    margin: 0;
}

.admin-order-hero p {
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-order-hero h2 {
    margin-top: 3px;
    color: var(--admin-text);
    font-size: 24px;
    font-weight: 800;
}

.admin-order-hero span {
    display: block;
    margin-top: 4px;
    color: var(--admin-muted);
    font-size: 13px;
}

.admin-order-status {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
}

.admin-order-status .admin-status {
    min-height: 30px;
    font-size: 12px;
    padding: 5px 10px;
}

.admin-order-document-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.admin-order-document-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.admin-detail-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
    gap: 16px;
    align-items: start;
}

.admin-detail-main,
.admin-detail-aside {
    display: grid;
    gap: 16px;
}

.admin-detail-panel {
    border: 1px solid var(--admin-border);
    border-radius: 6px;
    background: var(--admin-panel);
    box-shadow: 0 8px 18px rgba(61, 43, 23, 0.04);
    padding: 16px;
}

.admin-detail-panel-heading {
    margin-bottom: 12px;
}

.admin-detail-panel-heading p,
.admin-form-grid label span,
.admin-stacked-form label span,
.admin-form-static span {
    margin: 0 0 4px;
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-detail-panel-heading h3 {
    margin: 0;
    color: var(--admin-text);
    font-size: 16px;
    font-weight: 800;
}

.admin-help-text,
.admin-empty-text {
    margin: 0;
    color: var(--admin-muted);
    font-size: 13px;
    line-height: 1.45;
}

.admin-form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.admin-form-grid label,
.admin-stacked-form label {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.admin-form-grid input,
.admin-form-grid select,
.admin-stacked-form input,
.admin-stacked-form select {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-panel);
    color: var(--admin-text);
    font: inherit;
    padding: 8px 10px;
}

.admin-form-grid input:focus,
.admin-form-grid select:focus,
.admin-stacked-form input:focus,
.admin-stacked-form select:focus {
    border-color: var(--admin-accent);
    box-shadow: 0 0 0 2px rgba(157, 124, 71, 0.1);
    outline: none;
}

.admin-form-static {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.admin-form-static a,
.admin-detail-list a {
    color: var(--admin-accent);
    font-weight: 800;
    word-break: break-word;
}

.admin-form-actions {
    grid-column: 1 / -1;
}

.admin-order-lines {
    display: grid;
}

.admin-order-line {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr) minmax(110px, auto);
    gap: 14px;
    border-top: 1px solid var(--admin-border);
    padding: 14px 0;
}

.admin-order-line:first-child {
    border-top: 0;
    padding-top: 0;
}

.admin-order-line:last-child {
    padding-bottom: 0;
}

.admin-order-line-media {
    display: grid;
    width: 74px;
    height: 74px;
    place-items: center;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-order-line-media img {
    max-width: 100%;
    max-height: 70px;
    object-fit: contain;
}

.admin-order-line-content {
    display: grid;
    gap: 4px;
    align-content: start;
}

.admin-order-line-content strong {
    color: var(--admin-text);
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
}

.admin-order-line-content small,
.admin-order-line-total small {
    color: var(--admin-muted);
    font-size: 12px;
}

.admin-order-line-total {
    display: grid;
    gap: 4px;
    align-content: start;
    justify-items: end;
    text-align: right;
}

.admin-order-line-total strong {
    color: var(--admin-text);
    font-size: 14px;
    font-weight: 800;
}

.admin-order-line-total strong span {
    display: block;
    color: var(--admin-muted);
    font-size: 12px;
    font-weight: 700;
    text-decoration: line-through;
}

.admin-total-list,
.admin-detail-list {
    display: grid;
    gap: 0;
    margin: 0;
}

.admin-total-list > div,
.admin-detail-list > div {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) minmax(0, 1.4fr);
    gap: 12px;
    border-top: 1px solid var(--admin-border);
    padding: 10px 0;
}

.admin-total-list > div:first-child,
.admin-detail-list > div:first-child {
    border-top: 0;
    padding-top: 0;
}

.admin-total-list dt,
.admin-detail-list dt {
    color: var(--admin-muted);
    font-size: 12px;
    font-weight: 800;
}

.admin-total-list dd,
.admin-detail-list dd {
    margin: 0;
    color: var(--admin-text);
    font-size: 13px;
    font-weight: 700;
    word-break: break-word;
}

.admin-total-list dd {
    text-align: right;
}

.admin-total-list dd small {
    display: block;
    color: var(--admin-muted);
    font-weight: 600;
}

.admin-total-list .is-total {
    align-items: center;
    border-top-color: var(--admin-border-strong);
    padding-top: 14px;
}

.admin-total-list .is-total dt,
.admin-total-list .is-total dd {
    color: var(--admin-text);
    font-size: 17px;
    font-weight: 900;
}

.admin-comment-text {
    margin: 0;
    color: var(--admin-text);
    line-height: 1.5;
}

.admin-inline-alert {
    display: grid;
    gap: 4px;
    border: 1px solid var(--admin-border);
    border-left: 4px solid var(--admin-accent);
    border-radius: 4px;
    background: var(--admin-surface);
    color: var(--admin-text);
    margin-top: 12px;
    padding: 10px 12px;
}

.admin-inline-alert.is-danger {
    border-left-color: var(--admin-danger);
}

.admin-inline-alert.is-warning {
    border-left-color: var(--admin-accent);
}

.admin-split-forms {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.admin-stacked-form {
    display: grid;
    gap: 10px;
    border: 1px solid var(--admin-border);
    border-radius: 4px;
    background: var(--admin-surface);
    padding: 12px;
}

.admin-stacked-form-compact {
    display: grid;
    gap: 8px;
}

.admin-stacked-form-compact label {
    width: 100%;
}

.admin-stacked-form-compact input,
.admin-stacked-form-compact select {
    width: 100%;
    min-height: 32px;
    padding: 5px 9px;
}

.admin-stacked-form-compact .admin-button {
    width: fit-content;
    min-height: 32px;
    align-self: start;
    font-size: 12px;
    padding: 0 10px;
}

.admin-aside-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.admin-button-danger {
    border-color: var(--admin-danger);
    background: var(--admin-danger);
    color: #ffffff;
}

.admin-button-danger:hover,
.admin-button-danger:focus {
    border-color: #8d1515;
    background: #8d1515;
    color: #ffffff;
}

.admin-address {
    margin: 12px 0 0;
    color: var(--admin-text);
    font-style: normal;
    line-height: 1.5;
}

.admin-address strong {
    display: block;
}

.admin-email-timeline {
    display: grid;
    gap: 10px;
}

.admin-email-timeline article {
    display: grid;
    gap: 4px;
    border-top: 1px solid var(--admin-border);
    padding-top: 10px;
}

.admin-email-timeline article:first-child {
    border-top: 0;
    padding-top: 0;
}

.admin-email-timeline article > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.admin-email-timeline strong {
    color: var(--admin-text);
    font-size: 13px;
}

.admin-email-timeline small,
.admin-email-timeline span {
    color: var(--admin-muted);
    font-size: 12px;
    word-break: break-word;
}

.admin-email-timeline .is-danger {
    color: var(--admin-danger);
}

@media (max-width: 980px) {
    .admin-layout {
        display: block;
    }

    .admin-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        z-index: 40;
        width: min(var(--admin-sidebar-width), calc(100vw - 56px));
        transform: translateX(-100%);
        transition: transform 180ms ease;
    }

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

    .admin-nav {
        min-height: calc(100vh - 72px);
    }

    .admin-sidebar-close {
        display: inline-flex;
        width: 34px;
        height: 34px;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(234, 223, 207, 0.16);
        border-radius: 4px;
        background: rgba(252, 250, 247, 0.08);
        color: #ffffff;
    }

    .admin-sidebar-close span,
    .admin-sidebar-close span::after {
        display: block;
        width: 16px;
        height: 2px;
        border-radius: 2px;
        background: currentColor;
        content: "";
    }

    .admin-sidebar-close span {
        transform: rotate(45deg);
    }

    .admin-sidebar-close span::after {
        transform: rotate(90deg);
    }

    .admin-mobile-scrim {
        position: fixed;
        inset: 0;
        z-index: 30;
        display: block;
        background: rgba(32, 25, 23, 0.38);
        opacity: 0;
        pointer-events: none;
        transition: opacity 180ms ease;
    }

    .admin-mobile-scrim.is-visible {
        opacity: 1;
        pointer-events: auto;
    }

    .admin-menu-button {
        display: inline-flex;
    }

    .admin-topbar {
        padding: 10px 14px;
    }

    .admin-heading h1 {
        font-size: 17px;
    }

    .admin-account-copy {
        display: none;
    }

    .admin-page {
        padding: 16px;
    }

    .admin-workspace.has-settings-sidebar {
        display: block;
    }

    .admin-settings-sidebar {
        position: sticky;
        top: 58px;
        z-index: 10;
        height: auto;
        overflow-x: auto;
        overflow-y: hidden;
        border-right: 0;
        border-bottom: 1px solid var(--admin-border);
        background: rgba(252, 250, 247, 0.96);
        padding: 10px 12px;
        backdrop-filter: blur(14px);
    }

    .admin-settings-sidebar-header {
        display: none;
    }

    .admin-settings-nav {
        display: flex;
        width: max-content;
        max-width: none;
        align-items: center;
        gap: 6px;
    }

    .admin-settings-nav p {
        margin: 0 4px 0 10px;
        white-space: nowrap;
    }

    .admin-settings-nav a {
        min-height: 32px;
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .admin-settings-nav a.is-active {
        box-shadow: inset 0 -3px 0 var(--admin-accent);
    }

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

    .admin-home-grid {
        grid-template-columns: 1fr;
    }

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

    .admin-filter-header,
    .admin-table-heading {
        display: grid;
    }

    .admin-filter-panel {
        gap: 0;
        padding: 0;
    }

    .admin-filter-toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        border-radius: 6px;
        background: var(--admin-panel);
        color: var(--admin-text);
        cursor: pointer;
        padding: 14px 16px;
    }

    .admin-filter-toggle span {
        color: var(--admin-muted);
        font-size: 11px;
        font-weight: 800;
        text-transform: uppercase;
    }

    .admin-filter-toggle strong {
        color: var(--admin-text);
        font-size: 13px;
        font-weight: 800;
    }

    .admin-filter-toggle::after {
        width: 8px;
        height: 8px;
        border-right: 2px solid var(--admin-accent);
        border-bottom: 2px solid var(--admin-accent);
        content: "";
        transform: rotate(45deg);
        transition: transform 160ms ease;
    }

    .admin-filter-body {
        display: none;
        border-top: 1px solid var(--admin-border);
        padding: 16px;
    }

    .admin-filter-toggle-input:checked + .admin-filter-toggle::after {
        transform: rotate(-135deg);
    }

    .admin-filter-toggle-input:checked + .admin-filter-toggle + .admin-filter-body {
        display: grid;
    }

    .admin-filter-actions {
        justify-content: start;
    }

    .admin-table-actionbar {
        justify-content: start;
    }

    .admin-table-tools {
        justify-content: start;
    }

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

    .admin-order-hero {
        display: grid;
        align-items: start;
    }

    .admin-order-status {
        justify-content: start;
    }

    .admin-order-document-panel {
        display: grid;
    }

    .admin-order-document-actions {
        justify-content: start;
    }

    .admin-detail-grid {
        grid-template-columns: 1fr;
    }

    .admin-payment-webhook-grid {
        grid-template-columns: 1fr;
    }

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

    .admin-split-forms {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .admin-topbar {
        gap: 10px;
    }

    .admin-heading p {
        display: none;
    }

    .admin-alert-button {
        display: none;
    }

    .admin-home-hero {
        display: grid;
    }

    .admin-home-meta {
        border-left: 0;
        border-top: 1px solid var(--admin-border);
        padding-left: 0;
        padding-top: 12px;
        text-align: left;
    }

    .admin-settings-hero {
        display: grid;
        padding: 16px;
    }

    .admin-settings-hero h2 {
        font-size: 19px;
    }

    .admin-settings-grid {
        grid-template-columns: 1fr;
    }

    .admin-quick-grid {
        grid-template-columns: 1fr;
    }

    .admin-filter-grid {
        grid-template-columns: 1fr;
    }

    .admin-pagination {
        display: grid;
        justify-content: stretch;
    }

    .admin-pagination > a,
    .admin-pagination > span {
        width: 100%;
    }

    .admin-order-hero h2 {
        font-size: 19px;
    }

    .admin-form-grid,
    .admin-order-line {
        grid-template-columns: 1fr;
    }

    .admin-order-line-media {
        width: 100%;
        height: 96px;
    }

    .admin-order-line-total {
        justify-items: start;
        text-align: left;
    }

    .admin-total-list > div,
    .admin-detail-list > div {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .admin-total-list dd {
        text-align: left;
    }
}
