:root {
    --c-bg-deep: #07110d;
    --c-bg-mid: #0a1712;
    --c-bg-soft: #0d1f18;
    --c-surface-1: #121917;
    --c-surface-2: #16221d;
    --c-surface-3: #1b2a23;
    --c-surface-glass: rgba(18, 25, 23, 0.88);
    --c-border: #1f4d3a;
    --c-border-soft: rgba(31, 77, 58, 0.55);
    --c-border-bright: rgba(16, 185, 129, 0.55);
    --c-emerald: #15803d;
    --c-emerald-bright: #10b981;
    --c-lime: #4ade80;
    --c-lime-dim: rgba(74, 222, 128, 0.14);
    --c-silver: #cbd5e1;
    --c-steel: #94a3b8;
    --c-text: #e2e8f0;
    --c-muted: #94a3b8;
    --c-dim: #64748b;
    --c-success: #34d399;
    --c-warning: #fbbf24;
    --c-danger: #f87171;
    --c-info: #38bdf8;

    --sp-1: 0.25rem;
    --sp-2: 0.5rem;
    --sp-3: 0.75rem;
    --sp-4: 1rem;
    --sp-5: 1.25rem;
    --sp-6: 1.5rem;
    --sp-7: 2rem;
    --sp-8: 2.5rem;
    --sp-9: 3rem;
    --sp-10: 4rem;
    --sp-12: 6rem;

    --r-xs: 3px;
    --r-sm: 5px;
    --r-md: 8px;
    --r-lg: 14px;
    --r-pill: 999px;

    --fs-xs: 0.72rem;
    --fs-sm: 0.85rem;
    --fs-md: 0.95rem;
    --fs-lg: 1.15rem;
    --fs-xl: 1.75rem;
    --fs-2xl: 2.5rem;

    --font-body: "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-display: "Rajdhani", "Inter", "Segoe UI", sans-serif;
    --font-mono: "JetBrains Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;

    --header-h: 72px;
    --container: 1280px;
    --sidebar-w: 316px;

    --shadow-panel: 0 18px 45px rgba(0, 0, 0, 0.45), 0 2px 8px rgba(0, 0, 0, 0.3);
    --glow-emerald: 0 0 0 1px rgba(16, 185, 129, 0.18), 0 0 28px rgba(16, 185, 129, 0.18);
    --glow-lime: 0 0 12px rgba(74, 222, 128, 0.65);
    --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
    --clip-armor: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + var(--sp-4));
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    color: var(--c-text);
    background-color: var(--c-bg-deep);
    background-image: linear-gradient(180deg, rgba(3, 8, 6, 0.38) 0%, rgba(3, 10, 7, 0.12) 45%, rgba(3, 8, 6, 0.52) 100%), url("../img/main_background_doom.webp"), linear-gradient(180deg, var(--c-bg-deep) 0%, var(--c-bg-mid) 48%, var(--c-bg-soft) 100%);
    background-repeat: no-repeat;
    background-position: center center, center top, center center;
    background-size: auto, cover, auto;
    background-attachment: fixed;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image: linear-gradient(rgba(148, 163, 184, 0.022) 1px, transparent 1px), linear-gradient(90deg, rgba(148, 163, 184, 0.022) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 25%, #000 10%, transparent 88%);
    mask-image: radial-gradient(ellipse at 50% 25%, #000 10%, transparent 88%);
}

::selection {
    background: rgba(16, 185, 129, 0.35);
    color: #fff;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    color: var(--c-silver);
    letter-spacing: 0.04em;
    line-height: 1.2;
    margin: 0 0 var(--sp-4);
}

h2 {
    font-size: var(--fs-xl);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.11em;
}

h3 {
    font-size: 1.25rem;
    text-transform: uppercase;
    letter-spacing: 0.09em;
}

h4 {
    font-size: 1.05rem;
}

p {
    margin: 0 0 var(--sp-4);
}

a {
    color: var(--c-emerald-bright);
    text-decoration: none;
    transition: color 0.2s var(--ease), text-shadow 0.2s var(--ease);
}

a:hover {
    color: var(--c-lime);
    text-shadow: 0 0 14px rgba(74, 222, 128, 0.35);
}

img {
    max-width: 100%;
}

table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--c-text);
    margin-bottom: var(--sp-5);
}

th,
td {
    padding: 0.78rem 0.9rem;
    border-bottom: 1px solid var(--c-border-soft);
    vertical-align: middle;
    text-align: left;
}

tr,
td,
th {
    vertical-align: middle;
}

.horizontal-table tr,
.vertical-table tr,
.generic-form-table tr,
.horizontal-table td,
.vertical-table td,
.generic-form-table td {
    vertical-align: middle;
}

thead th,
.horizontal-table > tbody > tr:first-child > th,
.vertical-table > tbody > tr:first-child > th,
.woe-table > tbody > tr:first-child > th,
#server_status > tbody > tr:first-child > td {
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.12), rgba(16, 185, 129, 0.04));
    color: var(--c-silver);
    font-family: var(--font-display);
    font-size: var(--fs-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    border-bottom: 1px solid var(--c-border);
    white-space: nowrap;
}

tbody tr:nth-child(even) td,
.horizontal-table tr:nth-child(even) td,
.vertical-table tr:nth-child(even) td,
.woe-table tr:nth-child(even) td {
    background-color: rgba(18, 25, 23, 0.55);
}

tbody tr:hover td,
.horizontal-table tr:hover td,
.vertical-table tr:hover td,
.woe-table tr:hover td,
#server_status tr:hover td {
    background-color: rgba(16, 185, 129, 0.11);
    color: #fff;
}

td[align="right"],
th[align="right"],
.num,
.level,
.zeny,
.balance-amount,
.stat-value,
.pages,
.cost,
.qty {
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.top-ranked td,
.item-drop-mvp td {
    background-color: rgba(74, 222, 128, 0.13) !important;
    color: var(--c-lime) !important;
}

.empty-row {
    display: none;
}

.nowrap {
    white-space: nowrap;
}

.table-scroll {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-color: var(--c-border) rgba(7, 17, 13, 0.5);
    scrollbar-width: thin;
}

.table-scroll > table {
    min-width: max-content;
    margin-bottom: var(--sp-5);
}

.table-scroll::-webkit-scrollbar {
    height: 8px;
}

.table-scroll::-webkit-scrollbar-track {
    background: rgba(7, 17, 13, 0.55);
    border-radius: var(--r-pill);
}

.table-scroll::-webkit-scrollbar-thumb {
    background: var(--c-border);
    border-radius: var(--r-pill);
}

.table-scroll::-webkit-scrollbar-thumb:hover {
    background: var(--c-emerald);
}

.card--page td {
    overflow-wrap: break-word;
}

.horizontal-table td,
.vertical-table td,
.woe-table td,
#server_status td {
    padding: 0.7rem 0.8rem;
    background-color: rgba(18, 25, 23, 0.42);
    color: var(--c-text);
    border: 1px solid var(--c-border-soft);
    font-size: var(--fs-sm);
}

.horizontal-table th,
.vertical-table th,
.woe-table th,
#server_status th {
    padding: 0.7rem 0.8rem;
    background-color: rgba(16, 185, 129, 0.08);
    color: var(--c-silver);
    border: 1px solid var(--c-border);
    font-size: var(--fs-sm);
}

.not-applicable {
    color: var(--c-dim);
}

.td-action {
    color: var(--c-muted);
}

.container {
    width: min(100% - var(--sp-7), var(--container));
    margin-inline: auto;
}

.skip-link {
    position: fixed;
    top: var(--sp-2);
    left: var(--sp-2);
    z-index: 500;
    padding: var(--sp-2) var(--sp-4);
    background: var(--c-emerald);
    color: #fff;
    border-radius: var(--r-sm);
    transform: translateY(-160%);
    transition: transform 0.2s var(--ease);
}

.skip-link:focus {
    transform: translateY(0);
    color: #fff;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    background: rgba(7, 17, 13, 0.82);
    border-bottom: 1px solid var(--c-border);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    backdrop-filter: blur(16px) saturate(140%);
    transition: box-shadow 0.3s var(--ease), background 0.3s var(--ease);
}

.site-header.is-scrolled {
    background: rgba(7, 17, 13, 0.95);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45), 0 1px 0 rgba(74, 222, 128, 0.12);
}

.header-inner {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--sp-5);
    height: 100%;
    width: min(100% - var(--sp-7), var(--container));
    margin-inline: auto;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-3);
    flex: 0 0 auto;
}

.brand__logo {
    height: 42px;
    width: auto;
    display: block;
    filter: drop-shadow(0 0 12px rgba(74, 222, 128, 0.28));
}

.brand__text {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.brand__name {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--c-text);
}

.brand__tag {
    font-size: 0.6rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--c-dim);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
    margin-inline: auto;
    height: 100%;
}

.nav-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-1);
    padding: var(--sp-2) var(--sp-3);
    font-family: var(--font-display);
    font-size: 0.86rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--c-muted);
    white-space: nowrap;
    position: relative;
    transition: color 0.2s var(--ease);
}

.nav-link::after {
    content: "";
    position: absolute;
    left: var(--sp-3);
    right: var(--sp-3);
    bottom: 12px;
    height: 2px;
    background: linear-gradient(90deg, var(--c-emerald-bright), var(--c-lime));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.25s var(--ease);
    box-shadow: 0 0 10px rgba(74, 222, 128, 0.6);
}

.nav-link:hover,
.nav-item.is-active .nav-link {
    color: var(--c-lime);
}

.nav-link:hover::after,
.nav-item.is-active .nav-link::after {
    transform: scaleX(1);
}

.nav-caret {
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    opacity: 0.6;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% - 4px);
    left: 0;
    min-width: 208px;
    padding: var(--sp-2);
    background: rgba(13, 31, 24, 0.98);
    border: 1px solid var(--c-border);
    border-top: 2px solid var(--c-emerald-bright);
    border-radius: 0 0 var(--r-sm) var(--r-sm);
    box-shadow: var(--shadow-panel);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0.2s;
}

.nav-item:hover .dropdown-menu,
.nav-item:focus-within .dropdown-menu,
.nav-item.is-open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu a {
    display: block;
    padding: var(--sp-2) var(--sp-3);
    color: var(--c-muted);
    font-size: var(--fs-sm);
    border-left: 2px solid transparent;
}

.dropdown-menu a:hover {
    color: var(--c-lime);
    background: rgba(16, 185, 129, 0.09);
    border-left-color: var(--c-lime);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    flex: 0 0 auto;
}

.header-status {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    padding: var(--sp-1) var(--sp-3);
    border: 1px solid var(--c-border-soft);
    border-radius: var(--r-pill);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--c-lime);
    white-space: nowrap;
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    padding: 0;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    background: rgba(18, 25, 23, 0.9);
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    cursor: pointer;
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.nav-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--c-silver);
    transition: transform 0.25s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle[aria-expanded="true"] {
    border-color: var(--c-emerald-bright);
    box-shadow: var(--glow-emerald);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.user-menu {
    position: relative;
}

.user-menu__trigger {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    padding: var(--sp-2) var(--sp-3);
    background: rgba(18, 25, 23, 0.9);
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    color: var(--c-text);
    cursor: pointer;
    font-family: var(--font-display);
    font-size: var(--fs-sm);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.user-menu__avatar {
    display: inline-grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border: 1px solid var(--c-emerald-bright);
    border-radius: var(--r-xs);
    color: var(--c-lime);
    font-size: var(--fs-xs);
    background: rgba(16, 185, 129, 0.12);
}

.user-menu__panel {
    position: absolute;
    top: calc(100% + var(--sp-2));
    right: 0;
    width: 232px;
    padding: var(--sp-3);
    background: rgba(13, 31, 24, 0.98);
    border: 1px solid var(--c-border);
    border-top: 2px solid var(--c-emerald-bright);
    border-radius: var(--r-sm);
    box-shadow: var(--shadow-panel);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0.2s;
}

.user-menu:hover .user-menu__panel,
.user-menu:focus-within .user-menu__panel,
.user-menu.is-open .user-menu__panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-menu__balance {
    padding: var(--sp-2) var(--sp-3);
    margin-bottom: var(--sp-2);
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid var(--c-border-soft);
    border-radius: var(--r-xs);
}

.user-menu__balance small {
    display: block;
    color: var(--c-dim);
    font-size: 0.65rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.user-menu__balance strong {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--c-lime);
    font-variant-numeric: tabular-nums;
}

.user-menu__links {
    display: grid;
    gap: 2px;
}

.user-menu__links a {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    padding: var(--sp-2) var(--sp-3);
    color: var(--c-muted);
    font-size: var(--fs-sm);
    border-left: 2px solid transparent;
}

.user-menu__links a:hover {
    background: rgba(16, 185, 129, 0.1);
    border-left-color: var(--c-lime);
}

.user-menu__links a.is-danger {
    color: var(--c-danger);
    border-top: 1px solid var(--c-border-soft);
    margin-top: var(--sp-1);
}

.btn,
button,
input[type="submit"],
input[type="button"],
.submit_button,
.button-action input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    padding: 0.72rem 1.35rem;
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #f8fafc;
    background: linear-gradient(135deg, var(--c-emerald) 0%, var(--c-emerald-bright) 100%);
    border: 1px solid rgba(74, 222, 128, 0.5);
    border-radius: var(--r-sm);
    cursor: pointer;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), filter 0.2s var(--ease), border-color 0.2s var(--ease);
}

.btn:hover,
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
.submit_button:hover {
    color: #fff;
    transform: translateY(-2px);
    filter: brightness(1.12);
    box-shadow: 0 10px 24px rgba(16, 185, 129, 0.3), 0 0 18px rgba(74, 222, 128, 0.2);
}

.btn:active,
button:active,
input[type="submit"]:active {
    transform: translateY(0);
}

.btn--armor {
    border-radius: 0;
    clip-path: var(--clip-armor);
    border: 0;
    background: linear-gradient(135deg, var(--c-emerald) 0%, var(--c-emerald-bright) 55%, #0f766e 100%);
    filter: drop-shadow(0 0 10px rgba(16, 185, 129, 0.18));
}

.btn--ghost {
    color: var(--c-silver);
    background: rgba(18, 25, 23, 0.6);
    border-color: var(--c-border);
}

.btn--ghost:hover {
    color: var(--c-lime);
    border-color: var(--c-emerald-bright);
    background: rgba(16, 185, 129, 0.1);
}

.btn--sm {
    padding: 0.45rem 0.85rem;
    font-size: var(--fs-xs);
}

.btn--block {
    width: 100%;
}

.btn--silver {
    color: var(--c-bg-deep);
    background: linear-gradient(135deg, var(--c-silver), var(--c-steel));
    border-color: var(--c-silver);
    text-shadow: none;
}

.btn--silver:hover {
    color: #000;
    box-shadow: 0 10px 24px rgba(203, 213, 225, 0.22);
}

.hero {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 500px;
    padding: calc(var(--header-h) + var(--sp-9)) var(--sp-5) calc(var(--sp-9) + 44px);
    overflow: hidden;
    border-bottom: 1px solid var(--c-border);
    background-repeat: no-repeat;
    background-position: center center, center center, center center, center center;
    background-size: auto, cover, cover, auto;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(rgba(74, 222, 128, 0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(74, 222, 128, 0.05) 1px, transparent 1px);
    background-size: 58px 58px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000, transparent 72%);
    mask-image: radial-gradient(ellipse at 50% 40%, #000, transparent 72%);
}

.hero__sigil {
    position: absolute;
    top: -22%;
    right: -6%;
    width: min(660px, 88vw);
    aspect-ratio: 1;
    opacity: 0.26;
    pointer-events: none;
    animation: sigil-spin 90s linear infinite;
}

.hero__glow {
    position: absolute;
    bottom: -40%;
    left: 50%;
    width: 70%;
    height: 70%;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(74, 222, 128, 0.16), transparent 65%);
    pointer-events: none;
    animation: aura-pulse 6s ease-in-out infinite;
}

.hero__content {
    position: relative;
    z-index: 2;
    max-width: 860px;
    text-align: center;
}

.hero__eyebrow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-4);
    color: var(--c-silver);
    font-size: var(--fs-xs);
    font-weight: 600;
    letter-spacing: 0.4em;
    text-transform: uppercase;
}

.hero__eyebrow::before,
.hero__eyebrow::after {
    content: "";
    width: 56px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--c-steel));
}

.hero__eyebrow::after {
    transform: scaleX(-1);
}

.hero__title {
    margin: var(--sp-4) 0 var(--sp-3);
    font-size: clamp(2.8rem, 8vw, 5.6rem);
    font-weight: 700;
    line-height: 0.95;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: linear-gradient(180deg, #f1f5f9 0%, var(--c-silver) 42%, var(--c-emerald-bright) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 26px rgba(16, 185, 129, 0.28));
}

.hero__title span {
    background: linear-gradient(180deg, var(--c-lime), var(--c-emerald-bright));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}

.hero__subtitle {
    max-width: 620px;
    margin: 0 auto var(--sp-6);
    color: var(--c-muted);
    font-size: var(--fs-md);
    letter-spacing: 0.04em;
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--sp-3);
}

.hero__note {
    margin-top: var(--sp-5);
    color: var(--c-dim);
    font-size: var(--fs-xs);
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.status-strip {
    position: relative;
    z-index: 5;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    width: min(100% - var(--sp-6), var(--container));
    margin: -30px auto 0;
    background: linear-gradient(180deg, rgba(22, 34, 29, 0.95), rgba(18, 25, 23, 0.95));
    border: 1px solid var(--c-border);
    box-shadow: var(--shadow-panel), inset 0 1px 0 rgba(203, 213, 225, 0.06);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    clip-path: polygon(16px 0, 100% 0, 100% calc(100% - 16px), calc(100% - 16px) 100%, 0 100%, 0 16px);
}

.status-cell {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    padding: var(--sp-4) var(--sp-5);
    border-right: 1px solid var(--c-border-soft);
}

.status-cell:last-child {
    border-right: 0;
}

.status-cell__icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    border: 1px solid var(--c-border);
    border-radius: var(--r-xs);
    background: rgba(16, 185, 129, 0.07);
    color: var(--c-lime);
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
}

.status-cell__label {
    display: block;
    color: var(--c-dim);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.status-cell__value {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    margin-top: 2px;
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--c-text);
    font-variant-numeric: tabular-nums;
}

.status-dot {
    width: 8px;
    height: 8px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--c-lime);
    box-shadow: var(--glow-lime);
    animation: dot-pulse 2s ease-in-out infinite;
}

.status-dot--off {
    background: var(--c-danger);
    box-shadow: 0 0 10px rgba(248, 113, 113, 0.55);
    animation: none;
}

.status-dot--count {
    background: var(--c-emerald-bright);
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.6);
}

.status-cell__value.is-online {
    color: var(--c-lime);
}

.status-cell__value.is-offline {
    color: var(--c-danger);
}

.section {
    padding: var(--sp-9) 0;
}

.section--tight {
    padding: var(--sp-7) 0;
}

.section-head {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--sp-4);
    margin-bottom: var(--sp-6);
    padding-bottom: var(--sp-3);
    border-bottom: 1px solid var(--c-border-soft);
}

.section-head::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 96px;
    height: 2px;
    background: linear-gradient(90deg, var(--c-lime), transparent);
    box-shadow: 0 0 12px rgba(74, 222, 128, 0.5);
}

.section-head h2 {
    margin: 0;
}

.section-head__kicker {
    display: block;
    color: var(--c-emerald-bright);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    margin-bottom: var(--sp-1);
}

.section-head a {
    font-family: var(--font-display);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    white-space: nowrap;
}

.inner-main {
    padding-top: var(--sp-7);
    padding-bottom: var(--sp-9);
}

.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--sidebar-w);
    gap: var(--sp-6);
    align-items: start;
}

.layout__content {
    min-width: 0;
}

.layout__sidebar {
    display: grid;
    gap: var(--sp-4);
    min-width: 0;
}

.card {
    position: relative;
    background: linear-gradient(155deg, var(--c-surface-2), var(--c-surface-1));
    border: 1px solid var(--c-border);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-panel), inset 0 1px 0 rgba(203, 213, 225, 0.04);
    transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease), transform 0.25s var(--ease);
}

.card::before {
    content: "";
    position: absolute;
    top: -1px;
    left: var(--sp-5);
    right: var(--sp-5);
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(203, 213, 225, 0.42), transparent);
    pointer-events: none;
}

.card::after {
    content: "";
    position: absolute;
    top: -1px;
    right: -1px;
    width: 26px;
    height: 26px;
    border-top: 1px solid rgba(203, 213, 225, 0.5);
    border-right: 1px solid rgba(203, 213, 225, 0.5);
    border-radius: 0 var(--r-md) 0 0;
    pointer-events: none;
}

.card:hover {
    border-color: var(--c-border-bright);
    box-shadow: var(--glow-emerald), var(--shadow-panel);
    transform: translateY(-2px);
}

.card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    padding: var(--sp-4) var(--sp-5);
    border-bottom: 1px solid var(--c-border-soft);
}

.card__header h3 {
    margin: 0;
    font-size: 1.05rem;
}

.card__header span {
    color: var(--c-dim);
    font-size: var(--fs-xs);
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.card__body {
    padding: var(--sp-5);
}

.card__body > :last-child {
    margin-bottom: 0;
}

.card__footer {
    padding: var(--sp-3) var(--sp-5);
    border-top: 1px solid var(--c-border-soft);
}

.card--flat:hover {
    transform: none;
    box-shadow: var(--shadow-panel);
}

.card--page {
    padding: var(--sp-6);
}

.card--page > h2:first-child {
    padding-bottom: var(--sp-3);
    border-bottom: 1px solid var(--c-border-soft);
}

.news-grid {
    display: grid;
    gap: var(--sp-4);
}

.news-card {
    display: grid;
    grid-template-columns: 158px minmax(0, 1fr);
    overflow: hidden;
}

.news-card__thumb {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 150px;
    border-right: 1px solid var(--c-border-soft);
    background: radial-gradient(circle at 50% 45%, rgba(74, 222, 128, 0.2), transparent 62%), linear-gradient(145deg, var(--c-surface-3), var(--c-bg-soft));
}

.news-card__thumb::before {
    content: "";
    width: 64px;
    height: 64px;
    background: url("../img/hero-sigil.svg") center / contain no-repeat;
    opacity: 0.65;
    transition: transform 0.5s var(--ease);
}

.news-card:hover .news-card__thumb::before {
    transform: rotate(35deg) scale(1.12);
}

.news-card__body {
    padding: var(--sp-4) var(--sp-5);
    min-width: 0;
}

.news-card__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--sp-2);
    color: var(--c-dim);
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.news-card__meta .tag {
    color: var(--c-lime);
    font-weight: 700;
}

.news-card__title {
    margin: var(--sp-2) 0;
    font-size: 1.2rem;
    color: var(--c-text);
}

.news-card__excerpt {
    color: var(--c-muted);
    font-size: var(--fs-sm);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card__link {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    margin-top: var(--sp-2);
    font-family: var(--font-display);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.empty-state {
    padding: var(--sp-8) var(--sp-5);
    text-align: center;
    color: var(--c-muted);
}

.empty-state strong {
    display: block;
    margin-bottom: var(--sp-2);
    color: var(--c-silver);
    font-family: var(--font-display);
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

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

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

.quick-card {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    padding: var(--sp-4);
    text-decoration: none;
}

.quick-card__icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    flex: 0 0 auto;
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--c-lime);
    background: rgba(16, 185, 129, 0.09);
    border: 1px solid var(--c-border);
    clip-path: var(--clip-armor);
}

.quick-card strong {
    display: block;
    color: var(--c-text);
    font-family: var(--font-display);
    font-size: 0.95rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.quick-card small {
    color: var(--c-dim);
    font-size: var(--fs-xs);
}

.quick-card:hover {
    text-decoration: none;
}

.widget {
    padding: var(--sp-4);
}

.widget__title {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    margin: 0 0 var(--sp-4);
    padding-bottom: var(--sp-2);
    border-bottom: 1px solid var(--c-border-soft);
    color: var(--c-silver);
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.widget__title::before {
    content: "";
    width: 3px;
    height: 16px;
    background: linear-gradient(180deg, var(--c-lime), var(--c-emerald));
    box-shadow: 0 0 10px rgba(74, 222, 128, 0.5);
}

.widget__foot {
    margin-top: var(--sp-3);
    padding-top: var(--sp-3);
    border-top: 1px solid var(--c-border-soft);
    text-align: center;
}

.field {
    display: grid;
    gap: var(--sp-1);
    margin-bottom: var(--sp-3);
}

.field > label,
label {
    display: inline-block;
    color: var(--c-steel);
    font-size: var(--fs-sm);
    font-weight: 600;
    letter-spacing: 0.03em;
    margin-bottom: var(--sp-1);
}

.field__hint {
    color: var(--c-dim);
    font-size: var(--fs-xs);
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="search"],
input[type="file"],
select,
textarea {
    width: 100%;
    max-width: 100%;
    padding: 0.68rem 0.85rem;
    font-family: var(--font-body);
    font-size: var(--fs-sm);
    color: var(--c-text);
    background: linear-gradient(180deg, rgba(7, 17, 13, 0.9), rgba(18, 25, 23, 0.9));
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="search"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--c-emerald-bright);
    background: rgba(9, 20, 15, 0.95);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.14), 0 0 18px rgba(16, 185, 129, 0.18);
}

select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 2.4rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    background-size: 1rem;
}

select option {
    background: var(--c-surface-2);
    color: var(--c-text);
}

input[type="radio"],
input[type="checkbox"] {
    width: auto;
    margin-right: var(--sp-2);
    accent-color: var(--c-emerald-bright);
    cursor: pointer;
}

textarea {
    min-height: 120px;
    resize: vertical;
}

.generic-form {
    padding: 0;
    background: transparent;
    border: 0;
}

.generic-form-table {
    background: transparent;
    margin-top: var(--sp-2);
}

.generic-form-table th,
.generic-form-table td {
    background: transparent !important;
    border-bottom: 0;
    padding: var(--sp-2) var(--sp-2);
    vertical-align: middle;
}

.generic-form-table th {
    width: 26%;
    text-align: right;
    color: var(--c-muted);
    font-family: var(--font-body);
    font-size: var(--fs-sm);
    font-weight: 600;
    letter-spacing: normal;
    text-transform: none;
    white-space: nowrap;
}

.generic-form-table th label {
    color: var(--c-muted);
    font-weight: 600;
    text-transform: none;
}

.generic-form-table tr:hover td {
    background: transparent;
}

.generic-form-table td input[type="text"],
.generic-form-table td input[type="password"],
.generic-form-table td select,
.generic-form-table td textarea {
    max-width: 340px;
}

.generic-form-table td input[type="checkbox"] {
    margin-top: 0;
}

.generic-form-table td p {
    color: var(--c-muted);
    font-size: var(--fs-sm);
}

input[name*="year"],
input[name*="month"],
input[name*="day"],
select[name*="year"],
select[name*="month"],
select[name*="day"],
select[name*="birthdate"] {
    display: inline-block;
    width: auto;
    min-width: 76px;
    margin-right: var(--sp-2);
}

.security-code {
    width: 145px;
    height: auto;
    margin: var(--sp-2) 0;
    text-align: left;
}

.security-code img {
    display: block;
    width: 145px;
    height: 50px;
    object-fit: cover;
    border: 1px solid var(--c-border);
    border-radius: var(--r-xs);
}

.message,
.notice,
.error,
.red,
.green,
.success,
.warning,
.note,
.info-text {
    display: block;
    padding: var(--sp-3) var(--sp-4);
    margin: 0 0 var(--sp-5);
    border: 1px solid;
    border-left-width: 3px;
    border-radius: var(--r-sm);
    font-size: var(--fs-sm);
    font-weight: 500;
    text-shadow: none;
    letter-spacing: normal;
    text-transform: none;
}

.message,
.notice,
.info-text {
    color: #bbf7d0;
    background: rgba(16, 185, 129, 0.09);
    border-color: rgba(16, 185, 129, 0.35);
}

.error,
.red,
.state-banned,
.state-permanently-banned {
    color: #fecaca;
    background: rgba(248, 113, 113, 0.09);
    border-color: rgba(248, 113, 113, 0.4);
}

.green,
.success,
.created {
    color: #a7f3d0;
    background: rgba(52, 211, 153, 0.09);
    border-color: rgba(52, 211, 153, 0.35);
}

.warning,
.state-pending,
.hold-hours {
    color: #fde68a;
    background: rgba(251, 191, 36, 0.09);
    border-color: rgba(251, 191, 36, 0.35);
}

.note {
    color: var(--c-muted);
    background: rgba(148, 163, 184, 0.06);
    border-color: var(--c-border);
    font-style: normal;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    padding: 0.22rem 0.6rem;
    border: 1px solid var(--c-border);
    border-radius: var(--r-pill);
    background: rgba(18, 25, 23, 0.8);
    color: var(--c-muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.badge::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 8px currentColor;
}

.badge--online,
.online,
.up {
    color: var(--c-lime);
    border-color: rgba(74, 222, 128, 0.45);
    background: rgba(74, 222, 128, 0.1);
}

.badge--offline,
.offline,
.down {
    color: var(--c-dim);
    border-color: var(--c-border);
    background: rgba(100, 116, 139, 0.08);
}

.badge--gm {
    color: var(--c-silver);
    border-color: rgba(203, 213, 225, 0.4);
    background: rgba(203, 213, 225, 0.08);
}

.badge--admin {
    color: var(--c-warning);
    border-color: rgba(251, 191, 36, 0.4);
    background: rgba(251, 191, 36, 0.08);
}

.badge--plain::before {
    display: none;
}

.stat-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    padding: var(--sp-2) 0;
    border-bottom: 1px solid var(--c-border-soft);
    font-size: var(--fs-sm);
}

.stat-row:last-child {
    border-bottom: 0;
}

.stat-row span {
    color: var(--c-muted);
}

.stat-row strong {
    color: var(--c-lime);
    font-family: var(--font-mono);
    font-size: var(--fs-sm);
    font-variant-numeric: tabular-nums;
}

.rank-list {
    display: grid;
    gap: var(--sp-2);
}

.rank-item {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    padding: var(--sp-2);
    border: 1px solid transparent;
    border-radius: var(--r-xs);
    transition: background 0.2s var(--ease), border-color 0.2s var(--ease);
}

.rank-item:hover {
    background: rgba(16, 185, 129, 0.07);
    border-color: var(--c-border-soft);
}

.rank-item__pos {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    flex: 0 0 auto;
    border: 1px solid var(--c-border);
    border-radius: var(--r-xs);
    color: var(--c-steel);
    font-family: var(--font-display);
    font-size: var(--fs-xs);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.rank-item:first-child .rank-item__pos {
    color: var(--c-lime);
    border-color: var(--c-emerald-bright);
    background: rgba(74, 222, 128, 0.1);
    box-shadow: 0 0 12px rgba(74, 222, 128, 0.18);
}

.rank-item__name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--c-text);
    font-size: var(--fs-sm);
}

.rank-item__meta {
    color: var(--c-dim);
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-variant-numeric: tabular-nums;
}

.pages {
    margin-top: var(--sp-5);
    padding-top: var(--sp-4);
    border-top: 1px solid var(--c-border-soft);
    color: var(--c-muted);
    text-align: center;
    font-size: var(--fs-sm);
}

.pages a,
.pages .page-num,
.pages .page-prev,
.pages .page-next,
.pages .current-page {
    display: inline-block;
    min-width: 30px;
    padding: 0.3rem 0.6rem;
    margin: 0 2px;
    border: 1px solid var(--c-border);
    border-radius: var(--r-xs);
    color: var(--c-muted);
    text-align: center;
}

.pages a:hover {
    color: var(--c-lime);
    border-color: var(--c-emerald-bright);
    background: rgba(16, 185, 129, 0.1);
}

.pages .current-page {
    color: #07110d;
    background: var(--c-emerald-bright);
    border-color: var(--c-emerald-bright);
    font-weight: 700;
}

#submenu,
#pagemenu {
    color: var(--c-muted);
    font-size: var(--fs-sm);
    padding: var(--sp-2) 0;
    margin-bottom: var(--sp-4);
    border-bottom: 1px solid var(--c-border-soft);
}

#pagemenu {
    border-top: 1px solid var(--c-border-soft);
    border-bottom: 0;
}

#submenu a,
#pagemenu a,
.sub-menu-item,
.page-menu-item {
    color: var(--c-emerald-bright);
    font-size: var(--fs-sm);
    padding: 0 var(--sp-1);
}

.current-sub-menu {
    color: var(--c-lime) !important;
    font-weight: 700;
    text-shadow: 0 0 12px rgba(74, 222, 128, 0.4);
}

.credit-balance {
    float: right;
    display: inline-block;
    padding: var(--sp-2) var(--sp-4);
    margin: 0 0 var(--sp-4);
    color: var(--c-text);
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    font-variant-numeric: tabular-nums;
}

.credit-balance .balance-text {
    color: var(--c-dim);
    font-size: var(--fs-xs);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.credit-balance .balance-amount {
    color: var(--c-lime);
    font-family: var(--font-mono);
    font-weight: 700;
}

.search-form,
.search-form2 {
    display: none;
    margin: 0 0 var(--sp-4);
    padding: var(--sp-4);
    background: rgba(7, 17, 13, 0.5);
    border: 1px solid var(--c-border-soft);
    border-radius: var(--r-sm);
}

.search-form p,
.search-form2 p {
    color: var(--c-muted);
    border-bottom: 1px solid var(--c-border-soft);
    padding-bottom: var(--sp-2);
}

.search-form label,
.search-form2 label {
    color: var(--c-steel);
    font-size: var(--fs-xs);
    font-style: normal;
}

.search-form input[type="text"],
.search-form2 input[type="text"] {
    width: auto;
    max-width: 160px;
    display: inline-block;
}

.search-form input[type="submit"],
.search-form2 input[type="submit"] {
    padding: 0.35rem 0.8rem;
    font-size: var(--fs-xs);
}

#server_status {
    background: transparent;
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
    overflow: hidden;
}

#server_status th.server {
    color: var(--c-silver);
    font-weight: 700;
}

#server_status .status {
    text-align: center;
}

.woe-table,
.shop-table,
.install_table {
    background: transparent;
    border: 1px solid var(--c-border);
    border-radius: var(--r-sm);
}

.woe-table th,
.woe-table td,
.install_table th,
.install_table td {
    border-bottom: 1px solid var(--c-border-soft);
}

.woe-table .time {
    color: var(--c-silver);
    font-style: normal;
    font-variant-numeric: tabular-nums;
}

.character-stats td {
    border: 0;
    text-align: center;
}

.character-stats .stat-name {
    color: var(--c-dim);
}

.character-stats .stat-value {
    color: var(--c-lime);
}

.request,
.fs-path,
.script-line {
    color: var(--c-silver);
    background: rgba(7, 17, 13, 0.7);
    border: 1px solid var(--c-border);
    border-radius: var(--r-xs);
}

.keyword {
    color: var(--c-warning);
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
    align-items: center;
    justify-content: center;
    padding: var(--sp-4);
}

.modal.is-open {
    display: flex;
}

.modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3, 8, 6, 0.82);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.modal__dialog {
    position: relative;
    width: min(100%, 540px);
    max-height: 90vh;
    overflow-y: auto;
    background: linear-gradient(155deg, var(--c-surface-2), var(--c-surface-1));
    border: 1px solid var(--c-border);
    border-top: 2px solid var(--c-emerald-bright);
    border-radius: var(--r-md);
    box-shadow: var(--shadow-panel), var(--glow-emerald);
    animation: modal-in 0.25s var(--ease);
}

.modal__header,
.modal__body,
.modal__footer {
    padding: var(--sp-4) var(--sp-5);
}

.modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--c-border-soft);
}

.modal__header h3 {
    margin: 0;
}

.modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: var(--sp-2);
    border-top: 1px solid var(--c-border-soft);
}

.modal__close {
    padding: var(--sp-1) var(--sp-3);
    background: transparent;
    border: 1px solid var(--c-border);
    color: var(--c-muted);
}

.site-footer {
    padding: var(--sp-8) 0 var(--sp-6);
    border-top: 1px solid var(--c-border);
    background: linear-gradient(180deg, rgba(13, 31, 24, 0.5), var(--c-bg-deep));
}

.footer__grid {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-5);
}

.footer__brand {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
}

.footer__brand img {
    width: 38px;
    opacity: 0.8;
}

.footer__brand strong {
    display: block;
    font-family: var(--font-display);
    font-size: 0.9rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--c-silver);
}

.footer__brand small {
    color: var(--c-dim);
    font-size: var(--fs-xs);
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-4);
}

.footer__links a,
.footer__meta a {
    color: var(--c-muted);
    font-family: var(--font-display);
    font-size: var(--fs-xs);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.footer__links a:hover,
.footer__meta a:hover {
    color: var(--c-lime);
}

.footer__meta {
    width: 100%;
    padding-top: var(--sp-4);
    border-top: 1px solid var(--c-border-soft);
    color: var(--c-dim);
    font-size: var(--fs-xs);
    line-height: 1.8;
}

.footer__meta p {
    margin: 0;
}

.footer__meta select {
    width: auto;
    display: inline-block;
    padding: 0.2rem 1.8rem 0.2rem 0.5rem;
    font-size: var(--fs-xs);
}

.footer__tools {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-4);
    justify-content: flex-end;
    margin-top: var(--sp-2);
}

@keyframes sigil-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes aura-pulse {

    0%,
    100% {
        opacity: 0.5;
        transform: translateX(-50%) scale(1);
    }

    50% {
        opacity: 1;
        transform: translateX(-50%) scale(1.12);
    }
}

@keyframes dot-pulse {

    0%,
    100% {
        box-shadow: 0 0 6px rgba(74, 222, 128, 0.6);
        opacity: 1;
    }

    50% {
        box-shadow: 0 0 16px rgba(74, 222, 128, 0.95);
        opacity: 0.72;
    }
}

@keyframes modal-in {
    from {
        opacity: 0;
        transform: translateY(14px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 1180px) {
    .brand__text {
        display: none;
    }

    .nav-link {
        padding-inline: var(--sp-2);
        font-size: var(--fs-xs);
    }
}

@media (max-width: 1024px) {
    :root {
        --header-h: 64px;
    }

    .header-inner {
        width: min(100% - var(--sp-4), var(--container));
        justify-content: space-between;
    }

    .nav-toggle {
        display: flex;
        order: 3;
    }

    .header-actions {
        order: 2;
        margin-left: auto;
    }

    .header-status {
        display: none;
    }

    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        height: auto;
        max-height: 0;
        margin: 0;
        padding: 0 var(--sp-4);
        overflow: hidden;
        background: rgba(7, 17, 13, 0.98);
        border-bottom: 1px solid var(--c-border);
        box-shadow: var(--shadow-panel);
        transition: max-height 0.3s var(--ease), padding 0.3s var(--ease);
    }

    .main-nav.is-open {
        max-height: 75vh;
        padding-block: var(--sp-2);
        overflow-y: auto;
    }

    .nav-item {
        height: auto;
        display: block;
    }

    .nav-link {
        display: flex;
        width: 100%;
        padding: var(--sp-3);
        font-size: var(--fs-sm);
    }

    .nav-link::after {
        bottom: 6px;
        left: var(--sp-3);
        right: auto;
        width: 24px;
    }

    .dropdown-menu {
        position: static;
        min-width: 0;
        border: 0;
        border-left: 2px solid var(--c-border);
        border-radius: 0;
        box-shadow: none;
        background: rgba(18, 25, 23, 0.6);
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
        margin-left: var(--sp-3);
    }

    .nav-item.is-open .dropdown-menu {
        display: block;
    }

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

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

    .hero {
        min-height: 430px;
        padding-top: calc(var(--header-h) + var(--sp-7));
    }

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

@media (max-width: 720px) {
    :root {
        --sp-9: 2rem;
        --sp-10: 2.5rem;
    }

    .container,
    .header-inner {
        width: min(100% - var(--sp-3), var(--container));
    }

    .brand__logo {
        height: 36px;
    }

    .btn,
    button,
    input[type="submit"] {
        padding: 0.6rem 1rem;
    }

    .status-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: min(100% - var(--sp-3), var(--container));
        margin-top: -20px;
    }

    .status-cell {
        padding: var(--sp-3);
        border-bottom: 1px solid var(--c-border-soft);
    }

    .status-cell:nth-child(2) {
        border-right: 0;
    }

    .status-cell:nth-child(3),
    .status-cell:nth-child(4) {
        border-bottom: 0;
    }

    .section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .news-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .news-card__thumb {
        min-height: 96px;
        border-right: 0;
        border-bottom: 1px solid var(--c-border-soft);
    }

    .news-card__thumb::before {
        width: 46px;
        height: 46px;
    }

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

    .inner-main {
        padding-top: var(--sp-5);
        padding-bottom: var(--sp-7);
    }

    .card--page {
        padding: var(--sp-4);
    }

    .generic-form-table th {
        width: 38%;
        white-space: normal;
    }

    .footer__links {
        gap: var(--sp-3);
    }
}

@media (max-width: 480px) {
    .hero__title {
        font-size: clamp(2.2rem, 12vw, 3rem);
    }

    .hero__actions .btn,
    .hero__actions button {
        width: 100%;
    }

    .status-cell__icon {
        width: 32px;
        height: 32px;
    }

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

    .user-menu__trigger span:first-of-type {
        display: none;
    }

    .user-menu__panel {
        right: -64px;
    }
}

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