/* ===== Variables & base ===== */
:root {
  --kk-bg: #10201B;
  --kk-surface: #172B25;
  --kk-text: #EEF3EF;
  --kk-muted: #A9BDB3;
  --kk-accent: #E9B949;
  --kk-accent-text: #10201B;
  --kk-plate-bg: #E9B949;
  --kk-plate-text: #10201B;
  --kk-line: #2A4038;
  --kk-font-heading: Georgia, 'Times New Roman', serif;
  --kk-font-body: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --kk-radius-card: 12px;
  --kk-radius-btn: 999px;
  --kk-pad: clamp(16px, 4vw, 40px);
  --kk-section-gap: clamp(64px, 9vw, 128px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--kk-bg);
  color: var(--kk-text);
  font-family: var(--kk-font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.125rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--kk-font-heading);
  font-weight: 700;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.4rem, 4.6vw + 0.6rem, 4.6rem); line-height: 1.08; margin: 0 0 20px; }
h2 { font-size: clamp(1.8rem, 2.6vw + 0.8rem, 3rem); line-height: 1.15; margin: 0 0 16px; max-width: 20ch; text-wrap: balance; }
h3 { font-size: 1.25rem; line-height: 1.3; margin: 0 0 10px; }

p { max-width: 62ch; }

a { color: var(--kk-accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; display: block; object-fit: cover; }

ul, ol { padding-left: 1.2em; margin: 0; }
address { font-style: normal; }

.kk_wrap { max-width: 1200px; margin: 0 auto; padding-left: var(--kk-pad); padding-right: var(--kk-pad); }

.kk_skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--kk-plate-bg); color: var(--kk-plate-text);
  padding: 12px 20px; border-radius: var(--kk-radius-btn); z-index: 200;
}
.kk_skip:focus { left: 12px; top: 12px; }

/* ===== Background layer ===== */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  transform: translateZ(0);
  background:
    radial-gradient(38vw 38vw at 12% 8%, rgba(233, 185, 73, 0.18), transparent 70%),
    radial-gradient(46vw 46vw at 88% 32%, rgba(233, 185, 73, 0.14), transparent 70%),
    radial-gradient(42vw 42vw at 30% 82%, rgba(233, 185, 73, 0.12), transparent 70%),
    radial-gradient(34vw 34vw at 70% 95%, rgba(233, 185, 73, 0.12), transparent 70%);
}

/* ===== Header ===== */
.kk_header {
  position: sticky; top: 0; z-index: 100;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  gap: 12px; min-height: 72px;
  padding: 12px var(--kk-pad);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.25s ease, border-color 0.25s ease;
}
.kk_header.is_scrolled {
  background-color: rgba(23, 43, 37, 0.96);
  border-bottom-color: var(--kk-line);
}
.kk_header_mail { color: var(--kk-muted); font-size: 0.95rem; }
.kk_header_mail:hover { color: var(--kk-text); text-decoration: none; }
.kk_logo {
  font-family: var(--kk-font-heading); font-size: 1.3rem; font-weight: 700;
  color: var(--kk-text); text-align: center; white-space: nowrap;
}
.kk_logo:hover { color: var(--kk-text); text-decoration: none; }
.kk_nav_toggle {
  justify-self: end;
  background: transparent; color: var(--kk-text);
  border: 1px solid var(--kk-line); border-radius: var(--kk-radius-btn);
  min-height: 44px; padding: 0 22px; font-size: 1rem; font-weight: 600;
  cursor: pointer;
  transition: border-radius 0.2s ease, background-color 0.2s ease;
}
.kk_nav_toggle:hover { background: rgba(233, 185, 73, 0.12); border-radius: 12px; }
.kk_nav_toggle:focus-visible { outline: 2px solid var(--kk-accent); outline-offset: 2px; }
.kk_nav_toggle:active { border-radius: var(--kk-radius-btn); }

/* ===== Fullscreen nav ===== */
.kk_nav {
  position: fixed; inset: 0; z-index: 150;
  background: rgba(16, 32, 27, 0.98);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.kk_nav.kk_nav_open { opacity: 1; visibility: visible; }
.kk_nav_panel {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(24px, 6vw, 72px);
  max-width: 1000px; width: 100%; padding: var(--kk-pad);
}
.kk_nav_list { list-style: none; display: grid; gap: 14px; }
.kk_nav_link {
  display: inline-block;
  font-family: var(--kk-font-heading);
  font-size: clamp(1.5rem, 3.2vw, 2.4rem); color: var(--kk-text);
  padding: 4px 12px; border-radius: 8px;
  transition: transform 0.2s ease, color 0.2s ease;
}
.kk_nav_link:hover { color: var(--kk-accent); text-decoration: none; transform: translateX(6px); }
.kk_nav_link:focus-visible { outline: 2px solid var(--kk-accent); outline-offset: 2px; }
.kk_nav_link[aria-current="page"] { color: var(--kk-accent); }
.kk_nav_side { border-left: 1px solid var(--kk-line); padding-left: clamp(16px, 3vw, 32px); }
.kk_nav_contacts { list-style: none; display: grid; gap: 10px; }
.kk_nav_contacts span { color: var(--kk-muted); margin-right: 6px; font-size: 0.95rem; }

/* ===== Sections ===== */
.kk_section { padding-block: clamp(96px, 12vw, 120px); }
.kk_section:nth-of-type(even) { background: rgba(23, 43, 37, 0.45); }

.kk_section_grid { display: grid; gap: clamp(24px, 4vw, 56px); }
.kk_section_title { margin-bottom: 12px; }
.kk_section_lead { color: var(--kk-muted); margin: 0; }

/* ===== Hero ===== */
.kk_hero { padding-top: clamp(40px, 6vw, 72px); }
.kk_hero_grid { display: grid; gap: clamp(32px, 5vw, 64px); align-items: center; }
.kk_hero_title { max-width: 560px; }
.kk_hero_lead { color: var(--kk-muted); font-size: clamp(1.05rem, 1.5vw, 1.25rem); margin-bottom: 28px; }
.kk_hero_plate { margin-top: 32px; }
.kk_hero_collage { display: grid; gap: 16px; align-items: end; }
.kk_hero_img_a, .kk_hero_img_b {
  width: 100%; border: 1px solid var(--kk-line); background: var(--kk-surface);
  border-radius: var(--kk-radius-card);
}
.kk_hero_img_a { aspect-ratio: 1 / 1; }
.kk_hero_img_b { aspect-ratio: 3 / 4; }

/* ===== Accent & plate ===== */
.kk_accent {
  display: inline-block;
  font-family: var(--kk-font-heading);
  font-size: clamp(1.6rem, 2.2vw + 0.8rem, 3.2rem);
  font-weight: 700; color: var(--kk-accent); line-height: 1;
}
.kk_plate {
  display: inline-block;
  background: var(--kk-plate-bg); color: var(--kk-plate-text);
  border-radius: var(--kk-radius-card);
  padding: 20px 24px; max-width: 52ch;
}
.kk_plate p { margin: 0; max-width: none; }

/* ===== Buttons ===== */
.kk_button {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 26px;
  background: var(--kk-accent); color: var(--kk-accent-text);
  border: 1px solid transparent; border-radius: var(--kk-radius-btn);
  font-family: var(--kk-font-body); font-size: 1rem; font-weight: 600;
  text-decoration: none; cursor: pointer;
  transition: border-radius 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06), 0 12px 32px rgb(0 0 0 / 0.08);
}
.kk_button:hover { background: #d9a53d; border-radius: 12px; transform: translateY(-1px); text-decoration: none; }
.kk_button:focus-visible { outline: 2px solid var(--kk-accent); outline-offset: 3px; }
.kk_button:active { transform: translateY(0); border-radius: var(--kk-radius-btn); }
.kk_button_alt {
  background: transparent; color: var(--kk-text);
  border: 1px solid var(--kk-line);
}
.kk_button_alt:hover { background: rgba(233, 185, 73, 0.12); border-radius: 12px; }

/* ===== Numbered rows ===== */
.kk_numbered { list-style: none; padding: 0; display: grid; gap: 20px; }
.kk_numbered_item {
  display: grid; grid-template-columns: 56px 1fr; column-gap: 20px; align-items: start;
  min-height: 120px;
  padding: 28px 32px; border: 1px solid var(--kk-line); border-radius: var(--kk-radius-card);
  background: var(--kk-surface);
  transition: transform 0.25s ease, border-color 0.25s ease;
}
.kk_numbered_item:hover {
  transform: translateY(-4px);
  border-color: var(--kk-accent);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06), 0 12px 32px rgb(0 0 0 / 0.12);
}
.kk_numbered_num { grid-row: span 2; line-height: 1; padding-top: 6px; }
.kk_numbered_desc { color: var(--kk-muted); margin: 0; }

/* ===== Cards & prices ===== */
.kk_card {
  background: var(--kk-surface);
  border: 1px solid var(--kk-line);
  border-radius: var(--kk-radius-card);
  padding: 28px;
  transition: transform 0.25s ease;
}
.kk_card:hover {
  transform: translateY(-4px);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06), 0 12px 32px rgb(0 0 0 / 0.12);
}
.kk_prices { display: grid; gap: 24px; align-items: stretch; }
.kk_price_cost { color: var(--kk-accent); font-weight: 600; line-height: 1.4; margin: 0 0 16px; }
.kk_price_desc { color: var(--kk-muted); margin: 0; }
.kk_price_card_mid { border-color: var(--kk-accent); }

/* ===== Steps ===== */
.kk_steps { display: grid; gap: 20px; }
.kk_step { border-left: 3px solid var(--kk-accent); padding-left: 20px; }
.kk_step_desc { color: var(--kk-muted); margin: 0; }
.kk_step_photo { margin: 32px 0 0; max-width: 560px; }
.kk_step_photo img { border: 1px solid var(--kk-line); width: 100%; aspect-ratio: 16 / 9; }

/* ===== FAQ ===== */
.kk_faq { display: grid; gap: 12px; max-width: 760px; }
.kk_faq_item {
  background: var(--kk-surface); border: 1px solid var(--kk-line);
  border-radius: var(--kk-radius-card); padding: 4px 24px;
}
.kk_faq_q { cursor: pointer; font-weight: 600; padding: 16px 0; }
.kk_faq_q::marker { color: var(--kk-accent); }
.kk_faq_a { color: var(--kk-muted); margin: 0 0 16px; }

/* ===== Prose ===== */
.kk_prose { max-width: 760px; color: var(--kk-text); }
.kk_prose p, .kk_prose li { color: var(--kk-muted); }
.kk_prose h2 { margin-top: 40px; }
.kk_prose h3 { margin-top: 32px; }
.kk_prose ul, .kk_prose ol { color: var(--kk-muted); }
.kk_prose table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 0.95rem; }
.kk_prose th, .kk_prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--kk-line); color: var(--kk-muted); }
.kk_prose th { color: var(--kk-text); font-family: var(--kk-font-heading); }

/* ===== Forms ===== */
.kk_form { display: grid; gap: 20px; max-width: 560px; }
.kk_form_intro { margin-bottom: 24px; }
.kk_field { display: grid; margin-bottom: 4px; }
.kk_label { font-weight: 600; font-size: 0.95rem; margin-bottom: 8px; }
.kk_input {
  background: var(--kk-surface); color: var(--kk-text);
  border: 1px solid var(--kk-line); border-radius: var(--kk-radius-card);
  padding: 0 16px; height: 52px; font: inherit; width: 100%;
}
.kk_input::placeholder { color: #8FA69B; }
.kk_input:focus { outline: 2px solid var(--kk-accent); outline-offset: 1px; }
.kk_field_error .kk_input { border-color: #E88A6A; }
.kk_field_error .kk_label { color: #F0A288; }
.kk_textarea { resize: vertical; height: auto; min-height: 140px; padding: 14px 16px; }
.kk_check { display: flex; gap: 10px; align-items: start; font-size: 0.95rem; color: var(--kk-muted); }
.kk_check input { accent-color: var(--kk-accent); width: 18px; height: 18px; margin-top: 4px; flex: none; }
.kk_form_note { color: var(--kk-muted); font-size: 0.9rem; margin: 0; }
.kk_form_button { justify-self: start; }
.kk_form.is_sending .kk_form_button { opacity: 0.6; pointer-events: none; }

/* ===== Floating bar ===== */
.kk_float { display: none; }
.kk_float_bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  display: none; justify-content: center;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: rgba(16, 32, 27, 0.96);
  border-top: 1px solid var(--kk-line);
}
.kk_float_bar .kk_button { width: 100%; max-width: 480px; }

/* ===== Footer ===== */
.kk_footer { border-top: 1px solid var(--kk-line); background: rgba(23, 43, 37, 0.6); padding: clamp(40px, 6vw, 72px) 0 24px; }
.kk_footer_cols { display: grid; gap: clamp(28px, 5vw, 56px); }
.kk_owner p { color: var(--kk-muted); margin: 0 0 8px; }
.kk_footer_contacts, .kk_footer_links { list-style: none; padding: 0; display: grid; gap: 10px; }
.kk_footer_contacts span, .kk_footer_links { color: var(--kk-muted); font-size: 0.95rem; }
.kk_footer_bottom { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--kk-line); }
.kk_footer_copy { color: var(--kk-muted); font-size: 0.9rem; margin: 0; }

/* ===== Reveal ===== */
.kk_reveal { opacity: 1; }
html.kk_js_ready .kk_reveal {
  opacity: 0; transform: translateY(18px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
html.kk_js_ready .kk_reveal.is_revealed { opacity: 1; transform: none; }

/* ===== Inner page intro ===== */
.kk_page_intro { padding: clamp(40px, 6vw, 72px) 0 0; }
.kk_page_intro h1 { margin-bottom: 16px; }
.kk_page_intro p { color: var(--kk-muted); font-size: clamp(1.05rem, 1.5vw, 1.2rem); }

/* ===== Gallery blocks ===== */
.kk_gallery { display: grid; gap: 24px; }
.kk_gallery img { border: 1px solid var(--kk-line); background: var(--kk-surface); width: 100%; }

/* ===== Contacts block ===== */
.kk_contacts { list-style: none; padding: 0; display: grid; gap: 14px; max-width: 760px; }
.kk_contacts span { color: var(--kk-muted); margin-right: 8px; }

/* ===== Thanks & 404 ===== */
.kk_confirm { text-align: left; max-width: 760px; }
.kk_confirm .kk_plate { margin: 32px 0; }
.kk_next { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 32px; }

/* ===== Breakpoints ===== */
@media (max-width: 1279px) {
  .kk_nav_panel { gap: 40px; }
}

@media (max-width: 1023px) {
  .kk_header { min-height: 64px; }
  .kk_section_grid { grid-template-columns: 1fr; }
  .kk_section_grid > .kk_section_head { position: static; }
  .kk_prices { grid-template-columns: repeat(2, 1fr); }
  .kk_float_bar { display: flex; }
  .kk_nav_panel { grid-template-columns: 1fr; }
  .kk_nav_side { border-left: none; border-top: 1px solid var(--kk-line); padding: 24px 0 0; }
}

@media (min-width: 1024px) {
  .kk_section_grid { grid-template-columns: minmax(280px, 320px) 1fr; align-items: start; }
  .kk_section_grid > .kk_section_head { align-self: start; }
  .kk_section_grid > .kk_section_head { position: sticky; top: 96px; }
  .kk_hero_grid { grid-template-columns: 1.1fr 1fr; }
  .kk_hero_collage { grid-template-columns: 300px 260px; justify-content: start; align-items: end; }
  .kk_prices { grid-template-columns: repeat(3, 1fr); align-items: stretch; }
  .kk_price_card { display: flex; flex-direction: column; padding: 32px; }
  .kk_price_desc { margin: 0; }
  .kk_gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
  .kk_prices { grid-template-columns: 1fr; }
  .kk_numbered_item { grid-template-columns: 1fr; padding: 24px; }
  .kk_numbered_num { grid-row: auto; margin-bottom: 8px; }
  .kk_header_mail { font-size: 0.85rem; max-width: 30vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .kk_section { padding-block: clamp(64px, 9vw, 96px); }
}

@media (max-width: 639px) {
  .kk_hero_collage { grid-template-columns: 1fr; gap: 16px; }
  .kk_gallery { grid-template-columns: 1fr; }
}

@media (max-width: 479px) {
  .kk_nav_link { font-size: 1.4rem; }
  .kk_header_mail { display: none; }
  .kk_header { grid-template-columns: 1fr auto; }
  .kk_plate { padding: 20px; }
}

@media (max-height: 600px) and (min-width: 1024px) {
  .kk_hero { padding-top: 24px; }
  .kk_section_grid > .kk_section_head { position: static; }
}

/* ===== Reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  html.kk_js_ready .kk_reveal { opacity: 1; transform: none; }
}

/* ===== Price card headings ===== */
.kk_price_card { padding: 32px; }
.kk_price_name { margin: 0 0 16px; }

/* ===== Offscreen render ===== */
.kk_footer {
  content-visibility: auto;
  contain-intrinsic-size: auto 420px;
}
.kk_float_bar {
  content-visibility: auto;
  contain-intrinsic-size: auto 88px;
}
