/* mirdetstva.ru — общая основа. Цвета и типографика задаются темой эпохи. */

:root {
    --ink: #23303c;
    --muted: #5d7385;
    --accent: #0026ad;
    --accent2: #9c2c85;
    --green: #04aa34;
    --red: #e23620;
    --yellow: #f1cb00;
    --line: #cfe2f2;
    --panel: #ffffff;
    --panel-2: #eef7ff;
    --radius: 10px;
    --font: Tahoma, Verdana, "Segoe UI", Arial, sans-serif;
    --wrap: 980px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.6;
    color: var(--ink);
    background: #fff;
}

img, svg { max-width: 100%; }

a { color: var(--accent); }
a:hover { color: var(--accent2); }

h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }

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

.sec { margin: 0 0 38px; }
.sec-h { font-size: 26px; color: var(--accent); }
.lead { font-size: 16px; color: var(--muted); max-width: 76ch; }
.kicker {
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: 11px;
    color: var(--accent2);
    margin: 0 0 6px;
    font-weight: bold;
}

/* --- герой --- */
.hero-domain {
    font-size: clamp(30px, 7vw, 58px);
    letter-spacing: -.5px;
    margin: 0 0 10px;
    word-break: break-word;
}

.price-box {
    border: 2px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel-2);
    padding: 18px 20px;
    margin: 18px 0;
    max-width: 620px;
}
.price-main { font-size: 26px; font-weight: bold; color: var(--accent2); }
.price-note { font-size: 14px; color: var(--muted); margin-top: 4px; }
.price-status { margin-top: 10px; color: var(--green); font-weight: bold; font-size: 14px; }

.btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0; }
.btn {
    display: inline-block;
    padding: 11px 20px;
    border-radius: 22px;
    text-decoration: none;
    font-weight: bold;
    font-size: 15px;
    border: 2px solid transparent;
    cursor: pointer;
}
.btn-main { background: var(--accent2); color: #fff; }
.btn-main:hover { background: var(--accent); color: #fff; }
.btn-alt { background: #fff; color: var(--accent); border-color: var(--accent); }
.btn-alt:hover { background: var(--accent); color: #fff; }

.owner-line { font-size: 14px; color: var(--muted); }

/* --- карточки --- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 18px;
}
.card h3 { font-size: 17px; color: var(--accent2); }
.card p { margin: 0; font-size: 14px; color: var(--muted); }

.card-ico {
    width: 34px; height: 34px; margin-bottom: 8px; border-radius: 50%;
    background: var(--panel-2); border: 2px solid var(--line);
    background-repeat: no-repeat; background-position: center; background-size: 18px 18px;
}
.ico-clock  { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230026ad' stroke-width='2'><circle cx='12' cy='12' r='9'/><path d='M12 7v5l3 3'/></svg>"); }
.ico-speak  { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239c2c85' stroke-width='2'><path d='M4 5h16v11H9l-5 4z'/></svg>"); }
.ico-target { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e23620' stroke-width='2'><circle cx='12' cy='12' r='9'/><circle cx='12' cy='12' r='4'/></svg>"); }
.ico-ru     { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><rect y='4' width='24' height='5' fill='%23ffffff' stroke='%23cfe2f2'/><rect y='9' width='24' height='5' fill='%230026ad'/><rect y='14' width='24' height='5' fill='%23e23620'/></svg>"); }
.ico-link   { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2304aa34' stroke-width='2'><path d='M9 15l6-6'/><path d='M7 11a4 4 0 015-3l2-1a4 4 0 115 6l-2 1'/><path d='M17 13a4 4 0 01-5 3l-2 1a4 4 0 11-5-6l2-1'/></svg>"); }
.ico-hand   { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f1a900' stroke-width='2'><path d='M8 12V5a1.5 1.5 0 013 0v6'/><path d='M11 11V4a1.5 1.5 0 013 0v7'/><path d='M14 11V6a1.5 1.5 0 013 0v8a6 6 0 01-6 6H10a5 5 0 01-5-5v-3l3 1'/></svg>"); }

/* --- эпохи --- */
.era-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.era-card {
    display: block; text-decoration: none; color: inherit;
    border: 2px solid var(--line); border-radius: var(--radius);
    padding: 14px 16px; background: var(--panel);
}
.era-card:hover { border-color: var(--accent2); color: inherit; }
.era-card.is-active { border-color: var(--accent2); background: var(--panel-2); box-shadow: inset 0 0 0 2px #fff; }
.era-year { display: block; font-weight: bold; font-size: 18px; color: var(--accent); }
.era-name { display: block; font-size: 14px; color: var(--accent2); margin: 2px 0 6px; }
.era-note, .era-more { display: block; font-size: 13px; color: var(--muted); }
.era-more { margin-top: 8px; font-size: 12px; }

/* --- лента истории --- */
.tl { display: grid; gap: 16px; }
.tl-item { display: grid; grid-template-columns: 110px 1fr; gap: 16px; align-items: start; }
.tl-year {
    font-weight: bold; font-size: 20px; color: #fff; background: var(--accent);
    border-radius: 16px; text-align: center; padding: 4px 6px;
}
.tl-body { border-left: 3px solid var(--line); padding-left: 16px; }
.tl-body h3 { font-size: 17px; color: var(--accent2); }
.tl-body p { margin: 0; color: var(--muted); font-size: 14px; }
.tl-link { margin-top: 6px !important; font-size: 13px !important; }
.more { font-size: 14px; margin-top: 14px; }

/* --- шаги сделки --- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-top: 18px; }
.step { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; background: var(--panel); }
.step-n {
    display: inline-flex; width: 26px; height: 26px; border-radius: 50%;
    background: var(--accent2); color: #fff; align-items: center; justify-content: center;
    font-weight: bold; font-size: 14px; margin-bottom: 8px;
}
.step h3 { font-size: 16px; }
.step p { margin: 0; font-size: 14px; color: var(--muted); }

/* --- факты --- */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.fact { text-align: center; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 8px; background: var(--panel-2); }
.fact-n { display: block; font-size: 26px; font-weight: bold; color: var(--accent2); }
.fact-t { display: block; font-size: 13px; color: var(--muted); }

/* --- форма --- */
.form { max-width: 720px; }
.f-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.f-field { display: block; margin-bottom: 12px; }
.f-field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.f-field b { color: var(--red); }
.f-field input, .f-field textarea {
    width: 100%; padding: 10px 12px; font: inherit; font-size: 15px;
    border: 2px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink);
}
.f-field input:focus, .f-field textarea:focus { outline: none; border-color: var(--accent2); }
.f-hint { font-size: 13px; color: var(--muted); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.note { border-radius: var(--radius); padding: 12px 16px; margin-bottom: 16px; font-size: 14px; }
.note-ok { background: #e8f8ec; border: 1px solid var(--green); }
.note-err { background: #fdecea; border: 1px solid var(--red); }

/* --- FAQ --- */
.faq details {
    border: 1px solid var(--line); border-radius: var(--radius);
    padding: 10px 16px; margin-bottom: 8px; background: var(--panel);
}
.faq summary { cursor: pointer; font-weight: bold; color: var(--accent); }
.faq p { margin: 8px 0 4px; font-size: 14px; color: var(--muted); }

/* --- контакты --- */
.contact-box { border: 2px solid var(--line); border-radius: var(--radius); overflow: hidden; max-width: 640px; }
.contact-row { display: grid; grid-template-columns: 180px 1fr; gap: 12px; padding: 11px 16px; border-bottom: 1px solid var(--line); font-size: 15px; }
.contact-row:last-child { border-bottom: 0; }
.contact-k { color: var(--muted); font-size: 13px; }

/* --- переключатель эпох в шапке --- */
.era-switch { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 12px; }
.era-switch a {
    text-decoration: none; padding: 3px 9px; border-radius: 12px;
    border: 1px solid var(--line); color: var(--muted); background: #fff;
}
.era-switch a.is-active { background: var(--accent2); border-color: var(--accent2); color: #fff; }

.sale-strip {
    background: var(--accent2); color: #fff; font-size: 13px;
    padding: 7px 0; text-align: center;
}
.sale-strip a { color: #fff; text-decoration: underline; }
.sale-strip strong { white-space: nowrap; }

@media (max-width: 640px) {
    .tl-item { grid-template-columns: 1fr; gap: 6px; }
    .tl-year { display: inline-block; padding: 2px 14px; }
    .contact-row { grid-template-columns: 1fr; gap: 2px; }
    .sec-h { font-size: 22px; }
}
