/*
Theme Name: 1099Tracks
Theme URI: https://1099tracks.com
Author: 1099Tracks
Description: Marketing site theme for 1099tracks.com. Plain CSS, no build step. Pairs with the 1099tracks-owner plugin which renders /owner.
Version: 0.1.3
License: Proprietary
Text Domain: ttracks
*/

:root {
    --bg: #ffffff;
    --bg-soft: #f6f7f9;
    --ink: #0b1320;
    --ink-soft: #4a5566;
    --accent: #1f7a3f;
    --accent-soft: #e6f3ec;
    --border: #e3e6eb;
    --max-w: 1120px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.55;
    font-size: 17px;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* Header */
.site-header {
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky; top: 0; z-index: 10;
}
.site-header .container {
    display: flex; align-items: center; gap: 24px;
    padding-top: 14px; padding-bottom: 14px;
}
.site-logo { font-weight: 700; font-size: 19px; color: var(--ink); white-space: nowrap; }
.site-logo span { color: var(--accent); }
.site-nav {
    display: flex; align-items: center; gap: 22px;
    margin-left: auto;
}
.site-nav a {
    color: var(--ink-soft); font-size: 15px; font-weight: 500; white-space: nowrap;
}
/* Sign in as a green button (Max, 2026-08-28). Scoped rule because
   .site-nav a outranks a bare .cta on color; keep both halves here. */
.site-nav a.nav-signin {
    background: var(--accent); color: #ffffff; padding: 7px 13px;
    border-radius: 8px; font-weight: 600;
}
.site-nav a.nav-signin:hover { text-decoration: none; opacity: 0.92; }
.site-actions { display: flex; align-items: center; }
.cta {
    background: var(--accent); color: white; padding: 8px 14px; border-radius: 8px;
    font-size: 15px; font-weight: 600; white-space: nowrap;
}
.cta:hover { text-decoration: none; opacity: 0.92; }

/* Phone: two rows. Logo and the primary button share row one; the text links
   sit centred on row two. Four items on one line is what caused the button to
   wrap under the logo. No hamburger — three links do not earn a JS menu. */
@media (max-width: 640px) {
    .site-header .container {
        display: grid;
        grid-template-columns: 1fr auto;
        align-items: center;
        column-gap: 12px;
        row-gap: 10px;
        padding-top: 12px; padding-bottom: 12px;
    }
    /* Explicit rows. Without grid-row the nav's 1/-1 span pushes the button
       onto a third row, because it sits after the nav in the DOM. */
    .site-logo   { grid-column: 1; grid-row: 1; font-size: 20px; }
    .site-actions{ grid-column: 2; grid-row: 1; justify-self: end; }
    .site-nav    { grid-column: 1 / -1; grid-row: 2;
                   justify-content: center; gap: 26px; margin-left: 0; }
    .site-nav a  { font-size: 15px; }
    .cta         { padding: 7px 14px; font-size: 14px; }
}

/* Hero */
.hero {
    padding: 80px 0 60px;
    text-align: center;
}
.hero h1 {
    font-size: clamp(36px, 5vw, 56px);
    line-height: 1.1; margin: 0 0 18px; font-weight: 800;
}
.hero p.lede {
    font-size: 20px; color: var(--ink-soft); max-width: 640px; margin: 0 auto 32px;
}
.app-badges { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }
.app-badges img { height: 56px; }
.app-badges a { text-decoration: none; }
/* Text fallback for the Google Play link (legal-config.php ttracks_play_button). */
.play-button {
    display: inline-flex; flex-direction: column; justify-content: center;
    height: 56px; min-width: 180px; box-sizing: border-box; padding: 0 18px;
    background: #000; color: #fff; border-radius: 10px;
    font-size: 21px; font-weight: 600; line-height: 1.05; text-align: left;
}
.play-button small { font-size: 10px; font-weight: 500; letter-spacing: .04em; }

/* Feature grid */
.features {
    background: var(--bg-soft);
    padding: 64px 0;
}
.features h2 {
    text-align: center; margin: 0 0 40px; font-size: 30px; font-weight: 800;
}
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}
.feature {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
}
.feature h3 { margin: 0 0 8px; font-size: 18px; }
.feature p  { margin: 0; color: var(--ink-soft); font-size: 15px; }

/* Generic page */
.page-body {
    padding: 56px 0 96px;
}
.page-body h1 { font-size: 38px; margin: 0 0 24px; font-weight: 800; }
.page-body h2 { font-size: 22px; margin: 32px 0 12px; font-weight: 700; }
.page-body p, .page-body li { color: var(--ink); }
.page-body ul { padding-left: 22px; }

/* Pricing */
.pricing-card {
    border: 1px solid var(--border); border-radius: 14px; padding: 28px;
    max-width: 420px; margin: 24px auto; background: var(--bg);
}
.pricing-card .price { font-size: 42px; font-weight: 800; margin: 8px 0; }
.pricing-card .price small { font-size: 16px; font-weight: 500; color: var(--ink-soft); }
.pricing-card ul { padding-left: 18px; }
.pricing-card ul li { margin: 6px 0; }

/* Footer */
.site-footer {
    border-top: 1px solid var(--border);
    background: var(--bg-soft);
    padding: 32px 0 48px;
    color: var(--ink-soft);
    font-size: 14px;
}
.site-footer .container {
    display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px;
}
.site-footer a { color: var(--ink-soft); margin-right: 18px; }

/* Owner-page screens are rendered by the plugin's admin UI; the
   public /owner page itself is just the login gate. */
.owner-gate {
    padding: 80px 0; text-align: center;
}
.owner-gate .login-link {
    display: inline-block; background: var(--accent); color: white;
    padding: 12px 22px; border-radius: 10px; font-weight: 600;
}
.owner-gate .login-link:hover { text-decoration: none; }


/* ---- Single-page accordions (Pricing/FAQ/Privacy/Terms) ---- */
.accordion-stack { padding: 24px 0 64px; }
.accordion {
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg);
    margin-bottom: 14px;
    overflow: hidden;
}
.accordion summary {
    cursor: pointer;
    padding: 18px 22px;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
    content: "+";
    font-size: 22px;
    color: var(--ink-soft);
    transition: transform .15s ease;
}
.accordion[open] summary::after { content: "\2212"; }
.accordion summary h2 { margin: 0; font-size: 20px; }
.accordion summary:hover { background: var(--bg-soft); }
.accordion .accordion-body { padding: 4px 22px 24px; }
.accordion .accordion-body h3 { margin-top: 18px; }

/* ---- Affiliate portal ---- */
.affiliate-portal .stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin: 24px 0 32px;
}
.affiliate-portal .stat {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px;
    background: var(--bg);
}
.affiliate-portal .stat-label { font-size: 13px; color: var(--ink-soft); }
.affiliate-portal .stat-value { font-size: 26px; font-weight: 700; margin-top: 4px; }
.affiliate-portal .affiliate-table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0 28px;
}
.affiliate-portal .affiliate-table th,
.affiliate-portal .affiliate-table td {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
}
.affiliate-portal .affiliate-table th { font-size: 13px; color: var(--ink-soft); }

/* ---------------------------------------------------------------
   Plan comparison table (Free vs Premium) — added 2026-08-05.
   Rows mirror the six enforced tier gates in PHASE_2_SPEC.md §2.
   Horizontal scroll on narrow screens beats stacking here: the
   whole point is seeing the two columns side by side.
   --------------------------------------------------------------- */
.plan-compare { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.plan-table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
    font-size: 15px;
}
.plan-table th,
.plan-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--rule, #e6e6e6);
    text-align: center;
    vertical-align: middle;
}
.plan-table th { vertical-align: bottom; }
.plan-table .feat {
    text-align: left;
    color: var(--ink-soft);
    width: 42%;
}
.plan-table tbody .feat { color: inherit; }

.plan-table .plan-name  { display: block; font-weight: 700; font-size: 17px; }
.plan-table .plan-price { display: block; font-size: 30px; font-weight: 800; margin: 2px 0; }
.plan-table .plan-price small { font-size: 14px; font-weight: 500; color: var(--ink-soft); }
.plan-table .plan-note  { display: block; font-size: 12px; color: var(--ink-soft); font-weight: 400; }

.plan-table .plan-badge {
    display: inline-block;
    font-size: 11px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--accent, #1f8a4c);
    margin-bottom: 4px;
}

/* Premium column gets a subtle rail so the eye tracks it down the table. */
.plan-table th.is-premium,
.plan-table td.is-premium {
    background: rgba(31, 138, 76, 0.05);
    border-left: 1px solid rgba(31, 138, 76, 0.18);
    border-right: 1px solid rgba(31, 138, 76, 0.18);
}
.plan-table thead th.is-premium { border-top: 2px solid var(--accent, #1f8a4c); }
.plan-table tbody tr:last-child td.is-premium { border-bottom: 1px solid rgba(31, 138, 76, 0.18); }

.plan-table .yes { color: var(--accent, #1f8a4c); font-weight: 700; }
.plan-table .no  { color: var(--ink-soft); }

.plan-addons {
    margin-top: 28px;
    padding: 18px 20px;
    border: 1px solid var(--rule, #e6e6e6);
    border-radius: 12px;
    background: var(--bg-soft, #fafafa);
}
.plan-addons h3 { margin: 0 0 4px; font-size: 16px; }
.plan-addons p  { margin: 0 0 10px; color: var(--ink-soft); font-size: 14px; }
.plan-addons ul { margin: 0; padding-left: 18px; }
.plan-addons li { margin: 6px 0; font-size: 15px; }

/* ---------------------------------------------------------------
   Founder bio (parts/about-founder.php) — added 2026-08-18.
   Renders in two contexts: inside .page-body on /about, and inside
   an .accordion-body on the front page. Scoped to .about-founder so
   the same markup looks right in both without a context selector.
   --------------------------------------------------------------- */
.about-founder {
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-soft);
    padding: 24px 26px;
    margin: 24px 0 0;
}
/* The name is an h2 on /about and an h3 in the accordion (the caller
   passes the level so the outline stays correct). Both get the same
   size on purpose — it is the same block of content either way. */
.about-founder .about-founder-name {
    margin: 0;
    font-size: 22px;
    font-weight: 800;
}
.about-founder .about-founder-role {
    margin: 2px 0 16px;
    color: var(--accent);
    font-weight: 600;
    font-size: 15px;
    letter-spacing: 0.01em;
}
.about-founder p { margin: 0 0 14px; }
.about-founder p:last-child { margin-bottom: 0; }
.about-founder .about-founder-entity {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    color: var(--ink-soft);
    font-size: 14px;
    line-height: 1.5;
}

/* The nav carried three links when the "no hamburger" note above was
   written; About makes four, which is enough to overflow a 320px
   viewport on one line. Wrapping is the whole fix — still no JS. */
@media (max-width: 640px) {
    .site-nav { flex-wrap: wrap; row-gap: 6px; }
}
