/* Just Drink: colors and type follow the app's Theme.swift */

:root {
    --ground: #F2F6FA;
    --card: #FFFFFF;
    --ink: #0E2033;
    --ink2: #52637A;
    --line: #DEE6EF;
    --water: #2A86E8;
    --water-back: #9ACFF7;
    --water-ink: #1463C2;
    --glass: #E7F2FC;
    --ring: #8DB9E6;
    --tint: #1463C2;
    --track: #DCE8F5;
    --good: #13784F;
    --btn-bg: #1463C2;
    --btn-ink: #FFFFFF;
    --shadow: 0 12px 32px rgba(14, 32, 51, .08);
    --shadow-lift: 0 24px 60px rgba(20, 99, 194, .16);

    /* The eight container colors, in the app's order */
    --c1: #2A86E8;
    --c2: #D9453D;
    --c3: #1A8F61;
    --c4: #D46E12;
    --c5: #7B5BD6;
    --c6: #D63F8C;
    --c7: #B58500;
    --c8: #0E93B0;

    --font: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
    :root {
        --ground: #0B1520;
        --card: #15212F;
        --ink: #EAF1F8;
        --ink2: #9FB2C6;
        --line: #243446;
        --water: #3D97F5;
        --water-back: #2C5F8F;
        --water-ink: #7CC0FF;
        --glass: #122335;
        --ring: #2A4A6E;
        --tint: #7CC0FF;
        --track: #1D3550;
        --good: #4FD1A0;
        --btn-bg: #7CC0FF;
        --btn-ink: #0B1520;
        --shadow: 0 12px 32px rgba(0, 0, 0, .35);
        --shadow-lift: 0 24px 60px rgba(0, 0, 0, .45);

        --c1: #6CB2FF;
        --c2: #FF8A80;
        --c3: #4FD1A0;
        --c4: #FFB15C;
        --c5: #B39DFF;
        --c6: #FF8CC6;
        --c7: #FFD54F;
        --c8: #5FD4EE;
    }
}

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

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}

body {
    margin: 0;
    background-color: var(--ground);
    background-image:
        radial-gradient(70% 60% at 85% 12%, var(--glass), transparent 70%),
        radial-gradient(60% 50% at 10% 0%, var(--glass), transparent 70%);
    background-repeat: no-repeat;
    background-size: 100% 1100px;
    color: var(--ink);
    font-family: var(--font);
    font-size: 17px;
    font-weight: 500;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 {
    margin: 0;
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.01em;
    text-wrap: balance;
}

p { margin: 0; }

a { color: var(--tint); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible {
    outline: 3px solid var(--water);
    outline-offset: 3px;
    border-radius: 6px;
}

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.i, .i-fill { width: 24px; height: 24px; flex: none; }
.i {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.i-fill { fill: currentColor; stroke: none; }

.skip {
    position: absolute;
    left: 16px;
    top: -60px;
    padding: 10px 16px;
    background: var(--card);
    color: var(--ink);
    border-radius: 12px;
    font-weight: 800;
    z-index: 10;
}
.skip:focus { top: 12px; }

.wrap {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
}
.narrow { max-width: 800px; }

/* Top bar */

.bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 64px;
}
.studio {
    color: var(--ink);
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
}
.bar-nav { display: flex; gap: 22px; }
.bar-nav a {
    color: var(--ink2);
    font-weight: 700;
    text-decoration: none;
}
.bar-nav a:hover { color: var(--ink); }

/* Hero */

.hero { padding: 28px 0 32px; }
.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
    gap: 56px;
    align-items: center;
}
.hero-icon {
    display: block;
    width: 120px;
    height: 120px;
    margin-bottom: 26px;
    filter: drop-shadow(0 14px 24px rgba(20, 99, 194, .28));
}
.hero h1 {
    font-size: clamp(48px, 7vw, 76px);
    font-weight: 900;
    letter-spacing: -0.02em;
}
.pitch {
    margin-top: 12px;
    font-size: clamp(22px, 2.6vw, 28px);
    font-weight: 800;
    color: var(--water-ink);
    line-height: 1.25;
    text-wrap: balance;
}
.lede {
    margin-top: 16px;
    max-width: 34em;
    font-size: 18px;
    color: var(--ink2);
}
.appstore {
    display: inline-flex;
    align-items: center;
    margin-top: 28px;
    padding: 14px 26px;
    border-radius: 999px;
    background: var(--btn-bg);
    color: var(--btn-ink);
    font-weight: 800;
    font-size: 17px;
    text-decoration: none;
}
.appstore:hover { filter: brightness(1.08); }
.needs {
    margin-top: 12px;
    font-size: 15px;
    font-weight: 700;
    color: var(--ink2);
}

/* Illustration of the main screen */

.screen {
    margin: 0;
    justify-self: center;
    width: 100%;
    max-width: 370px;
    padding: 26px 18px 14px;
    border-radius: 44px;
    background: var(--ground);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-lift);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.m-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.m-eyebrow {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .09em;
    text-transform: uppercase;
    color: var(--ink2);
}
.m-total {
    font-size: 56px;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.02em;
}
.m-total small {
    margin-left: 6px;
    font-size: 22px;
    font-weight: 800;
    color: var(--ink2);
    letter-spacing: 0;
}
.m-goal {
    font-size: 15px;
    font-weight: 800;
    color: var(--ink2);
}
.m-goal b { color: var(--water-ink); font-weight: 800; }

.m-circle {
    position: relative;
    width: 74%;
    max-width: 260px;
    margin-top: 20px;
    aspect-ratio: 1;
    container-type: inline-size;
    border-radius: 50%;
    box-shadow: 0 10px 30px color-mix(in srgb, var(--water) 22%, transparent);
}
.m-circle > svg { display: block; width: 100%; height: 100%; }
.w-base { fill: var(--glass); }
.w-back { fill: var(--water-back); }
.w-front { fill: var(--water); }
.w-ring { fill: none; stroke: var(--ring); stroke-width: 5.6; }

@media (prefers-reduced-motion: no-preference) {
    .w-front { animation: wave-left 5s linear infinite; }
    .w-back { animation: wave-right 7.5s linear infinite; }
}
@keyframes wave-left { to { transform: translateX(-200px); } }
@keyframes wave-right { to { transform: translateX(200px); } }

.m-disc {
    position: absolute;
    inset: 29%;
    border-radius: 50%;
    background: color-mix(in srgb, var(--card) 94%, transparent);
    box-shadow: 0 4px 10px rgba(0, 0, 0, .14);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
}
.m-disc .i {
    width: 13cqw;
    height: 13cqw;
    color: var(--water-ink);
    stroke-width: 3.2;
}
.m-disc span {
    font-size: 20px;
    font-size: 8.4cqw;
    font-weight: 800;
    line-height: 1.1;
}

.m-caption {
    margin-top: 16px;
    max-width: 260px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--ink2);
}
.m-from {
    align-self: flex-start;
    margin: 18px 0 0 6px;
}
.m-cards {
    display: flex;
    gap: 9px;
    width: 100%;
    padding: 12px 2px 14px;
}
.m-card {
    position: relative;
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 12px 4px 10px;
    border-radius: 18px;
    background: var(--card);
    border: 1px solid var(--line);
}
.m-card.is-on {
    border: 2.5px solid var(--water);
    box-shadow: 0 6px 14px color-mix(in srgb, var(--water) 25%, transparent);
}
.m-tile {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    margin-bottom: 3px;
    border-radius: 13px;
    color: var(--c);
    background: color-mix(in srgb, var(--c) 16%, transparent);
}
.m-tile .i-fill { width: 22px; height: 22px; }
.m-name {
    font-size: 12px;
    font-weight: 800;
    line-height: 1.2;
}
.m-size {
    font-size: 11px;
    font-weight: 700;
    color: var(--ink2);
}
.m-badge {
    position: absolute;
    top: -9px;
    right: -9px;
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--water);
    color: #FFFFFF;
    box-shadow: 0 0 0 3px var(--ground);
}
.m-badge .i { width: 14px; height: 14px; stroke-width: 3.4; }

.m-bar {
    display: flex;
    width: 100%;
    padding: 6px;
    border-radius: 999px;
    background: var(--card);
    border: 1px solid var(--line);
    box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}
.m-bar span {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 0;
    font-size: 10.5px;
    font-weight: 800;
    color: var(--ink);
}
.m-bar .i { width: 20px; height: 20px; }
.m-bar .i-fill { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; }

/* Sections */

.section { padding: 72px 0; }
.section + .section { padding-top: 0; }
.eyebrow {
    font-size: 14px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--water-ink);
}
.section h2 {
    margin-top: 8px;
    font-size: clamp(30px, 4.2vw, 42px);
}
.section-lede {
    margin-top: 12px;
    max-width: 38em;
    font-size: 18px;
    color: var(--ink2);
}

/* Features */

.features {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
    gap: 16px;
    margin-top: 36px;
}
.feature {
    padding: 24px;
    border-radius: 26px;
    background: var(--card);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}
.f-icon {
    display: grid;
    place-items: center;
    width: 50px;
    height: 50px;
    margin-bottom: 16px;
    border-radius: 16px;
    color: var(--c);
    background: color-mix(in srgb, var(--c) 15%, transparent);
}
.f-icon .i, .f-icon .i-fill { width: 26px; height: 26px; }
.feature h3 { font-size: 20px; }
.feature p {
    margin-top: 8px;
    font-size: 16px;
    color: var(--ink2);
}
.feature-wide {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 20px;
}
.feature-wide .f-icon { margin-bottom: 0; }

/* Privacy */

.privacy {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    gap: 40px;
    align-items: center;
    padding: 44px;
    border-radius: 32px;
    background: var(--glass);
    border: 1px solid color-mix(in srgb, var(--ring) 45%, transparent);
}
.privacy-copy p { margin-top: 14px; color: var(--ink2); font-size: 17px; }
.privacy-copy p a { font-weight: 800; }
.checks {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 12px;
}
.checks li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-weight: 700;
}
.checks .i {
    width: 22px;
    height: 22px;
    margin-top: 2px;
    color: var(--good);
    stroke-width: 2.6;
}

/* Support */

.section-support { padding-bottom: 88px; }
.faq {
    display: grid;
    gap: 10px;
    margin-top: 32px;
}
.faq details {
    border-radius: 20px;
    background: var(--card);
    border: 1px solid var(--line);
    scroll-margin-top: 16px;
}
.faq details[open] { box-shadow: var(--shadow); }
.faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.3;
    cursor: pointer;
    list-style: none;
    border-radius: 20px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .i {
    width: 20px;
    height: 20px;
    color: var(--ink2);
    transition: transform .2s ease;
}
.faq details[open] summary .i { transform: rotate(90deg); }
.answer {
    display: grid;
    gap: 12px;
    padding: 0 20px 20px;
    font-size: 16.5px;
}
.answer strong { font-weight: 800; }

.contact {
    margin-top: 36px;
    padding: 32px 24px;
    border-radius: 26px;
    background: var(--glass);
    border: 1px solid color-mix(in srgb, var(--ring) 45%, transparent);
    text-align: center;
}
.contact h3 { font-size: 24px; }
.contact > p { margin-top: 8px; color: var(--ink2); }
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    padding: 14px 26px;
    border-radius: 999px;
    background: var(--btn-bg);
    color: var(--btn-ink);
    font-weight: 800;
    font-size: 17px;
    text-decoration: none;
}
.btn:hover { filter: brightness(1.08); }
.btn .i { width: 20px; height: 20px; }
.contact .email { margin-top: 14px; font-weight: 800; overflow-wrap: anywhere; }
.contact .fine { margin-top: 10px; font-size: 15px; }

/* Footer */

.footer {
    border-top: 1px solid var(--line);
    padding: 28px 0 calc(28px + env(safe-area-inset-bottom));
    font-size: 15px;
    color: var(--ink2);
}
.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
}
.footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer a { color: var(--ink2); font-weight: 700; text-decoration: none; }
.footer a:hover { color: var(--ink); text-decoration: underline; }

/* Narrower screens */

@media (max-width: 900px) {
    .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
    .hero-copy { text-align: center; }
    .hero-icon { margin-left: auto; margin-right: auto; }
    .lede { margin-left: auto; margin-right: auto; }
    .privacy { grid-template-columns: minmax(0, 1fr); gap: 28px; padding: 32px 26px; }
}

@media (max-width: 560px) {
    body { font-size: 16.5px; }
    .wrap {
        padding-left: max(16px, env(safe-area-inset-left));
        padding-right: max(16px, env(safe-area-inset-right));
    }
    .bar-nav { gap: 14px; }
    .bar-nav a { font-size: 15px; }
    .hero { padding: 16px 0 56px; }
    .hero-icon { width: 104px; height: 104px; }
    .section { padding: 56px 0; }
    .feature { padding: 22px 20px; }
    .feature-wide { flex-direction: column; align-items: flex-start; gap: 16px; }
    .privacy { padding: 28px 20px; border-radius: 26px; }
    .faq summary { font-size: 17px; padding: 16px 18px; }
    .answer { padding: 0 18px 18px; font-size: 16px; }
    .screen { padding: 22px 14px 12px; border-radius: 38px; }
    .m-cards { gap: 7px; }
}

@media (max-width: 440px) {
    .bar-nav .nav-extra { display: none; }
}
