/* Shared styles for the Tech Asylum site: landing page and legal pages. */

:root {
    --bg: #ffffff;
    --bg-soft: #f8fafc;
    --surface: #ffffff;
    --text: #0f172a;
    --text-muted: #475569;
    --border: #e2e8f0;
    --accent: #2f6bff;
    --accent-hover: #1d54e0;
    --accent-soft: #eef3ff;
    --accent-2: #0891b2;
    --hero-glow: rgba(34, 211, 238, 0.14);
    --note-bg: #ecfeff;
    --note-border: #22d3ee;
    --warn-bg: #fff7ed;
    --warn-border: #f59e0b;
    --shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 4px 16px rgba(15, 23, 42, 0.06);
    --shadow-hover: 0 2px 4px rgba(15, 23, 42, 0.06), 0 12px 28px rgba(47, 107, 255, 0.14);
    --radius: 14px;
    --max: 1080px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0f172a;
        --bg-soft: #131c33;
        --surface: #1e293b;
        --text: #f8fafc;
        --text-muted: #cbd5e1;
        --border: #334155;
        --accent: #5b8cff;
        --accent-hover: #82a7ff;
        --accent-soft: #1a2a55;
        --accent-2: #22d3ee;
        --hero-glow: rgba(34, 211, 238, 0.10);
        --note-bg: #0e2a33;
        --note-border: #22d3ee;
        --warn-bg: #2a2110;
        --warn-border: #f59e0b;
        --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 4px 16px rgba(0, 0, 0, 0.25);
        --shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.3), 0 12px 28px rgba(0, 0, 0, 0.4);
    }
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

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

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}

.site-header .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: 64px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text);
    letter-spacing: 0.2px;
}

.logo:hover {
    color: var(--text);
    text-decoration: none;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 8px;
}

.nav {
    display: flex;
    gap: 24px;
}

.nav a {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.95rem;
}

.nav a:hover {
    color: var(--text);
    text-decoration: none;
}

/* ---------- Landing page ---------- */

.hero {
    padding: 88px 0 72px;
    text-align: center;
    background:
        radial-gradient(ellipse at 80% 0%, var(--hero-glow) 0%, transparent 55%),
        linear-gradient(180deg, var(--accent-soft) 0%, var(--bg) 100%);
}

.eyebrow {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--accent-2);
    margin-bottom: 16px;
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    line-height: 1.15;
    margin: 0 auto 18px;
    max-width: 760px;
    letter-spacing: -0.5px;
}

.hero p {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 620px;
    margin: 0 auto 32px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    background: var(--accent);
    color: #fff;
    border: 1px solid var(--accent);
    transition: background 0.15s ease;
}

.btn:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: #fff;
    text-decoration: none;
}

.btn-ghost {
    background: transparent;
    color: var(--text);
    border-color: var(--border);
}

.btn-ghost:hover {
    background: var(--bg-soft);
    border-color: var(--border);
    color: var(--text);
}

.hero-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.section {
    padding: 72px 0;
}

.section-alt {
    background: var(--bg-soft);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-head {
    text-align: center;
    margin-bottom: 44px;
}

.section-head h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.1rem);
    margin: 0 0 10px;
    letter-spacing: -0.3px;
}

.section-head p {
    color: var(--text-muted);
    margin: 0 auto;
    max-width: 560px;
}

.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 24px;
}

.app-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.app-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.app-head {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.app-icon {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    border: 1px solid var(--border);
    flex-shrink: 0;
    object-fit: cover;
}

.app-head h3 {
    margin: 0 0 4px;
    font-size: 1.2rem;
}

.tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
}

.app-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0 0 20px;
    flex-grow: 1;
}

.app-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.app-links {
    display: flex;
    gap: 14px;
    font-size: 0.875rem;
}

.app-links a {
    color: var(--text-muted);
}

.app-links a:hover {
    color: var(--accent);
}

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

.value {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}

.value-icon {
    font-size: 1.6rem;
    margin-bottom: 10px;
}

.value h3 {
    margin: 0 0 6px;
    font-size: 1.05rem;
}

.value p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.contact {
    text-align: center;
}

.contact .section-head {
    margin-bottom: 12px;
}

.contact p {
    color: var(--text-muted);
    max-width: 520px;
    margin: 0 auto 24px;
}

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

.doc-hero {
    background: var(--bg-soft);
    border-bottom: 1px solid var(--border);
    padding: 48px 0 36px;
}

.doc-hero .wrap,
.doc .wrap {
    max-width: 820px;
}

.crumbs {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.crumbs a {
    color: var(--text-muted);
}

.doc-hero h1 {
    margin: 0 0 6px;
    font-size: clamp(1.7rem, 4vw, 2.3rem);
    letter-spacing: -0.3px;
}

.doc-hero .meta {
    color: var(--text-muted);
    margin: 0;
}

.doc {
    padding: 40px 0 64px;
}

.doc section {
    padding: 4px 0 20px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 24px;
}

.doc section:last-child {
    border-bottom: none;
}

.doc h2 {
    font-size: 1.3rem;
    margin: 0 0 10px;
}

.doc h3 {
    font-size: 1.05rem;
    margin: 20px 0 8px;
}

.doc p,
.doc li {
    color: var(--text-muted);
}

.doc strong {
    color: var(--text);
}

.doc ul,
.doc ol {
    padding-left: 22px;
}

.doc li {
    margin-bottom: 6px;
}

.doc code {
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 1px 5px;
    font-size: 0.9em;
}

.small {
    font-size: 0.9rem;
}

.box {
    border-radius: 10px;
    padding: 14px 18px;
    margin: 16px 0;
    border-left: 4px solid var(--accent);
    background: var(--accent-soft);
}

.box > :first-child {
    margin-top: 0;
}

.box > :last-child {
    margin-bottom: 0;
}

.box-note {
    background: var(--note-bg);
    border-left-color: var(--note-border);
}

.box-warn {
    background: var(--warn-bg);
    border-left-color: var(--warn-border);
}

.item {
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 16px;
    margin: 10px 0;
    color: var(--text-muted);
}

.item strong {
    display: block;
    margin-bottom: 2px;
}

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

.site-footer {
    border-top: 1px solid var(--border);
    padding: 40px 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 28px;
    margin-bottom: 28px;
}

.footer-grid h4 {
    margin: 0 0 10px;
    font-size: 0.85rem;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.footer-grid ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.footer-grid li {
    margin-bottom: 6px;
}

.footer-grid a {
    color: var(--text-muted);
}

.footer-grid a:hover {
    color: var(--accent);
}

.footer-grid p {
    margin: 10px 0 0;
}

.copyright {
    border-top: 1px solid var(--border);
    padding-top: 20px;
    text-align: center;
}

@media (max-width: 720px) {
    .nav {
        gap: 16px;
    }

    .nav a {
        font-size: 0.875rem;
    }

    .hero {
        padding: 56px 0 48px;
    }

    .section {
        padding: 52px 0;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 420px) {
    .nav a.hide-sm {
        display: none;
    }
}
