/* ==========================================================================
   COMMON.CSS — Luxury Dark & Gold Online Casino Theme
   Mobile-First Architecture: High-Converting Vegas Gold & Obsidian Dark
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,500;0,600;0,700;0,800;1,400;1,500;1,600;1,700&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root, [data-theme="dark"] {
    /* Casino Brand Colors - Luxury Vegas Gold & High-Roller Obsidian */
    --color-gold: #f5b82e;
    --color-gold-bright: #ffd466;
    --color-gold-hover: #e0a320;
    --color-gold-gradient: linear-gradient(135deg, #ffd700 0%, #f5b82e 50%, #c9820c 100%);
    --color-gold-subtle: rgba(245, 184, 46, 0.12);

    --color-green-emerald: #00c853;
    --color-green-hover: #00a844;
    --color-green-subtle: rgba(0, 200, 83, 0.14);

    --color-red-ruby: #ef4444;
    --color-red-subtle: rgba(239, 68, 68, 0.14);

    --color-purple-vip: #8b5cf6;
    --color-purple-subtle: rgba(139, 92, 246, 0.14);

    /* Dark Surfaces */
    --bg-backdrop: #07080b; /* Outer backdrop on laptop/desktop */
    --bg-page: #0d0f15;     /* Mobile app background */
    --bg-card: #151822;     /* Primary card background */
    --bg-card-hover: #1c202d;
    --bg-card-elevated: #1a1e2b;
    --bg-surface-soft: #11141c;
    --bg-glass: rgba(13, 15, 21, 0.94);

    /* Text */
    --text-primary: #ffffff;
    --text-body: #c2c9d6;
    --text-muted: #7e8b9f;
    --text-light: #ffffff;
    --text-light-muted: rgba(255, 255, 255, 0.75);

    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-mid: rgba(255, 255, 255, 0.15);
    --border-gold: rgba(245, 184, 46, 0.35);
    --border-gold-glow: rgba(245, 184, 46, 0.7);
    --border-green: rgba(0, 200, 83, 0.35);

    /* Radius */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 26px;
    --radius-pill: 9999px;

    /* Shadows & Glows */
    --shadow-subtle: 0 4px 14px rgba(0, 0, 0, 0.4);
    --shadow-card: 0 10px 25px -4px rgba(0, 0, 0, 0.5), 0 4px 10px rgba(0, 0, 0, 0.3);
    --shadow-elevated: 0 16px 36px -6px rgba(0, 0, 0, 0.7);
    --shadow-gold: 0 8px 25px -2px rgba(245, 184, 46, 0.45);
    --shadow-green: 0 8px 25px -2px rgba(0, 200, 83, 0.35);

    --font-serif: 'Playfair Display', Georgia, serif;
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    --transition-fast: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-smooth: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);

    --mobile-width: 480px;
}

[data-theme="light"] {
    /* Brand Gold adapted for high contrast on light mode */
    --color-gold: #b87707;
    --color-gold-bright: #9e6400;
    --color-gold-hover: #825000;
    --color-gold-gradient: linear-gradient(135deg, #df9b15 0%, #b87707 50%, #8f5800 100%);
    --color-gold-subtle: rgba(184, 119, 7, 0.12);

    /* Luxury Light Casino Surfaces */
    --bg-backdrop: #ebe7de;
    --bg-page: #f8f6f0;
    --bg-card: #ffffff;
    --bg-card-hover: #ffffff;
    --bg-card-elevated: #ffffff;
    --bg-surface-soft: #ede8dc;
    --bg-glass: rgba(248, 246, 240, 0.96);

    /* Text */
    --text-primary: #121815;
    --text-body: #49554e;
    --text-muted: #79857e;
    --text-light: #ffffff;
    --text-light-muted: rgba(255, 255, 255, 0.85);

    /* Borders */
    --border-subtle: rgba(18, 24, 21, 0.08);
    --border-mid: rgba(18, 24, 21, 0.14);
    --border-gold: rgba(212, 139, 17, 0.32);
    --border-gold-glow: rgba(212, 139, 17, 0.6);

    /* Shadows */
    --shadow-subtle: 0 4px 14px rgba(18, 24, 21, 0.05);
    --shadow-card: 0 10px 25px -4px rgba(18, 24, 21, 0.06), 0 4px 10px rgba(18, 24, 21, 0.02);
    --shadow-elevated: 0 16px 36px -6px rgba(18, 24, 21, 0.12);
}

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

html {
    scroll-behavior: smooth;
    font-size: 15px;
    background-color: var(--bg-backdrop);
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-backdrop);
    color: var(--text-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
}

/* ==========================================================================
   Mobile-Only Wrapper (Even on Laptop, show strictly as mobile)
   ========================================================================== */
.mobile-app-wrapper {
    width: 100%;
    max-width: var(--mobile-width);
    margin: 0 auto;
    background-color: var(--bg-page);
    min-height: 100vh;
    box-shadow: 0 0 60px rgba(0, 0, 0, 0.8), 0 0 20px rgba(245, 184, 46, 0.08);
    position: relative;
    overflow-x: hidden;
    padding-top: 64px; /* Space for fixed header navbar */
    padding-bottom: 74px; /* Space for fixed bottom bar */
    border-left: 1px solid rgba(245, 184, 46, 0.15);
    border-right: 1px solid rgba(245, 184, 46, 0.15);
}

.container {
    width: 90%;
    max-width: 440px;
    margin: 0 auto;
}

body.no-scroll {
    overflow: hidden;
}

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

ul {
    list-style: none;
}

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

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: transparent;
}

/* Typography Helpers */
.font-serif {
    font-family: var(--font-serif);
}

.italic-serif {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 500;
}

/* ==========================================================================
   Fixed Mobile Header
   ========================================================================== */
.site-header,
.mobile-app-wrapper > header {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--mobile-width);
    z-index: 1000;
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    transition: var(--transition-smooth);
}

.site-header.scrolled,
.mobile-app-wrapper > header.scrolled {
    background: rgba(10, 12, 17, 0.98);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.75);
}

/* ==========================================================================
   Live Winner Ticker Bar
   ========================================================================== */
.live-ticker {
    display: flex;
    align-items: center;
    background: #0f121a;
    border-bottom: 1px solid var(--border-subtle);
    height: 36px;
    overflow: hidden;
    position: relative;
    font-size: 0.74rem;
    z-index: 900;
}

.ticker-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: var(--color-gold-gradient);
    color: #0d0f15;
    font-weight: 800;
    font-size: 0.65rem;
    padding: 0 0.7rem;
    height: 100%;
    flex-shrink: 0;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.4);
    z-index: 2;
}

.ticker-track-wrap {
    flex: 1;
    overflow: hidden;
    position: relative;
    white-space: nowrap;
}

.ticker-track {
    display: inline-flex;
    align-items: center;
    gap: 2.5rem;
    animation: tickerScroll 22s linear infinite;
    white-space: nowrap;
}

.ticker-track:hover {
    animation-play-state: paused;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--text-body);
}

.ticker-item strong {
    color: var(--color-gold);
}

.ticker-item .win-amount {
    color: var(--color-green-emerald);
    font-weight: 800;
}

@keyframes tickerScroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Shimmer & Sweep Animation on Buttons */
.btn-primary-pill,
.btn-amber-pill,
.mobile-bottom-bar .btn-register {
    position: relative;
    overflow: hidden;
}

.btn-primary-pill::after,
.btn-amber-pill::after,
.mobile-bottom-bar .btn-register::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        60deg,
        transparent 30%,
        rgba(255, 255, 255, 0.35) 50%,
        transparent 70%
    );
    transform: rotate(25deg);
    animation: buttonLightSweep 3.5s infinite;
    pointer-events: none;
}

@keyframes buttonLightSweep {
    0% { transform: translate(-100%, -100%) rotate(25deg); }
    22%, 100% { transform: translate(100%, 100%) rotate(25deg); }
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    padding: 0 1.2rem;
    gap: 0.8rem;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #ffffff;
}

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

.logo-fallback {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.logo-icon-emblem {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--color-gold-gradient);
    color: #0d0f15;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 0 14px rgba(245, 184, 46, 0.4);
}

.logo-text-wrap {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1;
    letter-spacing: -0.2px;
}

.logo-subtitle {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--color-gold);
}

.header-auth {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.btn-signup {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.52rem 1.15rem;
    background: var(--color-gold-gradient);
    color: #0d0f15;
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.4px;
    box-shadow: var(--shadow-gold);
    transition: var(--transition-fast);
}

.btn-signup i {
    font-size: 0.95rem;
}

.theme-toggle-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border-gold);
    color: var(--color-gold);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    transition: var(--transition-fast);
    box-shadow: var(--shadow-subtle);
    padding: 0;
    flex-shrink: 0;
}

.theme-toggle-btn:hover {
    transform: rotate(20deg) scale(1.08);
    background: var(--bg-card-hover);
    color: var(--color-gold-bright);
}

.btn-signup:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 25px rgba(245, 184, 46, 0.6);
}

.mobile-menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 17px;
    padding: 0;
    z-index: 1002;
    cursor: pointer;
    flex-shrink: 0;
}

.mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-gold);
    border-radius: 2px;
    transition: var(--transition-smooth);
}

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

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

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

/* Nav Drawer in Mobile (Hidden by default) */
.nav-list {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #11141e;
    border-bottom: 2px solid var(--color-gold);
    padding: 0 1.5rem;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1001;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.85);
}

.nav-list.active {
    max-height: 480px;
    padding: 1.5rem 1.5rem 2rem;
    opacity: 1;
    pointer-events: all;
}

.nav-list ul {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.nav-list a {
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
    display: block;
    padding: 0.4rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-list a:hover {
    color: var(--color-gold);
}

/* ==========================================================================
   Advertising Slots
   ========================================================================== */
.ad-wrapper {
    margin: 1.5rem auto;
}

.ad-container {
    background: var(--bg-card);
    border: 1px solid var(--border-gold);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-subtle);
    position: relative;
}

.ad-label {
    position: absolute;
    top: 5px;
    right: 7px;
    background: rgba(0, 0, 0, 0.75);
    color: var(--color-gold);
    font-size: 0.6rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    pointer-events: none;
    z-index: 2;
    border: 1px solid rgba(245, 184, 46, 0.3);
}

/* ==========================================================================
   Mobile Footer
   ========================================================================== */
footer {
    background-color: #090a0f;
    border-top: 1px solid var(--border-subtle);
    padding: 2.8rem 0 1.5rem;
    margin-top: 3.5rem;
}

.footer-brand {
    margin-bottom: 1.8rem;
}

.footer-logo {
    height: 34px;
    width: auto;
    margin-bottom: 0.8rem;
}

.footer-desc {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.6;
    margin-bottom: 1.2rem;
}

.footer-trust-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.trust-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: #151822;
    border: 1px solid var(--border-gold);
    padding: 0.3rem 0.65rem;
    border-radius: var(--radius-pill);
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--color-gold);
}

.trust-badge-pill i {
    color: var(--color-gold);
}

.footer-nav {
    margin-bottom: 1.8rem;
}

.footer-nav h4,
.footer-contact h4 {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.9rem;
}

.footer-nav ul {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-nav a {
    color: var(--text-body);
    font-size: 0.86rem;
}

.footer-nav a:hover {
    color: var(--color-gold);
}

.contact-list {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    margin-bottom: 1.8rem;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--text-body);
    font-size: 0.85rem;
}

.contact-list i {
    color: var(--color-gold);
    font-size: 1.05rem;
}

.footer-bottom {
    padding-top: 1.4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.78rem;
    color: var(--text-muted);
    text-align: center;
}

.footer-links {
    margin-top: 0.5rem;
    display: flex;
    justify-content: center;
    gap: 0.8rem;
}

.footer-links a {
    color: var(--text-muted);
}

.footer-links a:hover {
    color: var(--color-gold);
}

/* ==========================================================================
   Fixed Mobile Bottom Bar (Constrained to 480px width)
   ========================================================================== */
.mobile-bottom-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--mobile-width);
    background: rgba(13, 15, 21, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--border-gold);
    padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom, 0px));
    z-index: 999;
    box-shadow: 0 -6px 25px rgba(0, 0, 0, 0.6);
    gap: 0.75rem;
}

.mobile-bottom-bar a {
    flex: 1;
    text-align: center;
    padding: 0.72rem;
    font-size: 0.86rem;
    font-weight: 800;
    border-radius: var(--radius-pill);
    letter-spacing: 0.4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

.mobile-bottom-bar .btn-login {
    background: #171a26;
    color: #ffffff;
    border: 1px solid var(--border-gold);
}

.mobile-bottom-bar .btn-login:hover {
    background: #1f2334;
    color: var(--color-gold);
}

.mobile-bottom-bar .btn-register {
    background: var(--color-gold-gradient);
    color: #0d0f15;
    box-shadow: 0 4px 16px rgba(245, 184, 46, 0.45);
}

.mobile-bottom-bar .btn-register:hover {
    box-shadow: 0 6px 20px rgba(245, 184, 46, 0.6);
}

/* ==========================================================================
   Light Mode Theme Overrides
   ========================================================================== */
[data-theme="light"] .logo-title,
[data-theme="light"] .hero h1,
[data-theme="light"] .hero-dealer-title,
[data-theme="light"] .hero-visual-caption,
[data-theme="light"] .section-title,
[data-theme="light"] .game-info h3,
[data-theme="light"] .feature-text h3,
[data-theme="light"] .bonus-card h3,
[data-theme="light"] .step-body-mobile h4,
[data-theme="light"] .author-info h5,
[data-theme="light"] .news-body h3,
[data-theme="light"] .faq-question,
[data-theme="light"] .hero-trust-item,
[data-theme="light"] .showcase-title,
[data-theme="light"] .showcase-verified,
[data-theme="light"] .footer-nav h4,
[data-theme="light"] .footer-contact h4,
[data-theme="light"] .nav-list a,
[data-theme="light"] .landing-title,
[data-theme="light"] .landing-content h2,
[data-theme="light"] .landing-content h3,
[data-theme="light"] .card-body h3,
[data-theme="light"] .card-body h3 a {
    color: var(--text-primary);
}

[data-theme="light"] .hero-visual-card {
    background: linear-gradient(160deg, #ede8ff 0%, #f5f2ff 100%);
    box-shadow: 0 16px 36px -6px rgba(124, 104, 238, 0.15);
    border-color: rgba(124, 104, 238, 0.25);
}

[data-theme="light"] .hero-visual-illustration {
    background: radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.9) 0%, rgba(236, 232, 255, 0.7) 70%);
    border-color: rgba(124, 104, 238, 0.2);
}

[data-theme="light"] .floating-pill {
    background: #ffffff;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .nav-list {
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .nav-list a {
    border-bottom: 1px solid rgba(18, 24, 21, 0.06);
}

[data-theme="light"] .mobile-bottom-bar .btn-login {
    background: #ffffff;
    color: var(--text-primary);
}

[data-theme="light"] .showcase-stat-box {
    background: rgba(255, 255, 255, 0.7);
    border-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .showcase-card.card-lavender {
    background: linear-gradient(145deg, #ede8ff, #f7f5ff);
    color: var(--text-primary);
}

[data-theme="light"] .showcase-card.card-amber {
    background: linear-gradient(145deg, #fdf5ea, #fffaf3);
    color: var(--text-primary);
}

[data-theme="light"] .showcase-card.card-green {
    background: linear-gradient(145deg, #092e21, #0c1c17);
    color: #ffffff;
}

[data-theme="light"] .showcase-card.card-green .showcase-title,
[data-theme="light"] .showcase-card.card-green .showcase-verified {
    color: #ffffff !important;
}

[data-theme="light"] .forest-banner {
    background: linear-gradient(145deg, #092e21 0%, #081a14 100%);
    color: #ffffff;
}

[data-theme="light"] .forest-banner h2 {
    color: #ffffff !important;
}

[data-theme="light"] .forest-banner p {
    color: rgba(255, 255, 255, 0.85) !important;
}

[data-theme="light"] .cta-box {
    background: linear-gradient(150deg, #1f271f 0%, #101914 100%);
    color: #ffffff;
}

[data-theme="light"] .cta-content h2 {
    color: #ffffff !important;
}

[data-theme="light"] .cta-content p {
    color: rgba(255, 255, 255, 0.82) !important;
}

[data-theme="light"] footer {
    background-color: #ede9df;
}

[data-theme="light"] .trust-badge-pill,
[data-theme="light"] .article-meta,
[data-theme="light"] .hero-badge {
    background: rgba(184, 119, 7, 0.08);
    border-color: rgba(184, 119, 7, 0.28);
    color: var(--color-gold);
    box-shadow: 0 2px 8px rgba(184, 119, 7, 0.06);
}

[data-theme="light"] .trust-badge-pill i,
[data-theme="light"] .article-meta i,
[data-theme="light"] .hero-badge i {
    color: var(--color-gold);
}
