/* ============================================================
   TryOnFusion — landing page
   Editorial light theme: warm paper background, near-black ink,
   a serif display face for headlines and Inter for everything
   else. The brand purple is an accent, used sparingly.
   ============================================================ */

:root {
    --paper:        #FBFAF8;
    --paper-2:      #F4F1EC;       /* tinted section band */
    --ink:          #111014;
    --ink-2:        #3B3A41;
    --muted:        #6E6C75;
    --line:         rgba(17, 16, 20, 0.09);
    --line-strong:  rgba(17, 16, 20, 0.16);
    --accent:       #6C5CE7;       /* brand purple — matches the app */
    --accent-deep:  #4C3DC8;
    --accent-soft:  #ECE9FD;
    --night:        #121018;       /* privacy band */
    --night-2:      #1C1924;

    --font-display: 'Instrument Serif', 'Iowan Old Style', Georgia, serif;
    --font-body:    'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

    --radius:       20px;
    --radius-sm:    12px;
    --shadow-lg:    0 40px 80px -24px rgba(26, 18, 60, 0.28), 0 12px 24px -12px rgba(26, 18, 60, 0.18);
    --shadow-md:    0 12px 32px -12px rgba(26, 18, 60, 0.22);

    --container:    1160px;
    --gutter:       24px;
}

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

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

body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 17px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a { color: inherit; }

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

.skip-link {
    position: absolute;
    left: 16px;
    top: -48px;
    padding: 10px 16px;
    background: var(--ink);
    color: #fff;
    border-radius: 999px;
    z-index: 100;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}
.skip-link:focus { top: 12px; }

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

/* ---------------- Type ---------------- */

h1, h2 {
    font-family: var(--font-display);
    font-weight: 400;
    letter-spacing: -0.015em;
    line-height: 1.02;
    color: var(--ink);
}

h1 { font-size: clamp(48px, 7.2vw, 92px); }
h2 { font-size: clamp(36px, 4.6vw, 58px); }
h1 em, h2 em { font-style: italic; color: var(--accent-deep); }

h3 {
    font-size: 19px;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.eyebrow {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent-deep);
    margin-bottom: 18px;
}
.eyebrow-light { color: #B8AEFF; }

.lede {
    font-size: clamp(18px, 1.6vw, 20px);
    line-height: 1.55;
    color: var(--ink-2);
    max-width: 34em;
}
.lede-light { color: rgba(255, 255, 255, 0.72); }

.muted { color: var(--muted); }
.muted a { color: var(--ink); text-underline-offset: 3px; }

/* ---------------- Buttons & links ---------------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    padding: 0 20px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, background-color 0.2s ease;
}
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #2A2830; transform: translateY(-1px); }

.text-link {
    display: inline-block;
    margin-top: 28px;
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.35);
    padding-bottom: 2px;
    transition: border-color 0.2s ease;
}
.text-link:hover { border-color: #fff; }

/* ---------------- Header ---------------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(251, 250, 248, 0.82);
    -webkit-backdrop-filter: saturate(180%) blur(16px);
    backdrop-filter: saturate(180%) blur(16px);
    border-bottom: 1px solid transparent;
    transition: border-color 0.25s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    letter-spacing: -0.02em;
}
.brand img { width: 32px; height: 32px; }

.nav { display: flex; gap: 32px; }
.nav a {
    font-size: 15px;
    font-weight: 500;
    color: var(--ink-2);
    text-decoration: none;
    transition: color 0.2s ease;
}
.nav a:hover { color: var(--ink); }

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

.hero { padding: 72px 0 96px; }

.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 56px;
}

.hero-copy h1 { margin-bottom: 26px; }
.hero-copy .lede { margin-bottom: 36px; }

.store-badges {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 16px 20px;
}
.store-badges--center { justify-content: center; }

/* Both badges render at the same height, as Google's and Apple's badge
   guidelines ask. Apple's clear space (a quarter of the badge height) is
   kept by the gap above. */
.store-badge {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    border-radius: 10px;
}
.store-badge img { height: 52px; width: auto; }
a.store-badge { transition: transform 0.2s ease; }
a.store-badge:hover { transform: translateY(-2px); }

.soon-tag {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent-deep);
    background: var(--accent-soft);
    border-radius: 999px;
    padding: 3px 10px;
    line-height: 1.4;
}

.hero-trust {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
    margin-top: 32px;
    font-size: 14px;
    color: var(--muted);
}
.hero-trust li { display: inline-flex; align-items: center; gap: 8px; }
.hero-trust li::before {
    content: "";
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent-soft) no-repeat center / 10px
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2 5 8.6l4.5-5' fill='none' stroke='%234C3DC8' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    flex: none;
}

/* ---- Phone illustration ---- */

.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    padding: 24px 0 40px;
}

.glow {
    position: absolute;
    inset: 4% 0 0;
    background:
        radial-gradient(closest-side at 50% 45%, rgba(108, 92, 231, 0.30), transparent 70%),
        radial-gradient(closest-side at 70% 70%, rgba(236, 196, 160, 0.45), transparent 70%);
    filter: blur(20px);
    z-index: 0;
}

.phone {
    position: relative;
    z-index: 1;
    width: min(310px, 76vw);
    aspect-ratio: 9 / 19;
    padding: 11px;
    border-radius: 52px;
    background: linear-gradient(145deg, #2B2A30, #0D0C10 60%);
    box-shadow: var(--shadow-lg), inset 0 0 0 1.5px rgba(255, 255, 255, 0.08);
}

.phone-screen {
    position: relative;
    height: 100%;
    border-radius: 42px;
    background: #F6F4F0;
    overflow: hidden;
    padding: 14px 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.island {
    position: absolute;
    top: 11px;
    left: 50%;
    width: 96px;
    height: 28px;
    transform: translateX(-50%);
    background: #0D0C10;
    border-radius: 999px;
}

.status {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    padding: 2px 8px 0;
    height: 28px;
}
.status-icons { display: inline-flex; gap: 4px; align-items: flex-end; }
.status-icons i { display: block; width: 4px; background: var(--ink); border-radius: 1px; }
.status-icons i:nth-child(1) { height: 6px; }
.status-icons i:nth-child(2) { height: 9px; }
.status-icons i:nth-child(3) { height: 12px; }

.app-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
}
.app-title { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; }
.star-pill {
    font-size: 12px;
    font-weight: 600;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 10px;
}

.product-card {
    background: #fff;
    border-radius: 22px;
    border: 1px solid var(--line);
    overflow: hidden;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}
.product-art {
    flex: 1;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #EFEAE2, #E6DFD4);
    padding: 12px;
}
.product-art svg { height: 100%; width: auto; max-height: 220px; }
.product-meta { padding: 12px 14px 14px; display: flex; flex-direction: column; }
.product-name { font-size: 15px; font-weight: 600; }
.product-src { font-size: 12px; color: var(--muted); }

.chips { display: flex; gap: 8px; }
.chip {
    font-size: 12px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--line);
    color: var(--ink-2);
}
.chip-on { background: var(--ink); color: #fff; border-color: var(--ink); }

.progress {
    height: 4px;
    border-radius: 999px;
    background: rgba(17, 16, 20, 0.08);
    overflow: hidden;
}
.progress span {
    display: block;
    height: 100%;
    width: 40%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent), #A99BFF);
    animation: progress 2.8s ease-in-out infinite;
}
@keyframes progress {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(260%); }
}

.gen-btn {
    height: 46px;
    border-radius: 999px;
    background: var(--ink);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* The notification the app sends when a try-on is ready. */
.toast {
    position: absolute;
    z-index: 2;
    top: 18%;
    right: max(-8px, calc(50% - 250px));
    width: min(290px, 72vw);
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.86);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-md);
    animation: toast-in 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 1.2s both;
}
.toast img {
    width: 36px;
    height: 36px;
    border-radius: 9px;
    background: #1A0A2E;
    padding: 4px;
    flex: none;
}
.toast p { font-size: 13px; line-height: 1.35; }
.toast-top { display: flex; justify-content: space-between; color: var(--muted); font-size: 12px !important; }
.toast-top strong { color: var(--ink-2); font-weight: 600; }
.toast-title { font-weight: 600; }
.toast-body { color: var(--ink-2); }

@keyframes toast-in {
    from { opacity: 0; transform: translateY(-14px) scale(0.97); }
    to   { opacity: 1; transform: none; }
}

/* ---------------- Works-with strip ---------------- */

.works {
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}
.works-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px 36px;
    padding-top: 22px;
    padding-bottom: 22px;
}
.works-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
}
.works ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 36px;
}
.works li {
    font-family: var(--font-display);
    font-size: 24px;
    color: var(--ink-2);
}

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

.section { padding: 120px 0; }
.section-tint { background: var(--paper-2); }

.section-head { max-width: 720px; margin-bottom: 64px; }
.section-head h2 + .lede,
.section-head h2 + .muted { margin-top: 20px; }

/* How it works */
.steps {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    counter-reset: none;
}
.step {
    border-top: 1px solid var(--line-strong);
    padding-top: 28px;
}
.step-num {
    display: block;
    font-family: var(--font-display);
    font-size: 56px;
    line-height: 1;
    color: var(--accent);
    margin-bottom: 22px;
}
.step h3 { margin-bottom: 10px; }
.step p { color: var(--ink-2); font-size: 16px; }

/* Features */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.feature {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px 30px 34px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.feature h3 { margin: 22px 0 8px; }
.feature p { color: var(--ink-2); font-size: 16px; }
/* The lead feature, set in ink so the grid has one clear entry point. */
.feature.feature-wide {
    background: var(--ink);
    color: #fff;
    border-color: var(--ink);
}
.feature.feature-wide p { color: rgba(255, 255, 255, 0.72); }
.feature.feature-wide .icon { stroke: #B8AEFF; background: rgba(255, 255, 255, 0.08); }

.icon {
    width: 48px;
    height: 48px;
    padding: 12px;
    border-radius: 14px;
    background: var(--accent-soft);
    fill: none;
    stroke: var(--accent-deep);
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Privacy band */
.section-dark {
    background: radial-gradient(120% 90% at 0% 0%, #241D3B 0%, var(--night) 55%);
    color: #fff;
}
.section-dark h2 { color: #fff; }
.privacy-inner {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 64px;
    align-items: start;
}
.privacy-inner .section-head { margin-bottom: 0; }
.privacy-list {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.privacy-list li {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: var(--radius);
    padding: 26px 24px;
}
.privacy-list h3 { color: #fff; margin-bottom: 8px; font-size: 17px; }
.privacy-list p { color: rgba(255, 255, 255, 0.66); font-size: 15px; }

/* FAQ */
.faq-inner {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 64px;
    align-items: start;
}
.faq-inner .section-head { position: sticky; top: 108px; margin-bottom: 0; }

.faq-list { border-top: 1px solid var(--line-strong); }
.faq-item { border-bottom: 1px solid var(--line-strong); }
.faq-item summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 24px 0;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.01em;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
    content: "";
    width: 12px;
    height: 12px;
    flex: none;
    border-right: 1.8px solid var(--ink);
    border-bottom: 1.8px solid var(--ink);
    transform: translateY(-3px) rotate(45deg);
    transition: transform 0.25s ease;
}
.faq-item[open] summary::after { transform: translateY(3px) rotate(-135deg); }
.faq-item p {
    color: var(--ink-2);
    padding: 0 40px 26px 0;
    font-size: 16px;
}
.faq-item p a { color: var(--ink); text-underline-offset: 3px; }

/* Download */
.download { padding-top: 40px; }
.download-card {
    text-align: center;
    border-radius: 32px;
    padding: 80px 32px;
    background:
        radial-gradient(60% 80% at 50% 0%, rgba(108, 92, 231, 0.16), transparent 70%),
        var(--paper-2);
    border: 1px solid var(--line);
}
.download-logo {
    width: 72px;
    height: 72px;
    margin: 0 auto 28px;
    border-radius: 18px;
    background: #1A0A2E;
    padding: 8px;
    box-shadow: var(--shadow-md);
}
.download-card h2 { margin-bottom: 16px; }
.download-card .lede { margin: 0 auto 36px; }

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

.site-footer {
    border-top: 1px solid var(--line);
    padding: 72px 0 40px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 40px;
}
.footer-brand p { color: var(--muted); margin-top: 14px; font-size: 15px; }
.footer-brand .brand img { width: 28px; height: 28px; }
.footer-col h4 {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 16px;
}
.footer-col a {
    display: block;
    color: var(--ink-2);
    text-decoration: none;
    font-size: 15px;
    margin-bottom: 10px;
}
.footer-col a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

.footer-bottom {
    margin-top: 56px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px 40px;
    font-size: 13px;
    color: var(--muted);
}
.trademarks { max-width: 640px; font-size: 12px; line-height: 1.55; }

/* ---------------- Motion ---------------- */

.js .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js .reveal { opacity: 1; transform: none; transition: none; }
    .toast { animation: none; }
    .progress span { animation: none; width: 65%; }
    .feature, a.store-badge, .btn { transition: none; }
}

/* ---------------- Responsive ---------------- */

@media (max-width: 1024px) {
    .features { grid-template-columns: repeat(2, 1fr); }
    .privacy-inner, .faq-inner { grid-template-columns: 1fr; gap: 48px; }
    .faq-inner .section-head { position: static; }
}

@media (max-width: 860px) {
    .nav { display: none; }
    .hero { padding: 40px 0 72px; }
    .hero-inner { grid-template-columns: 1fr; gap: 40px; }
    .hero-visual { padding-top: 8px; }
    .toast { right: 0; top: 10%; }
    .steps { grid-template-columns: 1fr; gap: 28px; }
    .section { padding: 88px 0; }
    .section-head { margin-bottom: 44px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 600px) {
    :root { --gutter: 16px; }
    body { font-size: 16px; }
    .header-inner { height: 60px; }
    .header-cta { height: 38px; padding: 0 16px; font-size: 14px; }
    .features { grid-template-columns: 1fr; }
    .privacy-list { grid-template-columns: 1fr; }
    .works li { font-size: 20px; }
    .works ul { gap: 6px 20px; }
    .download-card { padding: 56px 20px; border-radius: 24px; }
    .store-badge img { height: 48px; }
    .toast { width: min(260px, 78vw); }
    .faq-item summary { font-size: 17px; }
    .faq-item p { padding-right: 0; }
}
