/* ==========================================================================
   CareShift — main stylesheet
   ========================================================================== */

:root {
    /* Brand */
    --teal: #0E7C7B;
    --teal-dark: #0A5F5E;
    --teal-deep: #0B3B3A;
    --teal-tint: #E6F3F2;
    --coral: #F26B5B;
    --coral-dark: #D9503F;
    --coral-tint: #FDECEA;

    /* Neutrals */
    --ink: #1F2937;
    --muted: #5B6573;
    --line: #E3E8EC;
    --bg: #FFFFFF;
    --bg-soft: #F6F9F9;

    --success: #15803D;
    --success-tint: #DCFCE7;

    /* Type */
    --font-main: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --font-heading: "Bricolage Grotesque", "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

    /* Shape */
    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 22px;
    --shadow-sm: 0 1px 2px rgba(16, 40, 40, .06);
    --shadow: 0 10px 30px -12px rgba(16, 40, 40, .18);
    --shadow-lg: 0 30px 60px -20px rgba(11, 59, 58, .35);

    --container: 1160px;
    --header-h: 72px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
    margin: 0;
    font-family: var(--font-main);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
    font-family: var(--font-heading);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 0 0 .5em;
}
h1 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 700; }

p { margin: 0 0 1em; }
a { color: var(--teal); }
img, svg { display: block; max-width: 100%; }

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

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
    position: absolute; left: 16px; top: -48px; z-index: 100;
    background: var(--teal); color: #fff; padding: 8px 14px; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--coral); outline-offset: 2px; }

.eyebrow {
    display: inline-block;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: .9rem;
}

.lead { font-size: 1.15rem; color: var(--muted); max-width: 34em; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5em;
    padding: .7em 1.25em;
    border-radius: 999px;
    border: 2px solid transparent;
    font: 600 .95rem/1.2 var(--font-main);
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s, color .15s, border-color .15s, transform .15s, box-shadow .15s;
    white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }

.btn-lg { padding: .95em 1.6em; font-size: 1rem; }
.btn-block { width: 100%; }

.btn-primary { background: var(--coral); color: #fff; box-shadow: 0 8px 20px -8px rgba(242, 107, 91, .7); }
.btn-primary:hover { background: var(--coral-dark); }

.btn-secondary { background: transparent; color: var(--teal); border-color: var(--teal); }
.btn-secondary:hover { background: var(--teal-tint); }

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

.btn-light { background: #fff; color: var(--teal-deep); }
.btn-light:hover { background: var(--coral-tint); }

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    height: var(--header-h);
    background: rgba(255, 255, 255, .88);
    backdrop-filter: saturate(160%) blur(12px);
    -webkit-backdrop-filter: saturate(160%) blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s, box-shadow .2s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow-sm); }

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand .logo { height: 40px; width: auto; }

.site-nav { display: flex; align-items: center; gap: 32px; }

.nav-links {
    display: flex;
    gap: 28px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-links a {
    color: var(--ink);
    text-decoration: none;
    font-weight: 500;
    position: relative;
}
.nav-links a::after {
    content: "";
    position: absolute; left: 0; right: 0; bottom: -4px;
    height: 2px; background: var(--coral);
    transform: scaleX(0); transform-origin: left;
    transition: transform .2s;
}
.nav-links a:hover::after { transform: scaleX(1); }

.nav-actions { display: flex; gap: 8px; align-items: center; }

/* "Get the app" button and dialog */
.btn-app { background: var(--teal-tint); color: var(--teal-dark); }
.btn-app:hover { background: #D3ECEA; }
.btn-app svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.app-dialog {
    width: min(420px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow-y: auto;
    padding: 32px 28px 24px; border: 0; border-radius: 22px;
    box-shadow: var(--shadow-lg); text-align: center; color: var(--ink);
}
.app-dialog::backdrop { background: rgba(11, 59, 58, .55); backdrop-filter: blur(3px); }
.app-dialog[open] { animation: dialog-in .25s cubic-bezier(.2, .8, .3, 1); }
@keyframes dialog-in { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: none; } }
.app-dialog-close-form { position: absolute; top: 12px; right: 12px; margin: 0; }
.app-dialog-close { display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); cursor: pointer; }
.app-dialog-close:hover { background: var(--bg-soft); color: var(--ink); }
.app-dialog-close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.app-dialog-icon { display: block; margin: 0 auto 14px; border-radius: 18px; box-shadow: var(--shadow); }
.app-dialog h2 { font-size: 1.5rem; margin-bottom: .3em; }
.app-dialog-intro { color: var(--muted); margin-bottom: 20px; }
.app-dialog-steps { text-align: left; margin-bottom: 18px; padding: 16px 18px; border-radius: 14px; background: var(--bg-soft); }
.app-dialog-os { margin: 0 0 10px; font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--teal); }
.app-dialog-steps ol { margin: 0; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 10px; }
.app-dialog-steps li { position: relative; padding-left: 36px; line-height: 1.5; counter-increment: s; }
.app-dialog-steps li::before {
    content: counter(s); position: absolute; left: 0; top: 0;
    display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
    background: var(--teal); color: #fff; font-weight: 700; font-size: .82rem;
}
.app-dialog-note { margin: 12px 0 0; font-size: .84rem; color: var(--muted); }
.share-icon { display: inline-grid; place-items: center; width: 24px; height: 24px; vertical-align: -6px; border-radius: 6px; background: #E0E9FF; color: #1D4ED8; }
.share-icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.nav-toggle {
    display: none;
    width: 44px; height: 44px;
    border: 0; background: transparent; cursor: pointer;
    flex-direction: column; justify-content: center; align-items: center; gap: 5px;
    border-radius: var(--radius-sm);
}
.nav-toggle-bar {
    width: 22px; height: 2px; background: var(--ink); border-radius: 2px;
    transition: transform .2s, opacity .2s;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(4) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    padding: 72px 0 96px;
    background:
        radial-gradient(900px 500px at 85% 10%, var(--teal-tint), transparent 70%),
        radial-gradient(600px 400px at 0% 100%, var(--coral-tint), transparent 70%);
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    align-items: center;
    gap: 56px;
}

.hero-copy h1 { max-width: 13em; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 28px; }

.hero-points {
    display: flex; flex-wrap: wrap; gap: 10px 24px;
    list-style: none; padding: 0; margin: 0;
    color: var(--muted); font-size: .95rem;
}
.hero-points li { display: flex; align-items: center; gap: 8px; }
.hero-points li::before {
    content: "";
    width: 18px; height: 18px; flex: none;
    border-radius: 50%;
    background: var(--teal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 12px no-repeat;
}

/* Phone mockup */
.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.phone {
    position: relative;
    width: 280px;
    padding: 14px;
    border-radius: 42px;
    background: var(--teal-deep);
    box-shadow: var(--shadow-lg);
    transform: rotate(2deg);
}
.phone-notch {
    position: absolute; top: 14px; left: 50%;
    width: 90px; height: 22px;
    transform: translateX(-50%);
    background: var(--teal-deep);
    border-radius: 0 0 14px 14px;
    z-index: 1;
}
.phone-screen {
    background: var(--bg-soft);
    border-radius: 30px;
    padding: 44px 18px 22px;
    min-height: 500px;
}
.phone-greeting {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
    margin: 0 0 6px;
}

.badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 600;
}
.badge-success { background: var(--success-tint); color: var(--success); }

.shift-card {
    margin-top: 18px;
    padding: 18px;
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
}
.shift-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--muted); margin: 0 0 6px; }
.shift-patient { font-weight: 600; margin: 0; }
.shift-time { font-family: var(--font-heading); font-size: 1.6rem; font-weight: 700; color: var(--teal); margin: 2px 0 14px; }
.shift-btn {
    display: block;
    text-align: center;
    padding: 14px;
    border-radius: 12px;
    background: var(--teal);
    color: #fff;
    font-weight: 700;
    font-size: 1.05rem;
}

.mini-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 14px;
}
.mini-stats div {
    background: #fff;
    border-radius: 12px;
    padding: 12px;
    box-shadow: var(--shadow-sm);
}
.mini-stats strong { display: block; font-family: var(--font-heading); font-size: 1.15rem; }
.mini-stats span { font-size: .78rem; color: var(--muted); }

.float-card {
    position: absolute;
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 14px 16px;
    font-size: .85rem;
    color: var(--muted);
}
.float-card p { margin: 0; }
.float-title { color: var(--ink); font-weight: 700; }
.float-rate { color: var(--coral) !important; font-weight: 700; font-size: 1rem; margin-top: 4px !important; }

/* positioned over the phone's empty top and bottom areas so they never cover screen content */
.float-offer { bottom: 16px; left: 0; animation: float 6s ease-in-out infinite; }
.float-paid {
    top: -4px; right: 0;
    display: flex; align-items: center; gap: 12px;
    animation: float 6s ease-in-out 1.5s infinite;
}
.float-icon {
    width: 36px; height: 36px; border-radius: 50%;
    display: grid; place-items: center;
    background: var(--success-tint); color: var(--success);
    font-weight: 700;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* ---------- Sections ---------- */
.section { padding: 96px 0; }

.section-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }

/* About */
.about { border-top: 1px solid var(--line); }
.about-inner {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 56px;
    align-items: start;
}
.about-text { color: var(--muted); font-size: 1.08rem; }

/* How it works */
.how { background: var(--bg-soft); }

.steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    counter-reset: step;
}
.step {
    position: relative;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
}
.step p { color: var(--muted); margin: 0; font-size: .95rem; }

.step-num {
    display: grid;
    place-items: center;
    width: 44px; height: 44px;
    margin-bottom: 18px;
    border-radius: 50%;
    background: var(--teal);
    color: #fff;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
}
.step:last-child .step-num { background: var(--coral); }

/* connector line between steps on wide screens */
.step:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 50px;
    right: -24px;
    width: 24px;
    border-top: 2px dashed var(--teal);
    opacity: .4;
}

/* Benefits */
.benefit-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.benefit {
    padding: 32px 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}
.benefit:hover { border-color: transparent; box-shadow: var(--shadow); transform: translateY(-3px); }
.benefit p { color: var(--muted); margin: 0; }

.benefit-icon {
    display: grid;
    place-items: center;
    width: 52px; height: 52px;
    margin-bottom: 20px;
    border-radius: 14px;
    background: var(--teal-tint);
}
.benefit-icon svg,
.contact-icon svg {
    width: 26px; height: 26px;
    fill: none;
    stroke: var(--teal);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* CTA band */
.cta-band {
    background: var(--teal-deep);
    color: #fff;
    padding: 64px 0;
    position: relative;
    overflow: hidden;
}
.cta-band::before {
    content: "";
    position: absolute;
    right: -120px; top: -160px;
    width: 420px; height: 420px;
    border: 48px solid rgba(255, 255, 255, .06);
    border-radius: 50%;
}
.cta-inner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}
.cta-band h2 { margin-bottom: .3em; }
.cta-band p { margin: 0; color: rgba(255, 255, 255, .8); }

/* Contact */
.contact-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: start;
}
.contact-info > p { color: var(--muted); max-width: 28em; }

.contact-list { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.contact-list li { display: flex; align-items: center; gap: 14px; }
.contact-list a { color: var(--ink); font-weight: 600; text-decoration: none; }
.contact-list a:hover { color: var(--teal); }
.contact-icon {
    display: grid; place-items: center;
    width: 44px; height: 44px; flex: none;
    border-radius: 12px;
    background: var(--teal-tint);
}
.contact-icon svg { width: 22px; height: 22px; }

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow);
}

/* Forms */
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.field input,
.field textarea,
.field select {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--line);
    border-radius: var(--radius-sm);
    font: inherit;
    color: var(--ink);
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus,
.field textarea:focus,
.field select:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 4px var(--teal-tint);
}
.form-note { font-size: .85rem; color: var(--muted); }
.field-error { margin: 6px 0 0; font-size: .85rem; font-weight: 600; color: #B42318; }
.field.has-error input, .field.has-error textarea { border-color: #B42318; }
.form-alert { margin-bottom: 18px; padding: 12px 14px; border-radius: var(--radius-sm); background: #FEECE8; color: #7A271A; font-size: .92rem; }
.hp-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.contact-done { text-align: center; }
.contact-done-icon {
    display: inline-grid; place-items: center; width: 64px; height: 64px; margin-bottom: 16px;
    border-radius: 50%; background: #DCFCE7; color: #15803D;
    animation: pop .5s cubic-bezier(.3, 1.6, .5, 1) both;
}
.contact-done-icon svg { width: 32px; height: 32px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.contact-done h3 { font-size: 1.35rem; }
.contact-done p { color: var(--muted); margin-bottom: 20px; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--teal-deep);
    color: rgba(255, 255, 255, .75);
    padding-top: 56px;
    border-top: 1px solid rgba(255, 255, 255, .08);
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 32px;
    padding-bottom: 32px;
}
.footer-brand .logo { height: 40px; width: auto; margin-bottom: 12px; }
.footer-brand p { max-width: 24em; margin: 0; font-size: .95rem; }

.footer-links { display: flex; flex-wrap: wrap; gap: 12px 28px; }
.footer-links a { color: #fff; text-decoration: none; font-weight: 500; }
.footer-links a:hover { text-decoration: underline; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .12);
    padding-top: 20px;
    padding-bottom: 28px;
    font-size: .85rem;
}
.footer-bottom p { margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .steps { grid-template-columns: repeat(2, 1fr); }
    .step::after { display: none; }
}

@media (max-width: 900px) {
    .hero { padding: 48px 0 72px; }
    .hero-inner,
    .about-inner,
    .contact-inner { grid-template-columns: 1fr; gap: 40px; }
    .hero-copy h1 { max-width: none; }

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

    .cta-inner { flex-direction: column; align-items: flex-start; }

    /* mobile nav */
    .nav-toggle { display: flex; }
    .site-nav {
        position: fixed;
        top: var(--header-h);
        left: 0; right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        padding: 20px;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow);
        transform: translateY(-8px);
        opacity: 0;
        visibility: hidden;
        transition: opacity .2s, transform .2s, visibility .2s;
    }
    .site-nav.is-open { opacity: 1; transform: none; visibility: visible; }
    .nav-links { flex-direction: column; gap: 0; }
    .nav-links a { display: block; padding: 12px 4px; border-bottom: 1px solid var(--line); }
    .nav-links a::after { display: none; }
    .nav-actions { flex-direction: column; }
    .nav-actions .btn { width: 100%; padding: .9em; }
}

@media (max-width: 600px) {
    .container { padding: 0 16px; }
    .section { padding: 64px 0; }
    .steps { grid-template-columns: 1fr; }
    .hero-actions .btn { width: 100%; }
    .float-card { display: none; }
    .phone { transform: none; }
    .card { padding: 24px; }
    .footer-inner { flex-direction: column; }
}

/* ==========================================================================
   Landing page: SVG art and motion
   ========================================================================== */

/* Scroll reveal (only when JS is running; see main.js) */
.js .reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .7s ease var(--d, 0s), transform .8s cubic-bezier(.2, .7, .2, 1) var(--d, 0s);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* Hero extras */
.hero-inner { position: relative; z-index: 1; }
.hero-shapes { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hero-shapes .shape { transform-box: fill-box; transform-origin: center; animation: drift 9s ease-in-out infinite; }
.hero-shapes .shape-2 { animation-duration: 11s; animation-delay: -3s; }
.hero-shapes .shape-3 { animation-duration: 8s; animation-delay: -5s; }
.hero-shapes .shape-4 { animation-duration: 12s; animation-delay: -2s; }
.hero-shapes .shape-5 { animation-duration: 10s; animation-delay: -6s; }
@keyframes drift {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33%      { transform: translate(10px, -14px) rotate(12deg); }
    66%      { transform: translate(-8px, 8px) rotate(-8deg); }
}

.eyebrow-pill {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 14px 6px 10px; border-radius: 99px;
    background: rgba(255, 255, 255, .8); border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
}
.pulse-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--coral); }
.pulse-dot::after {
    content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--coral);
    animation: ping 1.8s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes ping { 75%, 100% { transform: scale(2.6); opacity: 0; } }

.hero-copy h1 { min-height: 3.45em; }
.typed-wrap { position: relative; display: inline-block; white-space: nowrap; color: var(--teal); }
.scribble { position: absolute; left: 0; bottom: -.12em; width: 100%; height: .32em; overflow: visible; }
.scribble path {
    fill: none; stroke: var(--coral); stroke-width: 7; stroke-linecap: round;
    stroke-dasharray: 320; stroke-dashoffset: 320;
    animation: scribble 1s .6s ease-out forwards;
}
@keyframes scribble { to { stroke-dashoffset: 0; } }
.typed-cursor { color: var(--coral); font-weight: 400; margin-left: 2px; }

.btn-shine { position: relative; overflow: hidden; }
.btn-shine::after {
    content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent);
    transform: skewX(-20deg);
    animation: shine 4.5s ease-in-out 1.5s infinite;
}
@keyframes shine { 0%, 70% { left: -60%; } 100% { left: 130%; } }
.btn-arrow { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s; }
.btn:hover .btn-arrow { transform: translateX(4px); }

/* Route between cities behind the phone */
.route-map { position: absolute; inset: -10px -30px; width: calc(100% + 60px); height: calc(100% + 20px); overflow: visible; }
.route-line {
    fill: none; stroke: var(--teal); stroke-width: 2.5; stroke-linecap: round; opacity: .45;
    stroke-dasharray: 2 10; animation: route-flow 1.4s linear infinite;
}
@keyframes route-flow { to { stroke-dashoffset: -24; } }
.pin .pin-dot { fill: var(--teal); stroke: #fff; stroke-width: 3; }
.pin .pin-ring {
    fill: none; stroke: var(--teal); stroke-width: 2;
    transform-box: fill-box; transform-origin: center;
    animation: pin-pulse 3s ease-out var(--d) infinite; opacity: 0;
}
.pin-coral .pin-dot { fill: var(--coral); }
.pin-coral .pin-ring { stroke: var(--coral); }
.pin text { font: 600 12px var(--font-main); fill: var(--muted); }
@keyframes pin-pulse { 0% { transform: scale(.4); opacity: .9; } 80%, 100% { transform: scale(1.8); opacity: 0; } }

.phone { z-index: 1; animation: phone-in 1s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes phone-in { from { opacity: 0; transform: translateY(30px) rotate(4deg); } to { opacity: 1; transform: rotate(2deg); } }
.float-card { z-index: 2; }
.shift-btn { display: flex; align-items: center; justify-content: center; gap: 8px; animation: btn-glow 2.4s ease-in-out infinite; }
.shift-btn svg { width: 20px; height: 20px; fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; }
@keyframes btn-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(14, 124, 123, .45); } 50% { box-shadow: 0 0 0 8px rgba(14, 124, 123, 0); } }
.clock-hand { transform-box: view-box; transform-origin: 12px 12px; animation: tick 6s steps(12) infinite; }
@keyframes tick { to { transform: rotate(360deg); } }

.mini-chart { width: 100%; height: 56px; margin-top: 14px; }
.mini-chart-area { fill: var(--teal-tint); }
.mini-chart-line {
    fill: none; stroke: var(--teal); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round;
    stroke-dasharray: 260; stroke-dashoffset: 260; animation: scribble 1.6s 1s ease-out forwards;
}

.float-gps {
    top: 60%; right: -18px;
    display: flex; align-items: center; gap: 8px;
    color: var(--success); font-weight: 600;
    animation: float 7s ease-in-out .8s infinite;
}
.float-gps svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }

/* Wave dividers */
.wave { position: absolute; left: 0; width: 100%; height: 60px; pointer-events: none; }
.wave-bottom { bottom: -1px; fill: var(--bg); }
.wave-top { top: -1px; fill: var(--bg); }
.hero { padding-bottom: 120px; }
.about { border-top: 0; }
.how { position: relative; padding: 130px 0 140px; }

/* About illustration */
.about-art { width: 100%; max-width: 340px; margin-top: 28px; overflow: visible; }
.about-art path, .about-art circle { fill: none; stroke: var(--teal); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.about-art .fill-coral { fill: var(--coral); stroke: var(--coral); stroke-width: 2; }
.about-art .dotted { stroke: var(--coral); stroke-dasharray: 1 9; stroke-width: 4; }
.about-ticks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 10px; color: var(--ink); font-size: 1rem; }
.about-ticks li { display: flex; gap: 10px; align-items: flex-start; }
.about-ticks li::before {
    content: ""; width: 20px; height: 20px; flex: none; margin-top: 3px; border-radius: 50%;
    background: var(--teal-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230E7C7B' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 12px no-repeat;
}

/* Line-drawing SVGs (lengths are set by main.js) */
.js .draw .is-drawable { transition: stroke-dashoffset 1.2s cubic-bezier(.6, .1, .2, 1) var(--draw-d, 0s); }
.js .draw .fill-coral { opacity: 0; transition: opacity .6s ease 1.1s; }
.js .draw.is-drawn .fill-coral { opacity: 1; }
.js .draw .dotted { opacity: 0; transition: opacity .6s ease 1.3s; }
.js .draw.is-drawn .dotted { opacity: 1; }

/* Step cards */
.step { transition: transform .25s, box-shadow .25s, border-color .25s; }
.step:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.step-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 18px; }
.step-top .step-num { margin-bottom: 0; }
.step-icon { width: 46px; height: 46px; }
.step-icon path, .step-icon circle { fill: none; stroke: var(--teal); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.step:last-child .step-icon path, .step:last-child .step-icon circle { stroke: var(--coral); }

/* Benefit icon hovers */
.benefit-icon svg { transition: transform .4s cubic-bezier(.3, 1.5, .5, 1); }
.benefit:hover .icon-flip svg { transform: rotateY(180deg); }
.benefit:hover .icon-bounce svg { animation: bounce .7s ease; }
.benefit:hover .icon-spin svg { transform: rotate(-20deg) scale(1.1); }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-6px); } 70% { transform: translateY(2px); } }

/* Heartbeat line in the CTA band */
.ecg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.ecg path {
    fill: none; stroke: rgba(255, 138, 122, .55); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round;
    stroke-dasharray: 280 1400; stroke-dashoffset: 1680;
    animation: ecg 4.5s linear infinite;
}
@keyframes ecg { to { stroke-dashoffset: 0; } }
.cta-inner { z-index: 1; }

@media (max-width: 900px) {
    .hero-copy h1 { min-height: 0; }
    .route-map { inset: -10px 0; width: 100%; }
}
@media (max-width: 600px) {
    .hero { padding-bottom: 96px; }
    .how { padding: 96px 0 110px; }
    .wave { height: 36px; }
    .route-map, .hero-shapes, .float-gps { display: none; }
}

/* ==========================================================================
   Legal pages (Imprint, Privacy Policy, Terms)
   ========================================================================== */
.legal-hero {
    padding: 56px 0 40px;
    background:
        radial-gradient(700px 300px at 90% 0%, var(--teal-tint), transparent 70%),
        var(--bg-soft);
    border-bottom: 1px solid var(--line);
}
.legal-hero h1 { font-size: clamp(2rem, 4vw, 2.8rem); margin-bottom: .3em; }
.legal-intro { color: var(--muted); font-size: 1.1rem; max-width: 40em; margin: 0 0 8px; }
.legal-updated { font-size: .85rem; color: var(--muted); margin: 0; }

.legal-body { padding: 36px 20px 72px; }
.legal-draft {
    margin-bottom: 32px; padding: 14px 18px; border-radius: var(--radius-sm);
    background: #FEF3C7; border: 1px solid #FDE68A; color: #78350F; font-size: .93rem;
}
.legal-draft code { background: rgba(255, 255, 255, .6); padding: 1px 6px; border-radius: 4px; font-size: .9em; }

.legal-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 48px; align-items: start; }
.legal-toc { position: sticky; top: calc(var(--header-h) + 24px); font-size: .9rem; }
.legal-toc p { margin: 0 0 10px; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.legal-toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.legal-toc a { display: block; padding: 5px 0 5px 14px; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; }
.legal-toc a:hover { color: var(--teal); border-left-color: var(--teal); }

.legal-article { max-width: 72ch; font-size: 1.02rem; line-height: 1.7; }
.legal-article section { padding-top: 8px; margin-bottom: 36px; scroll-margin-top: calc(var(--header-h) + 20px); }
.legal-article h2 { font-size: 1.4rem; margin-bottom: .6em; }
.legal-article ul { padding-left: 1.2em; margin: 0 0 1em; }
.legal-article li { margin-bottom: .45em; }
.legal-article li::marker { color: var(--teal); }
.legal-article address { font-style: normal; padding: 16px 20px; border-radius: var(--radius-sm); background: var(--bg-soft); border: 1px solid var(--line); margin-bottom: 1em; line-height: 1.8; }
.legal-dl { display: grid; grid-template-columns: 160px 1fr; gap: 6px 16px; margin: 0; }
.legal-dl dt { color: var(--muted); }
.legal-dl dd { margin: 0; }
.legal-article .table-wrap { overflow-x: auto; margin-bottom: 1em; }
.legal-table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.legal-table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); background: var(--bg-soft); }
.legal-article code { font-size: .88em; background: var(--bg-soft); padding: 1px 6px; border-radius: 4px; }
.legal-note { padding: 12px 16px; border-left: 3px solid #D97706; background: #FFFBEB; font-size: .9rem; color: #78350F; border-radius: 0 8px 8px 0; }
mark.legal-missing { background: #FEF3C7; color: #92400E; padding: 1px 6px; border-radius: 4px; font-weight: 600; font-size: .92em; }
.legal-links { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.legal-links a { font-weight: 600; text-decoration: none; }

@media (max-width: 900px) {
    .legal-grid { grid-template-columns: 1fr; gap: 24px; }
    .legal-toc { position: static; padding: 16px; border-radius: var(--radius-sm); background: var(--bg-soft); }
    .legal-toc ol { columns: 2; column-gap: 16px; border-left: 0; }
    .legal-toc a { padding-left: 0; border-left: 0; }
}
@media (max-width: 600px) {
    .legal-body { padding: 24px 16px 56px; }
    .legal-toc ol { columns: 1; }
    .legal-dl { grid-template-columns: 1fr; gap: 0; }
    .legal-dl dd { margin-bottom: 8px; }
}

@media print {
    .site-header, .site-footer, .legal-toc, .legal-links, .skip-link { display: none !important; }
    .legal-grid { display: block; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    html { scroll-behavior: auto; }
    .js .reveal { opacity: 1; transform: none; }
    .scribble path, .mini-chart-line { stroke-dashoffset: 0; }
    .js .draw .fill-coral, .js .draw .dotted { opacity: 1; }
    .ecg path { stroke-dasharray: none; stroke: rgba(255, 138, 122, .25); }
    .phone { transform: rotate(2deg); }
}

/* ---------- Language switch (EN | DE) ---------- */
.lang-switch { display: inline-flex; flex: none; padding: 3px; border-radius: 99px; background: var(--bg-soft); border: 1px solid var(--line); }
.lang-switch a { min-width: 34px; padding: 5px 9px; border-radius: 99px; color: var(--muted); font: 700 .78rem/1.2 var(--font-main); letter-spacing: .04em; text-align: center; text-decoration: none; transition: background-color .15s, color .15s; }
.lang-switch a:hover { color: var(--ink); }
.lang-switch a.is-on { background: #fff; color: var(--teal-dark); box-shadow: 0 1px 3px rgba(16, 40, 40, .15); }
.lang-switch a:focus-visible { outline: 3px solid var(--coral); outline-offset: 1px; }
.lang-switch-dark { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .14); }
.lang-switch-dark a { color: rgba(255, 255, 255, .7); }
.lang-switch-dark a:hover { color: #fff; }
.lang-switch-dark a.is-on { background: #fff; color: var(--teal-deep); }
@media (max-width: 900px) { .nav-actions .lang-switch { align-self: center; } }
.footer-links .lang-switch { margin-left: 4px; }
