/* ======================================================
   DrinkLab v2 — Vivid, Bold, Non-AI Design
   ====================================================== */

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

:root{
    --bg:#1b365d;
    --bg-light:#2a5090;
    --text:#fff;
    --accent:#a8d4ff;
}

html,body{
    width:100%;height:100%;overflow:hidden;
    font-family:'DM Sans',Helvetica,Arial,sans-serif;
    background:#0a0a0a;color:#fff;
    -webkit-font-smoothing:antialiased;
}

/* ── Solid Background ── */
#bg-solid{
    position:fixed;inset:0;z-index:0;
    background:var(--bg);
    transition:background .9s ease;
}

/* ── Floating Fruit Layer ── */
#fruit-layer{
    position:fixed;inset:0;z-index:1;
    pointer-events:none;overflow:hidden;
}
.fruit-img{
    position:absolute;
    width:auto;
    height:35vh;
    object-fit:contain;
    pointer-events:none;
    z-index:3;
    opacity:0;
    filter:drop-shadow(0 25px 35px rgba(0,0,0,0.6));
    transition:opacity 0.6s cubic-bezier(0.4,0,0.2,1);
    will-change:transform, opacity;
}

/* ── Giant Background Text ── */
#bg-text-wrap{
    position:fixed;inset:0;z-index:2;
    display:flex;align-items:center;justify-content:center;
    pointer-events:none;overflow:hidden;
}
#bg-text{
    font-family:'Anton',sans-serif;
    font-weight:400;
    font-size:clamp(120px,22vw,400px);
    color:rgba(255,255,255,.08);
    text-transform:uppercase;
    letter-spacing:.02em;
    user-select:none;white-space:nowrap;
    will-change:transform,opacity;
}

/* ── Canvas ── */
#canvas-container{
    position:fixed;inset:0;z-index:3;
}
#canvas-container canvas{
    cursor:grab;display:block;
}
#canvas-container canvas:active{cursor:grabbing}

/* ── Top Nav ── */
.topnav{
    position:fixed;top:0;left:0;right:0;z-index:100;
    display:flex;align-items:center;justify-content:space-between;
    padding:22px 48px;
}
.topnav-logo{
    font-family:'Bebas Neue',sans-serif;
    font-size:28px;letter-spacing:.06em;color:#fff;
}
.topnav-links{display:flex;gap:28px}
.topnav-links a{
    text-decoration:none;color:rgba(255,255,255,.65);
    font-size:14px;font-weight:500;
    transition:color .25s;
}
.topnav-links a:hover{color:#fff}

.order-btn{
    font-family:'DM Sans',sans-serif;font-weight:600;font-size:13px;
    background:rgba(255,255,255,.15);
    backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);
    border:1.5px solid rgba(255,255,255,.25);
    color:#fff;padding:10px 24px;border-radius:50px;
    cursor:pointer;display:flex;align-items:center;gap:6px;
    transition:all .3s;
}
.order-btn:hover{
    background:rgba(255,255,255,.3);
    transform:translateY(-2px);
}

/* ── Left Info ── */
.info-left{
    position:fixed;z-index:10;
    top:50%;left:48px;transform:translateY(-50%);
    max-width:360px;display:flex;flex-direction:column;gap:14px;
    pointer-events:none;
}
.info-left>*{pointer-events:all}

.info-badge{
    font-size:11px;font-weight:600;
    text-transform:uppercase;letter-spacing:.2em;
    color:var(--accent);
    transition:color .5s;
}
.info-title{
    font-family:'Playfair Display',serif;
    font-weight:900;font-size:clamp(44px,5.5vw,72px);
    line-height:1;letter-spacing:-.02em;
    color:#fff;
}
.info-desc{
    font-size:14px;font-weight:400;line-height:1.7;
    color:rgba(255,255,255,.6);max-width:320px;
}

/* ── Glass Card ── */
.glass-info{
    background:rgba(255,255,255,.08);
    backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);
    border:1px solid rgba(255,255,255,.12);
    border-radius:18px;padding:20px 24px;
    margin-top:6px;
    transition:all .4s ease;
}
.glass-info:hover{
    background:rgba(255,255,255,.12);
    border-color:rgba(255,255,255,.2);
    transform:translateY(-2px);
    box-shadow:0 12px 40px rgba(0,0,0,.25);
}
.glass-row{
    display:flex;justify-content:space-between;align-items:center;
    padding:6px 0;
}
.glass-label{
    font-size:12px;text-transform:uppercase;letter-spacing:.08em;
    color:rgba(255,255,255,.4);
}
.glass-val{font-size:15px;font-weight:700;color:#fff}
.glass-divider{
    height:1px;
    background:linear-gradient(90deg,transparent,rgba(255,255,255,.1),transparent);
    margin:4px 0;
}

/* ── Right Info ── */
.info-right{
    position:fixed;z-index:10;
    top:50%;right:48px;transform:translateY(-50%);
    display:flex;flex-direction:column;align-items:flex-end;gap:20px;
    pointer-events:none;
}
.info-right>*{pointer-events:all}

.flavor-text{
    font-size:13px;font-weight:500;
    text-transform:uppercase;letter-spacing:.12em;
    color:rgba(255,255,255,.5);
}
.size-group{
    display:flex;flex-direction:column;align-items:flex-end;gap:10px;
}
.size-title{
    font-size:10px;text-transform:uppercase;letter-spacing:.15em;
    color:rgba(255,255,255,.3);
}
.sizes{display:flex;gap:8px}
.sz{
    font-family:'DM Sans',sans-serif;font-size:13px;font-weight:600;
    background:rgba(255,255,255,.1);
    border:1px solid rgba(255,255,255,.15);
    color:rgba(255,255,255,.6);
    padding:9px 18px;border-radius:10px;cursor:pointer;
    transition:all .3s;
}
.sz:hover{
    background:rgba(255,255,255,.18);
    color:#fff;transform:translateY(-1px);
}
.sz.active{
    background:rgba(255,255,255,.25);
    border-color:rgba(255,255,255,.4);
    color:#fff;
    box-shadow:0 4px 16px rgba(0,0,0,.2);
}

/* ── Nav Arrows ── */
.arrow{
    position:fixed;z-index:50;top:50%;
    transform:translateY(-50%);
    width:52px;height:52px;border-radius:50%;
    background:rgba(255,255,255,.1);
    backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
    border:1px solid rgba(255,255,255,.15);
    color:#fff;cursor:pointer;
    display:flex;align-items:center;justify-content:center;
    transition:all .3s;
}
.arrow svg{width:20px;height:20px}
.arrow:hover{
    background:rgba(255,255,255,.22);
    transform:translateY(-50%) scale(1.08);
}
.arrow:active{transform:translateY(-50%) scale(.94)}
.arrow-l{left:20px}
.arrow-r{right:20px}

/* ── Dots ── */
.dots{
    position:fixed;z-index:50;
    bottom:60px;left:50%;transform:translateX(-50%);
    display:flex;gap:10px;align-items:center;
}
.dot{
    width:10px;height:10px;border-radius:50%;border:none;
    background:rgba(255,255,255,.25);cursor:pointer;
    transition:all .4s;
}
.dot:hover{background:rgba(255,255,255,.5)}
.dot.active{
    width:36px;border-radius:5px;
    background:rgba(255,255,255,.8);
}

/* ── Bottom ── */
.bottom{
    position:fixed;bottom:0;left:0;right:0;z-index:50;
    display:flex;justify-content:space-between;align-items:center;
    padding:18px 48px;
}
/* Developed by ilimdar mafis & webdesignhaus */
.agency-signature {
    color: #fff;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 20px;
    letter-spacing: .05em;
    opacity: 0.8;
    text-transform: uppercase;
}
.swipe-hint{
    font-size:11px;letter-spacing:.12em;
    text-transform:uppercase;color:rgba(255,255,255,.25);
}
.copy{
    font-size:11px;color:rgba(255,255,255,.2);
}

/* ── Mobile Bottom Nav Bar (hidden on desktop) ── */
.mobile-bottom-nav {
    display: none;
}

/* ── Responsive ── */
@media(max-width:900px){
    .topnav{padding:16px 20px}
    .topnav-links{display:none}
    .info-left{left:20px;max-width:280px;gap:10px}
    .info-title{font-size:36px}
    .info-right{right:20px}
    .arrow-l{left:8px}.arrow-r{right:8px}
    .arrow{width:40px;height:40px}
    .bottom{padding:12px 20px}
    .dots{bottom:44px}
    #bg-text{font-size:clamp(80px,28vw,200px)}
}
@media(max-width:600px){
    /* ── Hide desktop-only elements ── */
    .arrow       { display: none !important; }
    .dots        { display: none !important; }
    .bottom      { display: none !important; }
    .info-right  { display: none !important; }

    /* ── Top Nav ── */
    .topnav {
        padding: 14px 18px;
    }
    .order-btn {
        padding: 8px 14px;
        font-size: 11px;
    }

    /* ── Background text ── */
    #bg-text { font-size: clamp(70px, 26vw, 160px); }

    /* ── Product Info Panel — transparent, no overlay ── */
    .info-left {
        position: fixed;
        top: auto;
        bottom: 68px;
        left: 0;
        right: 0;
        max-width: none;
        transform: none;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 4px;
        padding: 10px 20px 10px;
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        border-top: none;
        pointer-events: none;
    }
    .info-left > * { pointer-events: all; }

    .info-badge {
        font-size: 10px;
        letter-spacing: .18em;
        margin-bottom: 0;
    }
    .info-title {
        font-size: 32px;
        line-height: 1;
        margin-bottom: 2px;
    }
    .info-desc {
        font-size: 12px;
        line-height: 1.55;
        color: rgba(255,255,255,0.55);
        max-width: 320px;
        margin: 0 auto;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    /* ── Glass Stats Card ── */
    .glass-info {
        width: 100%;
        max-width: 360px;
        padding: 10px 16px;
        margin-top: 4px;
        border-radius: 14px;
        display: flex;
        flex-direction: row;
        gap: 0;
        background: rgba(255,255,255,0.07);
    }
    .glass-row {
        flex: 1;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 4px 0;
        gap: 2px;
    }
    .glass-label {
        font-size: 9px;
        letter-spacing: .06em;
    }
    .glass-val {
        font-size: 13px;
        font-weight: 700;
    }
    .glass-divider {
        width: 1px;
        height: auto;
        background: linear-gradient(180deg,transparent,rgba(255,255,255,.15),transparent);
        margin: 4px 0;
        align-self: stretch;
    }

    /* ── Mobile Bottom Nav Bar — transparent ── */
    .mobile-bottom-nav {
        display: flex;
        align-items: center;
        justify-content: space-between;
        position: fixed;
        bottom: 0; left: 0; right: 0;
        z-index: 9999;
        height: 68px;
        padding: 0 20px;
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        border-top: none;
    }
    .mob-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 46px;
        height: 46px;
        border-radius: 50%;
        background: rgba(255,255,255,0.1);
        border: 1.5px solid rgba(255,255,255,0.22);
        color: #fff;
        cursor: pointer;
        transition: background .2s, transform .15s;
        flex-shrink: 0;
    }
    .mob-btn:active {
        background: rgba(255,255,255,0.25);
        transform: scale(0.88);
    }
    .mob-btn svg { width: 22px; height: 22px; pointer-events: none; }
    .mob-dots {
        display: flex;
        gap: 9px;
        align-items: center;
        flex: 1;
        justify-content: center;
    }
    .mob-dot {
        width: 7px; height: 7px;
        border-radius: 50%;
        border: none;
        background: rgba(255,255,255,0.28);
        cursor: pointer;
        transition: all .35s;
        padding: 0;
    }
    .mob-dot.active {
        width: 26px;
        border-radius: 4px;
        background: rgba(255,255,255,0.85);
    }
}


::selection{background:rgba(255,255,255,.2);color:#fff}

/* ── Checkout Overlay ── */
.checkout-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 100;
    pointer-events: none; /* Initially disabled */
    opacity: 0; /* Initially hidden */
    display: flex;
    justify-content: flex-end; /* Panel on the right */
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: opacity 0.5s ease;
}

.checkout-overlay.active {
    pointer-events: auto;
    opacity: 1;
}

.checkout-panel {
    width: 420px;
    height: 100%;
    background: rgba(20, 20, 20, 0.4);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: -20px 0 50px rgba(0, 0, 0, 0.5);
    padding: 60px 40px;
    position: relative;
    transform: translateX(100%); /* Slide out */
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.4s ease;
    display: flex;
    flex-direction: column;
}

.checkout-overlay.active .checkout-panel {
    transform: translateX(0); /* Slide in */
}

.close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 32px;
    cursor: pointer;
    transition: color 0.3s, transform 0.3s;
}
.close-btn:hover {
    color: #fff;
    transform: scale(1.1) rotate(90deg);
}

.checkout-header {
    margin-bottom: 30px;
}
#checkout-title {
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 5px;
    letter-spacing: .02em;
}
#checkout-size {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: .05em;
    text-transform: uppercase;
}

.checkout-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(255, 255, 255, 0.05);
    padding: 10px 20px;
    border-radius: 30px;
    width: fit-content;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.quantity-selector button {
    background: none;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    width: 30px; height: 30px;
    border-radius: 50%;
    transition: background 0.2s;
}
.quantity-selector button:hover {
    background: rgba(255, 255, 255, 0.1);
}
#qty-value {
    font-size: 20px;
    font-weight: 600;
    min-width: 30px;
    text-align: center;
}

.price-display {
    font-size: 24px;
    font-weight: 300;
    letter-spacing: .05em;
}
#total-price {
    font-weight: 700;
    font-size: 32px;
}

.checkout-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-top: 10px;
}
.input-group {
    position: relative;
}
.input-group input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 0;
    color: #fff;
    font-size: 16px;
    font-family: inherit;
    transition: border-color 0.3s;
}
.input-group input:focus {
    outline: none;
    border-color: #fff; /* We will override this via JS for the theme color */
}
.input-group label {
    position: absolute;
    left: 0;
    top: 10px;
    color: rgba(255, 255, 255, 0.4);
    font-size: 16px;
    transition: 0.3s ease all;
    pointer-events: none;
}
.input-group input:focus ~ label,
.input-group input:valid ~ label {
    top: -15px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
}

.confirm-btn {
    margin-top: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 16px;
    color: #fff;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .15em;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
}
.confirm-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    transform: translateY(-2px);
}
.btn-loader {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}
@keyframes spin { 100% { transform: translate(-50%, -50%) rotate(360deg); } }

.checkout-success {
    position: absolute;
    inset: 0;
    background: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}
.checkout-success.active {
    opacity: 1;
    pointer-events: auto;
}
.checkmark {
    font-size: 60px;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    border: 2px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}
.checkout-success h3 {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    margin-bottom: 10px;
}
.checkout-success p {
    color: rgba(255,255,255,0.6);
    font-size: 15px;
}

@media(max-width:600px) {
    .checkout-panel {
        width: 100%;
        padding: 40px 24px;
    }
}
