/* kolimisjargnekoristus.ee – stiilid. Ilma väliste fontide ja teekideta. */
:root {
  --ink: #14262e;
  --muted: #475a63;
  --line: #d6e1e4;
  --bg: #ffffff;
  --soft: #f1f7f7;
  --brand: #0b6e6e;
  --brand-dark: #07494c;
  --brand-ink: #053639;
  --accent: #ffb81c;
  --accent-dark: #e5a000;
  --warn-bg: #fff6df;
  --warn-line: #e8c45a;
  --err: #b3261e;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20, 38, 46, 0.06), 0 8px 24px rgba(20, 38, 46, 0.07);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  color-scheme: light;
}
img, svg { max-width: 100%; }
a { color: var(--brand); text-underline-offset: 0.18em; text-decoration-thickness: 0.08em; }
a:hover { color: var(--brand-dark); }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
.site-footer :focus-visible, .cta-band :focus-visible { outline-color: var(--accent); }

.wrap { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: 8px; }
.skip:focus { top: 10px; }

h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -0.01em; margin: 0 0 0.6em; color: var(--ink); text-wrap: balance; }
h1 { font-size: clamp(1.9rem, 4.2vw, 2.9rem); font-weight: 800; }
h2 { font-size: clamp(1.4rem, 2.4vw, 1.8rem); font-weight: 750; margin-top: 2.2em; }
h3 { font-size: 1.2rem; font-weight: 700; margin-top: 1.6em; }
p { margin: 0 0 1.05em; }
ul, ol { margin: 0 0 1.2em; padding-left: 1.3em; }
li { margin-bottom: 0.35em; }
strong { font-weight: 700; }
code { background: var(--soft); padding: 0.1em 0.35em; border-radius: 4px; }
blockquote { margin: 1.2em 0; padding: 1em 1.2em; border-left: 4px solid var(--brand); background: var(--soft); border-radius: 0 var(--radius) var(--radius) 0; }
blockquote p { margin: 0; }
.muted { color: var(--muted); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  min-height: 48px; padding: 0.7em 1.25em;
  border: 2px solid transparent; border-radius: 999px;
  font: inherit; font-weight: 700; line-height: 1.2; text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .15s;
}
.btn-primary { background: var(--accent); color: var(--ink); }
.btn-primary:hover { background: var(--accent-dark); color: var(--ink); }
.btn-phone { background: var(--brand); color: #fff; }
.btn-phone:hover { background: var(--brand-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--brand-dark); border-color: var(--brand); }
.btn-ghost:hover { background: var(--soft); color: var(--brand-dark); }
.btn-lg { min-height: 54px; padding-inline: 1.6em; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.4em 0 0.4em; }

/* ---------- header / nav ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 1.08rem; font-weight: 800; }
.brand-text small { font-size: 0.8rem; color: var(--muted); }
.nav-toggle { display: none; align-items: center; gap: 10px; min-height: 46px; padding: 0 14px; background: #fff; border: 2px solid var(--line); border-radius: 12px; font: inherit; font-weight: 700; color: var(--ink); cursor: pointer; }
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after { display: block; width: 20px; height: 2.5px; background: currentColor; border-radius: 2px; position: relative; content: ""; }
.nav-toggle-bars::before { position: absolute; top: -6px; }
.nav-toggle-bars::after { position: absolute; top: 6px; }
.site-nav { display: flex; align-items: center; gap: 20px; }
.nav-list { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-list > li { margin: 0; position: relative; }
.nav-list a, .menu-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px; border-radius: 10px; color: var(--ink); text-decoration: none; font: inherit; font-weight: 600; background: none; border: 0; cursor: pointer; }
.nav-list a:hover, .menu-btn:hover, .is-current > .menu-btn { background: var(--soft); color: var(--brand-dark); }
.nav-list a[aria-current="page"] { color: var(--brand-dark); box-shadow: inset 0 -3px 0 var(--accent); border-radius: 10px 10px 0 0; }
.menu-btn svg { transition: transform .15s; }
.menu-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.menu-panel { display: none; position: absolute; left: -8px; top: calc(100% + 6px); width: 560px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; grid-template-columns: 1.2fr 1fr; gap: 24px; }
.menu-panel.open { display: grid; }
html:not(.js) .has-menu:hover .menu-panel, html:not(.js) .has-menu:focus-within .menu-panel { display: grid; }
.menu-title { margin: 0 0 6px; font-size: 0.78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.menu-group ul { list-style: none; margin: 0; padding: 0; }
.menu-group li { margin: 0; }
.menu-group a { display: flex; min-height: 40px; padding: 0 10px; font-weight: 500; width: 100%; }
.nav-cta { display: flex; align-items: center; gap: 10px; }
.btn-phone-sm { min-height: 44px; padding: 0.5em 1em; border-color: transparent; }
.btn-phone-sm:hover { background: var(--soft); }

@media (max-width: 1060px) {
  .btn-phone-sm span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .btn-phone-sm { padding: 0.5em 0.7em; }
}
@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 14px; background: #fff; border-bottom: 1px solid var(--line); padding: 12px 20px 20px; max-height: calc(100vh - 72px); overflow-y: auto; box-shadow: var(--shadow); }
  .site-nav.open, html:not(.js) .site-nav { display: flex; }
  html:not(.js) .nav-toggle { display: none; }
  html:not(.js) .site-header { position: static; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list a, .menu-btn { width: 100%; min-height: 50px; justify-content: space-between; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav-list a[aria-current="page"] { box-shadow: inset 4px 0 0 var(--accent); border-radius: 0; }
  .menu-panel { position: static; width: auto; box-shadow: none; border: 0; padding: 4px 0 8px 8px; grid-template-columns: 1fr; gap: 8px; }
  html:not(.js) .menu-panel { display: grid; }
  .menu-btn svg { display: none; }
  .nav-cta { flex-direction: column; align-items: stretch; }
  .btn-phone-sm span { position: static; width: auto; height: auto; overflow: visible; clip: auto; }
  .btn-phone-sm { padding: 0.7em 1.25em; border-color: var(--brand); }
  .nav-cta .btn { width: 100%; }
}

/* ---------- hero (home) ---------- */
.hero { background: linear-gradient(160deg, #e9f4f3 0%, #f7fbfb 60%, #fff 100%); border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 40px; padding-block: 56px 60px; align-items: center; }
.hero-copy .lead { font-size: 1.18rem; color: #26404a; max-width: 38em; }
.hero-card { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 22px 24px; }
.hero-card h2 { margin: 0 0 12px; font-size: 1.1rem; }
.hero-card ul { list-style: none; margin: 0; padding: 0; }
.hero-card li { display: flex; flex-direction: column; margin: 0; padding: 12px 0; border-top: 1px solid var(--line); }
.hero-card li:first-child { border-top: 0; padding-top: 0; }
.hero-card li strong { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--brand-dark); }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; padding-block: 36px 40px; gap: 28px; } }

/* ---------- inner page head ---------- */
.page-head { background: linear-gradient(180deg, var(--soft), #fff); border-bottom: 1px solid var(--line); padding-block: 28px 34px; }
.page-head h1 { max-width: 22em; }
.page-head .lead { font-size: 1.15rem; color: #26404a; max-width: 44em; margin-bottom: 0.3em; }
.breadcrumb ol { display: flex; flex-wrap: wrap; list-style: none; margin: 0 0 18px; padding: 0; font-size: 0.92rem; color: var(--muted); }
.breadcrumb li { margin: 0; }
.breadcrumb li + li::before { content: "›"; margin: 0 0.55em; color: #8aa0a8; }
.breadcrumb a { color: var(--muted); }

/* ---------- document layout ---------- */
.doc { padding-block: 36px 56px; }
.prose { max-width: 46rem; }
.prose > section > h2:first-child, .prose > h2:first-child { margin-top: 0; }
.prose section + section { margin-top: 0.4em; }
.doc-toc { display: grid; grid-template-columns: 15.5rem minmax(0, 1fr); gap: 48px; max-width: 1140px; }
.toc { position: sticky; top: 96px; align-self: start; font-size: 0.95rem; max-height: calc(100vh - 120px); overflow: auto; }
.toc-title { margin: 0 0 8px; font-weight: 800; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.toc li { margin: 0; }
.toc a { display: block; padding: 6px 12px; color: var(--ink); text-decoration: none; margin-left: -2px; border-left: 2px solid transparent; }
.toc a:hover { color: var(--brand-dark); border-left-color: var(--brand); background: var(--soft); }
@media (max-width: 960px) {
  .doc-toc { display: block; }
  .toc { position: static; max-height: none; margin-bottom: 28px; background: var(--soft); border-radius: var(--radius); padding: 14px 18px; }
}

/* ---------- home bands ---------- */
.band { padding-block: 48px; }
.band-soft { background: var(--soft); border-block: 1px solid var(--line); }
.band .prose { max-width: 52rem; }
.band .prose > h2:first-child { margin-top: 0; }
.band .table-wrap, .band .steps { max-width: 52rem; }

/* ---------- lists, chips, steps ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 1.2em 0; padding: 0; }
.chips li { margin: 0; }
.chips a { display: inline-flex; align-items: center; min-height: 44px; padding: 0.4em 1em; border: 2px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 600; color: var(--brand-dark); background: #fff; }
.chips a:hover { border-color: var(--brand); background: var(--soft); }
.steps { list-style: none; counter-reset: step; padding: 0; margin: 1.4em 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; position: relative; margin: 0; padding: 14px 16px 14px 62px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.band-soft .steps li { background: #fff; }
.steps li::before { content: counter(step); position: absolute; left: 14px; top: 12px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; }
.checklist { list-style: none; padding: 0; margin: 0 0 1.4em; }
.checklist li { margin: 0; border-bottom: 1px solid var(--line); }
.checklist label { display: flex; gap: 12px; align-items: flex-start; padding: 10px 4px; cursor: pointer; }
.checklist input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--brand); }
.checklist input:checked + span { color: var(--muted); text-decoration: line-through; }

/* ---------- tables ---------- */
.table-wrap { margin: 1.3em 0 1.6em; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.table-wrap:focus-visible { outline-offset: 0; }
table { border-collapse: collapse; width: 100%; font-size: 0.98rem; }
th, td { text-align: left; padding: 12px 16px; vertical-align: top; border-bottom: 1px solid var(--line); }
thead th { background: var(--soft); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); }
tbody th { font-weight: 650; }
tbody tr:last-child > * { border-bottom: 0; }
@media (max-width: 640px) {
  .table-wrap { overflow: visible; border: 0; background: none; }
  table, tbody, tr, th, td { display: block; width: 100%; }
  thead { position: absolute; left: -9999px; }
  tr { margin-bottom: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; overflow: hidden; }
  th, td { border: 0; padding: 8px 14px; }
  tbody th { background: var(--soft); padding-block: 10px; }
  td[data-label]::before { content: attr(data-label); display: block; font-size: 0.75rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
}

/* ---------- FAQ ---------- */
.faq { margin: 1.2em 0 1.6em; display: grid; gap: 10px; }
.qa { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.qa summary { cursor: pointer; list-style: none; padding: 14px 52px 14px 18px; font-weight: 700; position: relative; border-radius: var(--radius); }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: ""; position: absolute; right: 20px; top: 50%; width: 10px; height: 10px; border-right: 2.5px solid var(--brand); border-bottom: 2.5px solid var(--brand); transform: translateY(-70%) rotate(45deg); transition: transform .15s; }
.qa[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.qa[open] summary { border-bottom: 1px solid var(--line); border-radius: var(--radius) var(--radius) 0 0; }
.qa summary:hover { background: var(--soft); }
.qa-body { padding: 14px 18px 4px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--brand-dark); color: #fff; padding-block: 48px; }
.cta-band h2 { color: #fff; margin: 0 0 0.4em; }
.cta-band p { color: #e3f1f1; max-width: 40em; }
.cta-band a:not(.btn) { color: #fff; }
.cta-band .btn-phone { background: transparent; border-color: #fff; color: #fff; }
.cta-band .btn-phone:hover { background: rgba(255,255,255,.12); color: #fff; }
.cta-band .actions { margin-top: 1em; }

/* ---------- contact + form ---------- */
.contact-card { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: 1.6em 0; padding: 24px; background: var(--soft); border: 1px solid var(--line); border-radius: 18px; }
.contact-card h2 { margin: 0 0 8px; font-size: 1.15rem; }
.big-phone { font-size: clamp(1.5rem, 3.4vw, 2rem); font-weight: 800; margin-bottom: 0.4em; }
.big-phone a { text-decoration: none; }
@media (max-width: 700px) { .contact-card { grid-template-columns: 1fr; } }
.form-section { margin: 2.2em 0; padding: 26px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: var(--shadow); max-width: 46rem; }
.form-section h2 { margin-top: 0; }
.form .field { margin-bottom: 18px; }
.form label { display: block; font-weight: 700; margin-bottom: 6px; }
.form .opt { font-weight: 400; color: var(--muted); }
.form .req { color: var(--err); }
.form input[type="text"], .form input[type="tel"], .form select, .form textarea {
  width: 100%; min-height: 50px; padding: 11px 14px; font: inherit; color: var(--ink); background: #fff;
  border: 2px solid #9bb0b6; border-radius: 10px;
}
.form textarea { resize: vertical; min-height: 140px; }
.form input[type="file"] { width: 100%; padding: 10px; border: 2px dashed #9bb0b6; border-radius: 10px; background: var(--soft); font: inherit; }
.form input:focus-visible, .form select:focus-visible, .form textarea:focus-visible { outline: 3px solid var(--accent); outline-offset: 1px; border-color: var(--brand); }
.form .field.invalid input, .form .field.invalid textarea, .form .field.invalid select { border-color: var(--err); }
.hint { margin: 6px 0 0; font-size: 0.9rem; color: var(--muted); }
.err { margin: 6px 0 0; font-size: 0.95rem; color: var(--err); font-weight: 700; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
@media (max-width: 640px) { .grid2 { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: 0.92rem; color: var(--muted); }
.form-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.form-errors { margin-bottom: 18px; padding: 14px 18px; border: 2px solid var(--err); border-radius: 12px; background: #fdecea; color: #6b1510; }
.form-errors ul { margin: 6px 0 0; }
.form-errors a { color: inherit; font-weight: 700; }
.form-success { margin-top: 18px; padding: 16px 18px; border: 2px solid var(--brand); border-radius: 12px; background: #e6f4f1; }
.notice { padding: 14px 18px; border-radius: 12px; margin: 0 0 20px; }
.notice-warn { background: var(--warn-bg); border: 1px solid var(--warn-line); }

/* ---------- footer ---------- */
.site-footer { background: #0e2a30; color: #d7e6e8; padding-top: 48px; margin-top: 0; }
.site-footer a { color: #fff; }
.foot-grid { display: grid; grid-template-columns: 1.5fr repeat(4, 1fr); gap: 32px; padding-bottom: 36px; }
.foot-title { font-size: 0.95rem; color: #fff; margin: 0 0 12px; }
.foot-col ul { list-style: none; margin: 0; padding: 0; }
.foot-col li { margin-bottom: 8px; font-size: 0.95rem; line-height: 1.35; }
.foot-col p { font-size: 0.95rem; }
.foot-note { color: #a9c0c4; font-size: 0.85rem !important; }
.foot-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; border-top: 1px solid rgba(255,255,255,.15); padding-block: 18px 22px; font-size: 0.9rem; }
.foot-bottom p { margin: 0; }
.foot-bottom nav { display: flex; flex-wrap: wrap; gap: 18px; }
@media (max-width: 1000px) { .foot-grid { grid-template-columns: 1fr 1fr; } .foot-company { grid-column: 1 / -1; } }
@media (max-width: 520px) { .foot-grid { grid-template-columns: 1fr; } }

/* ---------- mobile call bar ---------- */
.call-bar { display: none; }
@media (max-width: 760px) {
  .call-bar { display: grid; grid-template-columns: 1fr 1.4fr; gap: 10px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: rgba(255,255,255,.98); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(20,38,46,.1); }
  .call-bar .btn { min-height: 48px; }
  body { padding-bottom: 76px; }
}

/* ---------- print (nt kontrollnimekiri) ---------- */
@media print {
  .site-header, .site-footer, .call-bar, .cta-band, .toc, .actions, .skip { display: none !important; }
  body { padding: 0; font-size: 11pt; }
  .page-head { background: none; border: 0; padding: 0; }
  .prose { max-width: none; }
  a { color: inherit; text-decoration: none; }
}

/* ---------- nõusolekuriba ---------- */
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: #fff; text-decoration: underline; cursor: pointer; }
.consent { position: fixed; z-index: 60; left: 16px; right: 16px; bottom: 16px; max-width: 560px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 10px 40px rgba(20,38,46,.25); padding: 18px 20px; }
.consent[hidden] { display: none; }
.consent p { margin: 0 0 0.6em; font-size: 0.95rem; }
.consent-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.consent-actions .btn { flex: 1 1 140px; }
@media (max-width: 760px) { .consent { bottom: 88px; } }
