/* Gull Apps — shared styles
   Palette matches the apps themselves, so the site and the product feel like
   one thing. Values come from ColorGull's Theme.swift. */

:root {
    --coral:     #FA6B69;
    --sunshine:  #FFC233;
    --mint:      #4ACC99;
    --sky:       #4FA6F5;
    --lavender:  #A887F0;
    --bubblegum: #F780BF;

    --ink:       #2A3347;
    --ink-soft:  #6B7890;
    --surface:   #ffffff;

    --sky-top:   #B5E3FD;
    --sky-mid:   #D9F0FF;
    --sand:      #FFF7E6;

    --radius:      22px;
    --radius-lg:   28px;
    --shadow:      0 6px 20px rgba(42, 51, 71, 0.10);
    --shadow-lg:   0 14px 40px rgba(42, 51, 71, 0.16);
    --max-width:   1040px;
}

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

html { scroll-behavior: smooth; }

body {
    /* Rounded system faces first: the same signal the apps use to read as
       being for young children. Falls back gracefully off Apple platforms. */
    font-family: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont,
                 "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
    color: var(--ink);
    line-height: 1.6;
    background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 42%, var(--sand) 100%);
    background-attachment: fixed;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

a { color: #2C7BD1; }
a:hover { color: #1B5FA8; }

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

/* ---------- Navigation ---------- */

.nav {
    padding: 20px 0;
}

.nav .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--ink);
    text-decoration: none;
}

.nav-brand img { width: 34px; height: 34px; border-radius: 9px; }

.nav-links {
    display: flex;
    gap: 8px;
    list-style: none;
    flex-wrap: wrap;
}

.nav-links a {
    display: block;
    padding: 8px 14px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--ink-soft);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.6);
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
    background: var(--surface);
    color: var(--ink);
}

/* ---------- Hero ---------- */

.hero {
    text-align: center;
    padding: 40px 0 24px;
}

.hero-mascot { width: 150px; margin: 0 auto 8px; display: block; }

.hero-icon {
    width: 116px;
    height: 116px;
    border-radius: 26px;
    box-shadow: var(--shadow-lg);
    margin: 0 auto 20px;
    display: block;
}

h1 {
    font-size: clamp(2.2rem, 6vw, 3.4rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    margin-bottom: 14px;
}

.tagline {
    font-size: clamp(1.05rem, 2.4vw, 1.3rem);
    color: var(--ink-soft);
    max-width: 620px;
    margin: 0 auto 12px;
}

.hero-note {
    display: inline-block;
    background: var(--surface);
    border-radius: 999px;
    padding: 10px 22px;
    font-weight: 600;
    font-size: 0.98rem;
    box-shadow: var(--shadow);
    margin-top: 8px;
}

/* ---------- Sections ---------- */

section { padding: 44px 0; }

h2 {
    font-size: clamp(1.6rem, 3.6vw, 2.1rem);
    font-weight: 800;
    text-align: center;
    margin-bottom: 10px;
}

.section-intro {
    text-align: center;
    color: var(--ink-soft);
    max-width: 640px;
    margin: 0 auto 32px;
}

/* ---------- App cards ---------- */

.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
}

.app-card {
    display: block;
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
    text-align: center;
    text-decoration: none;
    color: inherit;
    box-shadow: var(--shadow);
    border: 3px solid transparent;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

a.app-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    color: inherit;
}

.app-card img,
.app-card .app-emoji {
    width: 88px;
    height: 88px;
    border-radius: 20px;
    margin: 0 auto 16px;
    display: grid;
    place-items: center;
    font-size: 46px;
}

.app-card h3 { font-size: 1.35rem; font-weight: 800; margin-bottom: 6px; }
.app-card p  { color: var(--ink-soft); font-size: 0.98rem; }

.app-card.is-coming { opacity: 0.82; }

.badge {
    display: inline-block;
    margin-top: 14px;
    padding: 5px 14px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.badge-live   { background: var(--mint);    color: #10402C; }
.badge-soon   { background: rgba(42,51,71,0.08); color: var(--ink-soft); }

/* Tint helpers, one per app family */
.tint-sky       .app-emoji { background: rgba(79,166,245,0.16); }
.tint-sunshine  .app-emoji { background: rgba(255,194,51,0.20); }
.tint-lavender  .app-emoji { background: rgba(168,135,240,0.18); }
.tint-mint      .app-emoji { background: rgba(74,204,153,0.18); }

/* ---------- Feature cards ---------- */

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.feature {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
}

.feature-icon { font-size: 34px; line-height: 1; margin-bottom: 12px; }
.feature h3 { font-size: 1.15rem; font-weight: 800; margin-bottom: 8px; }
.feature p  { color: var(--ink-soft); font-size: 0.97rem; }

/* ---------- Screenshot strip ---------- */

.shots {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding: 8px 4px 22px;
    scroll-snap-type: x mandatory;
}

.shots figure {
    flex: 0 0 auto;
    width: 216px;
    scroll-snap-align: center;
    text-align: center;
}

.shots img {
    width: 100%;
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    background: var(--surface);
    display: block;
}

.shots figcaption {
    margin-top: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--ink-soft);
}

/* Four items sit better as 2x2 than as a row of three with an orphan. */
@media (min-width: 720px) {
    .feature-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Promise panel ---------- */

.promise {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow);
}

.promise ul { list-style: none; display: grid; gap: 14px; }

.promise li {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    font-size: 1rem;
}

.promise li::before {
    content: "✓";
    flex: 0 0 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--mint);
    color: #10402C;
    font-weight: 800;
    display: grid;
    place-items: center;
    font-size: 0.9rem;
    margin-top: 2px;
}

/* ---------- App Store button ---------- */

.store-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--ink);
    color: #fff;
    padding: 14px 26px;
    border-radius: 999px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: var(--shadow);
    margin-top: 20px;
    max-width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
}

.store-btn:hover { color: #fff; background: #1B2435; }
.store-btn svg { width: 22px; height: 22px; fill: currentColor; }
.store-btn.is-disabled { background: rgba(42,51,71,0.22); cursor: default; }
.store-btn.is-disabled:hover { background: rgba(42,51,71,0.22); }

/* ---------- Legal pages ---------- */

.legal {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: clamp(28px, 5vw, 52px);
    box-shadow: var(--shadow);
    margin: 20px 0 56px;
}

.legal h1 { text-align: left; font-size: clamp(1.9rem, 4.4vw, 2.5rem); }
.legal h2 {
    text-align: left;
    font-size: 1.3rem;
    margin: 32px 0 10px;
    padding-top: 4px;
}
.legal h3 { font-size: 1.05rem; margin: 20px 0 6px; }
.legal p, .legal li { color: #3D4759; }
.legal p { margin-bottom: 14px; }
.legal ul, .legal ol { margin: 0 0 16px 22px; }
.legal li { margin-bottom: 8px; }

.updated {
    color: var(--ink-soft);
    font-size: 0.95rem;
    margin-bottom: 26px;
}

.callout {
    background: rgba(79,166,245,0.10);
    border-left: 5px solid var(--sky);
    border-radius: 14px;
    padding: 18px 22px;
    margin: 22px 0;
}

.callout p:last-child { margin-bottom: 0; }

/* ---------- FAQ ---------- */

.faq { display: grid; gap: 16px; }

.faq details {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 18px 22px;
    box-shadow: var(--shadow);
}

.faq summary {
    font-weight: 700;
    cursor: pointer;
    font-size: 1.05rem;
    list-style: none;
}

.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: " +"; color: var(--ink-soft); }
.faq details[open] summary::after { content: " –"; }
.faq details p { margin-top: 12px; color: var(--ink-soft); }

/* ---------- Footer ---------- */

.footer {
    padding: 36px 0 48px;
    text-align: center;
    color: var(--ink-soft);
    font-size: 0.93rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 10px 22px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    list-style: none;
}

.footer-links a { font-weight: 600; text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }

/* ---------- Overflow guards ---------- */
/*
   A single element wider than the viewport shifts the whole page sideways on a
   phone, which reads as broken text running off the right edge. These keep
   every wide thing inside its container instead.
*/

.hero-note,
.store-btn,
.shots,
.promise,
.legal { max-width: 100%; }

/* Long unbroken strings, chiefly the support address. */
.footer-links a,
.legal a { overflow-wrap: anywhere; }

@media (max-width: 420px) {
    .store-btn {
        min-width: 0;
        padding: 13px 20px;
        font-size: 0.95rem;
    }
    .hero-note { padding: 10px 16px; font-size: 0.92rem; }
    .container { padding: 0 16px; }
    .shots figure { width: 190px; }
}

/* ---------- Accessibility ---------- */

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

.skip-link {
    position: absolute;
    left: -9999px;
    background: var(--surface);
    padding: 12px 20px;
    border-radius: 12px;
    font-weight: 700;
    z-index: 10;
}

.skip-link:focus {
    left: 24px;
    top: 16px;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; animation: none !important; }
}
