/* =========================================================
   TOBWENE PHASE 2
   Authentication + Tobwene Studio
   ========================================================= */


/* =========================================================
   SHARED UI
   ========================================================= */

.inline-form {
    display: inline;
    margin: 0;
}

.profile-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 11px 6px 6px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
    font-size: 0.88rem;
}

.profile-avatar {
    width: 30px;
    height: 30px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: linear-gradient(
        135deg,
        #ff3b30,
        #9c0f0a
    );

    font-weight: 800;
}


/* =========================================================
   TOAST MESSAGES
   ========================================================= */

.toast-stack {
    position: fixed;

    z-index: 100;

    top: 90px;
    right: 22px;

    width: 420px;
    max-width: calc(100vw - 44px);

    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    padding: 13px 16px;

    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 16px;

    background: rgba(19, 21, 27, 0.96);

    box-shadow:
        0 18px 50px rgba(0, 0, 0, 0.36);

    transition:
        opacity 0.35s ease,
        transform 0.35s ease;
}

.toast-success {
    border-color: rgba(52, 211, 153, 0.30);
}

.toast-danger {
    border-color: rgba(248, 113, 113, 0.36);
}

.toast-warning {
    border-color: rgba(251, 191, 36, 0.32);
}

.toast-hide {
    opacity: 0;

    transform: translateY(-12px);

    pointer-events: none;
}


/* =========================================================
   AUTHENTICATION
   ========================================================= */

.auth-shell {
    min-height: 100vh;

    display: flex;

    background: #07080b;
}


/* LEFT SIDE */

.auth-panel {
    width: 42%;

    max-width: 640px;
    min-width: 420px;

    padding: 42px 5vw;

    display: flex;
    flex-direction: column;
    justify-content: center;

    margin: 0 auto;
}


.auth-brand {
    display: flex;
    align-items: center;
    gap: 12px;

    margin-bottom: 70px;
}

.auth-brand > div {
    display: flex;
    flex-direction: column;
}

.auth-brand strong {
    font-size: 1.05rem;
}

.auth-brand small {
    color: #a5a7af;

    font-size: 0.72rem;
}


/* AUTH HEADINGS */

.auth-copy h1 {
    margin: 12px 0 18px;

    font-size: 4rem;

    line-height: 0.94;

    letter-spacing: -0.06em;
}

.auth-copy p {
    max-width: 520px;

    color: #a5a7af;

    line-height: 1.65;
}


/* AUTH FORM */

.auth-form {
    margin-top: 32px;

    display: flex;
    flex-direction: column;
    gap: 16px;
}

.auth-form label {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.auth-form label > span {
    color: #d7d9de;

    font-size: 0.86rem;

    font-weight: 700;
}

.auth-form label small {
    color: #a5a7af;

    font-weight: 500;
}

.auth-form input {
    width: 100%;

    padding: 15px 16px;

    border:
        1px solid rgba(255, 255, 255, 0.09);

    border-radius: 16px;

    outline: none;

    background: #111319;

    color: #ffffff;

    font: inherit;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}

.auth-form input:focus {
    border-color:
        rgba(255, 59, 48, 0.65);

    box-shadow:
        0 0 0 4px
        rgba(255, 59, 48, 0.08);
}

.auth-submit {
    margin-top: 5px;

    border: 0;

    cursor: pointer;

    font-size: 1rem;
}

.auth-switch {
    margin-top: 22px;

    color: #a5a7af;

    font-size: 0.92rem;
}

.auth-switch a {
    color: #ffffff;

    font-weight: 700;
}


/* =========================================================
   AUTH ART SIDE
   ========================================================= */

.auth-art {
    position: relative;

    flex: 1;

    overflow: hidden;

    background:
        radial-gradient(
            circle at 70% 25%,
            rgba(255, 59, 48, 0.28),
            transparent 24%
        ),
        linear-gradient(
            135deg,
            #11141b,
            #08090c 62%
        );
}

.auth-art::after {
    content: "";

    position: absolute;

    top: 0;
    right: 0;
    bottom: 0;
    left: 0;

    background:
        linear-gradient(
            90deg,
            #07080b 0%,
            transparent 35%
        ),
        linear-gradient(
            0deg,
            rgba(7, 8, 11, 0.68),
            transparent 48%
        );
}

.auth-art-glow {
    position: absolute;

    top: 15%;
    right: -100px;

    width: 460px;
    height: 460px;

    border-radius: 50%;

    background:
        rgba(255, 59, 48, 0.08);

    filter: blur(15px);
}

.auth-art-copy {
    position: absolute;

    z-index: 2;

    left: 8%;
    right: 8%;
    bottom: 9%;
}

.auth-art-copy small {
    color: #ff7168;

    font-weight: 800;

    letter-spacing: 0.18em;
}

.auth-art-copy h2 {
    max-width: 760px;

    margin: 12px 0 15px;

    font-size: 4rem;

    line-height: 1;

    letter-spacing: -0.055em;
}

.auth-art-copy p {
    max-width: 560px;

    color: #c5c7cd;

    line-height: 1.6;
}

.auth-art-register {
    background:
        radial-gradient(
            circle at 65% 30%,
            rgba(119, 80, 255, 0.26),
            transparent 26%
        ),
        radial-gradient(
            circle at 80% 70%,
            rgba(255, 59, 48, 0.18),
            transparent 26%
        ),
        linear-gradient(
            135deg,
            #13151d,
            #08090c
        );
}


/* =========================================================
   TOBWENE STUDIO
   ========================================================= */

.studio-body {
    background: #090a0e;
}

.studio-shell {
    min-height: 100vh;

    display: flex;
}


/* =========================================================
   STUDIO SIDEBAR
   ========================================================= */

.studio-sidebar {
    position: sticky;

    top: 0;

    z-index: 80;

    width: 260px;
    min-width: 260px;

    height: 100vh;

    padding: 24px 18px;

    display: flex;
    flex-direction: column;

    background: #0d0f14;

    border-right:
        1px solid rgba(255, 255, 255, 0.09);
}

.studio-brand {
    padding:
        0 8px 24px;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.09);
}

.studio-brand > span:last-child {
    display: flex;
    flex-direction: column;
}

.studio-brand small {
    color: #ff7168;

    font-size: 0.68rem;

    letter-spacing: 0.16em;

    text-transform: uppercase;
}


/* SIDEBAR NAVIGATION */

.studio-nav {
    padding: 24px 0;

    display: flex;
    flex-direction: column;
    gap: 5px;
}

.studio-nav a {
    display: flex;

    align-items: center;

    gap: 12px;

    padding: 12px 13px;

    border-radius: 13px;

    color: #aeb1b9;

    font-size: 0.92rem;
}

.studio-nav a:hover,
.studio-nav a.active {
    background: #171a21;

    color: #ffffff;
}

.studio-nav a.active {
    box-shadow:
        inset 3px 0 0 #ff3b30;
}


/* SIDEBAR FOOTER */

.studio-sidebar-footer {
    margin-top: auto;

    padding: 16px 8px 0;

    display: flex;
    flex-direction: column;

    gap: 8px;

    border-top:
        1px solid rgba(255, 255, 255, 0.09);
}

.studio-sidebar-footer a,
.studio-sidebar-footer button {
    padding: 7px 0;

    border: 0;

    background: none;

    color: #aeb1b9;

    font: inherit;

    text-align: left;

    cursor: pointer;
}


/* =========================================================
   STUDIO MAIN AREA
   ========================================================= */

.studio-main {
    flex: 1;

    min-width: 0;
}


/* TOPBAR */

.studio-topbar {
    position: sticky;

    top: 0;

    z-index: 50;

    height: 72px;

    padding: 0 28px;

    display: flex;

    align-items: center;

    gap: 12px;

    background:
        rgba(9, 10, 14, 0.88);

    border-bottom:
        1px solid rgba(255, 255, 255, 0.09);

    backdrop-filter: blur(16px);
}

.studio-topbar > div {
    display: flex;

    flex-direction: column;
}

.studio-topbar small {
    color: #a5a7af;

    font-size: 0.69rem;

    letter-spacing: 0.12em;

    text-transform: uppercase;
}

.studio-topbar strong {
    font-size: 0.95rem;
}


/* ROLE BADGE */

.role-badge {
    margin-left: auto;

    padding: 7px 10px;

    border:
        1px solid rgba(255, 59, 48, 0.18);

    border-radius: 999px;

    background:
        rgba(255, 59, 48, 0.10);

    color: #ff7168;

    font-size: 0.75rem;

    font-weight: 800;
}


/* MOBILE MENU BUTTON */

.studio-menu {
    display: none;

    width: 40px;
    height: 40px;

    border:
        1px solid rgba(255, 255, 255, 0.09);

    border-radius: 12px;

    background: #161920;

    color: #ffffff;

    cursor: pointer;
}


/* =========================================================
   STUDIO CONTENT
   ========================================================= */

.studio-content {
    width: 100%;

    max-width: 1600px;

    margin: 0 auto;

    padding: 32px;
}

.studio-page-head {
    margin-bottom: 28px;

    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    gap: 20px;
}

.studio-page-head h1 {
    margin: 7px 0 8px;

    font-size: 4rem;

    letter-spacing: -0.055em;
}

.studio-page-head p {
    margin: 0;

    color: #a5a7af;
}


/* =========================================================
   DASHBOARD STATISTICS
   ========================================================= */

.stats-grid {
    display: flex;

    flex-wrap: wrap;

    gap: 14px;

    margin-bottom: 22px;
}

.stat-card {
    flex:
        1 1 180px;

    min-width: 180px;

    padding: 20px;

    display: flex;

    flex-direction: column;

    gap: 7px;

    border:
        1px solid rgba(255, 255, 255, 0.09);

    border-radius: 20px;

    background:
        linear-gradient(
            145deg,
            #12151b,
            #0e1015
        );
}

.stat-card small {
    color: #a5a7af;

    font-size: 0.78rem;
}

.stat-card strong {
    font-size: 2.3rem;

    letter-spacing: -0.05em;
}

.stat-card span {
    color: #898d96;

    font-size: 0.78rem;
}


/* =========================================================
   STUDIO DASHBOARD PANELS
   ========================================================= */

.studio-grid {
    display: flex;

    align-items: flex-start;

    gap: 20px;
}

.studio-grid > .studio-panel:first-child {
    flex:
        1.7 1 0;
}

.studio-grid > .studio-panel:last-child {
    flex:
        0.8 1 300px;

    min-width: 300px;
}

.studio-panel {
    overflow: hidden;

    border:
        1px solid rgba(255, 255, 255, 0.09);

    border-radius: 22px;

    background: #0f1117;
}

.studio-panel-head {
    padding: 20px 22px;

    display: flex;

    align-items: flex-end;

    justify-content: space-between;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.09);
}

.studio-panel-head small {
    color: #ff7168;

    font-size: 0.66rem;

    font-weight: 800;

    letter-spacing: 0.12em;

    text-transform: uppercase;
}

.studio-panel-head h2 {
    margin: 4px 0 0;

    font-size: 1.3rem;
}

.studio-panel-head > a {
    color: #b9bcc5;

    font-size: 0.82rem;
}


/* =========================================================
   STUDIO TABLE
   ========================================================= */

.studio-table-wrap {
    overflow-x: auto;
}

.studio-table {
    width: 100%;

    border-collapse: collapse;
}

.studio-table th,
.studio-table td {
    padding: 15px 18px;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.055);

    font-size: 0.84rem;

    text-align: left;

    white-space: nowrap;
}

.studio-table th {
    color: #868a94;

    font-size: 0.70rem;

    letter-spacing: 0.08em;

    text-transform: uppercase;
}

.studio-table td {
    color: #cfd1d7;
}

.studio-table td:first-child strong {
    color: #ffffff;
}


/* =========================================================
   SMALL BADGES
   ========================================================= */

.mini-badge {
    margin-left: 7px;

    padding: 4px 7px;

    border-radius: 999px;

    background:
        rgba(255, 59, 48, 0.12);

    color: #ff7168;

    font-size: 0.63rem;
}

.status-pill {
    padding: 5px 8px;

    border-radius: 999px;

    background: #171a20;

    font-size: 0.70rem;
}

.status-published {
    background:
        rgba(52, 211, 153, 0.09);

    color: #6ee7b7;
}

.status-draft {
    background:
        rgba(250, 204, 21, 0.08);

    color: #facc15;
}

.status-disabled,
.status-archived {
    color: #a5a7af;
}


/* =========================================================
   EMPTY STATE
   ========================================================= */

.studio-empty {
    padding: 35px 22px;

    display: flex;

    flex-direction: column;

    gap: 6px;

    color: #a5a7af;
}

.studio-empty strong {
    color: #ffffff;
}


/* =========================================================
   CATEGORY ADMIN LIST
   ========================================================= */

.category-admin-list {
    display: flex;

    flex-direction: column;
}

.category-admin-list > div {
    padding: 14px 20px;

    display: flex;

    align-items: center;

    justify-content: space-between;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.055);
}

.category-admin-list > div > span:first-child {
    display: flex;

    flex-direction: column;

    gap: 3px;
}

.category-admin-list small {
    color: #a5a7af;
}

.status-dot {
    width: 9px;
    height: 9px;

    border-radius: 50%;

    background: #545761;
}

.status-dot.active {
    background: #34d399;

    box-shadow:
        0 0 0 5px
        rgba(52, 211, 153, 0.08);
}

.studio-toast {
    top: 88px;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1150px) {

    .studio-grid {
        flex-direction: column;
    }

    .studio-grid > .studio-panel:first-child,
    .studio-grid > .studio-panel:last-child {
        width: 100%;

        flex: none;

        min-width: 0;
    }
}


@media (max-width: 900px) {

    .auth-shell {
        display: block;
    }

    .auth-panel {
        width: 100%;

        max-width: 720px;

        min-width: 0;
    }

    .auth-art {
        display: none;
    }

    .studio-sidebar {
        position: fixed;

        left: -280px;

        width: 260px;
        min-width: 260px;

        transition:
            left 0.25s ease;

        box-shadow:
            25px 0 60px
            rgba(0, 0, 0, 0.45);
    }

    .studio-sidebar.open {
        left: 0;
    }

    .studio-menu {
        display: flex;

        align-items: center;

        justify-content: center;
    }
}


@media (max-width: 700px) {

    .auth-panel {
        padding:
            28px 20px 90px;
    }

    .auth-brand {
        margin-bottom: 48px;
    }

    .auth-copy h1 {
        font-size: 3rem;
    }

    .studio-content {
        padding:
            22px 16px 90px;
    }

    .studio-page-head {
        align-items: flex-start;

        flex-direction: column;
    }

    .studio-page-head h1 {
        font-size: 3rem;
    }

    .studio-topbar {
        padding:
            0 16px;
    }

    .stats-grid {
        gap: 10px;
    }

    .stat-card {
        flex-basis:
            calc(50% - 5px);

        min-width: 0;
    }
}


@media (max-width: 480px) {

    .stat-card {
        padding: 16px;
    }

    .stat-card strong {
        font-size: 1.8rem;
    }

    .profile-chip > span:last-child {
        display: none;
    }

    .toast-stack {
        top: 74px;

        right: 12px;

        max-width:
            calc(100vw - 24px);
    }
}