:root {
    --bg: #f7f8fc;
    --surface: #ffffff;
    --text: #141622;
    --muted: #667085;
    --border: #e4e7ec;
    --primary: #5b4bdb;
    --primary-dark: #4938c7;
    --soft: #f0eeff;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

a { color: inherit; }

.container {
    width: min(1120px, calc(100% - 36px));
    margin: 0 auto;
}

.narrow {
    width: min(820px, calc(100% - 36px));
}

.site-header {
    background: rgba(255,255,255,.92);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(12px);
}

.nav {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    font-weight: 800;
    font-size: 20px;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--primary);
    color: white;
}

nav {
    display: flex;
    gap: 24px;
    color: var(--muted);
    font-size: 14px;
}

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

.hero {
    padding: 78px 0 44px;
    background: linear-gradient(180deg, #ffffff 0%, #f7f8fc 100%);
}

.hero-inner { text-align: center; }

.eyebrow {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 999px;
    background: var(--soft);
    color: var(--primary-dark);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
}

h1 {
    margin: 14px 0 12px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.04;
    letter-spacing: -.04em;
}

.hero-copy {
    max-width: 680px;
    margin: 0 auto;
    color: var(--muted);
    font-size: 18px;
}

.tool-section { padding: 20px 0 80px; }

.tool-card {
    max-width: 920px;
    margin: 0 auto;
    padding: 30px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 18px 50px rgba(16,24,40,.07);
}

.tool-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.tool-top h2 { margin: 0 0 3px; font-size: 24px; }
.tool-top p { margin: 0; color: var(--muted); }

.status {
    padding: 7px 11px;
    border-radius: 999px;
    background: #f2f4f7;
    color: #475467;
    font-size: 13px;
    white-space: nowrap;
}

label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 700;
}

textarea {
    width: 100%;
    min-height: 230px;
    resize: vertical;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    font: inherit;
    font-size: 16px;
    outline: none;
}

textarea:focus, select:focus, input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(91,75,219,.12);
}

.counter-row {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    font-size: 13px;
    margin-top: 7px;
}

.controls {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 16px;
    margin: 24px 0;
}

.field { min-width: 0; }

select {
    width: 100%;
    height: 46px;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0 12px;
    background: white;
    font: inherit;
}

input[type="range"] {
    width: 100%;
    height: 46px;
}

.generate-btn, .download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 50px;
    border: 0;
    border-radius: 11px;
    background: var(--primary);
    color: white;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
}

.generate-btn:hover, .download-btn:hover { background: var(--primary-dark); }
.generate-btn:disabled { opacity: .6; cursor: wait; }

.result {
    margin-top: 20px;
    padding: 18px;
    border-radius: 14px;
    background: #f8f8ff;
    border: 1px solid #e5e1ff;
}

.result.hidden { display: none; }
.result-title { font-weight: 800; margin-bottom: 12px; }
audio { width: 100%; margin-bottom: 12px; }

.download-btn {
    width: auto;
    padding: 0 18px;
    min-height: 44px;
}

.privacy-note {
    margin: 16px 0 0;
    text-align: center;
    color: var(--muted);
    font-size: 12px;
}

.content-section {
    padding: 80px 0;
    background: white;
    border-top: 1px solid var(--border);
}

.content-section h2 {
    font-size: 32px;
    line-height: 1.2;
    letter-spacing: -.025em;
}

.content-section p { color: var(--muted); }

.steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 34px;
}

.step {
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: 14px;
}

.step span {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--soft);
    color: var(--primary-dark);
    font-weight: 800;
}

.step h3 { margin: 14px 0 5px; }
.step p { margin: 0; font-size: 14px; }

.faq-section { background: var(--bg); }

details {
    padding: 18px 0;
    border-bottom: 1px solid var(--border);
}

summary {
    cursor: pointer;
    font-weight: 750;
}

details p { margin: 10px 0 0; }

.site-footer {
    background: #11131a;
    color: #d0d5dd;
    padding: 28px 0;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    font-size: 14px;
}

.footer-inner a {
    margin-left: 18px;
    text-decoration: none;
}

@media (max-width: 760px) {
    nav { display: none; }
    .hero { padding-top: 55px; }
    .tool-card { padding: 20px; }
    .controls, .steps { grid-template-columns: 1fr; }
    .tool-top, .footer-inner { flex-direction: column; }
    .status { align-self: flex-start; }
}
