/* ============================================
   CASINO ONLINE INDONESIA — Mobile-Only Styles
   Concept: Universal Mobile App Frame (Desktop & Mobile)
   Max Width: 480px centered on laptop & desktop
   Theme: Dark Casino / Emerald Green & Gold
   Font: Plus Jakarta Sans + Outfit
============================================ */

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

/* ── Variables ── */
:root {
    --app-max-width:    480px;
    --primary:          #16a34a;
    --primary-hover:    #15803d;
    --primary-light:    #22c55e;
    --primary-bright:   #4ade80;
    --primary-subtle:   rgba(22, 163, 74, 0.12);
    --primary-border:   rgba(22, 163, 74, 0.25);
    --accent:           #059669;
    --accent-light:     #10b981;
    --success:          #22c55e;
    --warning:          #f59e0b;
    --danger:           #ef4444;

    /* DARK casino canvas */
    --bg-body:          #0b1120;
    --bg-white:         #111827;
    --bg-light:         #0f172a;
    --bg-subtle:        #1e293b;
    --bg-card:          #1e293b;
    --bg-card-hover:    #334155;
    --bg-dark-card:     #0f172a;

    /* Desktop Outer Backdrop */
    --desktop-bg:       #050810;
    --desktop-frame-border: rgba(22, 163, 74, 0.15);

    /* Borders */
    --border-light:     rgba(148, 163, 184, 0.15);
    --border-subtle:    rgba(148, 163, 184, 0.08);
    --border-primary:   rgba(22, 163, 74, 0.3);
    --border-green:     #22c55e;

    /* Typography — light on dark */
    --text-dark:        #f1f5f9;
    --text-body:        #cbd5e1;
    --text-muted:       #94a3b8;
    --text-subtle:      #64748b;
    --text-white:       #ffffff;
    --text-primary:     var(--primary-light);

    /* Header & Navigation */
    --header-bg:        rgba(11, 17, 32, 0.92);
    --header-border:    rgba(148, 163, 184, 0.12);
    --header-height:    60px;
    --bottom-nav-height: 62px;

    /* Shapes */
    --radius-xs:        6px;
    --radius-sm:        10px;
    --radius-md:        14px;
    --radius-lg:        20px;
    --radius-xl:        28px;
    --radius-full:      9999px;

    /* Shadows */
    --shadow-xs:        0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-soft:      0 4px 12px -2px rgba(0, 0, 0, 0.4);
    --shadow-medium:    0 8px 24px -4px rgba(0, 0, 0, 0.5);
    --shadow-strong:    0 16px 40px -6px rgba(0, 0, 0, 0.6);
    --shadow-green:     0 6px 24px -4px rgba(22, 163, 74, 0.5);

    --transition:       all 0.25s cubic-bezier(0.4, 0, 0.2, 1);

    /* Backwards compatibility */
    --bg-black:         #0f172a;
    --gold:             #16a34a;
    --gold-light:       #22c55e;
    --border-gold:      rgba(22, 163, 74, 0.25);
    --shadow-gold:      var(--shadow-green);
    --shadow-dark:      var(--shadow-medium);
}

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

html {
    overflow-x: hidden;
    scroll-behavior: smooth;
    background-color: var(--desktop-bg);
}

/* ── Mobile Container Lock on All Screens ── */
body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--desktop-bg);
    color: var(--text-body);
    line-height: 1.6;
    font-weight: 400;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    padding-top: var(--header-height, 60px);
    padding-bottom: var(--bottom-nav-height, 62px);
}

/* The Mobile Viewport Wrapper */
body > header,
body > main,
body > footer,
.ad-container,
.mobile-app-bottom-bar,
.mobile-bottom-cta {
    width: 100%;
    max-width: var(--app-max-width);
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
}

body > main {
    background-color: var(--bg-body);
    min-height: calc(100vh - var(--header-height, 60px) - var(--bottom-nav-height, 62px));
    border-left: 1px solid var(--desktop-frame-border);
    border-right: 1px solid var(--desktop-frame-border);
    box-shadow: 0 0 60px rgba(22, 163, 74, 0.08), 0 0 120px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

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

ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* ── Container ── */
.container {
    width: 92%;
    max-width: 440px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* ── Section Header ── */
.section-header {
    text-align: center;
    margin-bottom: 1.75rem;
}

.section-pill-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: var(--primary-subtle);
    border: 1px solid var(--primary-border);
    color: var(--primary-light);
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-full);
    margin-bottom: 0.75rem;
}

.section-pill-tag::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    background: var(--primary-light);
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.3);
}

.section-title {
    font-family: 'Outfit', sans-serif;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-dark);
    text-align: center;
    line-height: 1.25;
    letter-spacing: -0.02em;
    margin-bottom: 0.6rem;
}

.section-title span {
    color: var(--primary-light);
    display: inline;
}

.section-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.55;
    margin: 0 auto 1.5rem;
    padding: 0 0.5rem;
}

/* ── Ad Container ── */
.ad-container {
    padding: 0.5rem 4%;
    margin: 1rem auto;
    background: transparent;
}

.ad-container a {
    display: block;
    width: 100%;
    text-align: center;
}

.ad-container img {
    width: 100%;
    height: auto;
    max-height: 70px;
    border-radius: var(--radius-md);
    object-fit: contain;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-light);
    background: var(--bg-card);
}

/* ── News Card (Shared Mobile) ── */
.news-grid {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.news-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
}

.news-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.news-content {
    padding: 1.1rem;
    display: flex;
    flex-direction: column;
}

.news-date {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--primary-light);
    background: var(--primary-subtle);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
    display: inline-block;
    align-self: flex-start;
    margin-bottom: 0.6rem;
}

.news-content h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.4rem;
    line-height: 1.35;
}

.news-content p {
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.5;
}

/* ── MOBILE HEADER (Fixed to 480px width) ── */
body > header {
    background: var(--header-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--app-max-width);
    height: var(--header-height, 60px);
    z-index: 1000;
    border-bottom: 1px solid var(--header-border);
    border-left: 1px solid var(--desktop-frame-border);
    border-right: 1px solid var(--desktop-frame-border);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 4%;
    height: 100%;
    width: 100%;
    gap: 0.75rem;
    box-sizing: border-box;
}

.logo {
    flex: 0 0 auto;
}

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

.logo img {
    height: 36px;
    width: auto;
}

/* Nav (Drawer dropdown) */
.nav-list {
    position: fixed;
    top: var(--header-height, 60px);
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--app-max-width);
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-light);
    border-left: 1px solid var(--desktop-frame-border);
    border-right: 1px solid var(--desktop-frame-border);
    box-shadow: var(--shadow-strong);
    padding: 1.1rem 1rem;
    display: none;
    flex-direction: column;
    z-index: 999;
}

.nav-list.active {
    display: flex;
}

.nav-list ul {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: 100%;
}

.nav-list a {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-dark);
    padding: 0.6rem 0.85rem;
    border-radius: var(--radius-sm);
    display: block;
    background: var(--bg-subtle);
    border: 1px solid var(--border-light);
}

.nav-list a:hover {
    color: var(--primary-light);
    background: var(--primary-subtle);
    border-color: var(--primary-border);
}

/* Header Auth */
.header-auth {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.header-auth .btn-signup {
    background: var(--primary);
    color: var(--text-white);
    padding: 0.45rem 1rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.8rem;
    box-shadow: var(--shadow-green);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.header-auth .btn-signup:hover {
    background: var(--primary-hover);
}

/* Mobile Toggle Hamburger */
.mobile-menu-toggle {
    display: flex;
    background: var(--bg-subtle);
    border: 1px solid var(--border-light);
    cursor: pointer;
    flex-direction: column;
    gap: 4px;
    padding: 8px 9px;
    border-radius: var(--radius-sm);
}

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

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

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

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

/* ── FOOTER (Mobile Layout) ── */
body > footer {
    background: var(--bg-light);
    border-top: 1px solid var(--border-light);
    border-left: 1px solid var(--desktop-frame-border);
    border-right: 1px solid var(--desktop-frame-border);
    padding: 2.5rem 5% calc(var(--bottom-nav-height, 62px) + 2rem);
    color: var(--text-body);
}

.footer-container {
    width: 100%;
}

.footer-main {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.footer-brand .logo img {
    height: 38px;
    width: auto;
}

.footer-tagline {
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.6;
}

.footer-social {
    display: flex;
    gap: 0.6rem;
    margin-top: 0.25rem;
}

.footer-social a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    background: var(--bg-subtle);
    color: var(--text-body);
    border: 1px solid var(--border-light);
}

.footer-social a:hover {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
}

.footer-nav h4,
.footer-contact h4 {
    font-family: 'Outfit', sans-serif;
    color: var(--text-dark);
    margin-bottom: 0.7rem;
    font-size: 0.95rem;
    font-weight: 700;
}

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

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

.footer-nav a:hover {
    color: var(--primary-light);
    padding-left: 4px;
}

.footer-contact .contact-item {
    color: var(--text-muted);
    font-size: 0.86rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.6rem;
}

.footer-contact .contact-item svg {
    color: var(--primary-light);
    flex-shrink: 0;
}

.footer-bottom {
    border-top: 1px solid var(--border-light);
    padding-top: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    color: var(--text-subtle);
    font-size: 0.8rem;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

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

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

/* ── STICKY MOBILE APP BOTTOM BAR ── */
.mobile-app-bottom-bar {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--app-max-width);
    height: var(--bottom-nav-height, 62px);
    background: rgba(11, 17, 32, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--border-light);
    border-left: 1px solid var(--desktop-frame-border);
    border-right: 1px solid var(--desktop-frame-border);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.4);
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    align-items: center;
    z-index: 1000;
}

.mobile-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-subtle);
    font-size: 0.66rem;
    font-weight: 700;
    gap: 3px;
    height: 100%;
    transition: var(--transition);
}

.mobile-bottom-nav-item svg {
    width: 20px;
    height: 20px;
    stroke-width: 2.2;
}

.mobile-bottom-nav-item:hover,
.mobile-bottom-nav-item.active {
    color: var(--primary-light);
}

.mobile-bottom-nav-item.item-highlight {
    color: var(--primary-light);
}

.mobile-bottom-nav-item.item-highlight .nav-icon-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: -16px;
    box-shadow: var(--shadow-green);
    border: 3px solid var(--bg-body);
}

.mobile-bottom-nav-item.item-highlight .nav-icon-circle svg {
    width: 18px;
    height: 18px;
    stroke: #ffffff;
}

/* Hide old redundant floating banner */
.mobile-bottom-cta { display: none !important; }

/* ── Edge-to-edge on real phones ── */
@media (max-width: 480px) {
    body,
    html {
        background-color: var(--bg-body);
    }

    body > main,
    body > header,
    body > footer,
    .mobile-app-bottom-bar {
        border-left: none;
        border-right: none;
    }
}
