/* ─────────────────────────────────────────────────────────────────────
   TapFate website — V2 brand design system (Claude Design 2026-05-11)
   Tokens mirror app/src/main/java/com/jung/tapfate/ui/theme/DesignTokens.kt
   ────────────────────────────────────────────────────────────────── */

:root {
    --color-bg:             #FAFAFA;
    --color-surface:        #FFFFFF;
    --color-text-primary:   #1A1A1A;
    --color-text-secondary: #666666;
    --color-accent:         #FF6B35;
    --color-accent-text:    #C2410C;
    --color-accent-light:   #FF8A5C;
    --color-accent-deep:    #E94E1B;
    --color-hairline:       rgba(26, 26, 26, 0.08);
    --color-danger:         #DC2626;

    --gradient-accent: linear-gradient(135deg, #FF8A5C 0%, #FF6B35 55%, #E94E1B 100%);

    --space-xxs: 4px;
    --space-xs:  8px;
    --space-s:   12px;
    --space-m:   16px;
    --space-l:   24px;
    --space-xl:  32px;
    --space-xxl: 48px;

    --radius-chip:  12px;
    --radius-card:  16px;
    --radius-large: 24px;
    --radius-pill:  999px;

    --shadow-e1: 0 4px 12px rgba(20, 12, 8, 0.04);
    --shadow-e2: 0 8px 24px rgba(20, 12, 8, 0.06);
    --shadow-e3: 0 16px 40px rgba(20, 12, 8, 0.10);
    --shadow-e4-cta: 0 16px 40px rgba(255, 107, 53, 0.40);
}

/* ── Reset / Base ──────────────────────────────────────────────────── */

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

html, body {
    margin: 0;
    padding: 0;
    font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', 'Helvetica Neue', sans-serif;
    background: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

img, video { max-width: 100%; display: block; }
a { color: var(--color-accent-text); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Layout ────────────────────────────────────────────────────────── */

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

/* ── Top nav ───────────────────────────────────────────────────────── */

.topnav {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(250, 250, 250, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-hairline);
}

.topnav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.topnav__logo {
    font-weight: 800;
    font-size: 24px;
    letter-spacing: -0.96px;
}
.topnav__logo .tf-orange {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.topnav__links {
    display: flex;
    gap: var(--space-l);
}
.topnav__links a {
    color: var(--color-text-secondary);
    font-size: 14px;
    font-weight: 600;
}
.topnav__links a:hover { color: var(--color-text-primary); }

.lang-switcher {
    display: flex;
    gap: var(--space-xs);
}
.lang-switcher button {
    background: transparent;
    border: 1px solid var(--color-hairline);
    color: var(--color-text-secondary);
    border-radius: var(--radius-pill);
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}
.lang-switcher button.active {
    background: var(--color-accent);
    color: white;
    border-color: var(--color-accent);
}

/* ── Hero ──────────────────────────────────────────────────────────── */

.hero {
    min-height: 70vh;
    display: flex;
    align-items: center;
    background: var(--color-bg);
    background-image:
        radial-gradient(at 20% 15%, rgba(255, 107, 53, 0.18) 0%, transparent 50%),
        radial-gradient(at 90% 30%, rgba(78, 205, 196, 0.18) 0%, transparent 50%),
        radial-gradient(at 50% 100%, rgba(200, 182, 255, 0.22) 0%, transparent 60%);
    padding: var(--space-xxl) 0;
}

.hero__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xxl);
    align-items: center;
}

@media (min-width: 768px) {
    .hero__inner { grid-template-columns: 1.2fr 1fr; }
}

.hero__title {
    font-size: clamp(48px, 8vw, 80px);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    margin: 0 0 var(--space-l) 0;
}
.hero__title .tf-orange {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero__sub {
    font-size: 18px;
    color: var(--color-text-secondary);
    margin: 0 0 var(--space-xl) 0;
    max-width: 480px;
}

.hero__buttons {
    display: flex;
    gap: var(--space-m);
    flex-wrap: wrap;
}

.hero__visual {
    aspect-ratio: 9 / 16;
    max-width: 360px;
    margin: 0 auto;
    border-radius: var(--radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-e3);
    background: var(--color-surface);
}
.hero__visual video, .hero__visual img {
    width: 100%; height: 100%; object-fit: cover;
}

/* ── Buttons ───────────────────────────────────────────────────────── */

.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: 14px 28px;
    border-radius: var(--radius-pill);
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.08s ease;
    border: none;
    line-height: 1;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }

.btn--primary {
    background: var(--gradient-accent);
    color: white;
    box-shadow: var(--shadow-e4-cta);
}
.btn--secondary {
    background: transparent;
    border: 2px solid var(--color-hairline);
    color: var(--color-text-primary);
}

/* ── Sections ──────────────────────────────────────────────────────── */

section { padding: var(--space-xxl) 0; }

.eyebrow {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 3px;
    color: var(--color-accent-text);
    text-transform: uppercase;
    margin-bottom: var(--space-m);
}

.section__title {
    font-size: clamp(32px, 5vw, 48px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0 0 var(--space-xl) 0;
}

.features {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-l);
}
@media (min-width: 768px) {
    .features { grid-template-columns: repeat(3, 1fr); }
}

.feature {
    padding: var(--space-l);
    background: var(--color-surface);
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-e1);
    border: 1px solid var(--color-hairline);
}
.feature__icon { font-size: 32px; margin-bottom: var(--space-m); }
.feature__title { font-size: 20px; font-weight: 700; margin: 0 0 var(--space-xs) 0; }
.feature__body { color: var(--color-text-secondary); margin: 0; }

/* ── Legal content (Markdown-rendered) ─────────────────────────────── */

.legal {
    padding: var(--space-xl) 0 var(--space-xxl);
    max-width: 760px;
    margin: 0 auto;
}
.legal h1 { font-size: 40px; font-weight: 800; letter-spacing: -0.02em; }
.legal h2 { font-size: 24px; font-weight: 700; margin-top: var(--space-xl); }
.legal h3 { font-size: 18px; font-weight: 700; margin-top: var(--space-l); }
.legal p, .legal ul, .legal ol { color: var(--color-text-secondary); }
.legal code { background: var(--color-hairline); padding: 2px 6px; border-radius: 4px; font-size: 0.9em; }
.legal table {
    width: 100%; border-collapse: collapse; margin: var(--space-m) 0;
    font-size: 14px;
}
.legal th, .legal td {
    text-align: left; padding: var(--space-s);
    border-bottom: 1px solid var(--color-hairline);
}
.legal th { font-weight: 700; }
.legal hr {
    border: 0; height: 1px; background: var(--color-hairline);
    margin: var(--space-xl) 0;
}

/* ── How It Works ──────────────────────────────────────────────────── */

.how-it-works { background: var(--color-surface); }

.steps {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-l);
    counter-reset: steps;
}
@media (min-width: 768px) {
    .steps { grid-template-columns: repeat(4, 1fr); }
}

.step {
    padding: var(--space-l);
    border-radius: var(--radius-card);
    border: 1px solid var(--color-hairline);
    position: relative;
}

.step__num {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--gradient-accent);
    color: white;
    font-weight: 800;
    font-size: 18px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: var(--space-m);
    box-shadow: var(--shadow-e4-cta);
}

.step__title { font-size: 18px; font-weight: 700; margin: 0 0 var(--space-xs); }
.step__body  { color: var(--color-text-secondary); margin: 0; font-size: 15px; }

/* ── Use Cases ─────────────────────────────────────────────────────── */

.use-cases { background: var(--color-bg); }

.usecase-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-m);
    margin-top: var(--space-xl);
}

.usecase-item {
    display: flex;
    align-items: center;
    gap: var(--space-s);
    padding: var(--space-m) var(--space-l);
    background: var(--color-surface);
    border-radius: var(--radius-pill);
    border: 1px solid var(--color-hairline);
    box-shadow: var(--shadow-e1);
    font-weight: 600;
    font-size: 15px;
}

.usecase-emoji { font-size: 24px; }

/* ── Pricing ───────────────────────────────────────────────────────── */

.pricing { background: var(--color-surface); }

.pricing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-l);
    max-width: 760px;
    margin: var(--space-xl) auto 0;
}
@media (min-width: 600px) {
    .pricing-grid { grid-template-columns: 1fr 1fr; }
}

.pricing-card {
    padding: var(--space-xl);
    border-radius: var(--radius-card);
    border: 1px solid var(--color-hairline);
    display: flex; flex-direction: column;
    gap: var(--space-m);
}

.pricing-card--pro {
    border-color: var(--color-accent);
    box-shadow: 0 0 0 1px var(--color-accent), var(--shadow-e3);
    position: relative;
}

.pricing-card__badge {
    display: inline-block;
    background: var(--gradient-accent);
    color: white;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    align-self: flex-start;
}

.pricing-card__tier  { font-size: 20px; font-weight: 700; }
.pricing-card__price { font-size: 36px; font-weight: 800; letter-spacing: -0.02em; }
.pricing-card__lucky { font-size: 16px; font-weight: 500; color: var(--color-text-secondary); }

.pricing-card__list {
    list-style: none;
    padding: 0; margin: 0;
    display: flex; flex-direction: column; gap: var(--space-xs);
    flex: 1;
}
.pricing-card__list li {
    color: var(--color-text-secondary);
    font-size: 14px;
    padding-left: 20px;
    position: relative;
}
.pricing-card__list li::before {
    content: "✓";
    position: absolute; left: 0;
    color: var(--color-accent); font-weight: 700;
}

.pricing-note {
    text-align: center;
    color: var(--color-text-secondary);
    font-size: 13px;
    max-width: 560px;
    margin: var(--space-xl) auto 0;
}

/* ── Footer ────────────────────────────────────────────────────────── */

.footer {
    padding: var(--space-xxl) 0;
    border-top: 1px solid var(--color-hairline);
    text-align: center;
    color: var(--color-text-secondary);
    font-size: 14px;
}
.footer__links {
    display: flex;
    justify-content: center;
    gap: var(--space-l);
    margin-bottom: var(--space-m);
    flex-wrap: wrap;
}

/* ── Utility ───────────────────────────────────────────────────────── */

[hidden] { display: none !important; }
.text-center { text-align: center; }
