/* ==========================================================================
   MET MOTION AI STUDIO - RETRO-MODERN PIXEL DESIGN SYSTEM ("JADUL KEKINIAN")
   Theme: Deep Cyber Black & Neon Stabilo Green (#39ff14)
   ========================================================================== */

:root {
    --bg-dark: #070907;
    --bg-card: rgba(13, 19, 13, 0.88);
    --bg-card-hover: rgba(18, 27, 18, 0.95);
    --border-glass: rgba(163, 230, 53, 0.18);
    --border-glass-hover: rgba(163, 230, 53, 0.45);

    --primary: #a3e635;
    --primary-lime: #b4f71e;
    --primary-hover: #bef264;
    --primary-dark: #4d7c0f;
    --primary-gradient: linear-gradient(135deg, #b4f71e 0%, #a3e635 60%, #84cc16 100%);
    --purple-gradient: linear-gradient(135deg, #b4f71e 0%, #22c55e 100%);
    --accent-glow: 0 0 20px rgba(180, 247, 30, 0.35);
    --cyan: #a3e635;
    
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --text-dim: #6b7280;
    --text-heading: #a3e635;

    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;

    --font-pixel: 'Silkscreen', monospace;
    --font-retro: 'Press Start 2P', monospace;
    --font-heading: 'Silkscreen', 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;
    --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Base Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(circle at 15% 15%, rgba(57, 255, 20, 0.08) 0%, transparent 45%),
        radial-gradient(circle at 85% 85%, rgba(0, 255, 136, 0.06) 0%, transparent 45%),
        linear-gradient(rgba(57, 255, 20, 0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(57, 255, 20, 0.015) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 40px 40px, 40px 40px;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 14.5px;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Custom Cyber Green Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: #070907;
}
::-webkit-scrollbar-thumb {
    background: rgba(57, 255, 20, 0.25);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.6);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
    filter: drop-shadow(0 0 6px rgba(57, 255, 20, 0.5));
}

/* Typography & Pixel Utilities ("Jadul Kekinian") */
.font-pixel {
    font-family: var(--font-pixel) !important;
    letter-spacing: 0.5px;
}

.font-retro {
    font-family: var(--font-retro) !important;
    letter-spacing: 0px;
    font-size: 10px;
}

h1, h2, h3, h4, .font-heading {
    font-family: var(--font-pixel);
    letter-spacing: 0.5px;
}

/* Utilities */
.hidden { display: none !important; }
.text-cyan, .text-primary { color: var(--primary) !important; }
.text-warning { color: var(--warning) !important; }
.text-success { color: var(--success) !important; }
.text-danger { color: var(--danger) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-sm { font-size: 13px; }
.text-xs { font-size: 11px; }
.text-2xl { font-size: 24px; }
.text-center { text-align: center; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.d-flex { display: flex; }
.flex-1 { flex: 1; }
.justify-between { justify-content: space-between; }
.align-center { align-items: center; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 14px; }
.mt-4 { margin-top: 20px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 14px; }
.mb-4 { margin-bottom: 20px; }
.p-0 { padding: 0 !important; }
.p-3 { padding: 16px; }
.gap-1 { gap: 6px; }
.gap-2 { gap: 12px; }

.filter-pill {
    padding: 4px 12px;
    font-size: 11px;
    border-radius: var(--radius-full);
    cursor: pointer;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    transition: var(--transition);
}
.filter-pill.active {
    background: rgba(57, 255, 20, 0.15);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.25);
}
.toggle-key-active {
    accent-color: var(--primary);
    transform: scale(1.2);
    cursor: pointer;
}

/* Glass Cards */
.card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    border-color: var(--border-glass-hover);
}

.card-header {
    padding: 16px 22px;
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(57, 255, 20, 0.03);
}

.card-step {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    background: var(--primary);
    color: #070907;
    font-family: var(--font-retro);
    font-weight: 800;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.5);
    flex-shrink: 0;
}

.card-title {
    font-family: var(--font-pixel);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #ffffff;
}

.card-body {
    padding: 22px;
}

/* ==========================================================================
   BRAND LOGO & NAVIGATION CORE
   ========================================================================== */

.brand-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.brand-logo-img {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    object-fit: contain;
    border: 2px solid var(--primary);
    background: #000;
    box-shadow: 0 0 14px rgba(163, 230, 53, 0.35);
    transition: var(--transition);
    flex-shrink: 0;
}

.brand-logo:hover .brand-logo-img {
    transform: scale(1.08) rotate(3deg);
    box-shadow: 0 0 25px rgba(57, 255, 20, 0.75);
}

.logo-text {
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-title {
    font-family: var(--font-pixel);
    font-weight: 700;
    font-size: 16px;
    letter-spacing: 1px;
    color: var(--primary);
    text-shadow: 0 0 12px rgba(57, 255, 20, 0.4);
}

.logo-badge {
    font-family: var(--font-retro);
    font-size: 9px;
    font-weight: 700;
    padding: 2px 7px;
    background: rgba(57, 255, 20, 0.15);
    color: var(--primary);
    border: 1px solid var(--primary);
    border-radius: 4px;
    box-shadow: 0 0 8px rgba(57, 255, 20, 0.25);
    letter-spacing: 0.5px;
}

/* Panel Layout Toggle Button */
.btn-layout-toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    background: rgba(57, 255, 20, 0.08);
    border: 1px solid rgba(57, 255, 20, 0.3);
    color: var(--primary);
    font-family: var(--font-pixel);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-layout-toggle:hover {
    background: rgba(57, 255, 20, 0.22);
    box-shadow: 0 0 14px rgba(57, 255, 20, 0.4);
    color: #fff;
    transform: translateY(-1px);
}

/* Navigation Item */
.nav-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 13.5px;
    transition: var(--transition);
    border: 1px solid transparent;
    text-decoration: none;
}

.nav-item:hover {
    color: #fff;
    background: rgba(57, 255, 20, 0.08);
    border-color: rgba(57, 255, 20, 0.25);
}

.nav-item.active {
    color: var(--primary);
    background: rgba(57, 255, 20, 0.15);
    border-color: rgba(57, 255, 20, 0.45);
    box-shadow: 0 0 14px rgba(57, 255, 20, 0.25);
}

.nav-item i {
    font-size: 15px;
}

.nav-admin {
    color: #f43f5e;
}
.nav-admin:hover, .nav-admin.active {
    color: #fb7185;
    background: rgba(244, 63, 94, 0.12);
    border-color: rgba(244, 63, 94, 0.3);
}

/* User Balance & Profile */
.user-balance-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glass);
    padding: 5px 12px;
    border-radius: var(--radius-full);
}

.balance-label {
    font-size: 12px;
    color: var(--text-muted);
}

.balance-amount {
    font-weight: 700;
    color: var(--primary);
    font-size: 13px;
    text-shadow: 0 0 8px rgba(57, 255, 20, 0.3);
}

.btn-balance-add {
    width: 22px;
    height: 22px;
    border-radius: var(--radius-full);
    background: var(--primary);
    color: #070907;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    transition: var(--transition);
}

.btn-balance-add:hover {
    transform: scale(1.15);
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.6);
}

.user-profile-menu {
    display: flex;
    align-items: center;
    gap: 10px;
}

.username-tag {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 600;
}

.btn-logout {
    color: var(--text-dim);
    font-size: 14px;
    transition: var(--transition);
}

.btn-logout:hover {
    color: var(--danger);
    transform: scale(1.1);
}

/* ==========================================================================
   DESKTOP DUAL NAVIGATION MODES (Panel Kiri vs Panel Atas)
   ========================================================================== */

@media (min-width: 993px) {
    .btn-mobile-toggle,
    .mobile-header-actions,
    .mobile-drawer-header,
    .mobile-nav-backdrop {
        display: none !important;
    }

    /* --- MODE 1: LEFT SIDEBAR (Default / Panel Kiri) --- */
    html.layout-sidebar-left body,
    body.layout-sidebar-left {
        padding-left: 0;
    }

    html.layout-sidebar-left .navbar,
    body.layout-sidebar-left .navbar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 260px;
        height: 100vh;
        background: rgba(8, 12, 8, 0.96);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-right: 1px solid var(--border-glass);
        border-bottom: none;
        z-index: 1000;
        overflow-y: auto;
        overflow-x: hidden;
        padding: 22px 16px;
        box-shadow: 5px 0 25px rgba(0, 0, 0, 0.5);
    }

    html.layout-sidebar-left .nav-container,
    body.layout-sidebar-left .nav-container {
        display: flex;
        flex-direction: column;
        height: 100%;
        width: 100%;
        padding: 0;
        gap: 16px;
        justify-content: flex-start;
        align-items: stretch;
    }

    html.layout-sidebar-left .brand-wrapper,
    body.layout-sidebar-left .brand-wrapper {
        padding-bottom: 16px;
        border-bottom: 1px solid var(--border-glass);
        width: 100%;
    }

    html.layout-sidebar-left .nav-menu-drawer,
    body.layout-sidebar-left .nav-menu-drawer {
        display: flex;
        flex-direction: column;
        flex: 1;
        justify-content: space-between;
        width: 100%;
    }

    html.layout-sidebar-left .nav-links,
    body.layout-sidebar-left .nav-links {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 6px;
    }

    html.layout-sidebar-left .nav-item,
    body.layout-sidebar-left .nav-item {
        width: 100%;
        padding: 10px 14px;
    }

    html.layout-sidebar-left .nav-actions,
    body.layout-sidebar-left .nav-actions {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 12px;
        padding-top: 16px;
        border-top: 1px solid var(--border-glass);
        margin-top: auto;
    }

    html.layout-sidebar-left .user-balance-pill,
    body.layout-sidebar-left .user-balance-pill {
        width: 100%;
        justify-content: space-between;
    }

    html.layout-sidebar-left .user-profile-menu,
    body.layout-sidebar-left .user-profile-menu {
        width: 100%;
        justify-content: space-between;
    }

    html.layout-sidebar-left .btn-layout-toggle,
    body.layout-sidebar-left .btn-layout-toggle {
        width: 100%;
        justify-content: center;
    }

    html.layout-sidebar-left .main-wrapper,
    body.layout-sidebar-left .main-wrapper {
        margin-left: 260px;
        width: calc(100% - 260px);
        max-width: calc(100% - 260px);
        min-height: 100vh;
        padding: 28px 32px;
    }

    html.layout-sidebar-left .app-footer,
    body.layout-sidebar-left .app-footer {
        margin-left: 260px;
        width: calc(100% - 260px);
        max-width: calc(100% - 260px);
    }

    /* --- MODE 2: TOP NAVBAR (Panel Atas) --- */
    html.layout-navbar-top .navbar,
    body.layout-navbar-top .navbar {
        position: sticky;
        top: 0;
        width: 100%;
        background: rgba(8, 12, 8, 0.94);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border-glass);
        border-right: none;
        z-index: 1000;
        padding: 0;
    }

    html.layout-navbar-top .nav-container,
    body.layout-navbar-top .nav-container {
        max-width: 1360px;
        margin: 0 auto;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 12px 24px;
        width: 100%;
    }

    html.layout-navbar-top .brand-wrapper,
    body.layout-navbar-top .brand-wrapper {
        border-bottom: none;
        padding-bottom: 0;
    }

    html.layout-navbar-top .nav-menu-drawer,
    body.layout-navbar-top .nav-menu-drawer {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        flex: 1;
        margin-left: 24px;
    }

    html.layout-navbar-top .nav-links,
    body.layout-navbar-top .nav-links {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }

    html.layout-navbar-top .nav-actions,
    body.layout-navbar-top .nav-actions {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 14px;
        margin-top: 0;
        padding-top: 0;
        border-top: none;
    }

    html.layout-navbar-top .main-wrapper,
    body.layout-navbar-top .main-wrapper {
        margin: 0 auto;
        width: 100%;
        max-width: 1360px;
        padding: 28px 24px;
    }

    html.layout-navbar-top .app-footer,
    body.layout-navbar-top .app-footer {
        margin: 0 auto;
        width: 100%;
    }
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVENESS (max-width: 992px)
   ========================================================================== */

@media (max-width: 992px) {
    .navbar {
        position: sticky;
        top: 0;
        width: 100%;
        height: 62px;
        padding: 0 16px;
        background: rgba(8, 12, 8, 0.97);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border-glass);
        z-index: 1000;
        display: flex;
        align-items: center;
    }

    .nav-container {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 0;
    }

    .brand-wrapper {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
    }

    .mobile-header-actions {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-mini-balance {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 5px 10px;
        background: rgba(57, 255, 20, 0.1);
        border: 1px solid rgba(57, 255, 20, 0.3);
        border-radius: 20px;
        font-size: 12px;
        font-weight: 700;
        color: #fff;
        text-decoration: none;
    }

    .btn-mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 38px;
        height: 38px;
        border-radius: 8px;
        background: rgba(57, 255, 20, 0.12);
        border: 1px solid rgba(57, 255, 20, 0.35);
        color: var(--primary);
        font-size: 18px;
        cursor: pointer;
    }

    .btn-mobile-toggle:hover {
        background: rgba(57, 255, 20, 0.25);
        color: #fff;
    }

    .nav-menu-drawer {
        position: fixed;
        top: 0;
        left: -320px;
        width: 290px;
        height: 100vh;
        background: #080c08;
        border-right: 1px solid var(--border-glass);
        z-index: 2000;
        padding: 20px 16px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.8);
        overflow-y: auto;
    }

    body.mobile-nav-open .nav-menu-drawer {
        left: 0 !important;
    }

    .mobile-nav-backdrop {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 1999;
        display: none;
        opacity: 0;
        transition: opacity 0.25s ease;
    }

    body.mobile-nav-open .mobile-nav-backdrop {
        display: block !important;
        opacity: 1 !important;
    }

    .mobile-drawer-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding-bottom: 14px;
        border-bottom: 1px solid var(--border-glass);
        margin-bottom: 14px;
    }

    .mobile-drawer-logo {
        width: 30px;
        height: 30px;
        object-fit: contain;
    }

    .btn-drawer-close {
        background: none;
        border: none;
        color: #888;
        font-size: 26px;
        cursor: pointer;
        line-height: 1;
    }

    .btn-drawer-close:hover {
        color: #fff;
    }

    .nav-links {
        display: flex;
        flex-direction: column;
        gap: 6px;
        width: 100%;
    }

    .nav-item {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px 14px;
        border-radius: 8px;
        color: var(--text-muted);
        font-size: 14px;
        font-weight: 600;
        width: 100%;
    }

    .nav-item.active {
        color: var(--primary);
        background: rgba(57, 255, 20, 0.15);
        border: 1px solid rgba(57, 255, 20, 0.4);
    }

    .nav-actions {
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding-top: 16px;
        border-top: 1px solid var(--border-glass);
        margin-top: auto;
    }

    .user-balance-pill {
        width: 100%;
        justify-content: space-between;
    }

    .user-profile-menu {
        width: 100%;
        justify-content: space-between;
    }

    .btn-layout-toggle {
        width: 100%;
        justify-content: center;
    }

    .main-wrapper {
        margin: 0 auto !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 16px 12px !important;
    }

    .studio-grid {
        grid-template-columns: 1fr !important;
        gap: 16px;
    }

    .provider-grid {
        grid-template-columns: 1fr !important;
    }

    .pricing-config-grid {
        grid-template-columns: 1fr !important;
    }

    .topup-grid {
        grid-template-columns: 1fr !important;
    }

    .app-footer {
        margin: 0 auto !important;
        width: 100% !important;
        max-width: 100% !important;
    }
}

/* Main Layout Shared */
.main-wrapper {
    flex: 1;
    width: 100%;
    transition: margin 0.3s cubic-bezier(0.16, 1, 0.3, 1), width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.content-container {
    max-width: 1150px;
    margin: 0 auto;
}

.page-title {
    font-family: var(--font-pixel);
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--primary);
    text-shadow: 0 0 14px rgba(57, 255, 20, 0.35);
}

.page-subtitle {
    color: var(--text-muted);
    font-size: 13.5px;
    margin-top: 4px;
}

/* Studio Layout */
.studio-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.studio-header-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.badge-chip {
    padding: 8px 14px;
    border-radius: var(--radius-full);
    font-size: 13px;
    border: 1px solid var(--border-glass);
    background: rgba(255, 255, 255, 0.03);
}

.chip-cost {
    border-color: rgba(57, 255, 20, 0.3);
    background: rgba(57, 255, 20, 0.08);
    color: var(--primary);
}

.chip-patch {
    border-color: rgba(245, 158, 11, 0.3);
    background: rgba(245, 158, 11, 0.08);
    color: var(--warning);
}

.chip-cdn {
    border-color: rgba(16, 185, 129, 0.3);
    background: rgba(16, 185, 129, 0.08);
    color: var(--success);
}

.studio-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 24px;
}

@media (max-width: 960px) {
    .studio-grid {
        grid-template-columns: 1fr;
    }
}

/* Dropzones */
.dropzone {
    border: 2px dashed rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.02);
    min-height: 190px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: var(--transition);
    overflow: hidden;
}

.dropzone:hover, .dropzone.dragover {
    border-color: var(--primary);
    background: rgba(57, 255, 20, 0.04);
}

.file-input-hidden {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 5;
}

.dropzone-placeholder {
    text-align: center;
    padding: 24px;
    pointer-events: none;
}

.dropzone-icon {
    font-size: 38px;
    color: var(--primary);
    margin-bottom: 12px;
    filter: drop-shadow(0 0 10px rgba(57, 255, 20, 0.4));
}

.dropzone-text {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.dropzone-btn {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
}

.dropzone-preview {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    z-index: 10;
}

.preview-media {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.btn-remove-media {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 30px;
    height: 30px;
    border-radius: var(--radius-full);
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 15;
    transition: var(--transition);
}

.btn-remove-media:hover {
    background: var(--danger);
    transform: scale(1.1);
}

.video-meta-badge {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.75);
    border: 1px solid var(--border-glass);
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 11px;
    color: #fff;
    z-index: 15;
}

/* Provider Select Cards */
.provider-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 8px;
}

.provider-card {
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.02);
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    transition: var(--transition);
}

.provider-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

.provider-card.active {
    border-color: var(--primary);
    background: rgba(57, 255, 20, 0.08);
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.15);
}

.provider-card.provider-warning.active {
    border-color: var(--danger);
    background: rgba(239, 68, 68, 0.08);
}

.provider-radio {
    width: 16px;
    height: 16px;
    border-radius: var(--radius-full);
    border: 2px solid var(--text-dim);
    margin-top: 3px;
    position: relative;
    flex-shrink: 0;
}

.provider-card.active .provider-radio {
    border-color: var(--primary);
}

.provider-card.active .provider-radio::after {
    content: '';
    position: absolute;
    inset: 2px;
    border-radius: var(--radius-full);
    background: var(--primary);
}

.provider-title {
    font-weight: 600;
    font-size: 14px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.provider-desc {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
}

.pill-badge {
    font-size: 10px;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: var(--radius-full);
    text-transform: uppercase;
}

.pill-recom {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.pill-fast {
    background: rgba(57, 255, 20, 0.15);
    color: var(--primary);
    border: 1px solid rgba(57, 255, 20, 0.3);
}

.pill-warn {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Model Options Cards */
.model-options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 8px;
}

.model-option-card {
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.02);
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    transition: var(--transition);
}

.model-option-card:hover {
    background: rgba(255, 255, 255, 0.05);
}

.model-option-card.active {
    border-color: var(--primary);
    background: rgba(57, 255, 20, 0.08);
}

.model-option-card.model-locked {
    opacity: 0.42;
    cursor: not-allowed;
    border-color: rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.25);
}

.model-option-card.model-locked:hover {
    background: rgba(0, 0, 0, 0.25);
    border-color: rgba(255, 255, 255, 0.06);
}

.model-option-card input[type="radio"] {
    margin-top: 3px;
    accent-color: var(--primary);
}

.model-name {
    font-weight: 600;
    font-size: 13px;
    color: #fff;
}

.model-cost {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* Forms & Inputs */
.form-group {
    display: flex;
    flex-direction: column;
}

.form-row {
    display: flex;
    gap: 14px;
}

.form-label {
    font-size: 13px;
    font-weight: 600;
    color: #cbd5e1;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.label-hint {
    font-size: 11px;
    font-weight: 400;
    color: var(--text-dim);
}

.form-input, .form-select {
    width: 100%;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    background: rgba(7, 10, 18, 0.6);
    border: 1px solid var(--border-glass);
    color: #fff;
    font-family: var(--font-body);
    font-size: 14px;
    outline: none;
    transition: var(--transition);
}

.form-input:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.2);
}

.input-with-button {
    position: relative;
    display: flex;
    align-items: center;
}

.btn-toggle-eye {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 14px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
    cursor: pointer;
}

.checkbox-label input {
    accent-color: var(--primary);
}

/* Action Button */
.btn-generate-main {
    width: 100%;
    padding: 16px 24px;
    border-radius: var(--radius-md);
    background: var(--primary-gradient);
    border: none;
    color: #070907;
    font-family: var(--font-pixel);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    box-shadow: 0 4px 25px rgba(57, 255, 20, 0.45);
    transition: var(--transition);
}

.btn-generate-main:hover {
    transform: translateY(-2px);
    background: #76ff03;
    color: #000;
    box-shadow: 0 6px 35px rgba(118, 255, 3, 0.7);
}

.btn-generate-main:active {
    transform: translateY(0);
}

.btn-generate-main:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-price-tag {
    background: rgba(0, 0, 0, 0.3);
    color: #070907;
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 11.5px;
    font-weight: 800;
    font-family: var(--font-retro);
}

.cost-disclaimer {
    font-size: 11px;
    color: var(--text-dim);
    text-align: center;
    margin-top: 10px;
}

/* General Buttons ("Jadul Kekinian" Retro-Modern) */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13.5px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: var(--primary);
    color: #070907;
    font-family: var(--font-pixel);
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 0 16px rgba(163, 230, 53, 0.3);
    border: none;
}

.btn-primary:hover {
    background: var(--primary-hover);
    color: #000;
    box-shadow: 0 0 24px rgba(190, 242, 100, 0.55);
    transform: translateY(-1px);
}

.btn-outline {
    background: rgba(57, 255, 20, 0.05);
    border: 1px solid rgba(57, 255, 20, 0.35);
    color: var(--primary);
    font-family: var(--font-pixel);
    font-size: 11.5px;
}

.btn-outline:hover {
    background: rgba(57, 255, 20, 0.18);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 0 14px rgba(57, 255, 20, 0.35);
    transform: translateY(-1px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-glass);
    color: #fff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 11px;
}

.btn-lg {
    padding: 13px 24px;
    font-size: 14px;
}

/* Live Generation Monitor Panel (Inline below generator) */
.generation-monitor {
    position: relative;
    width: 100%;
    margin-top: 16px;
    margin-bottom: 24px;
    scroll-margin-top: 80px;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.monitor-card {
    max-width: 100%;
    width: 100%;
    background: #0c130c;
    border: 1px solid rgba(57, 255, 20, 0.35);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.6), 0 0 25px rgba(57, 255, 20, 0.12);
    padding: 20px 22px;
    border-radius: var(--radius-lg);
}

.queue-chips-bar {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.queue-chip {
    cursor: pointer;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.queue-chip:hover {
    background: rgba(57, 255, 20, 0.1);
    color: #fff;
    border-color: rgba(57, 255, 20, 0.3);
}

.queue-chip.active {
    background: rgba(57, 255, 20, 0.18);
    border-color: var(--primary);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.2);
}

.queue-chip.chip-done {
    border-color: rgba(57, 255, 20, 0.4);
    color: #4ade80;
}

.monitor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.monitor-title-box {
    display: flex;
    align-items: center;
    gap: 14px;
}

.spinner-pulse {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    border: 3px solid rgba(57, 255, 20, 0.2);
    border-top-color: var(--primary);
    animation: spin 0.9s linear infinite;
}

.sm-spinner {
    width: 18px;
    height: 18px;
    border-width: 2px;
    display: inline-block;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.monitor-title {
    font-family: var(--font-heading);
    font-size: 19px;
    color: #fff;
}

.monitor-subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.monitor-percent {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 800;
    color: var(--primary);
}

.progress-bar-track {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-bottom: 24px;
}

.progress-bar-fill {
    height: 100%;
    background: var(--primary-gradient);
    border-radius: var(--radius-full);
    transition: width 0.4s ease;
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.8);
}

.pipeline-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    position: relative;
}

.step-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    z-index: 2;
}

.step-dot {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-glass);
    color: var(--text-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    transition: var(--transition);
}

.step-node.active .step-dot {
    background: var(--primary-gradient);
    color: #070a12;
    border-color: transparent;
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.5);
}

.step-node.completed .step-dot {
    background: var(--success);
    color: #fff;
    border-color: transparent;
}

.step-text {
    font-size: 11px;
    color: var(--text-dim);
}

.step-node.active .step-text {
    color: var(--primary);
    font-weight: 600;
}

.monitor-status-text {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
    min-height: 24px;
}

.monitor-result-box {
    margin-top: 20px;
    animation: fadeIn 0.4s ease;
}

.result-player-container {
    width: 100%;
    max-height: 320px;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #000;
    margin-bottom: 16px;
}

.result-video {
    width: 100%;
    max-height: 320px;
    object-fit: contain;
}

.result-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Flash Alerts */
.flash-container {
    margin-bottom: 20px;
}

.alert {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    font-size: 14px;
}

.alert-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-success {
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #a7f3d0;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #fde68a;
}

.alert-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 20px;
    cursor: pointer;
}

/* History Cards */
.history-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.history-card {
    display: flex;
    flex-direction: column;
}

.history-media-preview {
    height: 200px;
    background: #000;
    position: relative;
    overflow: hidden;
}

.history-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.history-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.history-status-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 3px 8px;
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 700;
}

.badge-completed { background: rgba(16, 185, 129, 0.8); color: #fff; }
.badge-processing { background: rgba(57, 255, 20, 0.8); color: #070a12; }
.badge-failed { background: rgba(239, 68, 68, 0.8); color: #fff; }
.badge-pending { background: rgba(245, 158, 11, 0.8); color: #070a12; }

.history-details {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.history-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.btn-card-delete {
    background: none;
    border: none;
    color: rgba(239, 68, 68, 0.6);
    cursor: pointer;
    padding: 3px 6px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    transition: var(--transition);
}

.btn-card-delete:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.15);
}

.history-info-row {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.badge-tag {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    font-size: 11px;
}

.history-actions {
    display: flex;
    gap: 6px;
    margin-top: auto;
}

/* Topup Cards & Table */
.topup-grid, .settings-grid, .admin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

@media (max-width: 860px) {
    .topup-grid, .settings-grid, .admin-grid {
        grid-template-columns: 1fr;
    }
}

.balance-summary-card {
    background: linear-gradient(135deg, rgba(57, 255, 20, 0.12) 0%, rgba(121, 40, 202, 0.12) 100%);
    border: 1px solid rgba(57, 255, 20, 0.3);
}

.balance-card-inner {
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.balance-card-label {
    font-size: 13px;
    color: var(--text-muted);
}

.balance-card-val {
    font-family: var(--font-pixel);
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
    text-shadow: 0 0 16px rgba(57, 255, 20, 0.45);
    margin: 4px 0;
    letter-spacing: 0.5px;
}

.balance-card-sub {
    font-size: 12px;
    color: var(--text-dim);
}

.balance-card-icon {
    font-size: 44px;
    color: var(--primary);
    filter: drop-shadow(0 0 12px rgba(57, 255, 20, 0.5));
}

.nominal-preset-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.btn-nominal {
    padding: 12px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    color: #fff;
    font-weight: 700;
    font-size: 12.5px;
    font-family: var(--font-pixel);
    cursor: pointer;
    transition: var(--transition);
}

.btn-nominal:hover, .btn-nominal.active {
    border-color: var(--primary);
    background: rgba(57, 255, 20, 0.15);
    color: var(--primary);
    box-shadow: 0 0 14px rgba(57, 255, 20, 0.35);
}

.qris-display-box {
    background: rgba(7, 10, 18, 0.8);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 20px;
}

.qris-header {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    margin-bottom: 14px;
}

.qris-qr-wrapper {
    display: flex;
    justify-content: center;
    background: #fff;
    padding: 16px;
    border-radius: var(--radius-md);
    max-width: 250px;
    margin: 0 auto;
}

.qris-image {
    max-width: 100%;
    height: auto;
}

.qris-amount-display {
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

/* Tables */
.table-responsive {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    background: rgba(255, 255, 255, 0.02);
    padding: 12px 16px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-glass);
}

td {
    padding: 14px 16px;
    font-size: 13px;
    border-bottom: 1px solid var(--border-glass);
}

tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.table-rumus td {
    padding: 12px 14px;
}

.rumus-val {
    font-size: 13px;
}

.rumus-sub {
    font-size: 11px;
    color: var(--text-muted);
}

.badge-accent {
    background: rgba(57, 255, 20, 0.15);
    color: var(--primary);
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 11px;
}

.tx-badge {
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 700;
}

.tx-topup, .tx-bonus { background: rgba(16, 185, 129, 0.2); color: var(--success); }
.tx-deduct { background: rgba(239, 68, 68, 0.2); color: var(--danger); }
.tx-refund { background: rgba(245, 158, 11, 0.2); color: var(--warning); }

.role-badge {
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-size: 10px;
    font-weight: 700;
}

.role-admin { background: rgba(236, 72, 153, 0.2); color: #f472b6; }
.role-user { background: rgba(255, 255, 255, 0.1); color: #cbd5e1; }

.credit-action-btns {
    display: flex;
    gap: 6px;
}

/* Stats */
.stats-row {
    display: flex;
    gap: 16px;
}

.stat-card {
    flex: 1;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    padding: 16px;
    border-radius: var(--radius-md);
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 32px;
    font-weight: 800;
}

.stat-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.info-note {
    display: flex;
    gap: 12px;
    background: rgba(57, 255, 20, 0.05);
    border: 1px solid rgba(57, 255, 20, 0.15);
    padding: 14px;
    border-radius: var(--radius-md);
}

/* ============================================================================
   AUTH PAGES - FULLSCREEN IMMERSIVE CYBER EXPERIENCE
   ============================================================================ */

/* Auth Page Container - Fullscreen with animated background */
.auth-page-body {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 20px;
}

/* Animated Grid Background */
.auth-page-body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        linear-gradient(rgba(57, 255, 20, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(57, 255, 20, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: authGridMove 20s linear infinite;
    z-index: 0;
}

@keyframes authGridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* CRT Scanline Overlay */
.auth-page-body::after {
    content: '';
    position: fixed;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.08) 2px,
        rgba(0, 0, 0, 0.08) 4px
    );
    pointer-events: none;
    z-index: 1;
    animation: crtFlicker 0.08s steps(2) infinite;
}

@keyframes crtFlicker {
    0% { opacity: 0.85; }
    50% { opacity: 0.92; }
    100% { opacity: 0.85; }
}

/* Cyber Particle Canvas */
.auth-particles-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

/* Auth Floating Orbs */
.auth-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    animation: orbFloat 8s ease-in-out infinite;
    z-index: 0;
}

.auth-orb-1 {
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(57, 255, 20, 0.4), transparent 70%);
    top: 10%; left: 5%;
    animation-delay: 0s;
}

.auth-orb-2 {
    width: 200px; height: 200px;
    background: radial-gradient(circle, rgba(0, 255, 136, 0.3), transparent 70%);
    bottom: 15%; right: 10%;
    animation-delay: -3s;
}

.auth-orb-3 {
    width: 150px; height: 150px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.35), transparent 70%);
    top: 60%; left: 60%;
    animation-delay: -5s;
}

@keyframes orbFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(20px, -30px) scale(1.05); }
    50% { transform: translate(-10px, 20px) scale(0.95); }
    75% { transform: translate(15px, 10px) scale(1.02); }
}

/* Auth Wrapper */
.auth-wrapper {
    max-width: 460px;
    width: 100%;
    z-index: 10;
    position: relative;
    animation: authCardEntrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes authCardEntrance {
    0% { opacity: 0; transform: translateY(40px) scale(0.95); filter: blur(10px); }
    100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

/* Auth Card - Glassmorphic with Neon Border */
.auth-card {
    background: rgba(10, 15, 10, 0.85) !important;
    backdrop-filter: blur(20px) saturate(1.2);
    -webkit-backdrop-filter: blur(20px) saturate(1.2);
    border: 1px solid rgba(57, 255, 20, 0.2) !important;
    border-radius: var(--radius-lg) !important;
    padding: 40px 36px !important;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 0 40px rgba(57, 255, 20, 0.08),
        0 20px 60px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(57, 255, 20, 0.1);
    transition: border-color 0.4s ease, box-shadow 0.4s ease;
}

.auth-card:hover {
    border-color: rgba(57, 255, 20, 0.35) !important;
    box-shadow:
        0 0 60px rgba(57, 255, 20, 0.12),
        0 20px 60px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(57, 255, 20, 0.15);
}

/* Animated neon border glow sweep */
.auth-card::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: inherit;
    background: conic-gradient(
        from 0deg,
        transparent 0%,
        rgba(57, 255, 20, 0.4) 10%,
        transparent 20%,
        transparent 100%
    );
    animation: authBorderSweep 4s linear infinite;
    z-index: -1;
    opacity: 0.6;
}

@keyframes authBorderSweep {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Inner glow effect at top */
.auth-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(57, 255, 20, 0.5), transparent);
}

/* Auth Logo */
.auth-logo-img-box {
    position: relative;
    display: inline-block;
}

.auth-logo-img-box img {
    animation: authLogoPulse 3s ease-in-out infinite;
}

@keyframes authLogoPulse {
    0%, 100% { box-shadow: 0 0 20px rgba(57, 255, 20, 0.45); }
    50% { box-shadow: 0 0 35px rgba(57, 255, 20, 0.7), 0 0 60px rgba(57, 255, 20, 0.2); }
}

.auth-logo-icon {
    width: 54px;
    height: 54px;
    border-radius: var(--radius-md);
    background: var(--primary-gradient);
    color: #070a12;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    box-shadow: var(--accent-glow);
}

/* Auth Title with text shadow glow */
.auth-title {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    text-shadow: 0 0 20px rgba(57, 255, 20, 0.3);
}

.auth-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 6px;
    line-height: 1.5;
}

/* Auth Form Enhanced Inputs */
.auth-form .form-input {
    background: rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(57, 255, 20, 0.15) !important;
    transition: all 0.3s ease;
}

.auth-form .form-input:focus {
    border-color: rgba(57, 255, 20, 0.5) !important;
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.15), 0 0 30px rgba(57, 255, 20, 0.05) !important;
    background: rgba(0, 0, 0, 0.6) !important;
}

/* Auth Submit Button Glow */
.auth-form .btn-primary {
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.auth-form .btn-primary::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.08) 50%, transparent 60%);
    animation: authBtnShine 3s ease-in-out infinite;
}

@keyframes authBtnShine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

/* Auth Footer Links */
.auth-footer a {
    position: relative;
}

.auth-footer a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.auth-footer a:hover::after {
    width: 100%;
}

/* Auth Terminal Decoration */
.auth-terminal-line {
    font-family: var(--font-retro);
    font-size: 8px;
    color: rgba(57, 255, 20, 0.3);
    text-align: center;
    margin-top: 20px;
    letter-spacing: 2px;
    animation: authTerminalBlink 2s steps(2) infinite;
}

@keyframes authTerminalBlink {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

/* ============================================================================
   APP FOOTER - PREMIUM BRANDING
   ============================================================================ */
.app-footer {
    border-top: 1px solid rgba(57, 255, 20, 0.12);
    padding: 32px 0 20px;
    margin-top: auto;
    font-size: 12px;
    color: var(--text-dim);
    position: relative;
    overflow: hidden;
}

/* Animated top border gradient */
.app-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(57, 255, 20, 0.5) 50%, transparent 100%);
    animation: footerBorderGlow 3s ease-in-out infinite;
}

@keyframes footerBorderGlow {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Footer Grid Layout */
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 30px;
    margin-bottom: 24px;
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}

/* Footer Brand Section */
.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-brand-logo img {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid rgba(163, 230, 53, 0.35);
}

.footer-brand-logo .footer-logo-text {
    font-family: var(--font-pixel);
    font-size: 14px;
    color: var(--primary);
    font-weight: 700;
}

.footer-brand-desc {
    font-size: 12px;
    color: var(--text-dim);
    line-height: 1.6;
    max-width: 280px;
}

/* Footer Column */
.footer-col-title {
    font-family: var(--font-pixel);
    font-size: 11px;
    color: var(--primary);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-links li a {
    font-size: 12px;
    color: var(--text-dim);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.footer-links li a:hover {
    color: var(--primary);
    filter: none;
    transform: translateX(4px);
}

.footer-links li a i {
    font-size: 12px;
    width: 16px;
    text-align: center;
}

/* Footer Social Icons */
.footer-social {
    display: flex;
    gap: 10px;
    margin-top: 8px;
}

.footer-social a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(57, 255, 20, 0.06);
    border: 1px solid rgba(57, 255, 20, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--text-dim);
    transition: var(--transition);
}

.footer-social a:hover {
    background: rgba(57, 255, 20, 0.15);
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(57, 255, 20, 0.2);
    filter: none;
}

/* Footer Bottom Bar */
.footer-bottom {
    border-top: 1px solid rgba(57, 255, 20, 0.08);
    padding-top: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.footer-bottom p {
    font-size: 11px;
    color: var(--text-dim);
    margin: 0;
}

.footer-engine-badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.footer-engine-badge {
    font-family: var(--font-retro);
    font-size: 7px;
    padding: 3px 8px;
    border-radius: var(--radius-full);
    background: rgba(57, 255, 20, 0.06);
    border: 1px solid rgba(57, 255, 20, 0.15);
    color: rgba(57, 255, 20, 0.5);
    letter-spacing: 0.5px;
}

/* Mode Switcher Grid (Kredit vs BYOK) */
.mode-switcher-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

@media (max-width: 640px) {
    .mode-switcher-grid {
        grid-template-columns: 1fr;
    }
}

.mode-tab-card {
    background: rgba(18, 24, 38, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    position: relative;
}

.mode-tab-card:hover {
    border-color: rgba(57, 255, 20, 0.4);
    background: rgba(22, 30, 48, 0.85);
}

.mode-tab-card.active {
    border-color: var(--cyan);
    background: linear-gradient(135deg, rgba(57, 255, 20, 0.12) 0%, rgba(18, 24, 38, 0.9) 100%);
    box-shadow: 0 0 20px rgba(57, 255, 20, 0.15);
}

.mode-tab-radio {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    margin-top: 2px;
    flex-shrink: 0;
    position: relative;
    transition: all 0.2s ease;
}

.mode-tab-card.active .mode-tab-radio {
    border-color: var(--cyan);
}

.mode-tab-card.active .mode-tab-radio::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cyan);
}

.mode-tab-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-bright);
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.mode-tab-desc {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
    line-height: 1.4;
}

.border-dashed-box {
    border: 1px dashed rgba(255, 255, 255, 0.15);
    background: rgba(10, 14, 23, 0.4);
    border-radius: var(--radius-md);
}

/* Switch Toggle */
.switch-toggle {
    position: relative;
    display: inline-block;
    width: 36px;
    height: 20px;
}

.switch-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-toggle .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.2);
    transition: .3s;
    border-radius: 20px;
}

.switch-toggle .slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

.switch-toggle input:checked + .slider {
    background-color: var(--cyan);
}

.switch-toggle input:checked + .slider:before {
    transform: translateX(16px);
}

/* Video Input Tab Toggle */
.video-input-toggle {
    display: inline-flex;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-full);
    padding: 3px;
    gap: 3px;
}

.btn-toggle-sub {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-toggle-sub:hover {
    color: #fff;
}

.btn-toggle-sub.active {
    background: var(--primary);
    color: #000;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.4);
}

/* Video Link Card */
.video-link-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.video-link-input-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
}

.video-link-input {
    flex: 1;
    background: rgba(10, 14, 23, 0.6);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    color: #fff;
    font-size: 13px;
    outline: none;
    transition: var(--transition);
}

.video-link-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.25);
}

.btn-fetch-link {
    white-space: nowrap;
    padding: 10px 18px;
    font-size: 13px;
    font-weight: 600;
}

.link-support-hints {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 11px;
    color: var(--text-muted);
}

.link-support-hints span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.04);
    padding: 3px 9px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* Engine Patch Durations Grid (Admin) */
.patch-engines-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.patch-engine-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    transition: var(--transition);
}

.patch-engine-card:hover {
    border-color: rgba(57, 255, 20, 0.4);
    background: rgba(57, 255, 20, 0.02);
}

.patch-engine-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.patch-engine-name {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
}

.patch-engine-badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    background: rgba(57, 255, 20, 0.12);
    color: var(--primary);
}

.patch-engine-input-box {
    display: flex;
    align-items: center;
    gap: 8px;
}

.patch-engine-input {
    width: 100%;
    background: rgba(10, 14, 23, 0.6);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

/* Announcement Banner (Running Text Marquee / News Ticker) */
.announcement-banner {
    margin-bottom: 20px;
    padding: 8px 16px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    border: 1px solid transparent;
    overflow: hidden;
}

.announcement-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.45);
    padding: 4px 12px;
    border-radius: var(--radius-full);
    flex-shrink: 0;
    z-index: 2;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #fff;
}

.banner-icon {
    font-size: 13px;
    flex-shrink: 0;
}

.marquee-track {
    flex: 1;
    overflow: hidden;
    position: relative;
    white-space: nowrap;
    mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
}

.marquee-content {
    display: inline-block;
    white-space: nowrap;
    animation: marqueeScroll 24s linear infinite;
    font-size: 13.5px;
    font-weight: 500;
    color: #fff;
}

.marquee-track:hover .marquee-content {
    animation-play-state: paused;
}

.marquee-spacer {
    display: inline-block;
    margin: 0 28px;
    color: var(--primary);
    opacity: 0.7;
}

@keyframes marqueeScroll {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-50%); }
}


.banner-info {
    background: rgba(57, 255, 20, 0.08);
    border-color: rgba(57, 255, 20, 0.3);
    box-shadow: 0 0 15px rgba(57, 255, 20, 0.1);
}

.banner-warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.35);
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.1);
}

.banner-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.35);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.12);
}

.banner-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.35);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.1);
}

/* Promo Banner on Topup */
.promo-banner {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.12) 0%, rgba(236, 72, 153, 0.12) 100%);
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    box-shadow: 0 0 25px rgba(245, 158, 11, 0.15);
}

.promo-badge-tag {
    background: linear-gradient(135deg, #f59e0b, #ec4899);
    color: #000;
    font-weight: 800;
    font-size: 11px;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Disabled & Maintenance Engine States */
.provider-card.provider-maintenance {
    opacity: 0.55;
    filter: grayscale(0.5);
    position: relative;
    cursor: not-allowed !important;
    border-color: rgba(239, 68, 68, 0.3) !important;
}

.provider-card.provider-maintenance:hover {
    background: rgba(239, 68, 68, 0.05) !important;
    transform: none !important;
}

.pill-danger {
    background: rgba(239, 68, 68, 0.2);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Pricing Settings Grid in Admin */
.pricing-config-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.pricing-config-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    transition: var(--transition);
}

.pricing-config-card:hover {
    border-color: rgba(57, 255, 20, 0.3);
    background: rgba(57, 255, 20, 0.02);
}

.pricing-config-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.pricing-config-title {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
}

/* Bulk Table Controls */
.table-bulk-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.table-chk {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--primary);
}

/* Toast Notifications Container & Items */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast-item {
    pointer-events: auto;
    min-width: 320px;
    max-width: 440px;
    background: rgba(10, 16, 10, 0.96);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(57, 255, 20, 0.35);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    color: #fff;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6), 0 0 15px rgba(57, 255, 20, 0.15);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transition: all 0.3s ease;
}

.toast-item.toast-success {
    border-color: rgba(74, 222, 128, 0.5);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6), 0 0 15px rgba(74, 222, 128, 0.25);
}

.toast-item.toast-danger {
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6), 0 0 15px rgba(239, 68, 68, 0.25);
}

.toast-icon {
    font-size: 20px;
    margin-top: 2px;
}

.toast-item.toast-success .toast-icon {
    color: #4ade80;
}

.toast-item.toast-danger .toast-icon {
    color: #f87171;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 700;
    font-size: 13.5px;
    margin-bottom: 2px;
    color: #fff;
}

.toast-message {
    font-size: 12px;
    color: #cbd5e1;
    line-height: 1.4;
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ==========================================================================
   AI Character Studio & Image Generator
   ========================================================================== */

/* Shortcut button in Index dropzone */
.btn-create-char-shortcut {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11.5px;
    font-weight: 600;
    color: #f472b6;
    background: rgba(236, 72, 153, 0.12);
    border: 1px solid rgba(236, 72, 153, 0.3);
    padding: 3px 10px;
    border-radius: var(--radius-full);
    text-decoration: none;
    transition: var(--transition);
}

.btn-create-char-shortcut:hover {
    background: rgba(236, 72, 153, 0.22);
    border-color: rgba(236, 72, 153, 0.5);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 0 10px rgba(236, 72, 153, 0.3);
}

/* Image Model Selector */
.image-model-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 6px;
}

.image-model-card {
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.02);
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    transition: var(--transition);
}

.image-model-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.25);
}

.image-model-card.active {
    border-color: #ec4899;
    background: rgba(236, 72, 153, 0.08);
    box-shadow: 0 0 15px rgba(236, 72, 153, 0.15);
}

.image-model-radio {
    width: 18px;
    height: 18px;
    border-radius: var(--radius-full);
    border: 2px solid var(--text-dim);
    margin-top: 2px;
    position: relative;
    flex-shrink: 0;
    transition: var(--transition);
}

.image-model-card.active .image-model-radio {
    border-color: #ec4899;
}

.image-model-card.active .image-model-radio::after {
    content: '';
    position: absolute;
    inset: 3px;
    border-radius: var(--radius-full);
    background: #ec4899;
}

.image-model-info {
    flex: 1;
}

.image-model-title {
    font-weight: 700;
    font-size: 13.5px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.image-model-desc {
    font-size: 11.5px;
    color: var(--text-muted);
    margin-top: 3px;
    line-height: 1.4;
}

/* Aspect Ratio Selector Chips */
.ratio-chips-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 6px;
}

@media (max-width: 600px) {
    .ratio-chips-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.ratio-chip {
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: var(--transition);
}

.ratio-chip:hover {
    background: rgba(255, 255, 255, 0.07);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.ratio-chip.active {
    background: rgba(57, 255, 20, 0.12);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.2);
}

/* Prompt Inspiration Chips */
.prompt-chips-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.prompt-chip {
    font-size: 11px;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    cursor: pointer;
    transition: var(--transition);
}

.prompt-chip:hover {
    background: rgba(236, 72, 153, 0.15);
    border-color: rgba(236, 72, 153, 0.4);
    color: #fff;
    transform: translateY(-1px);
}

/* API Key / Credit Source Banner */
.api-key-source-box {
    background: rgba(7, 10, 18, 0.5);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
}

/* Live Result Box */
.live-image-container {
    width: 100%;
    max-height: 380px;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-glass);
}

.live-image-preview {
    max-width: 100%;
    max-height: 380px;
    object-fit: contain;
    border-radius: var(--radius-md);
}

/* Character Gallery */
.image-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
    max-height: 600px;
    overflow-y: auto;
    padding-right: 4px;
}

.char-gallery-card {
    background: rgba(13, 21, 39, 0.6);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}

.char-gallery-card:hover {
    border-color: rgba(57, 255, 20, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
}

.char-thumb-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #000;
    overflow: hidden;
}

.char-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.char-gallery-card:hover .char-thumb-img {
    transform: scale(1.05);
}

.char-thumb-failed {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: rgba(239, 68, 68, 0.08);
}

.char-model-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    font-size: 10px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 2px 7px;
    border-radius: var(--radius-full);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.char-details {
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.char-prompt-snippet {
    font-size: 11.5px;
    color: #cbd5e1;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
}

/* ==========================================================================
   Virtual Try-On / Fitting Studio Enhancements
   ========================================================================== */

/* Try-On Tabs */
.tryon-nav-tabs {
    display: flex;
    gap: 12px;
    background: rgba(255, 255, 255, 0.03);
    padding: 6px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-glass);
    flex-wrap: wrap;
}

.btn-tryon-tab {
    flex: 1;
    min-width: 220px;
    padding: 12px 18px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    font-weight: 700;
    font-size: 12px;
    font-family: var(--font-pixel);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition);
}

.btn-tryon-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.btn-tryon-tab.active {
    background: rgba(236, 72, 153, 0.14);
    border-color: rgba(236, 72, 153, 0.4);
    color: #fff;
    box-shadow: 0 0 15px rgba(236, 72, 153, 0.2);
}

/* Dual Dropzones Grid */
.tryon-dropzone-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

@media (max-width: 640px) {
    .tryon-dropzone-grid {
        grid-template-columns: 1fr;
    }
}

.dropzone-sm {
    min-height: 155px !important;
}

/* Clothing Type Selector Grid */
.clothing-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 6px;
}

@media (max-width: 640px) {
    .clothing-type-grid {
        grid-template-columns: 1fr;
    }
}

.clothing-type-chip {
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
    text-align: left;
}

.clothing-type-chip:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.clothing-type-chip.active {
    background: rgba(236, 72, 153, 0.12);
    border-color: #ec4899;
    color: #fff;
    box-shadow: 0 0 12px rgba(236, 72, 153, 0.2);
}

.clothing-type-chip i {
    font-size: 16px;
    color: #ec4899;
}

/* Try-On Provider Selection Grid */
.tryon-provider-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

@media (max-width: 768px) {
    .tryon-provider-grid {
        grid-template-columns: 1fr;
    }
}

.tryon-prov-chip {
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-glass);
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
    text-align: left;
}

.tryon-prov-chip:hover {
    background: rgba(255, 255, 255, 0.07);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.tryon-prov-chip.active {
    background: rgba(57, 255, 20, 0.1);
    border-color: #39ff14;
    color: #fff;
    box-shadow: 0 0 12px rgba(57, 255, 20, 0.2);
}

.tryon-prov-chip i {
    font-size: 20px;
    flex-shrink: 0;
}

/* ============================================================================
   SPLASH / BOOT-UP SCREEN
   ============================================================================ */

.splash-active {
    overflow: hidden !important;
}

.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: #040604;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.splash-screen.splash-hide {
    opacity: 0;
    transform: scale(1.05);
    pointer-events: none;
}

.splash-scanlines {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 0, 0, 0.15) 2px,
        rgba(0, 0, 0, 0.15) 4px
    );
    pointer-events: none;
    z-index: 1;
}

.splash-inner {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
}

.splash-logo-box {
    position: relative;
}

.splash-logo-img {
    width: 80px;
    height: 80px;
    border-radius: 16px;
    border: 2px solid rgba(163, 230, 53, 0.5);
    box-shadow: 0 0 25px rgba(163, 230, 53, 0.35), 0 0 50px rgba(163, 230, 53, 0.15);
    animation: splashLogoPulse 1.5s ease-in-out infinite;
    object-fit: contain;
}

@keyframes splashLogoPulse {
    0%, 100% { box-shadow: 0 0 30px rgba(57, 255, 20, 0.4), 0 0 60px rgba(57, 255, 20, 0.15); }
    50% { box-shadow: 0 0 50px rgba(57, 255, 20, 0.6), 0 0 100px rgba(57, 255, 20, 0.25); }
}

.splash-title {
    font-size: 24px;
    color: #39ff14;
    text-shadow: 0 0 20px rgba(57, 255, 20, 0.5), 0 0 40px rgba(57, 255, 20, 0.2);
    letter-spacing: 4px;
}

.splash-subtitle {
    font-size: 7px;
    color: rgba(57, 255, 20, 0.5);
    letter-spacing: 3px;
    margin-top: -6px;
}

.splash-terminal {
    width: 100%;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(57, 255, 20, 0.15);
    border-radius: 6px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 8px;
}

.splash-term-line {
    font-family: var(--font-retro);
    font-size: 7px;
    color: rgba(57, 255, 20, 0.6);
    letter-spacing: 0.5px;
    opacity: 0;
    transform: translateX(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.splash-term-line.visible {
    opacity: 1;
    transform: translateX(0);
}

.splash-progress {
    width: 100%;
    height: 3px;
    background: rgba(57, 255, 20, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 6px;
}

.splash-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #39ff14, #00ff88);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.5);
    transition: width 0.1s linear;
}

.splash-status {
    font-size: 8px;
    color: rgba(57, 255, 20, 0.4);
    letter-spacing: 3px;
    animation: splashStatusBlink 0.8s steps(2) infinite;
}

@keyframes splashStatusBlink {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 1; }
}

/* ============================================================================
   GLOBAL PAGE TRANSITIONS & POLISH
   ============================================================================ */

/* Page content entrance animation */
.main-wrapper {
    animation: pageContentFadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes pageContentFadeIn {
    0% { opacity: 0; transform: translateY(12px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Enhanced card hover micro-animation */
.card {
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.studio-card:hover,
.history-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(57, 255, 20, 0.08);
}

/* Enhanced page title glow */
.page-title {
    position: relative;
}

.page-title .text-cyan,
.page-title .text-pink {
    filter: drop-shadow(0 0 6px currentColor);
}

/* Empty state enhancement */
.empty-state {
    text-align: center;
    padding: 60px 30px;
}

.empty-state .empty-icon {
    font-size: 48px;
    color: rgba(57, 255, 20, 0.2);
    margin-bottom: 16px;
    animation: emptyIconFloat 3s ease-in-out infinite;
}

@keyframes emptyIconFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Toast notification entrance */
@keyframes toastSlideIn {
    0% { transform: translateX(120%); opacity: 0; }
    100% { transform: translateX(0); opacity: 1; }
}

/* Badge pulse for "Dev" badge */
.badge-dev {
    animation: badgeDevPulse 2s ease-in-out infinite;
}

@keyframes badgeDevPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4); }
    50% { box-shadow: 0 0 0 4px rgba(245, 158, 11, 0); }
}

/* Smooth scrollbar for code/terminal blocks */
.splash-terminal::-webkit-scrollbar,
.log-container::-webkit-scrollbar {
    width: 4px;
}

.splash-terminal::-webkit-scrollbar-thumb,
.log-container::-webkit-scrollbar-thumb {
    background: rgba(163, 230, 53, 0.2);
    border-radius: 2px;
}

/* ============================================================================
   CLOUDFLARE TURNSTILE WIDGET (Exact match to user reference)
   ============================================================================ */
.cf-turnstile-container {
    width: 100%;
    margin: 18px 0;
}

.cf-turnstile-box {
    background: #222222;
    border: 1px solid #3c3c3c;
    border-radius: 6px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    user-select: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.cf-turnstile-box:hover {
    border-color: #555555;
}

.cf-turnstile-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.cf-check-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #10b981;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
    animation: cfPopIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cfPopIn {
    0% { transform: scale(0.4); opacity: 0; }
    70% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

.cf-status-text {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    letter-spacing: -0.2px;
}

.cf-turnstile-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    flex-shrink: 0;
}

.cf-brand-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.cf-cloud-icon {
    width: 26px;
    height: auto;
    object-fit: contain;
}

.cf-brand-name {
    font-size: 11px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.8px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.cf-links {
    font-size: 9.5px;
    color: #9ca3af;
    display: flex;
    gap: 4px;
    align-items: center;
}

.cf-links a {
    color: #9ca3af;
    text-decoration: underline;
    font-size: 9.5px;
}

.cf-links a:hover {
    color: #ffffff;
}

/* Spinner during verification */
.cf-spinner-ring {
    width: 26px;
    height: 26px;
    border: 3px solid rgba(255, 255, 255, 0.15);
    border-top-color: #f38020;
    border-radius: 50%;
    animation: cfSpin 0.7s linear infinite;
}

@keyframes cfSpin {
    to { transform: rotate(360deg); }
}

/* ============================================================================
   GOOGLE SIGN-IN & MODERN CARD SYSTEM (Inspired by User Image 1)
   ============================================================================ */

/* Big Google Sign-In Button */
.btn-google-auth {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 20px;
    background: #ffffff;
    color: #1f2937;
    border: 1px solid #e5e7eb;
    border-radius: var(--radius-full);
    font-size: 14px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
    text-decoration: none;
}

.btn-google-auth:hover {
    background: #f9fafb;
    color: #111827;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    filter: none;
}

.btn-google-auth .google-icon-svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Divider with text */
.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 18px 0;
    color: var(--text-dim);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-divider span {
    padding: 0 12px;
}

/* Modern Lime Pill Button (Style from Image 1) */
.btn-pill-action {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 16px 12px 24px;
    border-radius: var(--radius-full);
    background: #111111;
    color: #ffffff;
    font-family: var(--font-body);
    font-weight: 800;
    font-size: 13.5px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border: 1px solid rgba(255, 255, 255, 0.12);
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.btn-pill-action:hover {
    background: #000000;
    border-color: var(--primary);
    transform: translateY(-1px);
    box-shadow: 0 6px 22px rgba(163, 230, 53, 0.25);
    color: #ffffff;
}

.btn-pill-action .arrow-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary);
    color: #000000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 800;
    flex-shrink: 0;
    transition: transform 0.25s ease;
}

.btn-pill-action:hover .arrow-circle {
    transform: translateX(3px);
}

/* Lime Highlight Card (from Image 1) */
.card-lime {
    background: #b4f71e !important;
    color: #111827 !important;
    border-radius: 22px !important;
    border: none !important;
    padding: 24px !important;
    box-shadow: 0 12px 36px rgba(180, 247, 30, 0.25);
}

.card-lime .text-primary,
.card-lime .font-pixel {
    color: #111827 !important;
}

/* White Clean Card (from Image 1) */
.card-white {
    background: #ffffff !important;
    color: #111827 !important;
    border-radius: 22px !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    padding: 24px !important;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
}

.card-white .text-primary,
.card-white .font-pixel {
    color: #111827 !important;
}


