/*
 * Landing page. System fonts only, 360 px phones to wide screens.
 * Three sections: intro (name, what it is, Features / Demo / Install), features and privacy, AI notice and install.
 * Colours: primary green #4f7552 with a soft glow on a plain background. Light / dark follows the system.
 */
:root {
    --site-accent: #4f7552;
    --site-accent-strong: #3e5d41;
    --site-accent-soft: rgba(79, 117, 82, 0.12);
    --site-accent-text: #44664a;
    --site-glow: rgba(79, 117, 82, 0.3);
    --site-glow-strong: rgba(79, 117, 82, 0.5);
    --site-success: #6fa874;
    --site-bg: #f4f6f3;
    --site-bg-alt: rgba(79, 117, 82, 0.06);
    --site-section-alt: #eaefe9;
    --site-surface: #ffffff;
    --site-btn: #ffffff;
    --site-btn-hover: #ffffff;
    --site-border: rgba(30, 40, 31, 0.12);
    --site-border-strong: rgba(30, 40, 31, 0.22);
    --site-text: #161a16;
    --site-muted: #4a554b;
    --site-shadow: 0 1px 2px rgba(17, 17, 17, 0.06), 0 6px 20px rgba(17, 17, 17, 0.07);
    --site-radius: 14px;
    --site-font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --site-mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
    color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
    :root {
        --site-accent: #4f7552;
        --site-accent-strong: #618c65;
        --site-accent-soft: rgba(111, 158, 116, 0.2);
        --site-accent-text: #9cc7a0;
        --site-glow: rgba(79, 117, 82, 0.4);
        --site-glow-strong: rgba(97, 140, 101, 0.6);
        --site-bg: #121512;
        --site-bg-alt: rgba(255, 255, 255, 0.04);
        --site-section-alt: #171b17;
        --site-surface: #1b201b;
        --site-btn: #1e241e;
        --site-btn-hover: #263026;
        --site-border: rgba(255, 255, 255, 0.12);
        --site-border-strong: rgba(255, 255, 255, 0.24);
        --site-text: #f2f5f2;
        --site-muted: #c3ccc3;
        --site-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.35);
    }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
    margin: 0; font-family: var(--site-font); font-size: 17px; line-height: 1.6;
    color: var(--site-text); background: var(--site-bg); overflow-x: hidden;
}
a { color: var(--site-accent-text); text-underline-offset: 2px; }
a:hover { color: var(--site-accent-strong); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--site-accent); outline-offset: 2px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h3 { font-size: 1.02rem; }
p { margin: 0 0 0.9em; }
code { font-family: var(--site-mono); font-size: 0.88em; background: var(--site-bg-alt); border: 1px solid var(--site-border); border-radius: 5px; padding: 0.05em 0.35em; overflow-wrap: anywhere; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
@media (max-width: 480px) { .wrap { padding: 0 14px; } }

.skip-link { position: absolute; left: -999px; top: 8px; z-index: 1000; background: var(--site-btn); padding: 8px 12px; border-radius: 8px; }
.skip-link:focus { left: 8px; }

.logo { flex: 0 0 auto; display: block; filter: drop-shadow(0 0 8px var(--site-glow)); }

/* ---- buttons ---- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 46px; padding: 10px 20px; border-radius: 12px;
    font: inherit; font-size: 16px; font-weight: 600; line-height: 1.2; text-decoration: none; cursor: pointer;
    color: var(--site-text); background: var(--site-btn); border: 1px solid var(--site-border-strong); box-shadow: var(--site-shadow);
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.12s ease, box-shadow 0.15s ease;
}
.btn:hover { color: var(--site-text); background: var(--site-btn-hover); border-color: var(--site-accent); transform: translateY(-1px); }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.btn-primary, .btn-primary:hover { color: #fff; }
.btn-primary { background: var(--site-accent); border-color: var(--site-accent); box-shadow: 0 0 20px var(--site-glow); }
.btn-primary:hover { background: var(--site-accent-strong); border-color: var(--site-accent-strong); box-shadow: 0 0 28px var(--site-glow-strong); }
.btn-small { min-height: 40px; padding: 7px 14px; font-size: 15px; }

/* ---- 1. intro: the whole first screen ---- */
.intro {
    position: relative; min-height: 100vh; display: flex; align-items: center;
    padding: 72px 0 48px; text-align: center;
    background: radial-gradient(60% 50% at 50% 38%, var(--site-accent-soft), transparent 70%);
}
@supports (min-height: 100svh) { .intro { min-height: 100svh; } }
.intro-inner { display: flex; flex-direction: column; align-items: center; }
.intro-logo { width: clamp(64px, 12vw, 96px); height: auto; margin-bottom: 22px; filter: drop-shadow(0 0 22px var(--site-glow)); }
.intro-name { font-size: clamp(2.1rem, 1.3rem + 3.6vw, 3.6rem); font-weight: 800; letter-spacing: -0.025em; margin-bottom: 0.35em; }
.intro-about { max-width: 640px; font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem); color: var(--site-muted); margin-bottom: 1.8em; }
/* the demo button (big, accent colour), and under it a row of light chips: Features · Install · GitHub */
.intro-actions { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.btn-hero {
    min-height: 62px; padding: 14px 40px; font-size: 19px; border-radius: 999px;
    box-shadow: 0 0 0 6px var(--site-accent-soft), 0 10px 30px var(--site-glow);
}
.btn-hero:hover { box-shadow: 0 0 0 8px var(--site-accent-soft), 0 12px 36px var(--site-glow-strong); }
.btn-hero svg { width: 21px; height: 21px; }
.intro-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.chip {
    display: inline-flex; align-items: center; gap: 7px; padding: 8px 16px; border-radius: 999px;
    font-size: 15px; font-weight: 600; text-decoration: none;
    color: var(--site-accent-text); background: var(--site-accent-soft); border: 1px solid transparent;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.chip:hover { color: var(--site-accent-text); border-color: var(--site-accent); background: transparent; }
.chip svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.intro-meta { margin: 28px 0 0; font-size: 14px; color: var(--site-muted); }
@media (max-width: 560px) {
    .intro-actions { width: 100%; max-width: 360px; }
    .btn-hero { width: 100%; }
}

/* ---- sections ---- */
.section { padding: clamp(48px, 7vw, 92px) 0; }
.section-alt { background: var(--site-section-alt); border-top: 1px solid var(--site-border); }
.section-title { display: flex; align-items: center; justify-content: center; gap: 12px; font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.2rem); margin-bottom: 0.3em; }
.section-title .logo { filter: drop-shadow(0 0 6px var(--site-glow)); }
.section-lead { text-align: center; color: var(--site-muted); font-size: 1.05rem; margin: 0 auto 2em; max-width: 640px; }
#install .section-title { margin-bottom: 1.1em; }

.card { background: var(--site-surface); border: 1px solid var(--site-border); border-radius: var(--site-radius); box-shadow: var(--site-shadow); padding: 18px; }
.card p { color: var(--site-muted); font-size: 15px; margin-bottom: 0; line-height: 1.5; }
.icon-box {
    display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 40px; height: 40px;
    border-radius: 11px; background: var(--site-accent-soft); color: var(--site-accent-text);
}
.icon-box svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* features: compact cards, icon beside the text */
.feature-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.feature { display: flex; gap: 14px; align-items: flex-start; }
.feature h3 { margin-bottom: 0.2em; }

/* privacy: below the features */
.privacy { margin-top: 22px; padding: 20px 22px; }
.privacy h3 { display: flex; align-items: center; gap: 10px; font-size: 1.1rem; margin-bottom: 14px; }
.icon-box-small { width: 32px; height: 32px; border-radius: 9px; }
.icon-box-small svg { width: 17px; height: 17px; }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 10px 28px; }
.check-list li { position: relative; padding-left: 30px; color: var(--site-muted); font-size: 15px; line-height: 1.5; }
.check-list li::before {
    content: ''; position: absolute; left: 0; top: 0.15em; width: 19px; height: 19px; border-radius: 5px;
    background: var(--site-accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 11px no-repeat;
}

/* AI notice: at the top of the install section */
.ai-notice {
    display: flex; align-items: flex-start; gap: clamp(14px, 2.5vw, 22px); max-width: 860px; margin: 0 auto 26px;
    padding: clamp(18px, 2.6vw, 24px) clamp(18px, 3vw, 28px); border-radius: var(--site-radius);
    border: 1px solid var(--site-border); background: var(--site-surface); box-shadow: var(--site-shadow);
    background-image: linear-gradient(120deg, var(--site-accent-soft), transparent 55%);
}
.ai-icon { width: 48px; height: 48px; margin: 0; border-radius: 13px; background: var(--site-accent); color: #fff; filter: drop-shadow(0 0 12px var(--site-glow)); }
.ai-icon svg { width: 24px; height: 24px; }
.ai-body h3 { font-size: 1.1rem; margin-bottom: 0.3em; }
.ai-body p { margin: 0; color: var(--site-muted); font-size: 15.5px; }
.ai-body .ai-lead { color: var(--site-text); font-weight: 600; margin-bottom: 0.35em; }
@media (max-width: 480px) { .ai-notice { flex-direction: column; } }

.install-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 14px; }
.install-card { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.install-card h3 { margin: 0; }
.install-card p { margin: 0; }
.install-card .btn { margin-top: auto; }
.step-badge {
    display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px;
    border-radius: 8px; background: var(--site-accent); color: #fff; font-weight: 700; font-size: 15px;
}
.getting-started { margin: 24px 0 0; color: var(--site-muted); text-align: center; }

/* ---- footer: the same as on tycho.anulab.tech (dark in both modes) ---- */
.siteFooter {
    position: relative; color: #e0e0e0; font-family: var(--site-mono);
    padding: 8rem 2rem 2rem; display: flex; flex-direction: column; align-items: center;
    margin-top: auto; overflow: hidden; background: var(--site-section-alt);   /* continues the install section */
}
.footer-bg-layer { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.layer-1 { background-color: rgba(30, 30, 30, 0.4); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: crystalLayer1 8s ease-in-out infinite alternate; }
.layer-2 { background-color: rgba(25, 25, 25, 0.8); animation: crystalLayer2 6s ease-in-out infinite alternate; }
.layer-3 { background-color: rgba(20, 20, 20, 0.9); animation: crystalLayer3 4s ease-in-out infinite alternate; }
@keyframes crystalLayer1 {
    0% { clip-path: polygon(0% 4vw, 20% 0vw, 45% 5vw, 75% 1vw, 100% 3vw, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 1vw, 30% 6vw, 60% 1vw, 85% 5vw, 100% 2vw, 100% 100%, 0% 100%); }
}
@keyframes crystalLayer2 {
    0% { clip-path: polygon(0% 6vw, 25% 3vw, 55% 8vw, 80% 4vw, 100% 7vw, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 4vw, 35% 7vw, 50% 3vw, 70% 8vw, 100% 4vw, 100% 100%, 0% 100%); }
}
@keyframes crystalLayer3 {
    0% { clip-path: polygon(0% 9vw, 30% 5vw, 50% 10vw, 70% 6vw, 100% 8vw, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 7vw, 20% 9vw, 45% 6vw, 75% 10vw, 100% 6vw, 100% 100%, 0% 100%); }
}
.footer-bottom { position: relative; z-index: 2; width: 100%; max-width: 800px; padding-top: 1.5rem; text-align: center; font-size: 0.9rem; letter-spacing: 0.5px; }
.footer-bottom p { margin: 0 0 0.5rem 0; }
.footer-bottom a { color: #e0e0e0; }
.footer-bottom a:hover { color: #ffffff; text-shadow: 0 0 10px var(--site-glow-strong); }
.footer-bottom .footer-project { margin-bottom: 1rem; }
.heart { color: var(--site-success); }
.version { font-variant-numeric: tabular-nums; }
@media (max-width: 768px) {
    .siteFooter { padding-top: 6rem; }
    .layer-1 { animation: crystalMobile1 8s ease-in-out infinite alternate; }
    .layer-2 { animation: crystalMobile2 6s ease-in-out infinite alternate; }
    .layer-3 { animation: crystalMobile3 4s ease-in-out infinite alternate; }
}
@keyframes crystalMobile1 {
    0% { clip-path: polygon(0% 30px, 30% 10px, 60% 35px, 100% 15px, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 15px, 40% 40px, 70% 15px, 100% 30px, 100% 100%, 0% 100%); }
}
@keyframes crystalMobile2 {
    0% { clip-path: polygon(0% 45px, 35% 25px, 65% 50px, 100% 30px, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 30px, 25% 45px, 55% 25px, 100% 45px, 100% 100%, 0% 100%); }
}
@keyframes crystalMobile3 {
    0% { clip-path: polygon(0% 60px, 25% 45px, 50% 65px, 75% 50px, 100% 55px, 100% 100%, 0% 100%); }
    100% { clip-path: polygon(0% 50px, 35% 60px, 60% 45px, 100% 60px, 100% 100%, 0% 100%); }
}
@media (prefers-reduced-motion: reduce) { .footer-bg-layer { animation-play-state: paused; } }
