/* DM Track Timer marketing + docs site.
 * Hand-rolled CSS (no Tailwind / no build step) so the deploy is
 * "rsync the public/ directory" — same shape as the relay's
 * existing Plesk procedure.
 *
 * Brand accent matches the iPad app's AccentColor.colorset:
 *   rgb(242, 107, 46) light · rgb(255, 133, 66) dark
 * Pages are dark-themed by default since the app itself runs
 * dark + the screenshots harmonize with a dark backdrop. */

:root {
    --brand: #ff8542;
    --brand-soft: #ff854220;
    --brand-strong: #ffb085;
    --bg: #0a0a0c;
    --bg-elev: #131316;
    --bg-card: #1a1a1f;
    --border: #2a2a30;
    --text: #f4f4f5;
    --text-soft: #a1a1aa;
    --text-muted: #71717a;
    --gold: #fbbf24;
    --silver: #d4d4d8;
    --bronze: #fb923c;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI",
        Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--brand);
    text-decoration: none;
}
a:hover {
    color: var(--brand-strong);
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* ------- Top navigation ------- */
.topnav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(10, 10, 12, 0.85);
    backdrop-filter: saturate(180%) blur(16px);
    -webkit-backdrop-filter: saturate(180%) blur(16px);
    border-bottom: 1px solid var(--border);
}
.topnav-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand-mark {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 17px;
    color: var(--text);
}
.brand-mark:hover {
    color: var(--text);
    text-decoration: none;
}
.brand-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand) 0%, #ff5b1f 100%);
    box-shadow: 0 0 12px var(--brand-soft);
}
.topnav-links {
    display: flex;
    gap: 28px;
    list-style: none;
    font-size: 15px;
}
.topnav-links a {
    color: var(--text-soft);
    font-weight: 500;
}
.topnav-links a:hover {
    color: var(--text);
    text-decoration: none;
}

/* ------- Hero ------- */
.hero {
    position: relative;
    padding: 96px 24px 80px;
    text-align: center;
    overflow: hidden;
}
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 50% 40% at 50% 0%, rgba(255, 133, 66, 0.18), transparent 70%),
        radial-gradient(ellipse 40% 30% at 20% 60%, rgba(120, 90, 255, 0.10), transparent 70%);
    pointer-events: none;
}
.hero-inner {
    position: relative;
    max-width: 880px;
    margin: 0 auto;
}
.eyebrow {
    display: inline-block;
    padding: 6px 14px;
    margin-bottom: 24px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--brand);
    background: var(--brand-soft);
    border: 1px solid rgba(255, 133, 66, 0.3);
    border-radius: 999px;
}
.hero h1 {
    font-size: clamp(40px, 7vw, 64px);
    line-height: 1.05;
    letter-spacing: -0.025em;
    font-weight: 800;
    margin-bottom: 22px;
    background: linear-gradient(180deg, var(--text) 0%, var(--text-soft) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero p.lede {
    font-size: clamp(17px, 2vw, 20px);
    color: var(--text-soft);
    max-width: 640px;
    margin: 0 auto 36px;
}
.cta-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.btn {
    display: inline-block;
    padding: 13px 24px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 15px;
    transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}
.btn-primary {
    background: var(--brand);
    color: #1a0e08;
    border: 1px solid var(--brand);
}
.btn-primary:hover {
    background: var(--brand-strong);
    color: #1a0e08;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 8px 24px -8px rgba(255, 133, 66, 0.5);
}
.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    background: var(--bg-elev);
    color: var(--text);
    text-decoration: none;
    border-color: var(--text-soft);
}

/* ------- Section + grid ------- */
section {
    padding: 80px 24px;
}
.container {
    max-width: 1100px;
    margin: 0 auto;
}
.section-eyebrow {
    color: var(--brand);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 10px;
}
.section-title {
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.15;
    letter-spacing: -0.02em;
    font-weight: 700;
    margin-bottom: 14px;
}
.section-lede {
    font-size: 17px;
    color: var(--text-soft);
    max-width: 640px;
    margin-bottom: 48px;
}

.pillars {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}
.pillar {
    padding: 32px;
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: transform 0.18s ease, border-color 0.18s ease;
}
.pillar:hover {
    transform: translateY(-2px);
    border-color: var(--brand-soft);
}
.pillar-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: var(--brand-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 18px;
}
.pillar h3 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text);
}
.pillar p {
    font-size: 15px;
    color: var(--text-soft);
}

/* ------- Showcase ------- */
.showcase {
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-elev) 100%);
}
.showcase-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    margin-top: 36px;
}
.showcase-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.18s ease, border-color 0.18s ease;
}
.showcase-card:hover {
    transform: translateY(-3px);
    border-color: var(--brand);
}
.showcase-card img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    object-position: top center;
}
.showcase-card .caption {
    padding: 16px 18px;
    font-size: 14px;
    color: var(--text-soft);
}

/* ------- Docs index ------- */
.doc-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 22px;
    margin-top: 36px;
}
.doc-card {
    display: block;
    padding: 0;
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.18s ease, border-color 0.18s ease;
    color: var(--text);
}
.doc-card:hover {
    transform: translateY(-2px);
    border-color: var(--brand);
    text-decoration: none;
    color: var(--text);
}
.doc-card-image {
    aspect-ratio: 16 / 9;
    background: var(--bg-card);
    background-size: cover;
    background-position: center top;
}
.doc-card-body {
    padding: 22px 24px 26px;
}
.doc-card-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--brand);
    margin-bottom: 8px;
}
.doc-card h3 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
}
.doc-card p {
    font-size: 14px;
    color: var(--text-soft);
}

/* ------- Walkthrough step layout ------- */
.walkthrough-header {
    padding: 80px 24px 40px;
    text-align: center;
}
.walkthrough-header h1 {
    font-size: clamp(34px, 5vw, 52px);
    letter-spacing: -0.02em;
    font-weight: 800;
    margin-bottom: 18px;
}
.walkthrough-header p {
    font-size: 18px;
    color: var(--text-soft);
    max-width: 640px;
    margin: 0 auto;
}
.step {
    max-width: 1000px;
    margin: 0 auto;
    padding: 24px;
}
.step + .step {
    border-top: 1px solid var(--border);
    margin-top: 32px;
    padding-top: 56px;
}
.step-num {
    display: inline-block;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--brand);
    margin-bottom: 10px;
}
.step h2 {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 700;
    letter-spacing: -0.015em;
    margin-bottom: 14px;
}
.step p {
    font-size: 16px;
    color: var(--text-soft);
    margin-bottom: 18px;
}
.step strong {
    color: var(--text);
}
.step kbd {
    display: inline-block;
    padding: 3px 8px;
    font-size: 13px;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-bottom-width: 2px;
    border-radius: 5px;
    color: var(--text);
}
.step-shot {
    margin: 28px 0;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--bg-card);
}
.step-shot img {
    display: block;
    width: 100%;
    height: auto;
}
.step-caption {
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
    margin-top: 12px;
}
.step-callout {
    margin: 18px 0;
    padding: 16px 20px;
    background: var(--brand-soft);
    border-left: 3px solid var(--brand);
    border-radius: 4px;
    font-size: 15px;
    color: var(--text);
}
.step-callout strong {
    color: var(--brand-strong);
}

/* ------- Footer ------- */
footer {
    padding: 56px 24px 40px;
    text-align: center;
    border-top: 1px solid var(--border);
    background: var(--bg);
    color: var(--text-muted);
    font-size: 14px;
}
footer .footer-links {
    margin-bottom: 14px;
}
footer .footer-links a {
    color: var(--text-soft);
    margin: 0 12px;
}
footer .footer-meta {
    font-size: 13px;
    color: var(--text-muted);
}

/* ------- Mobile ------- */
@media (max-width: 700px) {
    .topnav-links {
        gap: 18px;
    }
    .topnav-links a:not(.btn) {
        display: none;
    }
    .hero {
        padding: 64px 20px 56px;
    }
    section {
        padding: 56px 20px;
    }
}
