/* ============================================================
   FATAFAT BALKAT - DESIGN TOKENS & LUXURY SALON SYSTEM
   Palette: Obsidian Black, Gold, Royal Blue & Clean Highlights
   ============================================================ */
:root {
    /* Brand Navy & Gold Palette (From Onboarding Theme) */
    --brand-navy: #0A1A3B;
    --brand-gold: #D4AF37;
    --gold: #D4AF37;
    --gold-600: #B8860B;
    --gold-700: #9A6E07;
    --gold-50: #FAF6E8;
    --gold-100: #F3E9C7;
    --gold-ring: rgba(212, 175, 55, 0.20);
    --shadow-gold: 0 12px 28px -10px rgba(212, 175, 55, 0.42);

    /* Navy Shades */
    --navy-900: #0A1A3B;
    --navy-800: #0F234A;
    --navy-700: #142C5A;
    --shadow-navy: 0 12px 28px -10px rgba(10, 26, 59, 0.40);

    /* Neutral Ink & Text */
    --black-obsidian: #0A1A3B;
    --ink-900: #0A1A3B;
    --ink-800: #1E293B;
    --ink-700: #334155;
    --body: #475569;
    --muted: #64748B;

    /* Accents & Status */
    --green: #10B981;
    --green-50: #ECFDF5;

    /* Backgrounds & Borders */
    --bg: #FFFFFF;
    --bg-alt: #F8F9FA;
    --bg-warm: #FAF6E8;
    --bg-dark: #0A1A3B;
    --border: #E2E8F0;
    --border-gold: rgba(212, 175, 55, 0.35);

    /* Fonts */
    --font-display: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Radii */
    --radius-lg: 24px;
    --radius-md: 18px;
    --radius-sm: 12px;
    --radius-pill: 100px;

    /* Shadows */
    --shadow-sm: 0 2px 10px rgba(10, 26, 59, 0.05);
    --shadow-md: 0 16px 36px -18px rgba(10, 26, 59, 0.14);
    --shadow-lg: 0 30px 60px -24px rgba(10, 26, 59, 0.20);

    --container-max: 1200px;
}

body {
    font-family: var(--font-body);
    color: var(--body);
    background: var(--bg);
    font-size: 1.0625rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6, .font-display {
    font-family: var(--font-display);
    color: var(--ink-900);
    letter-spacing: -0.02em;
    line-height: 1.25;
    font-weight: 700;
}

.container-dc {
    width: 90% !important;
    max-width: 90% !important;
    margin: 0 auto !important;
    padding: 0 24px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color .2s ease;
}

::selection {
    background: var(--gold-100);
    color: var(--ink-900);
}

:focus-visible {
    outline: 2.5px solid var(--gold);
    outline-offset: 3px;
    border-radius: 4px;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-dc {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 0.98rem;
    padding: 14px 30px;
    border-radius: var(--radius-pill);
    border: 1.5px solid transparent;
    transition: transform .22s ease, box-shadow .22s ease, background .22s ease, color .22s ease, border-color .22s ease;
    cursor: pointer;
    white-space: nowrap;
}

.btn-dc:active {
    transform: translateY(1px) scale(0.99);
}

.btn-primary-dc, .btn-gold-dc {
    background: #D4AF37;
    color: #0A1A3B;
    font-weight: 800;
    box-shadow: 0 10px 24px -6px rgba(212, 175, 55, 0.40);
    border: 1.5px solid #D4AF37;
}

.btn-primary-dc:hover, .btn-gold-dc:hover {
    background: #E5C158;
    color: #0A1A3B;
    transform: translateY(-2px);
    box-shadow: 0 16px 32px -8px rgba(212, 175, 55, 0.55);
}

.btn-secondary-dc, .btn-navy-dc {
    background: #0A1A3B;
    color: #FFFFFF;
    font-weight: 700;
    box-shadow: 0 10px 24px -6px rgba(10, 26, 59, 0.35);
    border: 1.5px solid #0A1A3B;
}

.btn-secondary-dc:hover, .btn-navy-dc:hover {
    background: #0F234A;
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 16px 32px -8px rgba(10, 26, 59, 0.50);
}

.btn-dark-dc {
    background: var(--black-obsidian);
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-dark-dc:hover {
    background: var(--ink-900);
    color: #FFFFFF;
    border-color: var(--gold);
    transform: translateY(-2px);
}

.btn-outline-dc {
    background: transparent;
    color: var(--ink-900);
    border-color: var(--border);
}

.btn-outline-dc:hover {
    border-color: var(--gold);
    color: var(--gold-700);
    background: var(--gold-50);
    transform: translateY(-2px);
}

.btn-ghost-dc {
    background: var(--bg-alt);
    color: var(--ink-900);
    border-color: transparent;
}

.btn-ghost-dc:hover {
    background: var(--gold-50);
    color: var(--gold-700);
}

.btn-sm-dc {
    padding: 10px 20px;
    font-size: 0.88rem;
}

.btn-dc svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* ============================================================
   FORMS & INPUTS
   ============================================================ */
.form-label-dc {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--ink-900);
    margin-bottom: 8px;
    display: block;
}

.form-control-dc {
    width: 100%;
    padding: 12px 18px;
    font-size: 0.95rem;
    font-family: var(--font-body);
    font-weight: 500;
    background: var(--bg-alt);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--ink-900);
    transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}

.form-control-dc:focus {
    background: #fff;
    border-color: var(--gold);
    box-shadow: 0 0 0 4px var(--gold-ring);
    outline: none;
}

.form-group-dc {
    margin-bottom: 20px;
}

/* ============================================================
   CARDS & BADGES
   ============================================================ */
.card-dc {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.card-dc:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--border-gold);
}

.icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 15px;
    background: var(--gold-50);
    color: var(--gold-700);
    border: 1px solid var(--border-gold);
    flex-shrink: 0;
}

.icon-badge svg {
    width: 26px;
    height: 26px;
}

.icon-badge.blue {
    background: var(--blue-50);
    color: var(--royal-blue);
    border-color: var(--blue-100);
}

.icon-badge.sm {
    width: 40px;
    height: 40px;
    border-radius: 12px;
}

.icon-badge.sm svg {
    width: 20px;
    height: 20px;
}

.badge-dc {
    font-weight: 700;
    font-size: 0.78rem;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.badge-pending { background: #FFF4E5; color: #B25E00; border: 1px solid #FFE0B2; }
.badge-assigned { background: #E6F3FF; color: #0066CC; border: 1px solid #B3D9FF; }
.badge-accepted { background: var(--gold-50); color: var(--gold-700); border: 1px solid var(--gold-100); }
.badge-started { background: #E6FFF9; color: #009973; border: 1px solid #B3FFEC; }
.badge-completed { background: var(--green-50); color: var(--green); border: 1px solid #A7F3D0; }
.badge-cancelled { background: #FFEBEB; color: #CC0000; border: 1px solid #FFCCCC; }

.badge-paid { background: var(--green-50); color: var(--green); border: 1px solid #A7F3D0; }
.badge-unpaid { background: #FFF4E5; color: #B25E00; border: 1px solid #FFE0B2; }

/* ============================================================
   DESKTOP PORTAL LAYOUT
   ============================================================ */
.portal-wrap {
    display: flex;
    min-height: 100vh;
    background: var(--bg-alt);
}

.portal-sidebar {
    width: 260px;
    background: var(--black-obsidian);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
}

.portal-sidebar-brand {
    padding: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.portal-sidebar-nav {
    padding: 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex-grow: 1;
}

.portal-sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    color: #94A3B8;
    transition: background .2s ease, color .2s ease;
}

.portal-sidebar-nav a:hover,
.portal-sidebar-nav a.active {
    background: rgba(212, 175, 55, 0.12);
    color: var(--gold);
}

.portal-sidebar-nav a svg {
    width: 20px;
    height: 20px;
}

.portal-sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.portal-main {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.portal-header {
    height: 70px;
    background: #fff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.portal-content {
    padding: 32px;
    flex-grow: 1;
}

/* ============================================================
   MOBILE WEB-APP SYSTEM (NATIVE LOOK AND FEEL)
   ============================================================ */
.mobile-app-shell {
    position: fixed;
    inset: 0;
    background: var(--bg-alt);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 9999;
    font-family: var(--font-body);
}

.mobile-top-bar {
    height: 56px;
    background: rgba(15, 23, 42, 0.94);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.25);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    color: #fff;
}

.mobile-top-bar h1 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--gold);
    margin: 0;
    flex-grow: 1;
    text-align: center;
}

.mobile-top-bar-action {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    position: relative;
}

.mobile-top-bar-action:active {
    background: rgba(255, 255, 255, 0.1);
}

.mobile-top-bar-action svg {
    width: 22px;
    height: 22px;
}

.mobile-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 8px;
    height: 8px;
    background: var(--gold);
    border-radius: 50%;
}

.mobile-content {
    flex-grow: 1;
    margin-top: 56px;
    margin-bottom: 64px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 20px 0;
}
.mobile-screen-area {
    width: 90% !important;
    margin: 0 auto !important;
}

.mobile-bottom-nav {
    height: 64px;
    background: rgba(15, 23, 42, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid rgba(212, 175, 55, 0.25);
    display: flex;
    align-items: center;
    justify-content: space-around;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding-bottom: env(safe-area-inset-bottom);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #94A3B8;
    font-size: 0.72rem;
    font-weight: 700;
    flex-grow: 1;
    height: 100%;
    cursor: pointer;
    border: none;
    background: transparent;
    padding: 0;
    transition: color .2s ease;
}

.mobile-nav-item.active {
    color: var(--gold);
}

.mobile-nav-item svg {
    width: 22px;
    height: 22px;
}

/* Screen manager */
.mobile-screen {
    display: none;
    animation: fadeScreen 0.28s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.mobile-screen.active {
    display: block;
}

@keyframes fadeScreen {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Components */
.mobile-section-title {
    font-size: 1.35rem;
    margin-bottom: 16px;
    font-weight: 700;
}

.mobile-card {
    background: #fff;
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid var(--border);
    margin-bottom: 12px;
    box-shadow: var(--shadow-sm);
    display: block;
}

.mobile-card:active {
    background: var(--bg-alt);
}

.mobile-field-group {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 20px;
}

.mobile-field {
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
    padding: 14px 16px;
}

.mobile-field:last-child {
    border-bottom: none;
}

.mobile-field-icon {
    color: var(--muted);
    margin-right: 12px;
    width: 20px;
    height: 20px;
}

.mobile-field-input {
    flex-grow: 1;
    border: none;
    background: transparent;
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--ink-900);
    width: 100%;
}

.mobile-field-input:focus {
    outline: none;
}

/* Sticky Action Button for mobile */
.mobile-sticky-btn {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #D4AF37 0%, #B8860B 100%);
    color: #0F172A;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-gold);
    border: none;
    z-index: 99;
}

.mobile-sticky-btn svg {
    width: 24px;
    height: 24px;
}

/* Mobile Quick Tabs/Chips */
.mobile-chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 16px;
    scrollbar-width: none;
}

.mobile-chips::-webkit-scrollbar {
    display: none;
}

.mobile-chip {
    padding: 8px 16px;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-pill);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--ink-700);
    white-space: nowrap;
    cursor: pointer;
}

.mobile-chip.active {
    background: var(--gold-50);
    border-color: var(--gold);
    color: var(--gold-700);
}

/* ============================================================
   RESPONSIVE OVERRIDES
   ============================================================ */
@media (max-width: 768px) {
    .portal-wrap {
        display: none;
    }
}
