:root {
    color-scheme: dark;
    --navy-950: #020c1b;
    --navy-900: #04152b;
    --surface: rgba(6, 29, 57, 0.88);
    --line: rgba(111, 230, 208, 0.42);
    --line-soft: rgba(122, 183, 241, 0.26);
    --text: #f5f8ff;
    --muted: #adc2dc;
    --mint: #6fe6d0;
    --cyan: #58c9ee;
    --blue: #5079fa;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--navy-950);
}

body {
    margin: 0;
    min-width: 320px;
    min-height: 100vh;
    background: var(--navy-950);
    color: var(--text);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
}

a,
button,
input {
    font: inherit;
}

a {
    color: inherit;
}

button,
input {
    touch-action: manipulation;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
.frequency-dial:focus-visible {
    outline: 3px solid var(--mint);
    outline-offset: 4px;
}

.landing-shell {
    width: calc(100% - 32px);
    max-width: 1180px;
    margin: 0 auto;
    padding: 24px 0 36px;
}

.landing-header,
.landing-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.landing-header {
    min-height: 58px;
    padding: 0 4px 18px;
}

.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--mint);
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-decoration: none;
    text-transform: uppercase;
}

.wave-mark {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    height: 30px;
}

.wave-mark i {
    display: block;
    width: 3px;
    border-radius: 3px;
    background: var(--mint);
}

.wave-mark i:nth-child(1),
.wave-mark i:nth-child(5) { height: 14px; }
.wave-mark i:nth-child(2) { height: 24px; }
.wave-mark i:nth-child(3) { height: 30px; }
.wave-mark i:nth-child(4) { height: 20px; }

.text-link {
    color: var(--muted);
    font-size: 0.95rem;
    font-weight: 700;
    text-decoration: none;
}

.text-link:hover,
.landing-footer a:hover {
    color: var(--mint);
}

.frequency-experience {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 0.9fr);
    gap: 42px;
    align-items: center;
    min-height: 620px;
    padding: 58px 6vw;
    border: 1px solid rgba(111, 230, 208, 0.34);
    border-radius: 24px;
    background:
        linear-gradient(90deg, rgba(2, 12, 27, 0.98) 0%, rgba(2, 13, 29, 0.88) 42%, rgba(3, 18, 38, 0.44) 100%),
        url("../assets/tinnitus-night-hero.png") center / cover no-repeat;
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.experience-copy {
    max-width: 600px;
}

.eyebrow {
    margin: 0 0 14px;
    color: var(--mint);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    max-width: 650px;
    margin-bottom: 22px;
    font-size: 2.8rem;
    line-height: 1.08;
}

h2 {
    margin-bottom: 12px;
    font-size: 1.8rem;
    line-height: 1.15;
}

.lead {
    max-width: 560px;
    margin-bottom: 18px;
    color: #d2e1f2;
    font-size: 1.08rem;
    line-height: 1.65;
}

.safety-note {
    max-width: 520px;
    margin-bottom: 28px;
    color: #b9d4df;
    font-size: 0.94rem;
    line-height: 1.55;
}

.transport-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.primary-button,
.secondary-button,
.cta-button {
    min-height: 54px;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: 13px;
    cursor: pointer;
    font-weight: 800;
    text-decoration: none;
}

.primary-button,
.cta-button {
    background: linear-gradient(110deg, var(--mint), var(--cyan) 52%, var(--blue));
    color: #031225;
}

.secondary-button {
    border-color: var(--line-soft);
    background: rgba(5, 22, 44, 0.78);
    color: var(--text);
}

.primary-button:hover,
.cta-button:hover {
    filter: brightness(1.08);
}

.secondary-button:hover:not(:disabled) {
    border-color: var(--mint);
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.48;
}

.audio-status {
    min-height: 24px;
    margin: 16px 0 0;
    color: var(--mint);
    font-weight: 700;
}

.dial-stage {
    display: grid;
    justify-items: center;
    gap: 22px;
}

.frequency-dial {
    --dial-angle: -42deg;
    position: relative;
    display: grid;
    place-items: center;
    width: 310px;
    height: 310px;
    border: 1px solid rgba(111, 230, 208, 0.28);
    border-radius: 50%;
    background:
        repeating-conic-gradient(from -110deg, rgba(92, 204, 237, 0.72) 0 1deg, transparent 1deg 5deg),
        conic-gradient(from -110deg, var(--mint) 0deg, var(--cyan) 112deg, rgba(42, 95, 154, 0.25) 112deg 220deg, transparent 220deg);
    box-shadow: 0 0 48px rgba(46, 133, 216, 0.2);
    cursor: grab;
    user-select: none;
    touch-action: none;
}

.frequency-dial:active {
    cursor: grabbing;
}

.dial-ticks,
.dial-core {
    position: absolute;
    border-radius: 50%;
}

.dial-ticks {
    inset: 12px;
    background: var(--navy-900);
    box-shadow: inset 0 0 0 2px rgba(129, 213, 244, 0.22);
}

.dial-core {
    inset: 26px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 8px;
    background: radial-gradient(circle at 40% 28%, #102e51 0%, #06172d 62%, #041124 100%);
    box-shadow: inset 0 0 0 1px rgba(149, 218, 247, 0.25);
}

.dial-core output {
    color: var(--text);
    font-size: 2.15rem;
    font-weight: 800;
    line-height: 1;
}

.dial-core span {
    color: var(--muted);
    font-size: 0.86rem;
}

.dial-pointer {
    position: absolute;
    top: calc(50% - 48px);
    left: 50%;
    width: 8px;
    height: 48px;
    border-radius: 5px;
    background: var(--mint);
    box-shadow: 0 0 18px rgba(111, 230, 208, 0.72);
    transform: translateX(-50%) rotate(var(--dial-angle));
    transform-origin: center 48px;
}

.dial-pointer::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--mint);
    transform: translate(-50%, -50%);
}

.volume-control {
    display: grid;
    width: min(100%, 330px);
    gap: 10px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
}

.volume-control > span {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.volume-control output {
    color: var(--mint);
}

input[type="range"] {
    width: 100%;
    accent-color: var(--mint);
}

.dial-help {
    max-width: 330px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 0.84rem;
    line-height: 1.5;
    text-align: center;
}

.app-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    margin-top: 26px;
    padding: 32px 38px;
    border: 1px solid var(--line-soft);
    border-radius: 18px;
    background: var(--surface);
}

.app-cta p:last-child {
    max-width: 650px;
    margin-bottom: 0;
    color: var(--muted);
    line-height: 1.55;
}

.landing-footer {
    justify-content: center;
    flex-wrap: wrap;
    padding: 22px 4px 0;
    color: #8ea6c2;
    font-size: 0.82rem;
}

.landing-footer a {
    color: #b5cce3;
    text-decoration: underline;
    text-underline-offset: 3px;
}

@media (max-width: 800px) {
    .frequency-experience {
        grid-template-columns: 1fr;
        gap: 36px;
        padding: 42px 24px;
    }

    .experience-copy {
        max-width: none;
    }

    .dial-stage {
        order: -1;
    }

    h1 {
        font-size: 2.2rem;
    }

    .app-cta {
        align-items: flex-start;
        flex-direction: column;
        padding: 28px 24px;
    }
}

@media (max-width: 480px) {
    .landing-shell {
        width: calc(100% - 20px);
        padding-top: 12px;
    }

    .brand-link {
        font-size: 0.8rem;
        letter-spacing: 0.05em;
    }

    .text-link {
        font-size: 0.82rem;
    }

    .frequency-experience {
        min-height: 0;
        padding: 34px 18px;
        border-radius: 18px;
    }

    .frequency-dial {
        width: 260px;
        height: 260px;
    }

    .dial-core output {
        font-size: 1.8rem;
    }

    .dial-pointer {
        top: calc(50% - 40px);
        height: 40px;
        transform-origin: center 40px;
    }

    .transport-controls,
    .transport-controls button,
    .cta-button {
        width: 100%;
    }

    h1 {
        font-size: 2rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}
