:root {
    --ink: #0b1f33;
    --navy: #102a43;
    --muted: #667085;
    --line: #e6e8ec;
    --soft: #f6f7f9;
    --paper: #ffffff;
    --gold: #c8a45d;
    --danger: #b42318;

    --ff-bg: #f5f7fb;
    --ff-panel: #ffffff;
    --ff-ink: #0b1f33;
    --ff-muted: #6b7280;
    --ff-soft: #f8fafc;
    --ff-line: #e5e7eb;
    --ff-line-2: #eef0f4;
    --ff-gold: #c8a45d;
    --ff-gold-soft: rgba(200, 164, 93, .12);
    --ff-shadow: 0 24px 70px rgba(15, 23, 42, .08);
    --ff-radius-lg: 28px;
    --ff-radius-md: 18px;
    --ff-radius-sm: 12px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    background: var(--soft);
    color: var(--ink);
}

a {
    color: var(--ink);
}

/* =========================================================
   Public Landing Page
========================================================= */

.landing {
    background:
        radial-gradient(circle at top left, rgba(200,164,93,.18), transparent 30%),
        linear-gradient(180deg, #fff 0%, #f6f7f9 100%);
}

.landing-wrap {
    min-height: 100vh;
    max-width: 880px;
    margin: 0 auto;
    padding: 60px 24px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.brand {
    font-weight: 900;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--ink);
}

.landing-wrap h1 {
    font-size: clamp(42px, 8vw, 78px);
    line-height: .95;
    margin: 22px 0;
    max-width: 780px;
}

.landing-wrap p {
    color: var(--muted);
    font-size: 20px;
    line-height: 1.6;
    max-width: 680px;
}

.landing-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 24px;
}

/* =========================================================
   Buttons
========================================================= */

.btn,
.header-actions a,
.form-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 11px 16px;
    border-radius: 13px;
    text-decoration: none;
    font-weight: 800;
    font-size: 14px;
    border: 1px solid transparent;
    transition: all .18s ease;
}

.btn.primary,
button {
    background: linear-gradient(135deg, var(--ff-ink) 0%, #153a5d 100%);
    color: #fff;
    border: 1px solid rgba(255,255,255,.08);
    box-shadow: 0 14px 30px rgba(11,31,51,.18);
}

.btn.secondary,
.header-actions .btn.secondary,
.form-actions .btn.secondary {
    background: #fff;
    color: var(--ff-ink);
    border-color: var(--ff-line);
    box-shadow: 0 8px 18px rgba(15,23,42,.04);
}

.btn:hover,
.header-actions a:hover,
.form-actions a:hover,
button:hover {
    transform: translateY(-1px);
}

/* =========================================================
   Auth / Login Page
========================================================= */

.auth-page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    background:
        radial-gradient(circle at top left, rgba(200,164,93,.16), transparent 32%),
        linear-gradient(180deg, #ffffff 0%, #f5f7fb 100%);
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: #fff;
    padding: 30px;
    border-radius: 24px;
    border: 1px solid var(--line);
    box-shadow: 0 20px 70px rgba(11,31,51,.1);
}

.auth-card h1 {
    margin: 16px 0 24px;
}

/* =========================================================
   Admin Layout
========================================================= */

body.app-page {
    background:
        radial-gradient(circle at top right, rgba(200, 164, 93, .12), transparent 28%),
        linear-gradient(180deg, #ffffff 0%, var(--ff-bg) 38%, var(--ff-bg) 100%);
    color: var(--ff-ink);
}

.app-page {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    min-height: 100vh;
}

.content {
    padding: 28px 32px;
    max-width: 1440px;
    width: 100%;
}

/* =========================================================
   Clean Compact Sidebar
   Works with includes/admin-sidebar.php using:
   sidebar clean-sidebar
   clean-brand
   clean-nav
   clean-account
========================================================= */

.clean-sidebar {
    width: 220px;
    min-width: 220px;
    height: 100vh;
    position: sticky;
    top: 0;
    padding: 24px 20px;
    background: #071b2b;
    border-right: 1px solid rgba(255,255,255,.08);
    display: flex;
    flex-direction: column;
    box-shadow: none;
}

.clean-brand {
    margin: 0 0 24px;
    padding: 0 0 18px;
    border-bottom: 1px solid rgba(255,255,255,.10);
}

.clean-brand a {
    display: block;
    text-decoration: none;
    color: #fff;
}

.clean-brand strong {
    display: block;
    font-size: 19px;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -.03em;
    color: #fff;
}

.clean-brand span {
    display: block;
    margin-top: 6px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: rgba(255,255,255,.42);
}

.clean-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.clean-nav a {
    display: block;
    position: relative;
    padding: 8px 0 8px 14px;
    margin: 0;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.25;
    letter-spacing: -.01em;
    color: rgba(255,255,255,.58);
    text-decoration: none;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    min-height: unset;
    transition: color .15s ease, padding-left .15s ease;
}

.clean-nav a:hover {
    color: rgba(255,255,255,.90);
    padding-left: 18px;
}

.clean-nav a.active {
    color: #ffffff;
    padding-left: 18px;
}

.clean-nav a.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 5px;
    height: 5px;
    margin-top: -2.5px;
    border-radius: 50%;
    background: var(--gold);
}

.clean-account {
    margin-top: 22px;
    padding-top: 16px;
    border-top: 1px solid rgba(255,255,255,.10);
}

.clean-account strong {
    display: block;
    color: #fff;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.2;
    max-width: 170px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.clean-account span {
    display: block;
    margin-top: 4px;
    color: rgba(255,255,255,.42);
    font-size: 11px;
    text-transform: capitalize;
}

.clean-account a {
    display: inline-block;
    margin-top: 12px;
    color: rgba(255,255,255,.58);
    text-decoration: none;
    font-size: 13px;
    font-weight: 650;
}

.clean-account a:hover {
    color: #fff;
}

/* =========================================================
   Page Header
========================================================= */

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.page-header.premium-header {
    background:
        radial-gradient(circle at 92% 18%, rgba(200,164,93,.18), transparent 26%),
        linear-gradient(135deg, #ffffff 0%, #fbfaf7 44%, #f7f9fc 100%);
    border: 1px solid var(--ff-line);
    border-radius: var(--ff-radius-lg);
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: var(--ff-shadow);
}

.page-header h1,
.page-header.premium-header h1 {
    margin: 0;
    font-size: clamp(30px, 3vw, 42px);
    line-height: 1.05;
    letter-spacing: -.04em;
}

.page-header p,
.page-header.premium-header p {
    color: var(--ff-muted);
    font-size: 15px;
    max-width: 680px;
    line-height: 1.6;
    margin: 8px 0 0;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--ff-gold);
    margin-bottom: 12px;
}

.eyebrow::before {
    content: "";
    width: 28px;
    height: 1px;
    background: var(--ff-gold);
}

.header-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* =========================================================
   Forms
========================================================= */

label {
    display: block;
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 900;
    color: var(--ff-ink);
    letter-spacing: -.01em;
}

input,
select,
textarea {
    width: 100%;
    min-height: 48px;
    padding: 13px 14px;
    border-radius: 15px;
    border: 1px solid var(--ff-line);
    background: #fff;
    color: var(--ff-ink);
    font-size: 15px;
    font-family: inherit;
    outline: none;
    transition: all .16s ease;
}

textarea {
    min-height: 110px;
    resize: vertical;
    line-height: 1.6;
}

input::placeholder,
textarea::placeholder {
    color: #a0a7b3;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--ff-gold);
    box-shadow: 0 0 0 4px var(--ff-gold-soft);
}

small {
    display: block;
    margin-top: 7px;
    color: var(--ff-muted);
    font-size: 12px;
    line-height: 1.45;
}

button {
    width: 100%;
    margin-top: 20px;
    padding: 14px;
    border: 0;
    border-radius: 12px;
    font-weight: 800;
    cursor: pointer;
}

.modern-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
    max-width: 1180px;
}

.form-card,
.form-section {
    position: relative;
    background: rgba(255,255,255,.96);
    border: 1px solid var(--ff-line);
    border-radius: var(--ff-radius-lg);
    padding: 26px;
    box-shadow: 0 18px 50px rgba(15, 23, 42, .045);
    overflow: hidden;
}

.form-section::before {
    content: "";
    position: absolute;
    left: 0;
    top: 24px;
    width: 4px;
    height: 44px;
    border-radius: 0 10px 10px 0;
    background: linear-gradient(180deg, var(--ff-gold), #ead7aa);
}

.form-section:hover {
    border-color: rgba(200,164,93,.34);
}

.compact-section {
    padding: 20px 26px;
}

.section-heading {
    display: grid;
    grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    padding-bottom: 20px;
    margin-bottom: 22px;
    border-bottom: 1px solid var(--ff-line-2);
}

.section-heading h2 {
    margin: 0;
    font-size: 22px;
    letter-spacing: -.02em;
    color: var(--ff-ink);
}

.section-heading p {
    margin: 0;
    color: var(--ff-muted);
    line-height: 1.6;
    font-size: 14px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
    margin-bottom: 18px;
}

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

.form-grid .full {
    grid-column: 1 / -1;
}

.form-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-top: 22px;
}

.form-actions button {
    width: auto;
    min-width: 180px;
}

.checkbox-line {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
    font-weight: 700;
}

.checkbox-line input {
    width: auto;
}

/* Toggle */

.toggle-line {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 0;
    cursor: pointer;
}

.toggle-line input {
    appearance: none;
    width: 46px;
    height: 26px;
    min-height: unset;
    border-radius: 999px;
    background: #d1d5db;
    position: relative;
    padding: 0;
    border: 0;
    flex: 0 0 auto;
}

.toggle-line input::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 3px 8px rgba(0,0,0,.18);
    transition: all .18s ease;
}

.toggle-line input:checked {
    background: linear-gradient(135deg, var(--ff-ink), #1f4f7a);
}

.toggle-line input:checked::after {
    left: 23px;
}

.toggle-line span {
    display: grid;
    gap: 2px;
}

.toggle-line strong {
    color: var(--ff-ink);
    font-size: 15px;
}

.toggle-line small {
    margin: 0;
}

/* Sticky Form Actions */

.sticky-actions {
    position: sticky;
    bottom: 18px;
    z-index: 20;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 14px;
    border: 1px solid rgba(229,231,235,.86);
    border-radius: 22px;
    background: rgba(255,255,255,.82);
    backdrop-filter: blur(18px);
    box-shadow: 0 18px 50px rgba(15, 23, 42, .09);
}

.sticky-actions button {
    width: auto;
    min-width: 178px;
    min-height: 46px;
    margin: 0;
    border-radius: 14px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 900;
}

.sticky-actions .btn.secondary {
    min-width: 130px;
}

/* =========================================================
   Alerts
========================================================= */

.alert,
.success-alert {
    border-radius: 16px;
    padding: 14px 16px;
    margin-bottom: 18px;
    font-weight: 700;
    border: 1px solid transparent;
}

.alert {
    background: #fff1f0;
    color: var(--danger);
    border-color: #ffd6d1;
}

.success-alert {
    background: #ecfdf3;
    color: #027a48;
    border-color: #abefc6;
}

/* =========================================================
   Stats / Tables / Cards
========================================================= */

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

.stat-card,
.table-card,
.mini-card {
    background: #fff;
    border: 1px solid var(--ff-line);
    border-radius: 22px;
    padding: 20px;
    box-shadow: 0 14px 40px rgba(15,23,42,.045);
}

.stat-card span {
    color: var(--ff-muted);
    display: block;
}

.stat-card strong {
    font-size: 36px;
    display: block;
    margin-top: 8px;
}

.table-card {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 14px;
    text-align: left;
    border-bottom: 1px solid var(--ff-line);
    vertical-align: top;
}

th {
    background: var(--ff-soft);
    color: var(--ff-muted);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: 11px;
}

td {
    font-size: 14px;
}

.card-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.mini-card h2 {
    margin: 0 0 8px;
}

.mini-card p {
    color: var(--ff-muted);
    margin: 0 0 16px;
}

.mini-stats {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    color: var(--ff-muted);
    font-size: 13px;
    margin-bottom: 16px;
}

.mini-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.mini-actions a {
    text-decoration: none;
    background: var(--ff-soft);
    padding: 10px 12px;
    border-radius: 10px;
    font-weight: 700;
}

/* =========================================================
   Responsive
========================================================= */

@media (max-width: 1020px) {
    .app-page {
        grid-template-columns: 1fr;
    }

    .clean-sidebar {
        width: 100%;
        min-width: 100%;
        height: auto;
        position: relative;
        padding: 16px 18px;
    }

    .clean-brand {
        margin-bottom: 12px;
        padding-bottom: 12px;
    }

    .clean-nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 14px;
    }

    .clean-nav a {
        padding: 6px 0;
        font-size: 13px;
    }

    .clean-nav a.active {
        padding-left: 12px;
    }

    .clean-account {
        display: none;
    }

    .content {
        padding: 22px;
    }

    .section-heading {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .form-grid,
    .stats-grid,
    .card-list {
        grid-template-columns: 1fr;
    }

    .page-header {
        flex-direction: column;
        gap: 16px;
    }

    .header-actions {
        width: 100%;
    }

    .header-actions .btn {
        flex: 1;
    }
}

@media (max-width: 640px) {
    .content {
        padding: 16px;
    }

    .page-header.premium-header,
    .form-section,
    .form-card {
        border-radius: 22px;
        padding: 20px;
    }

    .sticky-actions {
        flex-direction: column-reverse;
        bottom: 10px;
    }

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