/* -------------------------------------------------------------
 * SwiftVTU Enterprise - Kobble Design System
 * Inspired by Kobble.ng: Warm organic canvas, Figtree typography,
 * crisp white elevated cards, and fresh olive green accents.
 * ------------------------------------------------------------- */

@import url('https://fonts.googleapis.com/css2?family=Figtree:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --font: 'Figtree', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    
    /* Kobble Palette */
    --bg-canvas: #F5F4F0;
    --bg-card: #FFFFFF;
    --bg-subtle: #FAF9F6;
    
    --border-color: #E2E0D5;
    --border-hover: #C4C4B8;
    
    --primary: #6F9C3E;
    --primary-hover: #5F8C2E;
    --primary-light: rgba(111, 156, 62, 0.08);
    --primary-border: rgba(111, 156, 62, 0.25);
    
    --accent-orange: #FF882A;
    --accent-orange-light: rgba(255, 136, 42, 0.1);
    
    --text-dark: #1A202C;
    --text-muted: #4A5568;
    --text-light: #9A9A8E;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;
    
    --shadow-subtle: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.04);
    --shadow-hover: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-button: 0 4px 14px rgba(111, 156, 62, 0.25);
    
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

button,
input,
select,
textarea,
a {
    -webkit-tap-highlight-color: transparent;
}

button:focus,
.btn:focus {
    outline: none;
}

button:focus-visible,
.btn:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

body {
    font-family: var(--font);
    background-color: var(--bg-canvas);
    color: var(--text-dark);
    min-height: 100vh;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-dark);
    font-weight: 800;
    letter-spacing: -0.02em;
}

/* Kobble Navigation */
.kobble-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(245, 244, 240, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 0.85rem 2rem;
}

.kobble-nav {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.kobble-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: -0.03em;
}

.kobble-logo .logo-dot {
    width: 10px;
    height: 10px;
    border-radius: var(--radius-full);
    background: var(--primary);
    display: inline-block;
}

.kobble-menu {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    list-style: none;
}

.kobble-menu a {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.92rem;
    text-decoration: none;
    transition: var(--transition);
}

.kobble-menu a:hover,
.kobble-menu a.active {
    color: var(--text-dark);
}

/* Kobble Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: var(--font);
    font-weight: 700;
    font-size: 0.92rem;
    border-radius: var(--radius-full);
    padding: 0.65rem 1.4rem;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    border: 1px solid transparent;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

.btn:focus {
    outline: none;
}

.btn:active {
    transform: scale(0.985);
}

.btn-primary {
    background-color: var(--primary);
    color: #FFFFFF;
    box-shadow: var(--shadow-button);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    box-shadow: 0 6px 20px rgba(111, 156, 62, 0.35);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #FFFFFF;
    color: #5A5B50;
    border: 1px solid #E2E0D5;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    font-weight: 700;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-secondary:hover {
    background-color: #FFFFFF;
    border-color: #4A5568;
    color: #1A202C;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}

.btn-secondary:active {
    transform: translateY(0);
    box-shadow: none;
}

.btn-sm {
    padding: 0.38rem 0.85rem;
    font-size: 0.8rem;
}

.btn-lg {
    padding: 0.85rem 1.85rem;
    font-size: 1rem;
}

.btn-dark {
    background-color: var(--text-dark);
    color: #FFFFFF;
}

.btn-dark:hover {
    background-color: #2D3748;
    transform: translateY(-1px);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-dark);
    border-color: var(--border-color);
}

.btn-outline:hover {
    background-color: rgba(0, 0, 0, 0.04);
    border-color: var(--border-hover);
}

.btn-subtle {
    background-color: transparent;
    color: var(--text-muted);
}

.btn-subtle:hover {
    color: var(--text-dark);
    background-color: rgba(0, 0, 0, 0.04);
}

.btn-ghost-danger,
.btn-delete-plan {
    background: transparent !important;
    border: 1px solid transparent !important;
    box-shadow: none !important;
    color: #DC2626 !important;
    cursor: pointer !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.65rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.btn-ghost-danger:hover,
.btn-delete-plan:hover {
    background: rgba(239, 68, 68, 0.1) !important;
    color: #B91C1C !important;
    transform: none !important;
    box-shadow: none !important;
}

/* -------------------------------------------------------------
 * Universal Tab Navigation & Pill Styling
 * ------------------------------------------------------------- */
.tab-nav,
.tabs-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.35rem;
    -webkit-overflow-scrolling: touch;
}

/* Individual tab buttons & links */
.tab-btn,
.nav-tab,
.tab-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.15rem;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-muted);
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    transition: var(--transition);
    user-select: none;
    white-space: nowrap;
    cursor: pointer;
}

.tab-btn svg,
.nav-tab svg,
.tab-link svg {
    color: var(--text-light);
    stroke-width: 2;
    transition: color 0.2s ease;
}

/* Non-active tab hover */
.tab-btn:hover,
.nav-tab:hover,
.tab-link:hover {
    background: #FFFFFF;
    border-color: #4A5568;
    color: #1A202C;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}

.tab-btn:hover svg,
.nav-tab:hover svg,
.tab-link:hover svg {
    color: var(--text-dark);
}

/* Active tab */
.tab-btn.active,
.nav-tab.active,
.tab-link.active {
    background: #1A202C !important;
    color: #FFFFFF !important;
    border-color: #1A202C !important;
    box-shadow: 0 4px 12px rgba(26, 32, 44, 0.25) !important;
    transform: translateY(0);
}

.tab-btn.active svg,
.nav-tab.active svg,
.tab-link.active svg {
    color: #FFFFFF !important;
}

/* Tab badges (e.g. plan counts, operators) */
.tab-badge {
    font-size: 0.72rem;
    font-weight: 800;
    padding: 0.1rem 0.45rem;
    border-radius: var(--radius-full);
    background: #E5E7EB;
    color: #374151;
    transition: background 0.2s ease, color 0.2s ease;
}

.tab-btn.active .tab-badge,
.nav-tab.active .tab-badge,
.btn-primary .tab-badge {
    background: rgba(255, 255, 255, 0.25) !important;
    color: #FFFFFF !important;
}

/* Tab Underline Navigation Alternative */
.tabs-underline {
    display: flex;
    gap: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.75rem;
    overflow-x: auto;
}

.tab-underline-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 0.25rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-muted);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
}

.tab-underline-item:hover {
    color: var(--text-dark);
    border-bottom-color: var(--border-hover);
}

.tab-underline-item.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* General Link Styling */
a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--text-dark);
}

a.link-primary {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

a.link-primary:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}


/* Wallet Badge Pill */
.wallet-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 0.4rem 1rem;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-dark);
    box-shadow: var(--shadow-subtle);
}

.wallet-pill .pill-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    background: var(--primary);
}

/* Kobble Cards */
.kobble-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-card);
    transition: var(--transition);
}

.kobble-card-hover:hover {
    border-color: var(--primary-border);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.dest-icon-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--bg-subtle);
    border: 1px solid var(--border-color);
    color: var(--primary);
    flex-shrink: 0;
    transition: var(--transition);
}

.kobble-card-hover:hover .dest-icon-box,
.quick-dest-card:hover .dest-icon-box {
    background: var(--primary);
    color: #FFFFFF;
    border-color: var(--primary);
}

/* Form Controls (Comprehensive & Modern) */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label,
.form-label {
    display: block;
    margin-bottom: 0.45rem;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.01em;
}

.form-input,
.form-control,
.form-select,
input[type="text"],
input[type="number"],
input[type="password"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="search"],
select,
textarea {
    width: 100%;
    font-family: var(--font);
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-dark);
    background-color: #FFFFFF;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0.7rem 1rem;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
    line-height: 1.5;
}

.form-input:hover,
.form-control:hover,
input[type="text"]:hover,
input[type="number"]:hover,
input[type="password"]:hover,
input[type="email"]:hover,
input[type="tel"]:hover,
input[type="url"]:hover,
input[type="search"]:hover,
select:hover,
textarea:hover {
    border-color: var(--border-hover);
}

.form-input:focus,
.form-control:focus,
.form-select:focus,
input[type="text"]:focus,
input[type="number"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="url"]:focus,
input[type="search"]:focus,
textarea:focus {
    background-color: #FFFFFF;
    border-color: #6F9C3E;
    box-shadow: 0 0 0 3px rgba(111, 156, 62, 0.14);
}

.form-input::placeholder,
.form-control::placeholder,
input::placeholder,
textarea::placeholder {
    color: #9A9A8E;
    font-weight: 400;
}

/* -------------------------------------------------------------
 * Kobble Dropdowns & Select Design System (Adopted from kobble2.html)
 * ------------------------------------------------------------- */
select,
select.form-control,
select.form-input,
select.form-select,
.kobble-select {
    width: 100%;
    font-family: var(--font, 'Figtree', system-ui, sans-serif);
    font-size: 0.88rem;
    font-weight: 600;
    color: #1A202C;
    background-color: #FFFFFF;
    border: 1px solid #E2E0D5;
    border-radius: 12px;
    padding: 0.65rem 2.6rem 0.65rem 1rem;
    cursor: pointer;
    outline: none;
    line-height: 1.5;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%239A9A8E' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    background-size: 18px 18px;
    transition: border-color 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease;
}

select:hover,
select.form-control:hover,
select.form-input:hover,
select.form-select:hover,
.kobble-select:hover {
    border-color: #4A5568;
}

select:focus,
select.form-control:focus,
select.form-input:focus,
select.form-select:focus,
.kobble-select:focus {
    background-color: #FFFFFF;
    border-color: #6F9C3E !important;
    box-shadow: 0 0 0 3px rgba(111, 156, 62, 0.16) !important;
    outline: none;
}

select option {
    background: #FFFFFF;
    color: #1A202C;
    font-weight: 500;
    padding: 8px 12px;
}

/* Kobble Custom Dropdown Component (Trigger Button + Popover Menu) */
.kobble-dropdown {
    position: relative;
    display: inline-block;
}

/* -------------------------------------------------------------
 * Kobble Popover Dropdowns (Adopted from kobble2.html)
 * ------------------------------------------------------------- */
.kobble-select-wrapper {
    position: relative;
    width: 100%;
}

.kobble-select-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.65rem 1rem;
    background: #FFFFFF;
    border: 1px solid #E2E0D5;
    border-radius: 12px;
    font-family: var(--font, 'Figtree', system-ui, sans-serif);
    font-size: 0.88rem;
    font-weight: 600;
    color: #1A202C;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: border-color 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    text-align: left;
    user-select: none;
}

.kobble-select-trigger:hover {
    border-color: #4A5568;
}

.kobble-select-trigger:focus,
.kobble-select-trigger.open {
    outline: none;
    border-color: #6F9C3E;
    box-shadow: 0 0 0 3px rgba(111, 156, 62, 0.16);
}

.kobble-select-trigger .kobble-select-label {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.kobble-select-trigger .kobble-select-arrow {
    color: #9A9A8E;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    flex-shrink: 0;
}

.kobble-select-trigger.open .kobble-select-arrow {
    transform: rotate(180deg);
}

/* The Popover Menu That Appears When Pressed */
.kobble-select-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 1000;
    min-width: 100%;
    background: #FFFFFF;
    border: 1px solid #E2E0D5;
    border-radius: 14px;
    padding: 6px;
    box-shadow: 0 12px 30px -6px rgba(20, 22, 15, 0.14), 0 8px 12px -6px rgba(20, 22, 15, 0.06);
    display: none;
    max-height: 280px;
    overflow-y: auto;
}

.kobble-select-dropdown.open {
    display: flex;
    flex-direction: column;
    gap: 2px;
    animation: kobble-popover-in 0.18s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes kobble-popover-in {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.kobble-select-dropdown::-webkit-scrollbar {
    width: 6px;
}
.kobble-select-dropdown::-webkit-scrollbar-track {
    background: transparent;
}
.kobble-select-dropdown::-webkit-scrollbar-thumb {
    background: #E2E0D5;
    border-radius: 4px;
}
.kobble-select-dropdown::-webkit-scrollbar-thumb:hover {
    background: #CBD5E1;
}

.kobble-select-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.6rem 0.85rem;
    font-size: 0.86rem;
    font-weight: 600;
    color: #4A5568;
    border-radius: 9px;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
    user-select: none;
}

.kobble-select-option:hover {
    background: #F5F4F0;
    color: #1A202C;
}

.kobble-select-option.selected {
    background: rgba(111, 156, 62, 0.08);
    color: #1A202C;
    font-weight: 700;
}

.kobble-select-check {
    display: none;
    color: #6F9C3E;
    flex-shrink: 0;
}

.kobble-select-option.selected .kobble-select-check {
    display: inline-block;
}

select:disabled,
input:disabled,
textarea:disabled {
    background-color: var(--bg-subtle);
    color: #94A3B8;
    cursor: not-allowed;
    border-color: var(--border-color);
}

/* Form Helper text */
.form-help,
.form-text {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.35rem;
    display: block;
}

/* Form grid helpers */
.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .form-grid-2 {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
}

.form-grid-3 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.85rem;
}

@media (min-width: 768px) {
    .form-grid-3 {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
}

/* Alert Boxes */
.alert {
    padding: 0.9rem 1.2rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.alert-error {
    background-color: #FEE2E2;
    border: 1px solid #FCA5A5;
    color: #991B1B;
}

.alert-success {
    background-color: #ECFDF5;
    border: 1px solid #A7F3D0;
    color: #065F46;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
}

/* -------------------------------------------------------------
 * Auth Layout & Mobile Responsive System
 * ------------------------------------------------------------- */
.auth-wrapper {
    max-width: 500px;
    margin: 2.25rem auto 3rem;
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
}

.auth-card {
    padding: 2.25rem 2rem;
    width: 100%;
    box-sizing: border-box;
}

.auth-header-box {
    text-align: center;
    margin-bottom: 1.75rem;
}

.auth-icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--primary-light);
    color: var(--primary);
    margin-bottom: 0.85rem;
    border: 1px solid var(--primary-border);
}

.auth-title {
    font-size: clamp(1.4rem, 4vw, 1.75rem);
    font-weight: 800;
    margin-bottom: 0.35rem;
    color: var(--text-dark);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.auth-subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    margin: 0;
    line-height: 1.45;
}

/* 2-Column Grid on Desktop / Single Column on Mobile */
.auth-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    width: 100%;
    box-sizing: border-box;
}

@media (max-width: 640px) {
    .auth-wrapper {
        margin: 0.75rem auto 2rem;
        padding: 0 0.5rem;
        max-width: 100%;
    }

    .auth-card {
        padding: 1.5rem 1.15rem !important;
        border-radius: var(--radius-md) !important;
    }

    .auth-grid-2 {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    .guest-main {
        padding: 1rem 0.5rem 2.5rem !important;
    }

    .kobble-header {
        padding: 0.75rem 1rem !important;
    }

    .auth-header-box {
        margin-bottom: 1.35rem;
    }

    .form-input,
    .form-control,
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="tel"] {
        font-size: 16px !important; /* Prevents iOS auto-zoom on input tap */
        height: 48px;
    }

    .btn-auth-submit {
        height: 48px;
        font-size: 1rem !important;
    }
}

@media (max-width: 380px) {
    .auth-wrapper {
        padding: 0 0.15rem;
    }

    .auth-card {
        padding: 1.25rem 0.85rem !important;
    }

    .auth-title {
        font-size: 1.3rem;
    }
}

/* -------------------------------------------------------------
 * Kobble Sidebar & App Shell Layout
 * ------------------------------------------------------------- */
.app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
    background-color: var(--bg-canvas);
}

@media (min-width: 1024px) {
    .app-shell {
        flex-direction: row;
    }
}

/* Sidebar (Desktop) */
.kobble-sidebar {
    display: none;
}

@media (min-width: 1024px) {
    .kobble-sidebar {
        display: flex;
        flex-direction: column;
        width: 256px;
        min-width: 256px;
        height: 100vh;
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        background: #FFFFFF;
        border-right: 1px solid var(--border-color);
        padding: 1.5rem 1.15rem 1.25rem;
        z-index: 30;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .kobble-sidebar::-webkit-scrollbar {
        width: 4px;
    }

    .kobble-sidebar::-webkit-scrollbar-thumb {
        background: var(--border-color);
        border-radius: 4px;
    }
}



.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: -0.03em;
    padding: 0.25rem 0.5rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.25rem;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-section-label {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-light);
    padding: 14px 12px 4px;
    user-select: none;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 11px;
    border-radius: 11px;
    padding: 10px 12px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    color: #6B6B60;
    background: transparent;
    border: 1px solid transparent;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.sidebar-link svg {
    flex-shrink: 0;
    stroke-width: 1.8;
    color: #6B6B60;
    transition: color 0.2s ease, transform 0.2s ease;
}

.sidebar-link:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #1A202C;
    border-color: transparent;
}

.sidebar-link:hover svg {
    color: #1A202C;
}

.sidebar-link.active {
    background: var(--accent-orange);
    color: #FFFFFF;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 136, 42, 0.25);
    transform: translateX(2px);
    border-color: transparent;
}

.sidebar-link.active svg {
    stroke-width: 2.2;
    color: #FFFFFF !important;
}


/* Bottom Sidebar Area */
.sidebar-bottom {
    margin-top: auto;
    padding-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    flex-shrink: 0;
}

.sidebar-balance-card {
    display: block;
    background: var(--primary);
    border: 1px solid var(--primary);
    border-radius: 15px;
    padding: 1rem 1.1rem;
    color: #FFFFFF;
    text-decoration: none;
    transition: var(--transition);
}

.sidebar-balance-card:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(111, 156, 62, 0.3);
}

.balance-card-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.75);
}

.balance-card-amount {
    font-size: 22px;
    font-weight: 900;
    letter-spacing: -0.02em;
    margin: 4px 0 2px;
    color: #FFFFFF;
}

.balance-card-sub {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
}

.sidebar-user-row {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.4rem 0.25rem 0.2rem;
}

.user-avatar-circle {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--accent-orange);
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 13px;
    flex-shrink: 0;
}

.user-info {
    min-width: 0;
    flex: 1;
}

.user-info .name {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-info .tier {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: capitalize;
}

.user-logout-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition);
    flex-shrink: 0;
    border: none;
    background: transparent;
    cursor: pointer;
}

.user-logout-btn:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #EF4444;
}

.sidebar-support {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0.35rem 0.5rem;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
}

.support-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    display: inline-block;
    box-shadow: 0 0 0 2px rgba(111, 156, 62, 0.2);
}

/* Main Content Area */
.kobble-main {
    flex: 1;
    min-width: 0;
    width: 100%;
    padding: 1.25rem 1rem 6rem;
}

@media (min-width: 768px) {
    .kobble-main {
        padding: 2rem 2rem 6rem;
    }
}

@media (min-width: 1024px) {
    .kobble-main {
        margin-left: 256px;
        width: calc(100% - 256px);
        max-width: 1300px;
        padding: 2.5rem 3.5rem;
    }
}


/* Mobile Header & Bottom Navigation */
.mobile-top-bar {
    display: flex;
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 40;
    background: #FFFFFF;
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--shadow-subtle);
}

.mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 40;
    background: #FFFFFF;
    border-top: 1px solid var(--border-color);
    padding: 0.5rem 0.25rem;
    padding-bottom: calc(0.5rem + env(safe-area-inset-bottom, 0px));
    justify-content: space-around;
    align-items: center;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.04);
}

.mobile-bottom-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: var(--text-light);
    font-size: 11px;
    font-weight: 700;
    transition: var(--transition);
    min-width: 58px;
    padding: 0.35rem 0.2rem;
}

.mobile-bottom-item.active {
    color: var(--primary);
}

.mobile-bottom-item svg {
    stroke-width: 2.2;
}

/* Mobile Drawer */
.mobile-drawer-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 60;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.mobile-drawer-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 290px;
    max-width: 85vw;
    background: #FFFFFF;
    z-index: 70;
    display: flex;
    flex-direction: column;
    padding: 1.5rem 1.25rem;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.15);
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.3s;
    overflow-y: auto;
    visibility: hidden;
    pointer-events: none;
}

.mobile-drawer.open {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1rem;
}

.drawer-close-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
    background: var(--bg-subtle);
    color: var(--text-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.drawer-close-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

@media (min-width: 1024px) {
    .mobile-top-bar {
        display: none !important;
    }
    .mobile-bottom-nav {
        display: none !important;
    }
    .mobile-drawer,
    .mobile-drawer-backdrop {
        display: none !important;
    }
}

/* -------------------------------------------------------------
 * Responsive Dashboard Layouts
 * ------------------------------------------------------------- */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
}

.dashboard-stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

@media (min-width: 640px) {
    .dashboard-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
}

.dashboard-services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 2.5rem;
}

@media (min-width: 480px) {
    .dashboard-services-grid {
        gap: 1rem;
    }
}

@media (min-width: 768px) {
    .dashboard-services-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
    }
}

@media (min-width: 1024px) {
    .dashboard-services-grid {
        grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    }
}

.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-lg);
}

.table-responsive table {
    width: 100%;
    min-width: 640px;
}

/* -------------------------------------------------------------
 * Hit-Testing & Overlay Safeguards
 * ------------------------------------------------------------- */
.fixed { position: fixed !important; }
.inset-0 { top: 0 !important; right: 0 !important; bottom: 0 !important; left: 0 !important; }
.overflow-hidden { overflow: hidden !important; }
.pointer-events-none { pointer-events: none !important; }
.-z-10 { z-index: -10 !important; }

/* -------------------------------------------------------------
 * Kobble Bottom Sheet Component (Mobile-First)
 * Sliding bottom sheet on mobile (< 768px) with touch handle,
 * elevated centered modal dialog on tablet/desktop (>= 768px).
 * ------------------------------------------------------------- */
.kobble-sheet-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(20, 22, 15, 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.28s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.28s;
}

.kobble-sheet-backdrop.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.kobble-sheet-panel {
    width: 100%;
    max-width: 100%;
    max-height: calc(90vh - env(safe-area-inset-top, 0px));
    background: #FFFFFF;
    border-top: 1px solid var(--border-color);
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    border-top-left-radius: 24px;
    border-top-right-radius: 24px;
    box-shadow: 0 -12px 40px rgba(20, 22, 15, 0.14);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
}

.kobble-sheet-backdrop.open .kobble-sheet-panel {
    transform: translateY(0);
}

/* Touch drag handle pill */
.kobble-sheet-handle-bar {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 0 0.35rem;
    cursor: grab;
    user-select: none;
    touch-action: none;
    background: #FFFFFF;
}

.kobble-sheet-handle {
    width: 44px;
    height: 5px;
    background: #D5D3C8;
    border-radius: var(--radius-full);
    transition: background 0.2s ease, transform 0.2s ease;
}

.kobble-sheet-handle-bar:active .kobble-sheet-handle {
    background: var(--text-muted);
    transform: scaleX(1.15);
}

.kobble-sheet-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.4rem 1rem;
    border-bottom: 1px solid var(--border-color);
    background: #FFFFFF;
    flex-shrink: 0;
}

.kobble-sheet-body {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
    flex: 1;
    padding: 1.25rem 1.4rem;
}

.kobble-sheet-footer {
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color);
    padding: 0.9rem 1.4rem;
    background: #FAF9F6;
    flex-shrink: 0;
}

/* Tablet & Desktop (>= 768px): Refined Centered Card */
@media (min-width: 768px) {
    .kobble-sheet-backdrop {
        align-items: center;
        padding: 1.5rem;
    }

    .kobble-sheet-panel {
        max-width: 520px;
        max-height: 88vh;
        border: 1px solid var(--border-color);
        border-radius: 20px;
        box-shadow: 0 25px 50px -12px rgba(20, 22, 15, 0.2);
        padding-bottom: 0;
        transform: scale(0.96) translateY(16px);
        transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s;
    }

    .kobble-sheet-backdrop.open .kobble-sheet-panel {
        transform: scale(1) translateY(0);
    }

    .kobble-sheet-handle-bar {
        display: none;
    }

    .kobble-sheet-header {
        padding: 1.25rem 1.5rem;
    }

    .kobble-sheet-body {
        padding: 1.5rem;
    }

    .kobble-sheet-footer {
        padding: 1rem 1.5rem;
        border-bottom-left-radius: 20px;
        border-bottom-right-radius: 20px;
    }
}
