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

:root {
    --bg-dark: #0a0407;
    --bg-card: rgba(26, 11, 20, 0.75);
    --bg-card-hover: rgba(38, 16, 29, 0.85);
    --wine-dark: #1b060d;
    --wine-primary: #8b1225;
    --wine-glow: #d91c38;
    --gold-primary: #f4c465;
    --gold-light: #fff2d4;
    --gold-dark: #b88628;
    --gold-gradient: linear-gradient(135deg, #fff2cf 0%, #f4c465 50%, #b88628 100%);
    --gold-glow: rgba(244, 196, 101, 0.35);
    --text-main: #fceee6;
    --text-muted: #bda8a0;
    --border-glass: rgba(244, 196, 101, 0.22);
    --border-glass-light: rgba(255, 255, 255, 0.1);
    --shadow-luxury: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 35px rgba(139, 18, 37, 0.3);
    --safe-area-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }
a, button, input, select, textarea {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}
html { 
    background-color: var(--bg-dark);
    scroll-behavior: smooth;
}

body { 
    margin: 0; 
    color: var(--text-main); 
    background: radial-gradient(circle at 50% 0%, #2b0813 0%, #0a0407 70%);
    font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; 
    font-feature-settings: "kern" 1, "liga" 1;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Background Canvas Particles */
#bg-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
    opacity: 0.6;
}

#confetti-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 9999;
}

header, main, footer { position: relative; z-index: 1; }

a { color: inherit; text-decoration: none; transition: all 0.25s ease; }
button, input, select { font: inherit; }

/* Ticker Announcement Bar */
.ticker-bar {
    background: linear-gradient(90deg, #1b0710, #360b17, #1b0710);
    border-bottom: 1px solid rgba(244, 196, 101, 0.2);
    padding: 7px 0;
    font-size: 13px;
    font-weight: 600;
    overflow: hidden;
    position: relative;
    z-index: 10;
}
.ticker-wrapper {
    display: flex;
    white-space: nowrap;
    animation: ticker 30s linear infinite;
}
.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-right: 40px;
    color: var(--gold-light);
}
.ticker-badge {
    background: var(--gold-gradient);
    color: #110408;
    font-size: 10px;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 99px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
@keyframes ticker {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Header & Navigation */
.site-header { 
    height: 80px; 
    padding: 0 clamp(20px, 6vw, 100px); 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    color: #fff; 
    background: rgba(15, 5, 10, 0.75); 
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-glass); 
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.brand { 
    display: inline-flex; 
    align-items: center; 
    gap: 12px; 
    font-family: "Cinzel", serif;
    font-weight: 800; 
    font-size: 18px; 
    letter-spacing: .08em; 
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 20px var(--gold-glow);
}
.brand-mark { 
    width: 42px; 
    height: 42px; 
    display: grid; 
    place-items: center; 
    border: 2px solid var(--gold-primary); 
    border-radius: 50%; 
    color: var(--gold-primary);
    -webkit-text-fill-color: initial;
    font-family: "Cinzel", serif; 
    font-size: 22px; 
    font-weight: 900; 
    background: radial-gradient(circle, rgba(244, 196, 101, 0.2) 0%, transparent 70%);
    box-shadow: 0 0 15px var(--gold-glow), inset 0 0 10px var(--gold-glow);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.brand:hover .brand-mark {
    transform: rotate(360deg) scale(1.08);
    box-shadow: 0 0 25px rgba(244, 196, 101, 0.6), inset 0 0 15px rgba(244, 196, 101, 0.4);
}
.site-nav { 
    display: flex; 
    align-items: center; 
    gap: 26px; 
    font-size: 14px; 
    font-weight: 700; 
}
.site-nav a { 
    color: var(--text-muted); 
    position: relative;
    padding: 6px 0;
}
.site-nav a:hover, .site-nav a.active { 
    color: var(--gold-light); 
}
.site-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gold-gradient);
    transition: all 0.3s ease;
    transform: translateX(-50%);
    box-shadow: 0 0 8px var(--gold-primary);
}
.site-nav a:hover::after, .site-nav a.active::after {
    width: 100%;
}
.site-nav form { margin: 0; }
.nav-button { 
    padding: 8px 16px; 
    border: 1px solid rgba(244, 196, 101, 0.3); 
    border-radius: 99px;
    color: var(--gold-light); 
    background: rgba(244, 196, 101, 0.08); 
    cursor: pointer; 
    font-weight: 700; 
    transition: all 0.3s ease;
}
.nav-button:hover {
    background: rgba(244, 196, 101, 0.2);
    border-color: var(--gold-primary);
    box-shadow: 0 0 15px var(--gold-glow);
}
.nav-login { 
    padding: 10px 32px !important; 
    font-size: 15px !important;
    line-height: 1.3 !important;
    background: var(--gold-gradient) !important;
    color: #0f0508 !important;
    border-radius: 99px !important; 
    font-weight: 800 !important;
    letter-spacing: 0.05em;
    white-space: nowrap !important;
    box-shadow: 0 0 24px var(--gold-glow) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: auto !important;
    min-height: 44px !important;
}
.nav-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 28px rgba(244, 196, 101, 0.7) !important;
}
.nav-login::after { display: none !important; }



/* Mobile Navigation Drawer & Hamburger Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 42px;
    height: 42px;
    padding: 11px 9px;
    background: rgba(244, 196, 101, 0.08);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    cursor: pointer;
    z-index: 110;
    transition: all 0.3s ease;
}
.mobile-menu-toggle:active {
    transform: scale(0.92);
}
.hamburger-bar {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--gold-primary);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.mobile-menu-toggle.active .hamburger-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.mobile-menu-toggle.active .hamburger-bar:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.mobile-menu-toggle.active .hamburger-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.mobile-drawer-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(5, 2, 4, 0.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}
.mobile-drawer-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}
.mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: min(320px, 85vw);
    height: 100vh;
    background: rgba(18, 6, 13, 0.95);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-left: 1px solid var(--border-glass);
    z-index: 999;
    display: flex;
    flex-direction: column;
    padding: 24px 20px;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -15px 0 50px rgba(0, 0, 0, 0.9);
}
.mobile-drawer.open {
    transform: translateX(0);
}
.mobile-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-glass-light);
}
.mobile-drawer-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border-glass);
    background: rgba(244, 196, 101, 0.1);
    color: var(--gold-primary);
    font-size: 24px;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: transform 0.2s ease;
}
.mobile-drawer-close:active {
    transform: scale(0.9);
}
.mobile-drawer-nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 24px;
}
.mobile-drawer-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 14px;
    color: var(--text-main);
    font-weight: 700;
    font-size: 15px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid transparent;
    transition: all 0.25s ease;
}
.mobile-drawer-nav a.active, .mobile-drawer-nav a:hover {
    color: var(--gold-light);
    background: rgba(244, 196, 101, 0.12);
    border-color: var(--border-glass);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}
.drawer-icon {
    font-size: 18px;
}
.mobile-drawer-cta {
    margin-top: 10px;
    background: var(--gold-gradient) !important;
    color: #0f0508 !important;
    font-weight: 800 !important;
    justify-content: center;
    box-shadow: 0 4px 20px var(--gold-glow);
}
.mobile-drawer-logout {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(151, 28, 38, 0.3);
    border: 1px solid rgba(255, 118, 132, 0.35);
    color: #ff7684;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background 0.3s ease;
}
.mobile-drawer-logout:active {
    background: rgba(151, 28, 38, 0.5);
}

/* Mobile Bottom Navigation Fixed Dock */
.mobile-bottom-dock {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(64px + var(--safe-area-bottom));
    padding-bottom: var(--safe-area-bottom);
    background: rgba(10, 4, 7, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-glass);
    z-index: 950;
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.8);
    justify-content: space-around;
    align-items: center;
}
.dock-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 700;
    width: 33%;
    height: 100%;
    transition: all 0.25s ease;
}
.dock-item svg {
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275), stroke 0.25s ease;
}
.dock-item.active {
    color: var(--gold-primary);
}
.dock-item.active svg {
    stroke: var(--gold-primary);
    transform: translateY(-2px) scale(1.18);
    filter: drop-shadow(0 0 10px var(--gold-glow));
}
.dock-item:active {
    transform: scale(0.92);
}

/* Admin Base Styling */

.admin-body { 
    background: #090306; 
}
.admin-header { 
    min-height: 80px; 
    padding: 0 clamp(20px, 6vw, 100px); 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    color: #fff; 
    background: rgba(18, 6, 13, 0.9); 
    border-bottom: 2px solid var(--gold-primary); 
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
}

/* Flash Alerts */
.flash { 
    width: min(1100px, calc(100% - 40px)); 
    margin: 24px auto -10px; 
    padding: 16px 20px; 
    border-radius: 12px; 
    font-weight: 700; 
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    gap: 12px;
}
.flash-success { 
    color: #55f3a0; 
    background: rgba(19, 92, 49, 0.35); 
    border: 1px solid rgba(85, 243, 160, 0.4); 
}
.flash-error { 
    color: #ff7684; 
    background: rgba(151, 28, 38, 0.35); 
    border: 1px solid rgba(255, 118, 132, 0.4); 
}

/* Hero Section */
.hero { 
    min-height: 400px; 
    padding: 85px clamp(20px, 10vw, 160px) 110px; 
    position: relative; 
    overflow: hidden; 
    color: #fff; 
    text-align: center;
    background: radial-gradient(circle at 50% 30%, rgba(139, 18, 37, 0.45) 0%, transparent 65%),
                radial-gradient(circle at 80% 10%, rgba(244, 196, 101, 0.15) 0%, transparent 40%);
}
.hero::after { 
    content: "🎰"; 
    position: absolute; 
    right: 5%; 
    top: 50%; 
    transform: translateY(-50%);
    color: rgba(255,255,255,.03); 
    font-size: 320px; 
    pointer-events: none;
}
.eyebrow { 
    margin: 0 0 14px; 
    color: var(--gold-primary); 
    font-size: 13px; 
    font-weight: 800; 
    letter-spacing: .2em; 
    text-transform: uppercase;
    text-shadow: 0 0 12px var(--gold-glow);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.hero h1 { 
    position: relative; 
    z-index: 1; 
    max-width: 900px; 
    margin: 0 auto; 
    font-family: "Outfit", "Plus Jakarta Sans", sans-serif; 
    font-size: clamp(38px, 5.5vw, 72px); 
    font-weight: 900; 
    line-height: 1.15; 
    letter-spacing: -.03em; 
}
.hero h1 em { 
    font-style: normal;
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 25px var(--gold-glow));
}
.hero-copy { 
    position: relative; 
    z-index: 1; 
    max-width: 580px; 
    margin: 20px auto 0; 
    color: var(--text-muted); 
    font-size: 17px; 
    line-height: 1.6; 
}

/* Lucky Wheel Canvas Container */
.lucky-wheel-container {
    position: relative;
    width: 320px;
    height: 320px;
    margin: 30px auto 10px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.wheel-glow-ring {
    position: absolute;
    width: 340px;
    height: 340px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(244, 196, 101, 0.2) 0%, rgba(139, 18, 37, 0.4) 60%, transparent 100%);
    box-shadow: 0 0 50px rgba(244, 196, 101, 0.4), inset 0 0 30px rgba(244, 196, 101, 0.3);
    animation: ring-pulse 3s ease-in-out infinite alternate;
}
@keyframes ring-pulse {
    0% { transform: scale(0.98); opacity: 0.7; }
    100% { transform: scale(1.03); opacity: 1; }
}
canvas#luckyWheel {
    position: relative;
    z-index: 2;
    border-radius: 50%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
    transition: transform 5s cubic-bezier(0.15, 0.9, 0.15, 1);
}
.wheel-pointer {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
    width: 0;
    height: 0;
    border-left: 16px solid transparent;
    border-right: 16px solid transparent;
    border-top: 32px solid var(--gold-primary);
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.8)) drop-shadow(0 0 10px var(--gold-primary));
}
.wheel-center-hub {
    position: absolute;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--gold-gradient);
    z-index: 4;
    display: grid;
    place-items: center;
    color: #110408;
    font-weight: 900;
    font-size: 20px;
    box-shadow: 0 0 25px rgba(0,0,0,0.8), inset 0 0 10px rgba(255,255,255,0.6);
}

/* Draw Board Section */
.draw-board { 
    width: min(1140px, calc(100% - 36px)); 
    margin: -50px auto 0; 
    position: relative; 
    z-index: 10;
    padding: clamp(28px, 4vw, 54px); 
    background: var(--bg-card); 
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-luxury); 
    border: 1px solid var(--border-glass); 
    border-radius: 24px;
}
.draw-heading { 
    display: flex; 
    justify-content: space-between; 
    gap: 28px; 
    align-items: flex-start; 
    padding-bottom: 32px; 
    border-bottom: 1px solid var(--border-glass-light); 
}
.draw-heading h2, .admin-wrap h1, .auth-card h1 { 
    margin: 0; 
    font-family: "Outfit", sans-serif; 
    font-size: clamp(28px, 4vw, 46px); 
    font-weight: 800; 
    line-height: 1.2; 
    letter-spacing: -.02em; 
    color: #fff;
}
.draw-date {
    color: var(--text-muted);
    font-size: 15px;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Neon Digital Flip Clock */
.countdown-box {
    display: inline-flex;
    gap: 10px;
    margin-top: 14px;
}
.countdown-segment {
    background: rgba(10, 4, 7, 0.8);
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    padding: 8px 12px;
    text-align: center;
    min-width: 60px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}
.countdown-num {
    font-family: "Outfit", monospace;
    font-size: 24px;
    font-weight: 800;
    color: var(--gold-primary);
    text-shadow: 0 0 10px var(--gold-glow);
    display: block;
}
.countdown-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
}

.draw-seal { 
    width: 85px; 
    height: 85px; 
    display: grid; 
    place-items: center; 
    border: 2px dashed var(--gold-primary); 
    border-radius: 50%; 
    color: var(--gold-primary); 
    font-family: "Cinzel", serif; 
    font-weight: 900; 
    font-size: 13px;
    line-height: 1.1; 
    text-align: center; 
    transform: rotate(-10deg); 
    background: rgba(244, 196, 101, 0.08);
    box-shadow: 0 0 20px var(--gold-glow);
    animation: seal-rotate 12s linear infinite;
}
@keyframes seal-rotate {
    0% { transform: rotate(-10deg); }
    50% { transform: rotate(10deg); }
    100% { transform: rotate(-10deg); }
}

/* Prize Cards Grid & Pyramid Tree */
.prize-grid, .prize-pyramid-tree { 
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin: 36px 0;
    width: 100%;
}

.pyramid-row {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 20px;
    width: 100%;
    flex-wrap: wrap;
}

.pyramid-row .prize-card {
    flex: 1 1 280px;
    max-width: 480px;
    margin: 0;
}

/* Apex Level (Đỉnh cây thông - Giải Đặc Biệt) */
.pyramid-row.row-apex .prize-card {
    flex: 0 1 min(520px, 100%);
    max-width: 520px;
    border: 2px solid var(--gold-primary);
    background: linear-gradient(135deg, rgba(40, 10, 22, 0.95), rgba(18, 5, 12, 0.95));
    box-shadow: 0 0 30px var(--gold-glow), inset 0 0 20px rgba(244, 196, 101, 0.2);
}

.pyramid-row.row-apex .prize-card p {
    color: #ff4d6d;
    font-size: 20px;
    font-weight: 900;
    text-shadow: 0 0 15px rgba(255, 77, 109, 0.5);
    letter-spacing: 0.08em;
}

.pyramid-row.row-apex .prize-card .slot-digit {
    font-size: 32px;
    border-color: rgba(244, 196, 101, 0.5);
    box-shadow: 0 0 15px rgba(244, 196, 101, 0.3);
}

.prize-card { 
    padding: 30px 20px 26px; 
    text-align: center; 
    background: rgba(18, 6, 13, 0.7); 
    border: 1px solid var(--border-glass-light); 
    border-radius: 18px; 
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
}
.prize-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--border-glass), transparent);
    transition: all 0.4s ease;
}
.prize-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: var(--border-glass);
    box-shadow: 0 15px 35px rgba(0,0,0,0.6), 0 0 20px var(--gold-glow);
    background: var(--bg-card-hover);
}
.prize-card:hover::before {
    background: var(--gold-gradient);
    box-shadow: 0 0 15px var(--gold-primary);
}
.prize-card p { 
    margin: 0 0 12px; 
    color: var(--gold-primary); 
    font-size: 13px; 
    font-weight: 800; 
    letter-spacing: .12em; 
    text-transform: uppercase; 
}

/* Slot Machine Digit Reel Animation */
.slot-number-reel {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    min-height: 60px;
    margin: 10px 0;
}
.slot-digit {
    width: 44px;
    height: 56px;
    background: #090306;
    border: 1px solid var(--border-glass);
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-family: "Outfit", monospace;
    font-size: 32px;
    font-weight: 900;
    color: var(--gold-light);
    box-shadow: inset 0 0 15px rgba(0,0,0,0.9), 0 4px 10px rgba(0,0,0,0.5);
    overflow: hidden;
    position: relative;
}
.slot-digit.spinning {
    animation: digit-blur 0.15s linear infinite;
    color: var(--gold-primary);
    filter: blur(1px);
}
@keyframes digit-blur {
    0% { transform: translateY(-4px); }
    50% { transform: translateY(4px); }
    100% { transform: translateY(-4px); }
}

.prize-card strong { 
    display: block; 
    min-height: 56px; 
    color: var(--gold-light); 
    font-family: "Outfit", sans-serif; 
    font-size: clamp(32px, 4vw, 46px); 
    font-weight: 900; 
    letter-spacing: .08em; 
    text-shadow: 0 0 20px var(--gold-glow);
}
.prize-card span { 
    color: var(--text-muted); 
    font-size: 13px; 
    font-weight: 700; 
}

.prize-card.revealed { 
    background: radial-gradient(circle at 50% 0%, rgba(139, 18, 37, 0.8) 0%, rgba(20, 6, 14, 0.9) 100%); 
    border-color: var(--gold-primary); 
    box-shadow: 0 15px 40px rgba(139, 18, 37, 0.5), 0 0 30px var(--gold-glow); 
    animation: card-reveal-glow 0.8s ease-out both;
}
@keyframes card-reveal-glow {
    0% { transform: scale(0.9) translateY(10px); opacity: 0; }
    50% { transform: scale(1.05); }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}
.prize-card.revealed p { color: var(--gold-light); }
.prize-card.revealed span { color: #55f3a0; font-weight: 800; }

.draw-actions { 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    flex-direction: column;
    gap: 16px; 
    padding-top: 16px; 
}
.draw-actions p { 
    margin: 0; 
    color: var(--text-muted); 
    font-size: 15px; 
    text-align: center;
}

/* Luxury Buttons */
.draw-button { 
    display: inline-flex; 
    justify-content: center; 
    align-items: center; 
    gap: 10px;
    min-height: 52px; 
    padding: 0 32px; 
    border: 0; 
    border-radius: 99px; 
    color: #0f0508; 
    background: var(--gold-gradient); 
    box-shadow: 0 8px 25px var(--gold-glow), 0 0 15px rgba(244, 196, 101, 0.4); 
    cursor: pointer; 
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 15px; 
    font-weight: 800; 
    letter-spacing: .04em; 
    transition: all 0.3s ease; 
}
.draw-button:hover { 
    transform: translateY(-3px) scale(1.02); 
    box-shadow: 0 12px 35px rgba(244, 196, 101, 0.7), 0 0 25px var(--gold-primary); 
}
.draw-button:disabled { 
    opacity: .6; 
    cursor: not-allowed; 
    transform: none; 
}

/* Trust Section */
.trust-row { 
    width: min(950px, calc(100% - 40px)); 
    margin: 64px auto; 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 24px; 
}
.trust-row div { 
    display: flex; 
    align-items: center; 
    gap: 16px; 
    padding: 20px 24px;
    background: rgba(22, 10, 18, 0.5);
    border: 1px solid var(--border-glass-light);
    border-radius: 16px;
    backdrop-filter: blur(10px);
}
.trust-row b { 
    color: var(--gold-primary); 
    font-family: "Outfit", sans-serif; 
    font-size: 32px; 
    font-weight: 900; 
    text-shadow: 0 0 15px var(--gold-glow);
}
.trust-row span { 
    color: var(--text-main); 
    font-size: 13px; 
    font-weight: 800; 
    text-transform: uppercase; 
    letter-spacing: .06em; 
}

/* Empty State */
.empty-state { 
    width: min(760px, calc(100% - 40px)); 
    margin: -40px auto 60px; 
    position: relative; 
    z-index: 10;
    padding: 64px 40px; 
    text-align: center; 
    background: var(--bg-card); 
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 24px;
    box-shadow: var(--shadow-luxury); 
}
.empty-symbol { 
    color: var(--gold-primary); 
    font-size: 54px; 
    filter: drop-shadow(0 0 20px var(--gold-glow));
}
.empty-state h2 { 
    margin: 12px 0; 
    font-family: "Outfit", sans-serif; 
    font-size: 34px; 
    font-weight: 800; 
}
.empty-state p { 
    margin: 0 auto 30px; 
    max-width: 480px; 
    color: var(--text-muted); 
    line-height: 1.6; 
}

/* Latest Results Section */
.latest-results { 
    width: min(1140px, calc(100% - 36px)); 
    margin: 50px auto 70px; 
    padding: clamp(28px, 4vw, 44px); 
    border: 1px solid var(--border-glass); 
    border-radius: 24px;
    background: var(--bg-card); 
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-luxury);
}
.latest-results-heading { 
    display: flex; 
    align-items: flex-end; 
    justify-content: space-between; 
    gap: 24px; 
    padding-bottom: 24px; 
    border-bottom: 1px solid var(--border-glass-light); 
}
.latest-results-heading h2 { 
    margin: 0; 
    font-size: clamp(24px, 3vw, 36px); 
    font-weight: 800; 
    letter-spacing: -.02em; 
    color: #fff;
}
.latest-results-heading p:not(.eyebrow) { 
    margin: 8px 0 0; 
    color: var(--text-muted); 
    font-size: 14px; 
}
.latest-results-heading a { 
    color: var(--gold-primary); 
    font-size: 14px; 
    font-weight: 800; 
    white-space: nowrap; 
}
.latest-results-heading a:hover {
    text-shadow: 0 0 10px var(--gold-glow);
}
.latest-result-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); 
    gap: 16px; 
    padding-top: 26px; 
}
.latest-result-grid div { 
    padding: 20px 16px; 
    text-align: center; 
    border: 1px solid var(--border-glass-light); 
    background: rgba(14, 5, 10, 0.6); 
    border-radius: 14px;
    transition: all 0.3s ease;
}
.latest-result-grid div:hover {
    border-color: var(--border-glass);
    transform: translateY(-3px);
    background: rgba(28, 10, 20, 0.8);
}
.latest-result-grid span { 
    display: block; 
    margin-bottom: 8px; 
    color: var(--gold-primary); 
    font-size: 12px; 
    font-weight: 800; 
    letter-spacing: .08em; 
    text-transform: uppercase; 
}
.latest-result-grid b { 
    color: #fff; 
    font-family: "Outfit", monospace;
    font-size: 26px; 
    font-weight: 900; 
    letter-spacing: 0.05em;
}

/* Auth Cards */
.auth-wrap { 
    min-height: calc(100vh - 150px); 
    padding: 70px 20px; 
    display: flex;
    align-items: center;
    justify-content: center;
}
.auth-card { 
    width: min(480px, 100%); 
    padding: 44px 38px; 
    background: var(--bg-card); 
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: var(--shadow-luxury); 
    border: 1px solid var(--border-glass); 
    border-radius: 24px;
}
.auth-card h1 { font-size: 38px; }
.auth-card label, .admin-form > label, .draw-timing-fields > label { 
    display: grid; 
    gap: 8px; 
    margin-top: 22px; 
    color: var(--text-main); 
    font-size: 13px; 
    font-weight: 800; 
}
input { 
    width: 100%; 
    min-height: 48px; 
    padding: 12px 16px; 
    outline: 0; 
    border: 1px solid var(--border-glass-light); 
    border-radius: 12px; 
    color: #fff; 
    background: rgba(10, 4, 7, 0.7); 
    font-size: 14px;
    transition: all 0.3s ease;
}
input:focus { 
    border-color: var(--gold-primary); 
    box-shadow: 0 0 15px var(--gold-glow); 
    background: rgba(18, 6, 13, 0.9);
}
.auth-card .draw-button { 
    width: 100%; 
    margin-top: 28px; 
}
.check-label { 
    display: flex !important; 
    align-items: center; 
    grid-template-columns: auto 1fr; 
    gap: 10px !important; 
    font-weight: 600 !important; 
    cursor: pointer;
}
.check-label input { 
    width: 18px; 
    min-height: 18px; 
    accent-color: var(--gold-primary);
}
.field-error { color: #ff7684; font-weight: 600; }

/* Admin & History General Wrap */
.admin-wrap { 
    width: min(1140px, calc(100% - 36px)); 
    margin: 50px auto; 
    position: relative;
    z-index: 5;
}
.admin-topline { 
    display: flex; 
    align-items: flex-end; 
    justify-content: space-between; 
    gap: 30px; 
    margin-bottom: 36px; 
}
/* Search Form */
.search-form {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 28px 0;
    max-width: 580px;
}
.search-form input {
    flex: 1;
    min-height: 48px;
    margin: 0 !important;
}
.search-form .secondary-button {
    white-space: nowrap;
    min-height: 48px;
    padding: 0 24px;
    flex-shrink: 0;
}

.admin-table-wrap { 
    overflow-x: auto; 
    border: 1px solid var(--border-glass); 
    border-radius: 18px;
    background: var(--bg-card); 
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-luxury);
    margin-top: 20px;
}

.admin-table { 
    width: 100%; 
    border-collapse: collapse; 
    font-size: 14px; 
}
.admin-table th { 
    padding: 18px 20px; 
    color: var(--gold-primary); 
    background: rgba(12, 4, 8, 0.8); 
    font-size: 12px; 
    letter-spacing: .08em; 
    text-align: left; 
    text-transform: uppercase; 
    font-weight: 800;
}
.admin-table td { 
    padding: 20px; 
    border-top: 1px solid var(--border-glass-light); 
    white-space: nowrap; 
    color: var(--text-main);
}
.status { 
    padding: 6px 12px; 
    border-radius: 99px; 
    font-size: 12px; 
    font-weight: 800; 
}
.status-draft { color: #f4c465; background: rgba(244, 196, 101, 0.15); border: 1px solid rgba(244, 196, 101, 0.3); }
.status-published { color: #55f3a0; background: rgba(85, 243, 160, 0.15); border: 1px solid rgba(85, 243, 160, 0.3); }

.table-actions { display: flex; align-items: center; gap: 14px; }
.table-actions a, .table-actions button { 
    border: 0; 
    color: var(--gold-primary); 
    background: transparent; 
    cursor: pointer; 
    font-size: 13px; 
    font-weight: 800; 
}
.table-actions form { margin: 0; }
.no-data { padding: 40px !important; color: var(--text-muted); text-align: center; }

.history-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border: 1px solid var(--gold-primary);
    border-radius: 99px;
    color: #0f0508 !important;
    background: var(--gold-gradient);
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 4px 18px var(--gold-glow);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.history-button:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 6px 25px rgba(244, 196, 101, 0.6);
    color: #000000 !important;
}

/* History Cards */

.history-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 18px;
    padding: 28px;
    margin-bottom: 20px;
    backdrop-filter: blur(16px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: all 0.3s ease;
}
.history-card:hover {
    transform: translateY(-3px);
    border-color: var(--gold-primary);
    box-shadow: 0 15px 35px rgba(0,0,0,0.7), 0 0 20px var(--gold-glow);
}
.history-results {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}
.history-results span {
    background: rgba(10, 4, 7, 0.8);
    border: 1px solid var(--border-glass-light);
    border-radius: 12px;
    padding: 10px 16px;
    font-family: "Outfit", monospace;
    font-size: 18px;
    font-weight: 800;
    color: var(--gold-light);
}
.history-results span b {
    display: block;
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 10px;
    color: var(--gold-primary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 2px;
}

/* Traditional Lottery Table (Bảng Kết Quả Xổ Số) */
.lottery-table-wrap {
    width: 100%;
    margin-top: 16px;
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    overflow: hidden;
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-luxury);
}

.lottery-table {
    width: 100%;
    border-collapse: collapse;
    font-family: "Outfit", "Plus Jakarta Sans", sans-serif;
    text-align: center;
}

.lottery-table tr {
    border-bottom: 1px solid var(--border-glass-light);
    transition: all 0.3s ease;
}

.lottery-table tr:last-child {
    border-bottom: 0;
}

.lottery-table tr.row-spinning {
    background: rgba(244, 196, 101, 0.15) !important;
    box-shadow: inset 0 0 25px var(--gold-glow);
}

.lottery-table tr.row-spinning td.prize-label {
    background: rgba(244, 196, 101, 0.25);
    color: #ffffff;
    text-shadow: 0 0 15px var(--gold-glow);
}

.lottery-table tr.row-spinning td.prize-numbers {
    background: rgba(30, 8, 18, 0.6);
}

.lottery-table td.prize-label {
    width: 130px;
    min-width: 100px;
    padding: 14px 12px;
    background: rgba(15, 5, 10, 0.85);
    border-right: 1px solid var(--border-glass-light);
    color: var(--gold-primary);
    font-size: 15px;
    font-weight: 800;
    text-align: center;
    vertical-align: middle;
}

.lottery-table td.prize-numbers {
    padding: 14px 18px;
    vertical-align: middle;
    background: rgba(10, 4, 7, 0.5);
}

.lottery-numbers-grid {
    display: grid;
    gap: 10px 18px;
    justify-content: center;
    align-items: center;
}


.lottery-numbers-grid.count-1 { grid-template-columns: 1fr; }
.lottery-numbers-grid.count-2 { grid-template-columns: repeat(2, 1fr); }
.lottery-numbers-grid.count-3 { grid-template-columns: repeat(3, 1fr); }
.lottery-numbers-grid.count-4 { grid-template-columns: repeat(4, 1fr); }
.lottery-numbers-grid.count-5 { grid-template-columns: repeat(3, 1fr); }
.lottery-numbers-grid.count-6 { grid-template-columns: repeat(3, 1fr); }

.lottery-number-item {
    font-family: "Outfit", monospace;
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.05em;
}

.special-prize-row .lottery-number-item,
.special-prize-row td.prize-label {
    color: #ff4d6d;
    font-size: 26px;
    font-weight: 900;
    text-shadow: 0 0 14px rgba(255, 77, 109, 0.5);
}

.special-prize-row td.prize-label {
    font-size: 16px;
}

.number-group {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    margin: 4px 6px;
}

.slot-number-reel {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
}


/* Metric Cards */
.metric-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 20px; 
    margin: 32px 0; 
}
.metric-card { 
    min-height: 130px; 
    display: flex; 
    flex-direction: column; 
    justify-content: space-between; 
    padding: 24px; 
    border: 1px solid var(--border-glass); 
    border-radius: 18px;
    background: var(--bg-card); 
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}
.metric-card b { 
    color: var(--gold-primary); 
    font-family: "Outfit", sans-serif; 
    font-size: 42px; 
    font-weight: 900; 
    text-shadow: 0 0 15px var(--gold-glow);
}
.metric-card span { 
    color: var(--text-muted); 
    font-size: 12px; 
    font-weight: 800; 
    letter-spacing: .08em; 
    text-transform: uppercase; 
}

.account-list { 
    margin-top: 36px; 
    padding: 30px; 
    border: 1px solid var(--border-glass); 
    border-radius: 18px;
    background: var(--bg-card); 
    backdrop-filter: blur(16px);
}
.account-list h2 { 
    margin: 0 0 18px; 
    font-family: "Outfit", sans-serif; 
    font-size: 26px; 
    font-weight: 800; 
}
.account-draw {
    display: flex;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-glass-light);
    color: var(--text-main);
    font-weight: 700;
}
.account-draw:hover {
    color: var(--gold-primary);
    background: rgba(244, 196, 101, 0.05);
}

/* Form Styles */
.form-wrap { width: min(840px, calc(100% - 36px)); }
.back-link { 
    display: inline-flex;
    align-items: center;
    gap: 8px; 
    padding: 10px 22px;
    border: 1px solid rgba(244, 196, 101, 0.4);
    border-radius: 99px;
    color: var(--gold-light); 
    background: rgba(244, 196, 101, 0.08);
    font-size: 14px; 
    font-weight: 800;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.back-link:hover {
    background: rgba(244, 196, 101, 0.2);
    border-color: var(--gold-primary);
    color: #fff;
    transform: translateX(-3px);
    box-shadow: 0 0 18px var(--gold-glow);
}
.admin-form { 
    padding: 34px; 
    border: 1px solid var(--border-glass); 
    border-radius: 20px;
    background: var(--bg-card); 
    backdrop-filter: blur(16px);
}
.draw-timing-fields {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(230px, 0.85fr);
    gap: 16px;
    margin-top: 22px;
    align-items: start;
}
.admin-form > .draw-timing-fields > label {
    margin-top: 0;
}
.draw-timing-fields input {
    min-height: 46px;
}
.draw-timing-fields small:not(.field-error) {
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.45;
}
.draw-timing-fields input[type="datetime-local"] {
    color-scheme: dark;
    cursor: pointer;
}
.draw-timing-fields input[type="datetime-local"]::-webkit-calendar-picker-indicator {
    filter: invert(88%) sepia(30%) saturate(532%) hue-rotate(337deg) brightness(103%) contrast(92%);
    cursor: pointer;
}
.draw-timing-fields input[type="number"] {
    -moz-appearance: textfield;
}
.draw-timing-fields input[type="number"]::-webkit-inner-spin-button,
.draw-timing-fields input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.prize-form-heading { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    margin-top: 32px; 
    padding-top: 24px; 
    border-top: 1px solid var(--border-glass-light); 
}
.prize-form-heading h2 { 
    margin: 0; 
    font-size: 24px; 
    font-weight: 800; 
}
.prize-form-heading .add-prize-btn,
.prize-form-heading button#add-prize { 
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border: 1px solid var(--gold-primary); 
    border-radius: 12px;
    color: #0f0508 !important; 
    background: var(--gold-gradient); 
    cursor: pointer; 
    font-size: 14px; 
    font-weight: 800; 
    box-shadow: 0 4px 18px var(--gold-glow);
    transition: all 0.3s ease;
}
.prize-form-heading .add-prize-btn:hover,
.prize-form-heading button#add-prize:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(244, 196, 101, 0.6);
}

/* Prize Card Box Styles */
.prize-card-box {
    background: rgba(10, 4, 7, 0.6);
    border: 1px solid var(--border-glass-light);
    border-radius: 16px;
    padding: 20px;
    margin-top: 18px;
    backdrop-filter: blur(12px);
    box-shadow: inset 0 0 15px rgba(0,0,0,0.4);
    transition: all 0.2s ease;
}
.prize-card-box:hover {
    border-color: rgba(244, 196, 101, 0.4);
}
.prize-card-box.dragging {
    opacity: 0.4;
    border: 2px dashed var(--gold-primary);
    transform: scale(0.98);
}
.drag-handle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 48px;
    cursor: grab;
    color: var(--gold-primary);
    font-size: 22px;
    user-select: none;
    transition: transform 0.2s ease, color 0.2s ease;
}
.drag-handle:active {
    cursor: grabbing;
    transform: scale(1.2);
    color: #ffffff;
}

.prize-box-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
}
.prize-name-label {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    margin-top: 0 !important;
    color: var(--text-main);
    font-size: 13px;
    font-weight: 800;
}

.prize-box-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}
.btn-add-num {
    padding: 10px 18px;
    border: 1px solid rgba(244, 196, 101, 0.4);
    border-radius: 10px;
    background: rgba(244, 196, 101, 0.12);
    color: var(--gold-light);
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.btn-add-num:hover {
    background: rgba(244, 196, 101, 0.25);
    border-color: var(--gold-primary);
    box-shadow: 0 0 12px var(--gold-glow);
}
.btn-remove-prize {
    padding: 10px 16px;
    border: 1px solid rgba(255, 118, 132, 0.4);
    border-radius: 10px;
    background: rgba(151, 28, 38, 0.25);
    color: #ff7684;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.btn-remove-prize:hover {
    background: rgba(219, 48, 68, 0.4);
    border-color: #ff7684;
}
.prize-numbers-section {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px dashed var(--border-glass-light);
}
.numbers-heading {
    display: block;
    font-size: 12px;
    font-weight: 800;
    color: var(--text-muted);
    margin-bottom: 10px;
}
.numbers-inputs-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}
.num-input-group {
    display: inline-flex;
    align-items: center;
    position: relative;
    width: min(160px, 100%);
}
.num-input-group input {
    padding-right: 36px !important;
    font-family: "Outfit", monospace;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-align: center;
}
.btn-remove-num {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 118, 132, 0.25);
    color: #ff7684;
    font-size: 16px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: all 0.2s ease;
}
.btn-remove-num:hover {
    background: #ff7684;
    color: #000;
}

.form-actions { display: flex; gap: 14px; margin-top: 32px; }
.secondary-button { 
    min-height: 48px; 
    padding: 0 24px; 
    border: 1px solid var(--border-glass); 
    border-radius: 99px; 
    color: var(--gold-light); 
    background: rgba(244, 196, 101, 0.08); 
    cursor: pointer; 
    font-weight: 800; 
    transition: all 0.3s ease;
}
.secondary-button:hover {
    background: rgba(244, 196, 101, 0.2);
    border-color: var(--gold-primary);
}

/* Footer Styling */
.site-footer {
    border-top: 1px solid var(--border-glass-light);
    background: rgba(8, 3, 6, 0.95);
    padding: 45px 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 80px;
}
.site-footer p { margin: 8px 0; }
.footer-gold { color: var(--gold-primary); font-weight: 800; }

/* Comprehensive Mobile Responsive Adjustments */
@media (max-width: 768px) {
    body {
        padding-bottom: calc(64px + var(--safe-area-bottom));
    }
    
    .site-header { 
        height: 64px; 
        padding: 0 16px; 
    }
    .brand { 
        font-size: 15px; 
    }
    .brand-mark { 
        width: 36px; 
        height: 36px; 
        font-size: 18px; 
    }
    
    /* Navigation: Desktop links hidden, Mobile Toggle & Dock enabled */
    .site-nav { 
        display: none !important; 
    }
    .mobile-menu-toggle { 
        display: flex !important; 
    }
    .mobile-bottom-dock { 
        display: flex !important; 
    }

    /* Hero Section Responsive */
    .hero { 
        padding: 45px 16px 70px; 
    }
    .hero h1 { 
        font-size: clamp(26px, 7.5vw, 38px); 
        line-height: 1.2; 
    }
    .hero-copy { 
        font-size: 14px; 
        margin-top: 14px; 
        padding: 0 8px; 
    }
    
    /* Responsive Lucky Wheel */
    .lucky-wheel-container { 
        width: clamp(230px, 74vw, 290px); 
        height: clamp(230px, 74vw, 290px); 
        margin: 22px auto 10px; 
    }
    .wheel-glow-ring { 
        width: calc(100% + 16px); 
        height: calc(100% + 16px); 
    }
    canvas#luckyWheel { 
        width: 100% !important; 
        height: 100% !important; 
    }
    .wheel-center-hub { 
        width: 52px; 
        height: 52px; 
        font-size: 16px; 
    }
    .wheel-pointer { 
        top: -12px; 
        border-left-width: 12px; 
        border-right-width: 12px; 
        border-top-width: 24px; 
    }

    /* Draw Board Responsive */
    .draw-board { 
        margin-top: -24px; 
        padding: 22px 14px; 
        border-radius: 20px; 
        width: calc(100% - 24px); 
    }
    .draw-heading { 
        flex-direction: column; 
        align-items: center; 
        text-align: center; 
        gap: 14px; 
        padding-bottom: 22px; 
    }
    .draw-date { 
        justify-content: center; 
        font-size: 13px; 
    }
    .draw-seal { 
        width: 62px; 
        height: 62px; 
        font-size: 10px; 
        margin: 0 auto; 
    }

    /* Countdown Timer Segment */
    .countdown-box { 
        justify-content: center; 
        gap: 8px; 
        margin-top: 12px; 
    }
    .countdown-segment { 
        min-width: 50px; 
        padding: 6px 8px; 
        border-radius: 8px; 
    }
    .countdown-num { 
        font-size: 20px; 
    }
    .countdown-label { 
        font-size: 9px; 
    }

    /* Prize Cards Grid & Slot Machine Reel */
    .prize-grid { 
        grid-template-columns: 1fr; 
        gap: 14px; 
        margin: 24px 0; 
    }
    .prize-card { 
        padding: 20px 14px; 
        border-radius: 16px; 
    }
    .slot-number-reel { 
        gap: 5px; 
        min-height: 48px; 
    }
    .slot-digit { 
        width: 38px; 
        height: 48px; 
        font-size: 26px; 
        border-radius: 8px; 
    }
    .prize-card strong { 
        font-size: 32px; 
        min-height: 44px; 
    }

    /* Trust Section */
    .trust-row { 
        grid-template-columns: 1fr; 
        gap: 12px; 
        margin: 36px auto; 
        width: calc(100% - 24px); 
    }
    .trust-row div { 
        padding: 16px 18px; 
    }

    /* Latest Results */
    .latest-results { 
        width: calc(100% - 24px); 
        padding: 20px 14px; 
        margin: 36px auto; 
    }
    /* Hide hero section and lucky wheel on mobile to push lottery table to the top */
    .hero {
        display: none !important;
    }

    .latest-results-heading { 

        flex-direction: column; 
        align-items: flex-start; 
        gap: 12px; 
    }
    .latest-result-grid { 
        grid-template-columns: repeat(2, 1fr); 
        gap: 10px; 
        padding-top: 18px; 
    }
    .latest-result-grid div { 
        padding: 14px 10px; 
    }
    .latest-result-grid b { 
        font-size: 22px; 
    }

    /* Mobile Responsive Lottery Table Fitting */
    .lottery-table-wrap {
        margin-top: 14px !important;
        border-radius: 12px !important;
        width: 100% !important;
        overflow-x: hidden !important;
    }

    .lottery-table {
        width: 100% !important;
        table-layout: fixed !important;
    }

    .lottery-table td.prize-label {
        width: 75px !important;
        min-width: 65px !important;
        max-width: 80px !important;
        padding: 10px 4px !important;
        font-size: 12px !important;
        font-weight: 800 !important;
        line-height: 1.2 !important;
        word-break: break-word !important;
    }

    .lottery-table td.prize-numbers {
        padding: 8px 4px !important;
    }

    .lottery-numbers-grid {
        gap: 4px 4px !important;
        width: 100% !important;
    }

    .lottery-numbers-grid.count-4 {
        grid-template-columns: repeat(4, 1fr) !important;
    }

    .lottery-numbers-grid.count-3 {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .lottery-numbers-grid.count-2 {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .lottery-numbers-grid.count-1 {
        grid-template-columns: 1fr !important;
    }

    .lottery-number-item {
        font-size: clamp(12px, 3.6vw, 16px) !important;
        letter-spacing: -0.2px !important;
        padding: 2px 0 !important;
        width: 100% !important;
        text-align: center !important;
        box-sizing: border-box !important;
    }

    .slot-digit {
        width: auto !important;
        min-width: 0 !important;
        height: auto !important;
        padding: 0 !important;
        margin: 0 0.2px !important;
        font-size: clamp(12px, 3.6vw, 16px) !important;
        font-weight: 800 !important;
        display: inline-block !important;
    }

    .special-prize-row .lottery-number-item,
    .special-prize-row .slot-digit {
        font-size: clamp(16px, 4.8vw, 22px) !important;
    }


    /* Auth Cards & Input Touch Target */
    .auth-wrap { 
        padding: 30px 16px 50px; 
    }
    .auth-card { 
        padding: 28px 18px; 
        border-radius: 20px; 
    }
    .auth-card h1 { 
        font-size: 28px; 
    }
    input, select, textarea { 
        font-size: 16px !important; /* Prevents iOS Safari auto-zoom */
        min-height: 46px; 
    }
    .draw-button { 
        min-height: 48px; 
        width: 100%; 
    }
    .draw-button:active { 
        transform: scale(0.97); 
    }

    /* History & Account Pages */
    .admin-wrap { 
        width: calc(100% - 24px); 
        margin: 24px auto 40px; 
    }
    .admin-topline { 
        flex-direction: column; 
        align-items: flex-start; 
        gap: 14px; 
        margin-bottom: 24px; 
    }
    .history-card { 
        flex-direction: column; 
        align-items: flex-start; 
        gap: 14px; 
        padding: 18px 14px; 
        border-radius: 16px; 
    }
    .history-results { 
        gap: 8px; 
        width: 100%; 
    }
    .history-results span { 
        padding: 8px 12px; 
        font-size: 15px; 
        flex: 1 1 calc(50% - 8px); 
        text-align: center; 
    }

    /* Metric Cards Grid */
    .metric-grid { 
        grid-template-columns: repeat(3, 1fr); 
        gap: 8px; 
        margin: 20px 0; 
    }
    .metric-card { 
        padding: 14px 8px; 
        min-height: 90px; 
        align-items: center; 
        text-align: center; 
    }
    .metric-card b { 
        font-size: 24px; 
    }
    .metric-card span { 
        font-size: 9px; 
    }

    /* Admin Form & Tables */
    .admin-form { 
        padding: 20px 14px; 
        border-radius: 16px; 
    }
    .draw-timing-fields { 
        grid-template-columns: 1fr; 
        gap: 0; 
    }
    .draw-timing-fields > label + label { 
        margin-top: 18px; 
    }
    .prize-input-row { 
        grid-template-columns: 1fr 1fr 34px; 
        gap: 8px; 
    }

    .site-footer { 
        margin-top: 50px; 
        padding: 30px 16px; 
    }
}

/* Decorative Grand Royal Side Pillars for Chinese VIP Gaming Aesthetics */
.main-wrapper-3col {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    width: min(1520px, calc(100% - 32px));
    margin: 0 auto;
    align-items: start;
}

@media (min-width: 1280px) {
    .main-wrapper-3col {
        grid-template-columns: 250px minmax(0, 1fr) 250px;
    }
}

.side-art-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: sticky;
    top: 90px;
    height: 560px;
    user-select: none;
    pointer-events: none;
}

@media (max-width: 1279px) {
    .side-art-column {
        display: none;
    }
}

.royal-side-pillar {
    position: relative;
    width: 240px;
    height: 520px;
    background: linear-gradient(180deg, rgba(35, 10, 22, 0.8) 0%, rgba(15, 4, 10, 0.9) 50%, rgba(45, 12, 25, 0.8) 100%);
    border: 2px solid var(--gold-primary);
    border-radius: 28px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 24px 16px;
    backdrop-filter: blur(16px);
    box-shadow: 0 15px 45px rgba(0,0,0,0.7), 0 0 35px rgba(244, 196, 101, 0.3), inset 0 0 30px rgba(244, 196, 101, 0.18);
    transition: all 0.5s ease;
}

.pillar-glow-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--gold-glow) 0%, transparent 70%);
    opacity: 0.5;
    animation: ring-pulse 4s infinite alternate;
    pointer-events: none;
}

.pillar-header-badge {
    padding: 8px 18px;
    border: 1px solid var(--gold-primary);
    border-radius: 99px;
    background: linear-gradient(135deg, rgba(139, 18, 37, 0.95), rgba(20, 6, 14, 0.95));
    color: var(--gold-primary);
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.08em;
    box-shadow: 0 0 20px var(--gold-glow);
    white-space: nowrap;
    z-index: 3;
}

.pillar-center-hub {
    position: relative;
    width: 115px;
    height: 115px;
    border: 3px solid var(--gold-primary);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(184, 134, 40, 0.95) 0%, rgba(139, 18, 37, 0.95) 70%, rgba(30, 8, 18, 0.98) 100%);
    display: grid;
    place-items: center;
    text-align: center;
    color: #ffffff;
    font-family: "Outfit", serif;
    font-size: 17px;
    font-weight: 900;
    line-height: 1.25;
    box-shadow: 0 0 35px var(--gold-glow), inset 0 0 20px rgba(255, 242, 212, 0.4);
    z-index: 3;
    animation: hub-pulse 3s infinite alternate;
}

.pillar-center-hub::after {
    content: '';
    position: absolute;
    inset: -8px;
    border: 1px dashed var(--gold-primary);
    border-radius: 50%;
    animation: hub-rotate 16s linear infinite;
}

.pillar-bottom-badge {
    padding: 8px 16px;
    border-radius: 12px;
    background: rgba(10, 4, 7, 0.85);
    border: 1px solid var(--border-glass-light);
    color: var(--gold-light);
    font-size: 13px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 3;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

/* Floating Lucky Orbit Items */
.pillar-orbit {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.orbit-item {
    position: absolute;
    font-size: 28px;
    filter: drop-shadow(0 0 12px var(--gold-glow));
    animation: orbit-float 3.5s infinite ease-in-out alternate;
}

.o-1 { top: 75px; left: 16px; animation-delay: 0s; }
.o-2 { top: 110px; right: 16px; animation-delay: 0.7s; }
.o-3 { top: 230px; left: 10px; animation-delay: 1.4s; }
.o-4 { top: 270px; right: 10px; animation-delay: 2.1s; }
.o-5 { bottom: 80px; left: 18px; animation-delay: 2.8s; }
.o-6 { bottom: 60px; right: 18px; animation-delay: 3.5s; }

@keyframes orbit-float {
    0% { transform: translateY(0) scale(1) rotate(0deg); }
    100% { transform: translateY(-20px) scale(1.18) rotate(18deg); }
}

@keyframes hub-rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes hub-pulse {
    0% { transform: scale(1); box-shadow: 0 0 30px var(--gold-glow); }
    100% { transform: scale(1.06); box-shadow: 0 0 45px rgba(244, 196, 101, 0.7); }
}

/* Dynamic Live Spin Animation State */
body.is-drawing .royal-side-pillar {
    border-color: #ff4d6d;
    box-shadow: 0 0 55px rgba(255, 77, 109, 0.75), inset 0 0 30px rgba(255, 77, 109, 0.4);
    animation: live-pillar-shake 0.7s infinite alternate ease-in-out;
}

body.is-drawing .pillar-center-hub {
    border-color: #ff4d6d;
    background: radial-gradient(circle, #ff4d6d 0%, rgba(139, 18, 37, 0.95) 70%, rgba(30, 8, 18, 0.98) 100%);
    box-shadow: 0 0 50px rgba(255, 77, 109, 0.95);
}

body.is-drawing .orbit-item {
    animation-duration: 0.9s !important;
}

@keyframes live-pillar-shake {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(-10px) scale(1.04); }
}



