/* Cookie Solutions / CEPUMS — vietnes stils
   Akcents: Samariešu sarkanais #C62828 (tas pats, kas CEPUMS programmā). */

@font-face {
  font-family: "Manrope";
  src: url("/assets/fonts/manrope-latin-ext.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Manrope";
  src: url("/assets/fonts/manrope-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* Krāsas */
  --red: #C62828;
  --red-deep: #8E1C1C;
  --red-soft: #FBE9E7;
  --ink: #23262F;
  --ink-soft: #4A4E5A;
  --muted: #5F6370;
  --navy: #1E2433;
  --navy-2: #283045;
  --on-navy: #F3F0EC;
  --on-navy-muted: #B9BDC8;
  --cream: #FCF8F5;
  --tint: #F5EFEA;
  --paper: #FFFFFF;
  --line: #E7DFD8;
  --focus: #1E2433;
  --ok: #2E6B3F;

  /* Tipogrāfija */
  --font: "Manrope", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --fs-sm: 0.9375rem;
  --fs-base: 1.0625rem;
  --fs-lg: 1.1875rem;
  --fs-h3: 1.25rem;
  --fs-h2: clamp(1.75rem, 1.2rem + 2vw, 2.5rem);
  --fs-h1: clamp(2rem, 1.25rem + 3vw, 3.15rem);

  /* Atstarpes */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px;
  --s6: 32px; --s7: 48px; --s8: 64px; --s9: 96px;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(30, 36, 51, .06), 0 8px 24px rgba(30, 36, 51, .08);
  --shadow-lg: 0 2px 6px rgba(30, 36, 51, .08), 0 24px 60px rgba(30, 36, 51, .18);
  --container: 1180px;
  --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { line-height: 1.18; margin: 0 0 var(--s4); letter-spacing: -0.015em; }
h1 { font-size: var(--fs-h1); font-weight: 800; }
h2 { font-size: var(--fs-h2); font-weight: 800; }
h3 { font-size: var(--fs-h3); font-weight: 700; }
p { margin: 0 0 var(--s4); }
a { color: var(--red); text-underline-offset: 3px; }
a:hover { color: var(--red-deep); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.section-dark :focus-visible, .site-footer :focus-visible, .cta-band :focus-visible { outline-color: #fff; }
mark { background: #FFF1B8; color: inherit; padding: 0 .2em; border-radius: 3px; }

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--s4); }
@media (min-width: 640px) { .container { padding: 0 var(--s5); } }
.narrow { max-width: 820px; }
.muted { color: var(--muted); }
.accent { color: var(--red); }

.skip-link {
  position: absolute; left: var(--s4); top: -100px; z-index: 100;
  background: var(--navy); color: #fff; padding: var(--s3) var(--s4); border-radius: var(--radius-sm);
}
.skip-link:focus { top: var(--s3); color: #fff; }

/* Pogas */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s2);
  min-height: 44px; padding: 10px 22px; border-radius: 999px;
  font: inherit; font-weight: 700; font-size: var(--fs-sm); text-decoration: none; line-height: 1.2;
  border: 2px solid transparent; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s, transform .15s;
}
.btn svg { flex: none; }
.btn-lg { min-height: 52px; padding: 13px 28px; font-size: var(--fs-base); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-deep); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-light { background: #fff; color: var(--red-deep); }
.btn-light:hover { background: var(--red-soft); color: var(--red-deep); }
.btn[disabled] { opacity: .65; cursor: progress; }

.eyebrow {
  font-size: .8125rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--red); margin-bottom: var(--s3);
}
.section-dark .eyebrow, .cta-band .eyebrow { color: #FF8A80; }

/* Galvene */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(252, 248, 245, .94);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: var(--s5); min-height: var(--header-h); }
.brand { flex: none; display: block; }
.brand img { height: 46px; width: auto; }
.site-nav { display: flex; align-items: center; gap: var(--s5); margin-left: auto; }
.site-nav ul { display: flex; gap: var(--s1); list-style: none; margin: 0; padding: 0; }
.site-nav ul a {
  display: block; padding: 10px 12px; border-radius: 8px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: var(--fs-sm);
}
.site-nav ul a:hover { color: var(--red); background: var(--red-soft); }
.nav-toggle {
  display: none; margin-left: auto; align-items: center; gap: var(--s2);
  min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--paper); color: var(--ink); font: inherit; font-weight: 700; font-size: var(--fs-sm); cursor: pointer;
}

@media (max-width: 959px) {
  :root { --header-h: 68px; }
  .brand img { height: 40px; }
  .js .nav-toggle { display: inline-flex; }
  .js .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: var(--s4);
    padding: var(--s4) var(--s4) var(--s5); background: var(--cream);
    border-bottom: 1px solid var(--line); box-shadow: 0 16px 30px rgba(30, 36, 51, .12);
  }
  .js .site-nav.is-open { display: flex; }
  .site-nav ul { flex-direction: column; }
  .site-nav ul a { padding: 12px; font-size: var(--fs-base); }
  /* Bez JavaScript: navigācija redzama zem logotipa */
  html:not(.js) .header-inner { flex-wrap: wrap; padding-bottom: var(--s3); }
  html:not(.js) .site-nav { margin-left: 0; flex-wrap: wrap; }
  html:not(.js) .site-nav ul { flex-direction: row; flex-wrap: wrap; }
}

/* Sākuma ekrāns */
.hero { position: relative; overflow: hidden; padding: var(--s8) 0 calc(var(--s9) + var(--s6)); }
.hero::before {
  content: ""; position: absolute; inset: 0 0 0 58%;
  background: var(--navy);
  border-bottom-left-radius: 48px;
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1fr 1.08fr; gap: var(--s7); align-items: center; }
.hero h1 { margin-bottom: var(--s5); }
.lead { font-size: var(--fs-lg); color: var(--ink-soft); max-width: 36em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--s3); margin: var(--s6) 0 var(--s5); }
.hero-facts { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); list-style: none; padding: 0; margin: 0; color: var(--ink-soft); font-size: var(--fs-sm); font-weight: 600; }
.hero-facts li { display: flex; align-items: center; gap: var(--s2); }
.hero-facts svg { color: var(--red); }
.hero-visual { position: relative; }
.app-window {
  margin: 0; background: var(--paper); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-lg); border: 1px solid rgba(255, 255, 255, .08);
}
.app-window-bar { display: flex; gap: 6px; padding: 10px 14px; background: #EEE8E3; }
.app-window-bar span { width: 10px; height: 10px; border-radius: 50%; background: #CFC6BF; }
.app-window img { width: 100%; }
.hero-badge {
  position: absolute; display: flex; align-items: center; gap: var(--s3);
  padding: 12px 16px; background: var(--paper); border-radius: 12px; box-shadow: var(--shadow);
  font-size: var(--fs-sm); color: var(--ink);
}
.hero-badge svg { color: var(--red); flex: none; }
.hero-badge-a { left: -28px; bottom: 18%; }

@media (max-width: 959px) {
  .hero { padding: var(--s6) 0 var(--s9); }
  .hero::before { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: var(--s6); }
  .hero-visual { background: var(--navy); border-radius: 24px; padding: var(--s7) var(--s4) var(--s8); }
  .hero-badge-a { left: 12px; bottom: auto; top: -18px; }
}
@media (max-width: 479px) {
  .hero-actions .btn { width: 100%; }
  .hero-badge { padding: 8px 12px; font-size: .8125rem; }
}

/* Ieguvumi */
.benefits { position: relative; margin-top: calc(-1 * var(--s9)); z-index: 2; }
.benefits-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s5); }
.benefit {
  background: var(--paper); border-radius: var(--radius); padding: var(--s6);
  box-shadow: var(--shadow); border-top: 4px solid var(--red);
}
.benefit h2 { font-size: var(--fs-h3); margin-top: var(--s4); }
.benefit p { color: var(--ink-soft); margin: 0; }
.icon-tile {
  display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
  background: var(--red-soft); color: var(--red);
}
.icon-tile-lg { width: 72px; height: 72px; border-radius: 20px; margin-bottom: var(--s5); }
@media (max-width: 899px) { .benefits-grid { grid-template-columns: 1fr; } }

/* Sadaļas */
.section { padding: var(--s9) 0; }
.section-tint { background: var(--tint); }
.section-head { max-width: 760px; margin-bottom: var(--s7); }
.section-head p:last-child { color: var(--ink-soft); font-size: var(--fs-lg); margin-bottom: 0; }
@media (max-width: 639px) { .section { padding: var(--s8) 0; } .section-head { margin-bottom: var(--s6); } }

/* Mērķauditorija */
.audience-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s5); }
.audience { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s6); }
.audience svg { color: var(--red); margin-bottom: var(--s4); }
.audience p { color: var(--ink-soft); margin: 0; }
@media (max-width: 899px) { .audience-grid { grid-template-columns: 1fr; } }

/* Plūsma */
.flow { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: var(--s4); counter-reset: flow; }
.flow-step {
  position: relative; background: var(--paper); border-radius: var(--radius); padding: var(--s5) var(--s4);
  box-shadow: var(--shadow);
}
.flow-step h3 { font-size: 1.0625rem; margin-bottom: var(--s2); }
.flow-step p { font-size: var(--fs-sm); color: var(--ink-soft); margin: 0; line-height: 1.5; }
.flow-num {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: var(--red); color: #fff; font-weight: 800; margin-bottom: var(--s3);
}
.flow-step:not(:last-child)::after {
  content: ""; position: absolute; top: 40px; right: -14px; width: 12px; height: 12px;
  border-top: 3px solid var(--red); border-right: 3px solid var(--red); transform: rotate(45deg);
}
.flow-note { display: flex; align-items: center; gap: var(--s3); margin: var(--s6) 0 0; color: var(--ink-soft); font-weight: 600; }
.flow-note svg { color: var(--red); flex: none; }
@media (max-width: 1099px) {
  .flow { grid-template-columns: repeat(3, 1fr); gap: var(--s5); }
  .flow-step:nth-child(3)::after { display: none; }
  .flow-step:not(:last-child)::after { right: -18px; }
}
@media (max-width: 639px) {
  .flow { grid-template-columns: 1fr; gap: var(--s5); }
  .flow-step { display: grid; grid-template-columns: auto 1fr; column-gap: var(--s4); }
  .flow-num { grid-row: span 2; margin: 0; }
  .flow-step:nth-child(3)::after { display: block; }
  .flow-step:not(:last-child)::after { top: auto; bottom: -19px; right: auto; left: 30px; transform: rotate(135deg); }
}

/* Funkcijas */
.feature { display: grid; grid-template-columns: 1fr 1.25fr; gap: var(--s7); align-items: center; margin-bottom: var(--s9); }
.feature-reverse { grid-template-columns: 1.25fr 1fr; }
.feature-reverse .feature-text { order: 2; }
.feature-text h3 { font-size: 1.625rem; margin-top: var(--s4); }
.feature-media { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-lg); border: 1px solid var(--line); background: var(--paper); }
.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
.checklist li { position: relative; padding-left: 32px; color: var(--ink-soft); }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .2em; width: 20px; height: 20px; border-radius: 50%;
  background: var(--red-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8' fill='none' stroke='%23C62828' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat;
}
@media (max-width: 899px) {
  .feature, .feature-reverse { grid-template-columns: 1fr; gap: var(--s5); margin-bottom: var(--s8); }
  .feature-reverse .feature-text { order: 0; }
}
.more-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s5); }
.more { padding: var(--s5); border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); }
.more svg { color: var(--red); margin-bottom: var(--s3); }
.more h3 { font-size: 1.0625rem; margin-bottom: var(--s2); }
.more p { font-size: var(--fs-sm); color: var(--ink-soft); margin: 0; }
@media (max-width: 1023px) { .more-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 559px) { .more-grid { grid-template-columns: 1fr; } }

/* Integrācijas (tumšā josla) */
.section-dark { background: var(--navy); color: var(--on-navy); }
.section-dark h2 { color: #fff; }
.integration-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s5); }
.integration { background: var(--navy-2); border-radius: var(--radius); padding: var(--s6); border: 1px solid rgba(255, 255, 255, .08); }
.integration svg { color: #FF8A80; margin-bottom: var(--s4); }
.integration h3 { color: #fff; }
.integration p { color: var(--on-navy-muted); margin: 0; }
@media (max-width: 899px) { .integration-grid { grid-template-columns: 1fr; } }

/* Demo */
.demo-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: var(--s7); align-items: start; }
.demo-intro p:not(.eyebrow) { color: var(--ink-soft); font-size: var(--fs-lg); }
.steps { list-style: none; counter-reset: s; margin: var(--s6) 0; padding: 0; display: grid; gap: var(--s4); }
.steps li { counter-increment: s; position: relative; padding-left: 52px; min-height: 36px; color: var(--ink-soft); }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: -2px; width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; background: var(--paper); border: 2px solid var(--red); color: var(--red); font-weight: 800;
}
.steps strong { color: var(--ink); }
.contact-box { background: var(--paper); border-radius: var(--radius); padding: var(--s5); border: 1px solid var(--line); }
.contact-box h3 { font-size: 1.0625rem; }
.contact-box ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2); font-weight: 700; }
.demo-form { background: var(--paper); border-radius: var(--radius); padding: var(--s6); box-shadow: var(--shadow); display: grid; gap: var(--s4); }
@media (max-width: 899px) { .demo-grid { grid-template-columns: 1fr; } }
@media (max-width: 479px) { .demo-form { padding: var(--s5) var(--s4); } .demo-form .btn { width: 100%; } }

.field { display: grid; gap: 6px; margin: 0; min-width: 0; }
fieldset.field { border: 0; padding: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s4); }
@media (max-width: 559px) { .field-row { grid-template-columns: 1fr; } }
label, legend { font-weight: 700; font-size: var(--fs-sm); color: var(--ink); }
legend { padding: 0; margin-bottom: 6px; }
.req { color: var(--red); }
.optional { font-weight: 500; color: var(--muted); }
input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; font: inherit; font-size: 1rem; color: var(--ink);
  background: #fff; border: 1.5px solid #CBC2BA; border-radius: var(--radius-sm);
  transition: border-color .15s, box-shadow .15s;
}
textarea { resize: vertical; min-height: 110px; }
input:hover, select:hover, textarea:hover { border-color: #9E958E; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(30, 36, 51, .25); }
[aria-invalid="true"] { border-color: var(--red) !important; }
.field-error { margin: 0; color: var(--red-deep); font-size: var(--fs-sm); font-weight: 600; }
.choices { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); }
.choice { display: inline-flex; align-items: flex-start; gap: var(--s2); font-weight: 600; cursor: pointer; }
.choice input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--red); flex: none; }
.consent { font-weight: 500; color: var(--ink-soft); line-height: 1.5; }
.form-note { margin: 0; font-size: .875rem; color: var(--muted); }
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-status:empty { display: none; }
.form-status { padding: var(--s4); border-radius: var(--radius-sm); font-weight: 600; }
.form-status.is-ok { background: #E6F2E9; color: var(--ok); border: 1px solid #B9D8C1; }
.form-status.is-error { background: var(--red-soft); color: var(--red-deep); border: 1px solid #F2C2BC; }
.form-status:focus { outline: none; }

/* BUJ */
.faq { display: grid; gap: var(--s3); }
.faq details { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.faq summary {
  list-style: none; cursor: pointer; padding: var(--s4) var(--s5); padding-right: 56px; position: relative;
  font-weight: 700; font-size: var(--fs-base);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 22px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
  border-right: 2.5px solid var(--red); border-bottom: 2.5px solid var(--red); transform: rotate(45deg); transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq summary:hover { color: var(--red); }
.faq details p { padding: 0 var(--s5) var(--s5); margin: 0; color: var(--ink-soft); }

/* Aicinājuma josla */
.cta-band { background: var(--red); color: #fff; padding: var(--s8) 0; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--s5); flex-wrap: wrap; }
.cta-band h2 { color: #fff; margin-bottom: var(--s2); }
.cta-band p { margin: 0; color: #FFE5E1; font-size: var(--fs-lg); }

/* Kājene */
.site-footer { background: var(--navy); color: var(--on-navy-muted); font-size: var(--fs-sm); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: var(--s7); padding-top: var(--s8); padding-bottom: var(--s7); }
.footer-brand img { height: 56px; width: auto; margin-bottom: var(--s4); }
.footer-brand p { max-width: 30em; }
.footer-col h2 { font-size: 1rem; color: #fff; margin-bottom: var(--s4); letter-spacing: 0; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2); }
.site-footer a { color: var(--on-navy); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: var(--s5) 0; }
.footer-bottom p { margin: 0; }
@media (max-width: 799px) { .footer-grid { grid-template-columns: 1fr; gap: var(--s6); } }

/* Teksta un ziņojumu lapas */
.page { padding: var(--s8) 0 var(--s9); }
.page-center { min-height: 60vh; display: grid; align-items: center; }
.message-page { text-align: center; }
.message-page .icon-tile-lg { color: var(--ok); background: #E6F2E9; }
.message-page .lead { margin: 0 auto var(--s6); }
.prose h1 { margin-bottom: var(--s5); }
.prose h2 { font-size: 1.375rem; margin-top: var(--s7); }
.prose ul { padding-left: 1.25em; margin: 0 0 var(--s4); }
.prose li { margin-bottom: var(--s2); }
.prose p, .prose li { color: var(--ink-soft); }
.draft-note { background: #FFF6D6; border: 1px solid #EBD58A; border-radius: var(--radius-sm); padding: var(--s4) var(--s5); margin-bottom: var(--s6); color: #5A4A10; }
