/* =========================================
   WARM EDITORIAL CASINO — Mobile-Only / H5 Viewport
   Enforced Mobile Phone Layout (Even on Laptops/Desktops)
   Palette : Warm Oat Cream (#F5EFEB) + Deep Espresso (#1C1713) + Honey Amber (#E68A22)
   Fonts   : Inter (Clean, Modern & Highly Legible)
   ========================================= */

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

/* ---- Design Tokens ---- */
:root {
    /* Backgrounds */
    --bg-base:          #F5EFEB;
    --bg-canvas:        #F5EFEB;
    --bg-canvas-alt:    #EDE5DC;
    --bg-white:         #FFFFFF;
    --bg-card-light:    #FFFFFF;
    --bg-card-cream:    #EFE8DE;

    /* Contrast Dark - Deep Velvet Espresso */
    --bg-espresso:      #1C1713;
    --bg-espresso-deep: #14100D;
    --bg-espresso-card: #251F1A;
    --bg-espresso-soft: #2F2722;
    --bg-espresso-pill: #38302A;

    /* Signature Accent - Warm Honey Amber */
    --clr-amber:        #E68A22;
    --clr-amber-hover:  #CF7716;
    --clr-amber-light:  #FDF1E2;
    --clr-amber-subtle: rgba(230, 138, 34, 0.12);
    --clr-amber-border: rgba(230, 138, 34, 0.35);

    /* Text Colors */
    --clr-text-dark:    #1C1713;
    --clr-text-muted:   #756B61;
    --clr-text-subtle:  #9C9287;
    --clr-text-light:   #F5EFEB;
    --clr-text-light-muted: #A89F95;

    /* Borders */
    --border-light:     rgba(28, 23, 19, 0.08);
    --border-medium:    rgba(28, 23, 19, 0.14);
    --border-dark:      rgba(255, 255, 255, 0.08);

    /* Radii */
    --radius-pill:      9999px;
    --radius-xl:        24px;
    --radius-lg:        18px;
    --radius-md:        12px;
    --radius-sm:        8px;

    /* Shadows */
    --shadow-soft:      0 4px 18px rgba(28, 23, 19, 0.04);
    --shadow-card:      0 10px 28px rgba(28, 23, 19, 0.07);
    --shadow-dark:      0 14px 35px rgba(0, 0, 0, 0.35);

    /* Enforced Mobile App Width */
    --mobile-width:     480px;
    --header-h:         68px;

    /* Transitions */
    --transition:       all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast:  all 0.15s ease;

    /* Aliases */
    --clr-primary:      var(--clr-amber);
    --primary-color:    var(--clr-amber);
    --clr-border:       var(--border-light);
    --border-color:     var(--border-light);
    --text-muted:       var(--clr-text-muted);
    --text-main:        var(--clr-text-dark);
    --bg-card:          var(--bg-card-light);
    --clr-accent:       var(--clr-amber);
    --clr-secondary:    var(--bg-espresso);
    --clr-white:        #FFFFFF;
    --clr-text:         var(--clr-text-dark);
    --clr-text2:        var(--clr-text-muted);
    --clr-muted:        var(--clr-text-muted);
}

/* ---- Reset ---- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: #120E0C; /* Dark luxury backdrop outside mobile container on laptop */
}

/* Body acts as the desktop frame hosting the centered mobile app */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: var(--clr-text-dark);
    background-color: #120E0C;
    background-image: 
        radial-gradient(circle at 50% 20%, rgba(230, 138, 34, 0.06) 0%, transparent 60%),
        radial-gradient(circle at 10% 80%, rgba(28, 23, 19, 0.8) 0%, transparent 70%);
    background-attachment: fixed;
    line-height: 1.6;
    letter-spacing: -0.01em;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.no-scroll {
    overflow: hidden;
}

/* =========================================
   CENTERED MOBILE VIEWPORT WRAPPER (ENFORCED MOBILE)
   ========================================= */
.mobile-app-wrapper {
    width: 100%;
    max-width: var(--mobile-width);
    min-height: 100vh;
    background-color: var(--bg-canvas);
    position: relative;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5), 0 0 100px rgba(0, 0, 0, 0.3);
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    padding-top: 64px; /* Space for fixed mobile header navbar */
    padding-bottom: 74px; /* Space for mobile sticky bottom bar */
}

@media (max-width: 480px) {
    .mobile-app-wrapper {
        max-width: 100%;
        box-shadow: none;
    }
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    color: var(--clr-text-dark);
    line-height: 1.25;
    font-weight: 800;
    letter-spacing: -0.02em;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    font-family: inherit;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: var(--transition);
}

ul, ol {
    list-style: none;
}

.container {
    width: 100%;
    padding: 0 16px;
    margin: 0 auto;
}

/* =========================================
   MOBILE HEADER (FIXED NAVBAR)
   ========================================= */
#main-header, header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--mobile-width);
    z-index: 1000;
    padding: 12px 16px;
    background: rgba(245, 239, 235, 0.95);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.25s ease, box-shadow 0.25s ease;
}

#main-header.scrolled, header.scrolled {
    background: rgba(245, 239, 235, 0.98);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

.header-container {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.logo a {
    display: flex;
    align-items: center;
}

.logo img {
    max-height: 38px;
    width: auto;
    object-fit: contain;
}

/* Header Right Actions */
.header-auth {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Reference Signature Pill Toggle Button */
.pill-toggle-btn {
    display: inline-flex;
    align-items: center;
    background: var(--bg-espresso);
    color: #FFFFFF;
    border-radius: var(--radius-pill);
    padding: 4px 12px 4px 6px;
    font-size: 0.78rem;
    font-weight: 700;
    gap: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
    transition: var(--transition);
}

.pill-toggle-btn .toggle-knob {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--clr-amber);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    font-size: 0.65rem;
}

.pill-toggle-btn:active {
    transform: scale(0.96);
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    gap: 4px;
    position: relative;
    z-index: 1002;
    cursor: pointer;
}

.mobile-menu-toggle span {
    display: block;
    width: 16px;
    height: 2px;
    background: var(--clr-text-dark);
    border-radius: 2px;
    transition: var(--transition);
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

/* Mobile Slide-Out Drawer Navigation (Strictly hidden until toggled) */
.nav-list {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    max-width: 80%;
    height: 100vh;
    background: var(--bg-canvas);
    border-left: 1px solid var(--border-light);
    padding: 20px 18px 30px;
    z-index: 1001;
    display: block;
    overflow-y: auto;
    box-shadow: -8px 0 25px rgba(0, 0, 0, 0.25);
    transform: translateX(100%);
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, visibility 0.3s;
}

@media (min-width: 481px) {
    .nav-list {
        right: calc(50% - var(--mobile-width) / 2);
    }
}

.nav-list.active {
    transform: translateX(0);
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

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

.nav-drawer-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--clr-text-dark);
}

.nav-drawer-title i {
    color: var(--clr-amber);
    font-size: 0.9rem;
}

.nav-close-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    color: var(--clr-text-dark);
    font-size: 0.95rem;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    transition: var(--transition-fast);
}

.nav-close-btn:hover, .nav-close-btn:active {
    background: var(--bg-espresso);
    color: #FFFFFF;
    transform: rotate(90deg);
}

.nav-list ul {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-list ul li a {
    display: block;
    padding: 12px 16px;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--clr-text-dark);
    border-radius: var(--radius-md);
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    transition: var(--transition-fast);
}

.nav-list ul li a:hover, .nav-list ul li a:active {
    background: var(--bg-espresso);
    color: #FFFFFF;
}

.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(18, 14, 12, 0.65);
    backdrop-filter: blur(6px);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* =========================================
   EDITORIAL BADGES & PILL BUTTONS
   ========================================= */
.editorial-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--clr-text-dark);
    background: #FFFFFF;
    padding: 5px 12px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 6px rgba(28, 23, 19, 0.03);
}

.editorial-badge .badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--clr-amber);
}

.editorial-asterisk {
    color: var(--clr-amber);
    font-weight: 700;
    font-size: 0.85em;
    vertical-align: super;
}

/* Primary Amber Button */
.btn-primary, .btn-signup {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--clr-amber);
    color: #FFFFFF !important;
    font-weight: 700;
    font-size: 0.84rem;
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    box-shadow: 0 4px 14px rgba(230, 138, 34, 0.35);
    transition: var(--transition);
    text-align: center;
}

.btn-primary:active, .btn-signup:active {
    transform: scale(0.97);
}

/* Light Outline Pill */
.btn-outline-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: #FFFFFF;
    color: var(--clr-text-dark);
    font-weight: 700;
    font-size: 0.84rem;
    padding: 10px 18px;
    border-radius: var(--radius-pill);
    border: 1.5px solid var(--border-medium);
    transition: var(--transition);
    text-align: center;
}

.btn-outline-pill:active {
    background: var(--bg-espresso);
    color: #FFFFFF;
}

/* =========================================
   STICKY MOBILE BOTTOM APP BAR
   ========================================= */
.mobile-bottom-bar {
    position: fixed;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 24px);
    max-width: calc(var(--mobile-width) - 24px);
    background: rgba(28, 23, 19, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-pill);
    padding: 6px;
    z-index: 1000;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
    display: flex;
    gap: 6px;
}

.mobile-bottom-bar .btn-login {
    flex: 1;
    text-align: center;
    padding: 10px 14px;
    color: #FFFFFF;
    font-weight: 700;
    font-size: 0.82rem;
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.mobile-bottom-bar .btn-register {
    flex: 1.3;
    text-align: center;
    padding: 10px 16px;
    color: #FFFFFF;
    font-weight: 700;
    font-size: 0.82rem;
    border-radius: var(--radius-pill);
    background: var(--clr-amber);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(230, 138, 34, 0.35);
}

.mobile-bottom-bar .btn-register:active {
    transform: scale(0.97);
}

/* =========================================
   MOBILE FOOTER
   ========================================= */
#main-footer, footer {
    background: var(--bg-espresso);
    color: var(--clr-text-light);
    padding: 40px 16px 24px;
    border-top: 1px solid var(--border-dark);
}

.footer-top {
    display: flex;
    flex-direction: column;
    gap: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand img {
    max-height: 38px;
    margin-bottom: 12px;
}

.footer-desc {
    color: var(--clr-text-light-muted);
    font-size: 0.85rem;
    line-height: 1.65;
    margin-bottom: 14px;
}

.footer-badges-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.footer-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--bg-espresso-soft);
    color: var(--clr-text-light-muted);
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-badge-pill i {
    color: var(--clr-amber);
}

.footer-nav h4, .footer-contact h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-nav h4::after, .footer-contact h4::after {
    content: '';
    display: block;
    width: 16px;
    height: 2px;
    background: var(--clr-amber);
    border-radius: 2px;
}

.footer-nav ul, .footer-contact ul {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-nav ul li a {
    color: var(--clr-text-light-muted);
    font-size: 0.84rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.footer-nav ul li a:hover {
    color: var(--clr-amber);
}

.footer-contact ul li {
    color: var(--clr-text-light-muted);
    font-size: 0.84rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-contact ul li i {
    color: var(--clr-amber);
}

.footer-bottom {
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
}

.footer-bottom p {
    color: var(--clr-text-light-muted);
    font-size: 0.78rem;
}

.footer-links a {
    color: var(--clr-amber);
    font-size: 0.78rem;
    font-weight: 600;
}