:root {
    --bg: #f7f5f1;
    --paper: #ffffff;
    --text: #171717;
    --muted: #666;
    --line: #d8d2c8;
    --accent: #111;
    --success: #edf8ef;
    --error: #fff0f0;
}

* {
    box-sizing: border-box;
}

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

a {
    color: inherit;
}

.app-header {
    border-bottom: 1px solid var(--line);
    background: var(--paper);
}

.app-header__inner {
    width: min(1100px, calc(100% - 32px));
    margin: 0 auto;
    padding: 14px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.app-title {
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
}

.contact-jump {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
}

.contact-jump select {
    max-width: 320px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
}

.page {
    width: min(860px, calc(100% - 32px));
    margin: 32px auto;
}

.notice {
    margin: 0 auto 18px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    text-align: center;
}

.notice--success {
    background: var(--success);
}

.notice--error {
    background: var(--error);
}

.contact-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: clamp(24px, 5vw, 52px);
    text-align: center;
}

.position-count {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

h1 {
    margin: 0;
    font-size: clamp(2.4rem, 8vw, 5.4rem);
    line-height: 0.95;
    letter-spacing: -0.06em;
}

.phone-block {
    margin: 26px auto;
    padding: 20px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.phone-block p {
    margin: 7px 0;
    font-size: clamp(1.35rem, 4vw, 2.2rem);
    font-weight: 750;
}

.phone-block span,
.data-list dt,
.notes-box span,
.radio-group p {
    color: var(--muted);
    font-weight: 700;
}

.data-list {
    margin: 0 auto 34px;
    display: grid;
    gap: 12px;
}

.data-list div {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}

.data-list dt,
.data-list dd {
    display: inline;
    margin: 0;
}

.call-form {
    margin: 0 auto;
    max-width: 620px;
}

fieldset {
    margin: 0;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 14px;
}

legend {
    padding: 0 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.07em;
}

.checkbox-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    font-weight: 700;
}

.radio-group {
    margin: 14px 0;
}

.radio-group p {
    margin: 0 0 8px;
}

.radio-group label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 10px;
}

.notes-box {
    display: grid;
    gap: 8px;
    margin-top: 18px;
    text-align: left;
}

.notes-box span {
    text-align: center;
}

textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    font: inherit;
    resize: vertical;
}

.last-saved {
    color: var(--muted);
    font-size: 0.92rem;
}

.next-button {
    width: min(100%, 340px);
    margin-top: 22px;
    padding: 16px 22px;
    border: 2px solid var(--accent);
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-size: 1.1rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
}

.next-button:hover,
.next-button:focus-visible {
    background: #fff;
    color: var(--accent);
}

.save-note {
    margin: 10px auto 0;
    max-width: 420px;
    color: var(--muted);
    font-size: 0.9rem;
}

.contact-back-link {
    display: inline-block;
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.contact-back-link:hover,
.contact-back-link:focus-visible {
    color: var(--text);
}

.completion-block {
    width: min(100%, 420px);
    margin: 16px auto 0;
}

.completion-text {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
}

.completion-bar {
    height: 12px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--bg);
}

.completion-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--accent);
}

@media (max-width: 680px) {
    .app-header__inner {
        align-items: stretch;
        flex-direction: column;
    }

    .contact-jump {
        align-items: stretch;
        flex-direction: column;
    }

    .contact-jump select {
        max-width: none;
        width: 100%;
    }
}
