/* The home page for visitors (templates/core/home.html, decision of 8.11.2026).
   Only loaded there. Self-served, no web fonts. Animations only with JavaScript
   (class hx-js on <html>, static/js/home.js) and never with reduced motion. */

:root {
    --hx-ink: #0f1f18;
    --hx-mint: #7fd6a4;
    --hx-teal: #1f8f7a;
    --hx-sky: #bfe0ff;
    --hx-peach: #ffd9b3;
    --hx-deep: #123d2b;
    --hx-glass: rgba(255, 255, 255, 0.72);
    --hx-phone-w: 270px;
}

main.home { max-width: none; padding: 0; overflow-x: clip; }
.hx-inner { max-width: 72rem; margin: 0 auto; padding-left: 16px; padding-right: 16px; }

/* ---------- Hero ---------- */
.hx-hero { position: relative; padding: 2.2rem 0 3rem; overflow: hidden; isolation: isolate; }
.hx-blobs { position: absolute; inset: -20% -10% auto; height: 140%; z-index: -1; filter: blur(60px); opacity: 0.75; }
.hx-blobs span { position: absolute; border-radius: 50%; }
.hx-blobs span:nth-child(1) { width: 46vmax; height: 46vmax; left: -12vmax; top: -6vmax; background: var(--hx-mint); }
.hx-blobs span:nth-child(2) { width: 38vmax; height: 38vmax; right: -10vmax; top: 4vmax; background: var(--hx-sky); }
.hx-blobs span:nth-child(3) { width: 30vmax; height: 30vmax; left: 30%; top: 30vmax; background: var(--hx-peach); opacity: 0.8; }

/* minmax(0, 1fr): the phone must not widen the column past the screen (360 px phones) */
.hx-hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2.5rem; align-items: center; }
.hx-eyebrow {
    display: flex; width: fit-content; letter-spacing: 0; line-height: 1.3; align-items: center; gap: 0.5rem; margin: 0 0 1rem;
    padding: 0.35rem 0.8rem; border-radius: 999px; background: var(--hx-glass);
    border: 1px solid rgba(47, 111, 79, 0.15); color: var(--accent-strong);
    font-size: 0.82rem; font-weight: 600; backdrop-filter: blur(8px);
}
.hx-dot { width: 8px; height: 8px; border-radius: 50%; background: #2fbf71; box-shadow: 0 0 0 4px rgba(47, 191, 113, 0.18); }
.hx-title {
    margin: 0 0 1rem; font-size: clamp(2.1rem, 8.5vw, 4rem); line-height: 1.04;
    font-weight: 800; letter-spacing: -0.035em; color: var(--hx-ink);
}
.hx-title-end { display: block; }
.hx-rotate { display: inline-block; position: relative; }
.hx-word {
    display: inline-block;
    background: linear-gradient(100deg, var(--accent) 0%, var(--hx-teal) 45%, #4cc38a 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hx-lead { margin: 0 0 1.4rem; max-width: 36rem; font-size: 1.08rem; line-height: 1.55; color: var(--ink-soft); }
.hx-lead .hx-free { font-weight: 700; color: var(--accent); }

.hx-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.hx-actions .btn { min-height: 46px; padding: 0.6rem 1.2rem; font-size: 1rem; border-radius: 12px; }
.hx-cta { box-shadow: 0 10px 24px rgba(47, 111, 79, 0.28); }
/* The two hero buttons (12.11.2026): a gradient pill with an arrow, a glass pill beside it */
.hx-actions-hero { gap: 0.75rem; }
.hx-actions-hero .btn {
    min-height: 54px; padding: 0.8rem 1.7rem; border-radius: 999px; gap: 0.45rem;
    font-size: 1.1rem; font-weight: 700; letter-spacing: 0.01em;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-position 0.45s ease, background-color 0.18s ease;
}
.hx-actions-hero .hx-cta {
    color: #fff; border: 0;
    background: linear-gradient(100deg, var(--accent) 0%, var(--hx-teal) 50%, #4cc38a 100%);
    background-size: 200% 100%; background-position: 0 0;
    box-shadow: 0 14px 30px rgba(31, 143, 122, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
/* Bigger and with a slow glow (16.11.2026): the one action of the hero; bigger still
   since the search field left (2.12.2026) */
.hx-actions-hero .hx-cta {
    min-height: 76px; padding: 1.2rem 3.4rem; font-size: 1.55rem; font-weight: 800;
    animation: hx-cta-glow 2.6s ease-in-out infinite;
}
@keyframes hx-cta-glow {
    0%, 100% { box-shadow: 0 14px 30px rgba(31, 143, 122, 0.38), 0 0 0 0 rgba(76, 195, 138, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.28); }
    50% { box-shadow: 0 18px 40px rgba(31, 143, 122, 0.5), 0 0 0 12px rgba(76, 195, 138, 0), inset 0 1px 0 rgba(255, 255, 255, 0.28); }
}
@media (max-width: 559px) { .hx-actions-hero .hx-cta { width: 100%; justify-content: center; } }
.hx-actions-hero .hx-cta svg { width: 28px; height: 28px; stroke-width: 2.4; transition: transform 0.18s ease; }
.hx-actions-hero .hx-cta:hover, .hx-actions-hero .hx-cta:focus-visible {
    color: #fff; background-position: 100% 0; transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(31, 143, 122, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
.hx-actions-hero .hx-cta:hover svg { transform: translateX(4px); }
.hx-login {
    background: var(--hx-glass); color: var(--accent); border: 2px solid var(--accent);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    box-shadow: 0 8px 22px rgba(15, 31, 24, 0.08);
}
.hx-login:hover, .hx-login:focus-visible {
    background: #fff; color: var(--accent); transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(15, 31, 24, 0.14);
}
/* The apps in their stores under the button (2.12.2026): black like the store badges */
.store-badges { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1.1rem 0 0; }
.store-badge {
    display: inline-flex; align-items: center; gap: 0.55rem; min-height: 52px; padding: 0.4rem 1.1rem 0.4rem 0.85rem;
    border-radius: 11px; border: 1px solid #a6a6a6; background: #000; color: #fff; text-decoration: none;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.store-badge:hover, .store-badge:focus-visible { color: #fff; transform: translateY(-2px); box-shadow: 0 10px 22px rgba(15, 31, 24, 0.22); }
.store-logo { flex: none; width: 26px; height: 26px; }
.store-text { display: flex; flex-direction: column; line-height: 1.1; text-align: left; }
.store-small { font-size: 0.7rem; letter-spacing: 0.02em; }
.store-name { font-size: 1.2rem; font-weight: 600; letter-spacing: -0.01em; }
@media (prefers-reduced-motion: reduce) { .store-badge { transition: none; } .store-badge:hover { transform: none; } }
.hx-free-note { display: flex; align-items: center; gap: 0.35rem; margin: 0.75rem 0 0 0.3rem; font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); }
.hx-free-note svg { width: 16px; height: 16px; stroke-width: 2.4; color: var(--accent); }
@media (prefers-reduced-motion: reduce) {
    .hx-actions-hero .btn, .hx-actions-hero .hx-cta svg { transition: none; }
    .hx-actions-hero .hx-cta { animation: none; }
    .hx-actions-hero .btn:hover, .hx-actions-hero .btn:focus-visible { transform: none; }
    .hx-actions-hero .hx-cta:hover svg { transform: none; }
}

/* The phone frame */
.hx-hero-device { position: relative; justify-self: center; padding: 1rem 2.5rem; }
.hx-phone {
    position: relative; width: var(--hx-phone-w); aspect-ratio: 9 / 19.5;
    padding: 10px; border-radius: 46px; background: #0d1512;
    box-shadow: 0 0 0 2px #2a3732, 0 40px 80px -20px rgba(15, 31, 24, 0.45), 0 18px 36px -18px rgba(15, 31, 24, 0.4);
}
.hx-phone::before {
    content: ""; position: absolute; top: 18px; left: 50%; z-index: 2;
    width: 30%; height: 22px; transform: translateX(-50%); border-radius: 999px; background: #0d1512;
}
.hx-screen { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: 36px; background: var(--bg); }
.hx-screen img { position: absolute; top: 0; left: 0; width: 100%; height: auto; display: block; }
.hx-slide, .hx-shot { opacity: 0; transition: opacity 0.8s ease; }
.hx-slide.is-on, .hx-shot.is-on { opacity: 1; }
/* the screen starts below the notch */
.hx-screen img { padding-top: 26px; background: var(--surface); }

/* Floating glass chips */
.hx-chip {
    position: absolute; z-index: 3; display: flex; align-items: center; gap: 0.45rem;
    padding: 0.55rem 0.85rem; border-radius: 14px; background: var(--hx-glass);
    border: 1px solid rgba(255, 255, 255, 0.8); backdrop-filter: blur(12px);
    box-shadow: 0 12px 30px rgba(15, 31, 24, 0.14); font-size: 0.85rem; font-weight: 650;
    color: var(--hx-ink); white-space: nowrap;
}
.hx-chip svg { width: 18px; height: 18px; color: var(--accent); }
.hx-count { padding: 0.1rem 0.45rem; border-radius: 7px; background: var(--accent-soft); color: var(--accent-strong); }
.hx-chip-1 { top: 12%; left: -0.2rem; }
.hx-chip-2 { top: 46%; right: -0.6rem; }
.hx-chip-3 { bottom: 10%; left: 0; }

/* ---------- Marquee of the nutrients ---------- */
.hx-marquee {
    overflow: hidden; padding: 0.9rem 0; background: var(--hx-ink); color: #dff3e8;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.hx-track { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.6rem; padding: 0 16px; }
.hx-track span { font-size: 0.95rem; font-weight: 600; white-space: nowrap; }
.hx-track span:nth-child(3n + 1) { color: var(--hx-mint); }
.hx-track span[aria-hidden] { display: none; }

/* ---------- Figures ---------- */
.hx-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; padding-top: 2.5rem; padding-bottom: 1rem; }
.hx-stat { padding: 1.2rem 1rem; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.hx-stat strong {
    display: block; font-size: clamp(1.7rem, 6vw, 2.6rem); line-height: 1.1; font-weight: 800; letter-spacing: -0.03em;
    background: linear-gradient(100deg, var(--accent), var(--hx-teal)); -webkit-background-clip: text; background-clip: text; color: transparent;
    font-variant-numeric: tabular-nums;
}
.hx-stat span { display: block; margin-top: 0.35rem; color: var(--ink-soft); font-size: 0.9rem; overflow-wrap: break-word; }

/* ---------- Section heads ---------- */
.hx-head { max-width: 40rem; margin: 0 auto 2rem; text-align: center; }
.hx-head h2 { margin: 0 0 0.6rem; font-size: clamp(1.6rem, 5vw, 2.4rem); line-height: 1.1; font-weight: 800; letter-spacing: -0.03em; color: var(--hx-ink); }
.hx-head p { margin: 0; color: var(--ink-soft); font-size: 1.02rem; }
.hx-kicker { margin: 0 0 0.5rem; color: var(--hx-teal); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }

/* ---------- Story ---------- */
.hx-story { padding-top: 3.5rem; padding-bottom: 2rem; }
.hx-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 2.5rem; }
.hx-step { position: relative; padding-left: 3.2rem; }
.hx-num {
    position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 2.3rem; height: 2.3rem;
    border-radius: 50%; background: var(--accent-soft); color: var(--accent-strong); font-weight: 800;
}
.hx-step h3 { margin: 0.2rem 0 0.4rem; font-size: 1.25rem; font-weight: 750; color: var(--hx-ink); }
.hx-step p { margin: 0 0 1rem; color: var(--ink-soft); font-size: 1rem; line-height: 1.55; }
.hx-step-shot {
    margin: 0; width: min(100%, 300px); aspect-ratio: 9 / 13; overflow: hidden; border-radius: 22px;
    border: 8px solid #0d1512; box-shadow: 0 24px 48px -24px rgba(15, 31, 24, 0.45); background: var(--surface);
}
.hx-step-shot img { width: 100%; height: auto; display: block; }
.hx-story-device { display: none; }

/* ---------- PC ---------- */
.hx-desk { padding: 3.5rem 0 3rem; background: linear-gradient(180deg, transparent, var(--accent-soft) 35%, var(--accent-soft) 70%, transparent); perspective: 1400px; }
.hx-browser { max-width: 52rem; margin: 0 auto; overflow: hidden; border-radius: 14px; background: var(--surface); border: 1px solid var(--line-strong); box-shadow: 0 50px 90px -40px rgba(15, 31, 24, 0.5); transform-origin: 50% 100%; }
.hx-browser-bar { display: flex; align-items: center; gap: 0.4rem; padding: 0.55rem 0.8rem; background: #eef2ef; border-bottom: 1px solid var(--line); }
.hx-browser-bar i { width: 11px; height: 11px; border-radius: 50%; background: #e46a5e; }
.hx-browser-bar i:nth-child(2) { background: #e9b949; }
.hx-browser-bar i:nth-child(3) { background: #58b56e; }
.hx-browser-bar span { margin-left: 0.6rem; padding: 0.15rem 0.7rem; border-radius: 999px; background: var(--surface); color: var(--ink-faint); font-size: 0.75rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hx-browser img { display: block; width: 100%; height: auto; }

/* ---------- Trust ---------- */
.hx-trust { padding-top: 3rem; padding-bottom: 2.5rem; }
.hx-cards { display: grid; gap: 0.9rem; }
.hx-card { padding: 1.4rem 1.2rem; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform 0.25s ease, box-shadow 0.25s ease; }
.hx-card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px -20px rgba(15, 31, 24, 0.3); }
.hx-card h3 { margin: 0.7rem 0 0.35rem; font-size: 1.1rem; color: var(--hx-ink); }
.hx-card p { margin: 0; color: var(--ink-soft); }
.hx-card-icon { display: grid; place-items: center; width: 2.6rem; height: 2.6rem; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.hx-card-icon svg { width: 22px; height: 22px; }
.hx-points { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 0.6rem 1.6rem; margin: 1.6rem 0 0; padding: 0; }
.hx-points li { display: flex; align-items: center; gap: 0.45rem; color: var(--hx-ink); font-weight: 600; }
.hx-points svg { width: 20px; height: 20px; color: var(--accent); }

/* ---------- Questions ---------- */
.hx-faq { padding-top: 1rem; padding-bottom: 2.5rem; }
.hx-faq-list { max-width: 46rem; margin: 0 auto; display: grid; gap: 0.6rem; }
.hx-faq details { border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.hx-faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 1.1rem; font-weight: 700; color: var(--hx-ink); }
.hx-faq summary::-webkit-details-marker { display: none; }
.hx-faq summary::after { content: "+"; flex: none; font-size: 1.3rem; line-height: 1; color: var(--accent); transition: transform 0.2s ease; }
.hx-faq details[open] summary::after { transform: rotate(45deg); }
.hx-faq details p { margin: 0; padding: 0 1.1rem 1.1rem; color: var(--ink-soft); line-height: 1.55; }
.hx-faq-more { margin: 1.2rem 0 0; text-align: center; }

/* ---------- Final call ---------- */
.hx-final { position: relative; overflow: hidden; margin-top: 1.5rem; padding: 3.5rem 0; text-align: center; color: #fff; background: radial-gradient(120% 140% at 10% 0%, #2f8f63 0%, var(--hx-deep) 55%, #0b241a 100%); }
.hx-final::after { content: ""; position: absolute; inset: auto -20% -60% -20%; height: 120%; background: radial-gradient(closest-side, rgba(127, 214, 164, 0.35), transparent); pointer-events: none; }
.hx-final .hx-inner { position: relative; z-index: 1; }
.hx-final h2 { margin: 0 0 0.5rem; font-size: clamp(1.7rem, 5.5vw, 2.6rem); font-weight: 800; letter-spacing: -0.03em; }
.hx-final p { margin: 0 0 1.4rem; color: #cfe9db; font-size: 1.05rem; }
.hx-final .hx-actions { justify-content: center; }
.hx-cta-light { background: #fff; color: var(--hx-deep); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25); }
.hx-cta-light:hover { background: #effaf3; color: var(--hx-deep); }
.hx-note { padding-top: 1rem; padding-bottom: 0.5rem; text-align: center; }

/* ---------- Narrow phones: the phone frame shrinks to fit ---------- */
@media (max-width: 400px) {
    :root { --hx-phone-w: min(270px, calc(100vw - 6.5rem)); }
    .hx-hero-device { padding: 1rem 1.75rem; }
    .hx-chip-3 { left: -1rem; }
}

/* ---------- Wider screens ---------- */
@media (min-width: 640px) {
    .hx-stats { grid-template-columns: repeat(4, 1fr); }
    .hx-cards { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 900px) {
    :root { --hx-phone-w: 300px; }
    .hx-hero { padding: 4rem 0 4.5rem; }
    .hx-hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
    .hx-chip-1 { left: -2.5rem; }
    .hx-chip-2 { right: 0; }
    .hx-chip-3 { left: -1.5rem; }
}

/* ---------- Motion: only with JavaScript and without reduced motion ---------- */
@media (prefers-reduced-motion: no-preference) {
    .hx-js .hx-blobs span { animation: hx-drift 22s ease-in-out infinite alternate; }
    .hx-js .hx-blobs span:nth-child(2) { animation-duration: 27s; animation-delay: -6s; }
    .hx-js .hx-blobs span:nth-child(3) { animation-duration: 31s; animation-delay: -12s; }
    .hx-js .hx-chip { animation: hx-float 6s ease-in-out infinite; }
    .hx-js .hx-chip-2 { animation-delay: -2s; }
    .hx-js .hx-chip-3 { animation-delay: -4s; }
    .hx-js .hx-phone { animation: hx-rise 1s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
    /* tall pictures scroll inside the screen like a swipe, then rest */
    .hx-js .hx-slide.hx-scroll.is-on { animation: hx-swipe 7.5s ease-in-out 0.9s both; }
    .hx-js .hx-word { transition: opacity 0.35s ease, transform 0.35s ease, filter 0.35s ease; }
    .hx-js .hx-word.is-out { opacity: 0; transform: translateY(0.35em); filter: blur(6px); }

    /* the nutrients run endlessly */
    .hx-js .hx-track { flex-wrap: nowrap; justify-content: flex-start; width: max-content; padding: 0; animation: hx-marquee 70s linear infinite; }
    .hx-js .hx-track span { padding-right: 1.6rem; }
    .hx-js .hx-track { gap: 0; }
    .hx-js .hx-track span[aria-hidden] { display: inline; }
    .hx-js .hx-marquee:hover .hx-track { animation-play-state: paused; }

    .hx-js .hx-reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1); }
    .hx-js .hx-reveal.is-in { opacity: 1; transform: none; }
    .hx-js .hx-cards .hx-reveal:nth-child(2) { transition-delay: 0.1s; }
    .hx-js .hx-cards .hx-reveal:nth-child(3) { transition-delay: 0.2s; }
    .hx-js .hx-stats .hx-reveal:nth-child(2) { transition-delay: 0.08s; }
    .hx-js .hx-stats .hx-reveal:nth-child(3) { transition-delay: 0.16s; }
    .hx-js .hx-stats .hx-reveal:nth-child(4) { transition-delay: 0.24s; }

    .hx-js .hx-tilt { transform: rotateX(22deg) scale(0.9) translateY(30px); opacity: 0.6; transition: transform 1.3s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 1.3s ease; }
    .hx-js .hx-tilt.is-in { transform: none; opacity: 1; }
}

/* the scroll story with one phone that follows (wide screens, JavaScript) */
@media (min-width: 900px) {
    .hx-js .hx-story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
    .hx-js .hx-step { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; }
    .hx-js .hx-step { padding-left: 0; }
    .hx-js .hx-num { position: static; margin-bottom: 0.9rem; }
    .hx-js .hx-step-shot { display: none; }
    .hx-js .hx-step { opacity: 0.35; transition: opacity 0.4s ease; }
    .hx-js .hx-step.is-on { opacity: 1; }
    .hx-js .hx-step.is-on .hx-num { background: var(--accent); color: #fff; box-shadow: 0 0 0 6px var(--accent-soft); }
    .hx-js .hx-story-device { display: block; }
    .hx-js .hx-phone-sticky { position: sticky; top: calc(var(--header-h) + 6vh); margin: 0 auto; }
}

@keyframes hx-drift {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(6vmax, 4vmax) scale(1.08); }
    100% { transform: translate(-4vmax, 6vmax) scale(0.95); }
}
@keyframes hx-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes hx-rise { from { opacity: 0; transform: translateY(40px) rotate(-2deg); } to { opacity: 1; transform: none; } }
@keyframes hx-swipe { 0% { transform: translateY(0); } 70%, 100% { transform: translateY(var(--hx-swipe, -45%)); } }
@keyframes hx-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
