:root{--ink:#18202b;--muted:#687386;--red:#c6283d;--red-dark:#8f1729;--gold:#d7ad56;--cream:#fff9f2;--paper:#fff;--line:#e9e3dc;--shadow:0 18px 50px rgba(33,24,20,.12)}*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;color:var(--ink);font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;background:#f7f4f0}a{color:inherit;text-decoration:none}.container{width:min(1160px,calc(100% - 36px));margin:auto}.site-header{height:82px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;position:sticky;top:0;z-index:20}.nav,.admin-header .container{display:flex;align-items:center;justify-content:space-between}.logo{display:flex;align-items:center;gap:11px}.logo span,.brand-mark{display:grid;place-items:center;width:46px;height:46px;border-radius:50%;background:var(--red);color:#fff;font-family:serif;font-size:26px}.logo strong{font-size:13px;line-height:1.05;letter-spacing:2px}.nav nav,.admin-header nav{display:flex;gap:28px;font-weight:700;font-size:14px}.nav nav a:hover{color:var(--red)}.hero{min-height:600px;display:grid;align-items:center;position:relative;overflow:hidden;background:radial-gradient(circle at 20% 15%,rgba(198,40,61,.12),transparent 35%),linear-gradient(135deg,#fffaf5,#f4ede5)}.hero:after{content:"";position:absolute;width:460px;height:460px;border:90px solid rgba(198,40,61,.055);border-radius:50%;right:-110px;top:40px}.sakura{position:absolute;color:rgba(198,40,61,.17);font-size:180px}.sakura-a{left:-40px;bottom:-40px;transform:rotate(18deg)}.sakura-b{right:29%;top:25px;font-size:80px}.hero-grid{display:grid;grid-template-columns:1.1fr .9fr;gap:70px;align-items:center;position:relative;z-index:2}.eyebrow{font-weight:800;letter-spacing:2.3px;font-size:12px;color:var(--red);margin:0 0 14px}.hero h1{font-family:Georgia,serif;font-size:68px;line-height:1.02;margin:0 0 24px}.hero h1 span{color:var(--red)}.lead{font-size:18px;line-height:1.7;color:var(--muted);max-width:610px}.button,button{border:0;border-radius:8px;background:var(--red);color:#fff;padding:14px 22px;display:inline-block;font-weight:800;cursor:pointer;box-shadow:0 8px 20px rgba(198,40,61,.18)}button:hover,.button:hover{background:var(--red-dark)}.count-card{background:rgba(255,255,255,.9);padding:34px;border:1px solid #fff;border-radius:18px;box-shadow:var(--shadow);text-align:center;backdrop-filter:blur(8px)}.count-card>p{margin:0;color:var(--muted)}.count-card>strong{display:block;font-family:Georgia,serif;font-size:22px;margin:9px 0 24px}.count-card small{color:var(--muted)}.countdown{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:18px}.countdown div{background:var(--ink);color:#fff;padding:18px 6px;border-radius:10px}.countdown b{display:block;font-size:30px}.countdown span{font-size:11px;text-transform:uppercase;color:#cbd1da}.live-section,.history-section{padding:90px 0}.live-section{background:#fff}.section-heading{display:flex;justify-content:space-between;align-items:end;margin-bottom:30px}.section-heading h2{font:700 44px Georgia,serif;margin:0}.live-badge{background:#fdebee;color:var(--red);padding:10px 14px;border-radius:99px;font-weight:800;font-size:12px}.live-badge i{display:inline-block;width:8px;height:8px;background:var(--red);border-radius:50%;margin-right:5px;animation:pulse 1.3s infinite}.result-board{max-width:900px;margin:auto;background:linear-gradient(145deg,#202b39,#111821);color:#fff;border-radius:22px;overflow:hidden;box-shadow:0 25px 60px rgba(15,22,31,.25)}.board-top{display:flex;justify-content:space-between;padding:20px 28px;background:rgba(255,255,255,.07);font-weight:700;color:#dce1e7}.prize-list{padding:28px}.prize-row{display:grid;grid-template-columns:105px 1fr;align-items:center;gap:20px;padding:19px;border-radius:14px;margin-bottom:14px;background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.08)}.prize-row:last-child{margin:0}.medal{text-align:center;border-right:1px solid rgba(255,255,255,.14)}.medal small{display:block;color:#adb7c4;font-size:10px;letter-spacing:2px}.medal b{font:700 32px Georgia,serif;color:var(--gold)}.digits{display:grid;grid-template-columns:repeat(6,1fr);gap:10px}.digit{display:grid;place-items:center;min-width:0;aspect-ratio:1/1.08;border-radius:10px;background:linear-gradient(#fff,#eee8df);color:var(--ink);font:700 clamp(26px,4vw,48px) Georgia,serif;box-shadow:inset 0 -4px 0 rgba(0,0,0,.08)}.rank-1{background:linear-gradient(90deg,rgba(215,173,86,.18),rgba(255,255,255,.06))}.history-section{background:#f7f4f0}.history-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:20px}.history-card{background:#fff;padding:24px;border-radius:14px;border:1px solid var(--line);box-shadow:0 8px 25px rgba(35,30,25,.05)}.history-head{display:flex;justify-content:space-between;border-bottom:1px solid var(--line);padding-bottom:17px;margin-bottom:12px}.history-head small{display:block;color:var(--muted);font-size:10px;letter-spacing:1.5px}.history-head b{font-size:18px}.history-head time{text-align:right;color:var(--muted);font-size:13px}.history-prize{display:flex;justify-content:space-between;align-items:center;padding:10px 0}.history-prize span{color:var(--muted);font-size:13px}.history-prize strong{font:700 21px ui-monospace,SFMono-Regular,monospace;letter-spacing:3px}.empty-state{grid-column:1/-1;text-align:center;padding:50px;background:#fff;border-radius:14px;color:var(--muted)}footer{background:#111821;color:#c8cfd8;padding:30px 0}footer .container{display:flex;justify-content:space-between;align-items:center}footer p{font-size:13px}.auth-page{min-height:100vh;display:grid;place-items:center;background:linear-gradient(135deg,#fff8f0,#eee4db)}.auth-card{width:min(430px,calc(100% - 32px));background:#fff;padding:38px;border-radius:18px;box-shadow:var(--shadow)}.brand-mark{margin:auto}.auth-card h1{text-align:center;font:700 30px Georgia,serif}.auth-card form,.panel form{display:grid;gap:16px}label{display:grid;gap:7px;font-weight:700;font-size:13px}input,select{width:100%;padding:12px 13px;border:1px solid #d8dce2;border-radius:8px;background:#fff;font:inherit;color:var(--ink)}input:focus,select:focus{outline:2px solid rgba(198,40,61,.2);border-color:var(--red)}.notice,.error{padding:13px 15px;border-radius:8px;margin:15px 0}.notice{background:#e8f6ed;color:#267044}.error{background:#fde9ec;color:#a51f34}.back-link{display:block;text-align:center;margin-top:20px;color:var(--muted)}.admin-page{background:#f4f6f8}.admin-header{height:68px;background:#17202b;color:#fff;display:flex;align-items:center}.admin-header .logo span{width:38px;height:38px}.admin-header nav a{color:#d8dee6}.admin-main{padding:45px 0 80px}.admin-title{display:flex;justify-content:space-between;align-items:center;margin-bottom:26px}.admin-title h1{margin:0;font:700 38px Georgia,serif}.admin-title>span{color:var(--muted);font-size:13px}.admin-grid{display:grid;grid-template-columns:1fr 1.25fr;gap:22px}.panel{background:#fff;padding:26px;border-radius:13px;border:1px solid #e1e5e9;box-shadow:0 5px 20px rgba(30,40,50,.04)}.panel h2{margin-top:0;font-size:20px}.helper{color:var(--muted);font-size:13px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.form-grid.three{grid-template-columns:repeat(3,1fr)}.timezone-preview{padding:12px;background:#f4f6f8;border-radius:8px;font-size:13px}.table-panel{margin-top:22px}.table-wrap{overflow-x:auto}table{width:100%;border-collapse:collapse;font-size:13px}th,td{text-align:left;padding:13px;border-bottom:1px solid #e7eaed;white-space:nowrap}th{color:var(--muted);font-size:11px;text-transform:uppercase}.status{padding:5px 9px;border-radius:20px;font-weight:800;font-size:10px}.status.published{background:#e5f5ea;color:#247044}.status.draft{background:#fff0db;color:#9b6416}button.danger{padding:8px 11px;background:#fff;color:#b42339;border:1px solid #efc5cc;box-shadow:none}@keyframes pulse{50%{opacity:.35;transform:scale(.75)}}@media(max-width:850px){.hero{min-height:auto;padding:80px 0}.hero-grid,.admin-grid{grid-template-columns:1fr}.hero h1{font-size:52px}.history-grid{grid-template-columns:repeat(2,1fr)}.nav nav{display:none}}@media(max-width:560px){.container{width:min(100% - 24px,1160px)}.site-header{height:68px}.hero{padding:58px 0}.hero-grid{gap:36px}.hero h1{font-size:41px}.lead{font-size:15px}.count-card{padding:24px 15px}.countdown{gap:6px}.countdown div{padding:13px 3px}.countdown b{font-size:23px}.live-section,.history-section{padding:60px 0}.section-heading h2{font-size:34px}.result-board{border-radius:14px}.board-top{padding:16px;font-size:12px}.prize-list{padding:12px}.prize-row{grid-template-columns:62px 1fr;gap:8px;padding:10px}.digits{gap:4px}.digit{border-radius:6px;font-size:25px}.medal b{font-size:25px}.history-grid{grid-template-columns:1fr}.form-grid,.form-grid.three{grid-template-columns:1fr}.admin-title{align-items:start;gap:10px;flex-direction:column}footer .container{gap:18px;flex-direction:column;text-align:center}}
.logo-image {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.logo-image img {
    display: block;
    width: auto;
    height: 58px;
    max-width: 240px;
    object-fit: contain;
}

.footer-logo img {
    height: 64px;
}

@media (max-width: 768px) {
    .logo-image img {
        height: 44px;
        max-width: 180px;
    }

    .footer-logo img {
        height: 50px;
    }
}
.stage-settings-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:20px;
    margin:20px 0;
}

.stage-setting-card{
    padding:20px;
    border:1px solid rgba(0,0,0,.1);
    border-radius:16px;
    background:#fff;
}

.stage-setting-card h3{
    margin:0 0 18px;
}

.stage-setting-card label{
    display:block;
    margin-bottom:16px;
}

.stage-setting-card input{
    width:100%;
    margin-top:7px;
}

@media(max-width:850px){
    .stage-settings-grid{
        grid-template-columns:1fr;
    }
}
.prize-display{
    flex:1;
    text-align:center;
}

.prize-stage-status{
    margin-bottom:12px;
    font-size:13px;
    font-weight:800;
    letter-spacing:1.4px;
}

.prize-stage-time{
    display:block;
    margin-top:12px;
    opacity:.72;
}

.prize-row.is-waiting .prize-stage-status{
    color:#dc2626;
}

.prize-row.is-standby .prize-stage-status{
    color:#d97706;
}

.prize-row.is-rolling .prize-stage-status{
    color:#2563eb;
    animation:stagePulse .75s infinite alternate;
}

.prize-row.is-result .prize-stage-status{
    color:#16a34a;
}

.prize-row.is-rolling .digit{
    animation:numberRolling .18s infinite alternate;
}

@keyframes stagePulse{
    from{
        opacity:.45;
    }

    to{
        opacity:1;
    }
}

@keyframes numberRolling{
    from{
        transform:translateY(-2px);
        filter:blur(.5px);
    }

    to{
        transform:translateY(2px);
        filter:blur(0);
    }
}

.live-badge i{
    background:#ef4444;
    box-shadow:0 0 10px #ef4444;
}

.live-badge.live i{
    background:#22c55e;
    box-shadow:0 0 10px #22c55e;
}.stage-settings-list{
    display:grid;
    gap:12px;
    margin:24px 0;
}

.stage-dropdown{
    overflow:hidden;
    border:1px solid rgba(15,23,42,.12);
    border-radius:16px;
    background:#fff;
    box-shadow:0 8px 24px rgba(15,23,42,.05);
}

.stage-dropdown summary{
    position:relative;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:20px;
    padding:18px 50px 18px 20px;
    cursor:pointer;
    list-style:none;
    user-select:none;
}

.stage-dropdown summary::-webkit-details-marker{
    display:none;
}

.stage-dropdown summary::after{
    content:"＋";
    position:absolute;
    right:20px;
    top:50%;
    transform:translateY(-50%);
    font-size:24px;
    font-weight:700;
    line-height:1;
    transition:transform .2s ease;
}

.stage-dropdown[open] summary::after{
    content:"−";
}

.stage-dropdown summary span{
    font-size:17px;
    font-weight:800;
}

.stage-dropdown summary small{
    text-align:right;
    font-size:12px;
    font-weight:600;
    opacity:.65;
}

.stage-dropdown[open] summary{
    border-bottom:1px solid rgba(15,23,42,.1);
}

.stage-dropdown-content{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:18px;
    padding:20px;
}

.stage-dropdown-content label{
    display:block;
    margin:0;
    font-weight:700;
}

.stage-dropdown-content input{
    display:block;
    width:100%;
    box-sizing:border-box;
    margin-top:8px;
}

.stage-dropdown-content small{
    display:block;
    margin-top:7px;
    font-weight:500;
    opacity:.7;
}

@media(max-width:800px){
    .stage-dropdown summary{
        align-items:flex-start;
        flex-direction:column;
        gap:6px;
    }

    .stage-dropdown summary small{
        text-align:left;
        padding-right:10px;
    }

    .stage-dropdown-content{
        grid-template-columns:1fr;
    }
}
.history-prize.is-locked strong{
    opacity:.45;
    letter-spacing:3px;
}

.history-prize.is-locked small{
    display:block;
    margin-top:4px;
    font-size:11px;
    opacity:.65;
}

.history-prize.is-revealed strong{
    opacity:1;
}
.history-edit-form{
    display:inline-block;
    width:calc(100% - 90px);
    vertical-align:middle;
}

.history-edit-fields{
    display:grid;
    grid-template-columns:repeat(3,minmax(110px,1fr)) auto;
    align-items:center;
    gap:10px;
}

.history-edit-fields input{
    width:100%;
    min-width:0;
    box-sizing:border-box;
    padding:10px 12px;
    font-weight:700;
    letter-spacing:2px;
    text-align:center;
}

.edit-button{
    white-space:nowrap;
}

.history-delete-form{
    display:inline-block;
    margin-left:8px;
    vertical-align:middle;
}

@media(max-width:900px){
    .history-edit-form{
        display:block;
        width:100%;
    }

    .history-edit-fields{
        grid-template-columns:1fr;
    }

    .history-delete-form{
        display:block;
        margin:10px 0 0;
    }

    .history-delete-form button{
        width:100%;
    }
}
.admin-pagination{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:14px;
    margin-top:24px;
    flex-wrap:wrap;
}

.pagination-pages{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:7px;
    flex-wrap:wrap;
}

.pagination-button,
.pagination-number{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:40px;
    padding:8px 14px;
    border:1px solid rgba(15,23,42,.14);
    border-radius:10px;
    background:#fff;
    color:inherit;
    font-size:14px;
    font-weight:700;
    text-decoration:none;
    transition:
        background .2s ease,
        border-color .2s ease,
        transform .2s ease;
}

.pagination-number{
    min-width:40px;
    padding-left:10px;
    padding-right:10px;
}

.pagination-button:hover,
.pagination-number:hover{
    transform:translateY(-1px);
    border-color:rgba(15,23,42,.35);
}

.pagination-number.active{
    background:#111827;
    border-color:#111827;
    color:#fff;
    cursor:default;
}

.pagination-button.disabled{
    opacity:.4;
    cursor:not-allowed;
}

.pagination-dots{
    padding:0 3px;
    opacity:.55;
}

@media(max-width:600px){
    .admin-pagination{
        gap:10px;
    }

    .pagination-button{
        flex:1;
        min-width:110px;
    }

    .pagination-pages{
        width:100%;
        order:-1;
    }
}

.site-footer{
    margin-top:80px;
    padding:64px 0 0;
    background:#0f172a;
    color:#e5e7eb;
}

.footer-main{
    display:grid;
    grid-template-columns:minmax(260px,1.4fr) repeat(3,minmax(150px,1fr));
    gap:48px;
    align-items:start;
    padding-bottom:48px;
}

.footer-brand{
    max-width:420px;
}

.footer-logo{
    display:inline-flex;
    align-items:center;
    gap:14px;
    margin-bottom:22px;
    color:#fff;
    text-decoration:none;
}

.footer-logo img{
    display:block;
    width:auto;
    height:58px;
    max-width:180px;
    object-fit:contain;
}

.footer-logo strong{
    font-size:18px;
    line-height:1.2;
    letter-spacing:.5px;
}

.footer-brand p{
    margin:0;
    color:rgba(229,231,235,.76);
    font-size:14px;
    line-height:1.85;
}

.footer-column h3{
    margin:0 0 20px;
    color:#fff;
    font-size:15px;
    font-weight:800;
    letter-spacing:.4px;
}

.footer-links{
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    gap:13px;
}

.footer-links a{
    color:rgba(229,231,235,.74);
    font-size:14px;
    line-height:1.5;
    text-decoration:none;
    transition:
        color .2s ease,
        transform .2s ease;
}

.footer-links a:hover{
    color:#fff;
    transform:translateX(3px);
}

.footer-info{
    display:grid;
    gap:16px;
}

.footer-info p{
    display:flex;
    flex-direction:column;
    gap:4px;
    margin:0;
}

.footer-info span{
    color:rgba(229,231,235,.58);
    font-size:12px;
    line-height:1.4;
}

.footer-info strong{
    color:#fff;
    font-size:14px;
    line-height:1.5;
}

.footer-bottom{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:24px;
    min-height:72px;
    padding-top:20px;
    padding-bottom:20px;
    border-top:1px solid rgba(255,255,255,.1);
}

.footer-bottom p{
    margin:0;
    color:rgba(229,231,235,.62);
    font-size:13px;
    line-height:1.6;
}

.footer-bottom-links{
    display:flex;
    align-items:center;
    gap:20px;
}

.footer-bottom-links a{
    color:rgba(229,231,235,.7);
    font-size:13px;
    text-decoration:none;
}

.footer-bottom-links a:hover{
    color:#fff;
}

@media(max-width:1050px){
    .footer-main{
        grid-template-columns:repeat(2,minmax(0,1fr));
        gap:40px 36px;
    }

    .footer-brand{
        max-width:none;
    }
}

@media(max-width:700px){
    .site-footer{
        margin-top:56px;
        padding-top:44px;
    }

    .footer-main{
        grid-template-columns:1fr;
        gap:34px;
        padding-bottom:38px;
    }

    .footer-brand,
    .footer-column{
        width:100%;
    }

    .footer-logo{
        gap:12px;
        margin-bottom:18px;
    }

    .footer-logo img{
        height:48px;
        max-width:150px;
    }

    .footer-logo strong{
        font-size:16px;
    }

    .footer-brand p{
        font-size:14px;
        line-height:1.8;
    }

    .footer-column h3{
        margin-bottom:15px;
        font-size:14px;
    }

    .footer-links{
        gap:11px;
    }

    .footer-info{
        gap:14px;
    }

    .footer-bottom{
        align-items:flex-start;
        flex-direction:column;
        gap:12px;
        min-height:0;
        padding-top:22px;
        padding-bottom:26px;
    }

    .footer-bottom-links{
        gap:18px;
    }
}

@media(max-width:420px){
    .site-footer{
        padding-top:38px;
    }

    .footer-main{
        gap:30px;
    }

    .footer-logo{
        align-items:flex-start;
        flex-direction:column;
        gap:10px;
    }

    .footer-logo img{
        height:44px;
    }

    .footer-bottom-links{
        flex-wrap:wrap;
    }
}
.mobile-nav-toggle{
    display:none;
    position:relative;
    z-index:1002;
    flex:0 0 46px;
    width:46px;
    height:46px;
    min-width:46px;
    min-height:46px;
    padding:0;
    margin:0;
    border:1px solid rgba(15,23,42,.14);
    border-radius:12px;
    background:#ffffff !important;
    color:#0f172a !important;
    box-shadow:0 6px 18px rgba(15,23,42,.08);
    cursor:pointer;
    appearance:none;
    -webkit-appearance:none;
}

.mobile-nav-toggle:hover,
.mobile-nav-toggle:focus{
    background:#f8fafc !important;
    color:#0f172a !important;
}

.mobile-nav-toggle svg{
    position:absolute;
    top:50%;
    left:50%;
    width:24px;
    height:24px;
    transform:translate(-50%,-50%);
    fill:none;
    stroke:currentColor;
    stroke-width:2;
    stroke-linecap:round;
    stroke-linejoin:round;
}

.mobile-nav-toggle .close-icon{
    display:none;
}

.mobile-nav-toggle.is-open .menu-icon{
    display:none;
}

.mobile-nav-toggle.is-open .close-icon{
    display:block;
}

.mobile-navigation-overlay{
    position:fixed;
    inset:0;
    z-index:998;
    visibility:hidden;
    opacity:0;
    background:rgba(15,23,42,.55);
    backdrop-filter:blur(2px);
    transition:
        opacity .25s ease,
        visibility .25s ease;
}

.mobile-navigation-overlay.is-open{
    visibility:visible;
    opacity:1;
}

body.mobile-menu-open{
    overflow:hidden;
}

@media(min-width:851px){
    .mobile-navigation{
        display:flex;
        align-items:center;
        gap:24px;
    }

    .mobile-navigation a{
        color:inherit;
        text-decoration:none;
    }
}

@media(max-width:850px){
    .site-header{
        position:relative;
        z-index:1000;
    }

    .site-header .container.nav{
        display:flex;
        align-items:center;
        justify-content:space-between;
        gap:14px;
        min-height:72px;
    }

    .site-header .logo-image{
        display:flex;
        align-items:center;
        gap:10px;
        min-width:0;
    }

    .site-header .logo-image img{
        width:auto;
        height:40px;
        max-width:52px;
        object-fit:contain;
    }

    .site-header .logo-image strong{
        display:block;
        overflow:hidden;
        max-width:190px;
        color:inherit;
        font-size:14px;
        white-space:nowrap;
        text-overflow:ellipsis;
    }

    .mobile-nav-toggle{
        display:block !important;
    }

    .site-header .mobile-navigation{
        position:fixed !important;
        top:0;
        right:0;
        bottom:0;
        z-index:1001;
        display:flex !important;
        flex-direction:column;
        align-items:stretch;
        gap:0;
        width:min(86vw,360px);
        height:100dvh;
        padding:92px 24px 30px;
        margin:0;
        background:#ffffff;
        box-shadow:-20px 0 60px rgba(15,23,42,.2);
        visibility:hidden;
        opacity:0;
        transform:translateX(105%);
        transition:
            transform .28s ease,
            opacity .28s ease,
            visibility .28s ease;
        overflow-y:auto;
    }

    .site-header .mobile-navigation.is-open{
        visibility:visible;
        opacity:1;
        transform:translateX(0);
    }

    .site-header .mobile-navigation a{
        display:block;
        width:100%;
        padding:17px 4px;
        border-bottom:1px solid rgba(15,23,42,.1);
        color:#0f172a !important;
        font-size:15px;
        font-weight:700;
        line-height:1.4;
        text-align:left;
        text-decoration:none;
    }

    .site-header .mobile-navigation a:first-child{
        border-top:1px solid rgba(15,23,42,.1);
    }

    .site-header .mobile-navigation a:hover{
        color:#dc2626 !important;
    }
}

@media(max-width:420px){
    .site-header .logo-image strong{
        max-width:150px;
        font-size:13px;
    }

    .site-header .mobile-navigation{
        width:90vw;
        padding-right:20px;
        padding-left:20px;
    }
}

/* =========================================================
   GLOBAL MOBILE SAFETY
   ========================================================= */

html,
body{
    width:100%;
    max-width:100%;
    overflow-x:hidden;
}

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

img,
svg,
video{
    max-width:100%;
    height:auto;
}

.container{
    width:min(100% - 32px, 1180px);
    max-width:100%;
    margin-left:auto;
    margin-right:auto;
}

p,
h1,
h2,
h3,
h4,
h5,
h6,
a,
span,
strong,
small,
time{
    overflow-wrap:anywhere;
    word-break:normal;
}

input,
select,
textarea,
button{
    max-width:100%;
}

/* =========================================================
   MOBILE HEADER
   ========================================================= */

@media(max-width:850px){

    .site-header .container.nav{
        width:min(100% - 24px, 1180px);
        min-height:68px;
        padding-top:10px;
        padding-bottom:10px;
    }

    .site-header .logo-image{
        flex:1 1 auto;
        min-width:0;
        max-width:calc(100% - 60px);
    }

    .site-header .logo-image img{
        flex:0 0 auto;
        width:auto;
        height:38px;
        max-width:48px;
    }

    .site-header .logo-image strong{
        display:block;
        min-width:0;
        max-width:none;
        overflow:visible;
        font-size:13px;
        line-height:1.25;
        white-space:normal;
        text-overflow:clip;
        overflow-wrap:anywhere;
    }

    .mobile-nav-toggle{
        flex:0 0 44px;
        width:44px;
        height:44px;
        min-width:44px;
        min-height:44px;
    }

    .site-header .mobile-navigation{
        width:min(90vw,360px);
        max-width:100%;
        padding:88px 22px 32px;
    }

    .site-header .mobile-navigation a{
        white-space:normal;
        overflow-wrap:anywhere;
    }
}

/* =========================================================
   HERO / BANNER / GENERAL CONTENT
   ========================================================= */

@media(max-width:768px){

    .page-banner{
        padding:42px 0 34px;
    }

    .page-banner h1{
        margin:0;
        font-size:clamp(28px,9vw,42px);
        line-height:1.12;
    }

    .page-content{
        padding-top:38px;
        padding-bottom:20px;
    }

    .page-content .container{
        width:min(100% - 28px, 900px);
    }

    .page-content h1{
        font-size:clamp(30px,9vw,44px);
        line-height:1.12;
    }

    .page-content h2{
        margin-top:36px;
        font-size:clamp(22px,7vw,30px);
        line-height:1.2;
    }

    .page-content p{
        font-size:15px;
        line-height:1.8;
    }

    .eyebrow{
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }
}

/* =========================================================
   HOME HERO
   ========================================================= */

@media(max-width:850px){

    .hero{
        overflow:hidden;
    }

    .hero-grid{
        grid-template-columns:1fr;
        gap:34px;
        padding-top:48px;
        padding-bottom:48px;
    }

    .hero-content{
        min-width:0;
    }

    .hero-content h1{
        margin-top:12px;
        font-size:clamp(34px,11vw,54px);
        line-height:1.05;
        overflow-wrap:anywhere;
    }

    .hero-content .lead{
        max-width:100%;
        font-size:15px;
        line-height:1.75;
    }

    .count-card{
        width:100%;
        min-width:0;
        padding:24px 18px;
    }

    .count-card > p,
    .count-card > strong,
    .count-card > small{
        display:block;
        max-width:100%;
        overflow-wrap:anywhere;
    }

    .count-card > strong{
        font-size:15px;
        line-height:1.5;
    }

    .countdown{
        grid-template-columns:repeat(4,minmax(0,1fr));
        gap:7px;
        width:100%;
    }

    .countdown div{
        min-width:0;
        padding:12px 4px;
    }

    .countdown b{
        font-size:clamp(20px,7vw,30px);
    }

    .countdown span{
        font-size:10px;
        white-space:normal;
    }
}

@media(max-width:390px){

    .countdown{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}

/* =========================================================
   SECTION HEADING / LIVE BADGE
   ========================================================= */

@media(max-width:700px){

    .section-heading{
        align-items:flex-start;
        flex-direction:column;
        gap:16px;
    }

    .section-heading > div{
        min-width:0;
        width:100%;
    }

    .section-heading h2{
        font-size:clamp(28px,9vw,40px);
        line-height:1.12;
    }

    .live-badge{
        align-self:flex-start;
        max-width:100%;
        white-space:normal;
        line-height:1.4;
    }
}

/* =========================================================
   LIVE RESULT BOARD
   ========================================================= */

@media(max-width:768px){

    .result-board{
        overflow:hidden;
        border-radius:18px;
    }

    .board-top{
        align-items:flex-start;
        flex-direction:column;
        gap:8px;
        padding:18px;
    }

    .board-top span{
        width:100%;
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }

    .prize-list{
        padding:14px;
    }

    .prize-row{
        align-items:flex-start;
        flex-direction:column;
        gap:14px;
        min-width:0;
        padding:18px 14px;
    }

    .medal{
        align-self:flex-start;
        flex:0 0 auto;
    }

    .prize-display{
        width:100%;
        min-width:0;
    }

    .prize-stage-status,
    .prize-stage-time{
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }

    .digits{
        display:grid;
        grid-template-columns:repeat(6,minmax(0,1fr));
        gap:5px;
        width:100%;
        max-width:100%;
    }

    .digit{
        min-width:0;
        width:100%;
        height:auto;
        aspect-ratio:1 / 1.1;
        padding:0;
        font-size:clamp(20px,8vw,34px);
    }
}

/* =========================================================
   HISTORY CARDS
   ========================================================= */

@media(max-width:768px){

    .history-grid{
        grid-template-columns:1fr;
        gap:18px;
    }

    .history-card{
        min-width:0;
        padding:18px;
    }

    .history-head{
        align-items:flex-start;
        flex-direction:column;
        gap:10px;
    }

    .history-head > div,
    .history-head time{
        width:100%;
        max-width:100%;
        text-align:left;
        white-space:normal;
        overflow-wrap:anywhere;
    }

    .history-prize{
        align-items:flex-start;
        flex-direction:column;
        gap:5px;
    }

    .history-prize span,
    .history-prize strong,
    .history-prize small{
        max-width:100%;
        overflow-wrap:anywhere;
    }
}

/* =========================================================
   FOOTER
   ========================================================= */

@media(max-width:700px){

    .site-footer{
        overflow:hidden;
    }

    .footer-main{
        width:min(100% - 28px,1180px);
        grid-template-columns:1fr;
        gap:34px;
    }

    .footer-brand,
    .footer-column{
        min-width:0;
        max-width:100%;
    }

    .footer-logo{
        align-items:center;
        max-width:100%;
    }

    .footer-logo img{
        flex:0 0 auto;
        max-width:54px;
        height:46px;
    }

    .footer-logo strong{
        min-width:0;
        font-size:15px;
        line-height:1.3;
        white-space:normal;
        overflow-wrap:anywhere;
    }

    .footer-brand p,
    .footer-column p,
    .footer-links a,
    .footer-info span,
    .footer-info strong{
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }

    .footer-bottom{
        width:min(100% - 28px,1180px);
    }

    .footer-bottom p{
        max-width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }
}

/* =========================================================
   ADMIN MOBILE TABLE SAFETY
   ========================================================= */

@media(max-width:800px){

    .admin-main{
        width:min(100% - 24px,1180px);
    }

    .table-wrap{
        width:100%;
        max-width:100%;
        overflow-x:auto;
        -webkit-overflow-scrolling:touch;
    }

    .table-wrap table{
        min-width:760px;
    }

    .history-edit-fields{
        min-width:620px;
    }

    .admin-title{
        align-items:flex-start;
        flex-direction:column;
        gap:10px;
    }

    .stage-dropdown summary{
        padding-right:48px;
    }

    .stage-dropdown summary small{
        width:100%;
        white-space:normal;
        overflow-wrap:anywhere;
    }
}