/* =========================================================================
   COORA — 1:1 with crm-erp.lv. Near-black bg, single pink-red accent,
   Inter Medium (500) headings, pink-silk hero + feature backdrop,
   real dashboard screenshot, big rounded dark cards with subtle borders.
   ========================================================================= */

:root {
  --accent: #f72e52;
  --accent-600: #e21d42;
  --accent-700: #c01736;
  --accent-tint: rgba(247, 46, 82, .12);
  --accent-glow: rgba(247, 46, 82, .55);

  --ink: #ffffff;
  --body: #c7c9d1;
  --muted: #8a8d97;
  --line: rgba(255, 255, 255, .10);
  --line-2: rgba(255, 255, 255, .06);

  --bg: #0a0a0b;
  --bg-soft: #0d0d0e;
  --surface: rgba(255, 255, 255, .035);
  --surface-2: rgba(255, 255, 255, .05);
  --footer: #070708;

  --r-sm: 10px;
  --r-md: 18px;
  --r-lg: 24px;
  --shadow-lg: 0 40px 90px rgba(0, 0, 0, .55);

  --container: 1180px;
  --font: "Inter", "Inter Placeholder", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Sora", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--body);
  background: var(--bg);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Real site: Inter Medium (500) for all headings, tight tracking. */
h1, h2, h3, h4 {
  color: var(--ink);
  font-family: var(--font);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -.02em;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.3rem, 5vw, 3.5rem); letter-spacing: -.02em; line-height: 1.12; }
h2 { font-size: clamp(1.5rem, 2.4vw, 1.9rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1rem; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 24px; }

.section { padding: clamp(64px, 9vw, 120px) 0; }
.section--soft { background: var(--bg-soft); }
.section__head { max-width: 680px; margin: 0 auto 56px; text-align: center; }
.section__head h2 { margin-bottom: 14px; }
.section__head p { font-size: 1.05rem; color: var(--muted); margin: 0; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: inherit; font-size: .96rem; font-weight: 500;
  padding: 13px 26px; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; transition: transform .15s ease, background .2s ease, border-color .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-600); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--lg { padding: 15px 32px; font-size: 1rem; }
.btn--block { width: 100%; justify-content: center; }

/* ---------- header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 10, 11, .72);
  backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line-2);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font-family: var(--font-display); font-weight: 700; color: var(--ink); font-size: 1.55rem; letter-spacing: -.03em; line-height: 1; }
.brand__mark { display: block; width: auto; height: 1.5em; filter: brightness(0) invert(1); }
.brand__word { display: inline-block; }
.nav { display: flex; align-items: center; gap: 32px; margin-left: auto; }
.nav a { font-weight: 500; font-size: .94rem; color: var(--body); }
.nav a:hover { color: var(--ink); }
.nav__cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; flex-direction: column; gap: 5px; padding: 8px; }
.nav-toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; }

/* ---------- hero (pink silk backdrop, centered) ---------- */
.hero { position: relative; overflow: hidden; text-align: center; }
.hero__bg--shader { background-image: none !important; }
.hero__bg--shader #heroShader { display: block; width: 100%; height: 100%; }
.hero__bg {
  position: absolute; inset: 0; z-index: 0;
  background-image: url("../img/hero-bg.png");
  background-size: cover; background-position: center top;
}
.hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(120% 80% at 50% 0%, rgba(10,10,11,.10) 0%, rgba(10,10,11,.45) 50%, var(--bg) 92%),
    linear-gradient(180deg, rgba(10,10,11,.35) 0%, rgba(10,10,11,0) 26%);
}
.hero__inner {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center;
  padding: clamp(80px, 11vw, 150px) 0 0;
}
.hero__title { margin-bottom: 22px; max-width: 18ch; }
.hero__title em { color: var(--accent); font-style: normal; }
.hero__lead { font-size: 1.1rem; color: var(--body); max-width: 64ch; margin-bottom: 32px; line-height: 1.65; }
.hero__shot {
  margin: clamp(48px, 7vw, 96px) auto 0; max-width: 980px; width: 100%;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg); overflow: hidden; background: var(--surface);
}
.hero__shot img { width: 100%; display: block; }

/* ---------- logo wall ---------- */
.logos { padding: 50px 0; border-bottom: 1px solid var(--line-2); background: var(--bg); }
.logos__label { text-align: center; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 28px; }
.logos__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 24px 52px; }
.logos__row img { height: 28px; width: auto; opacity: .5; filter: grayscale(1) brightness(1.9); transition: opacity .2s ease, filter .2s ease; }
.logos__row img:hover { opacity: 1; filter: grayscale(0) brightness(1); }

/* ---------- features (pink-silk backdrop, big rounded cards) ---------- */
.features { position: relative; overflow: hidden; }
.features__bg {
  position: absolute; inset: 0; z-index: 0;
  background-image: url("../img/features-bg.png");
  background-size: cover; background-position: center;
  opacity: .9;
}
.features__bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--bg) 0%, rgba(10,10,11,.55) 22%, rgba(10,10,11,.55) 78%, var(--bg) 100%);
}
.features > .container { position: relative; z-index: 1; }

.fcard {
  position: relative;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: rgba(14, 14, 16, .66);
  backdrop-filter: blur(8px);
  padding: 36px 34px;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.fcard__visual { position: relative; height: 180px; margin-bottom: 28px; display: flex; align-items: center; justify-content: center; }
.fcard h3 { margin: 0 0 10px; font-size: 1.3rem; }
.fcard p { margin: 0; font-size: .98rem; color: var(--muted); line-height: 1.6; }

.feature-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.feature-trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 22px; }

/* --- Venn (ERP + CRM overlapping circles) --- */
.venn { position: relative; width: 260px; height: 160px; }
.venn__c {
  position: absolute; top: 50%; width: 150px; height: 150px; border-radius: 50%;
  transform: translateY(-50%);
  border: 1px solid var(--accent-glow);
  background: radial-gradient(circle at 50% 50%, var(--accent-tint) 0%, rgba(247,46,82,.04) 55%, transparent 72%);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 600; font-size: .82rem; letter-spacing: .04em; color: var(--ink);
}
.venn__c--l { left: 8px; }
.venn__c--r { right: 8px; }
.venn__c span { transform: translateX(0); }
.venn__c--l span { margin-right: 38px; }
.venn__c--r span { margin-left: 38px; }
.venn__mark {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 2;
}
.venn__logo { display: block; width: 52px; height: auto; filter: brightness(0) saturate(100%) invert(22%) sepia(99%) saturate(3000%) hue-rotate(330deg) brightness(100%) contrast(110%); }

/* --- red-check list --- */
.checklist { width: 100%; display: flex; flex-direction: column; gap: 10px; }
.check {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border: 1px solid var(--line); border-radius: 12px;
  background: rgba(255,255,255,.03);
  opacity: 0; transform: translateX(-10px);
  transition: opacity .5s ease, transform .5s ease;
}
.in .check { opacity: 1; transform: none; }
.in .check:nth-child(1) { transition-delay: .05s; }
.in .check:nth-child(2) { transition-delay: .18s; }
.in .check:nth-child(3) { transition-delay: .31s; }
.in .check:nth-child(4) { transition-delay: .44s; }
.check__tick {
  flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: .8rem;
}
.check span { font-size: .95rem; color: var(--ink); }

/* --- chat bubbles --- */
.chat { width: 100%; display: flex; flex-direction: column; gap: 14px; }
.bubble {
  max-width: 84%; padding: 12px 16px; border-radius: 16px;
  font-size: .92rem; line-height: 1.45; color: var(--ink);
  opacity: 0; transform: translateY(10px);
  transition: opacity .5s ease, transform .5s ease;
}
.bubble time { display: block; margin-top: 6px; font-size: .72rem; color: var(--muted); }
.bubble--in { align-self: flex-start; background: rgba(255,255,255,.07); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.bubble--out { align-self: flex-end; background: var(--accent); border-bottom-right-radius: 4px; }
.bubble--out time { color: rgba(255,255,255,.75); }
.in .bubble--in { transition-delay: .1s; }
.in .bubble--out { transition-delay: .55s; }
.in .bubble { opacity: 1; transform: none; }

/* --- wireframe globe --- */
.globe { position: relative; width: 150px; height: 150px; }
.globe__o {
  position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid var(--accent-glow);
  box-shadow: 0 0 40px rgba(247,46,82,.18) inset;
}
.globe__o::before, .globe__o::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid rgba(247,46,82,.4);
}
.globe__o::before { transform: scaleX(.5); }
.globe__o::after { transform: scaleX(.16); }
.globe__lat {
  position: absolute; left: 0; right: 0; height: 1px; background: rgba(247,46,82,.32);
}
.globe__lat--1 { top: 32%; left: 6%; right: 6%; }
.globe__lat--2 { top: 50%; }
.globe__lat--3 { top: 68%; left: 6%; right: 6%; }

/* --- price visual --- */
.price { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.price__amount { font-family: var(--font-display); font-weight: 700; font-size: 2.4rem; color: var(--ink); letter-spacing: -.03em; }
.price__amount small { font-size: 1rem; font-weight: 500; color: var(--muted); }
.price__users { display: flex; align-items: center; }
.price__avatar {
  width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--bg-soft);
  background: linear-gradient(135deg, var(--accent), var(--accent-700));
  margin-left: -10px; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: .82rem; font-weight: 600;
}
.price__avatar:first-child { margin-left: 0; }
.price__avatar--more { background: rgba(255,255,255,.08); color: var(--ink); }

/* ---------- testimonials ---------- */
.quotes { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.quote { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 34px; }
.quote p { font-size: 1.05rem; color: var(--ink); line-height: 1.55; }
.quote__by { display: flex; align-items: center; gap: 14px; margin-top: 22px; }
.quote__photo { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; flex: 0 0 auto; }
.quote__by b { display: block; color: var(--ink); font-size: .95rem; }
.quote__by span { font-size: .85rem; color: var(--muted); }

/* ---------- contact ---------- */
.contact { text-align: center; }
.contact__rows { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 40px; margin: 8px 0 30px; }
.contact__rows a { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-size: 1.05rem; }
.contact__rows i { color: var(--accent); font-size: 1.2rem; }

/* ---------- onboarding form ---------- */
.onboard { background: var(--bg-soft); color: var(--ink); }
.onboard__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 52px; align-items: start; }
.onboard__intro ul { list-style: none; padding: 0; margin: 24px 0 0; }
.onboard__intro li { display: flex; gap: 12px; padding: 12px 0; color: var(--body); border-bottom: 1px solid var(--line-2); }
.onboard__intro li i { color: var(--accent); font-size: 1.2rem; flex: 0 0 auto; }
.form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: clamp(24px, 3vw, 38px); box-shadow: var(--shadow-lg); }
.form-card .fieldset-title { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin: 26px 0 14px; }
.form-card .fieldset-title:first-child { margin-top: 0; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: .88rem; font-weight: 500; color: var(--body); }
.field label .req { color: var(--accent); }
.field input, .field textarea {
  font-family: inherit; font-size: .98rem; color: var(--ink);
  padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-sm);
  background: var(--bg); transition: border-color .15s ease, box-shadow .15s ease;
}
.field input::placeholder, .field textarea::placeholder { color: #5c5f68; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }
.field .help { font-size: .8rem; color: var(--muted); }
.field .error { font-size: .8rem; color: #ff5a73; display: none; }
.field.invalid input, .field.invalid textarea { border-color: #ff5a73; }
.field.invalid .error { display: block; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-consent { display: flex; gap: 10px; align-items: flex-start; margin: 8px 0 18px; font-size: .85rem; color: var(--body); }
.form-consent input { margin-top: 3px; }
.form-success { display: none; padding: 18px; border-radius: var(--r-sm); background: var(--accent-tint); color: var(--accent); font-weight: 600; }

/* ---------- footer ---------- */
.footer { background: var(--footer); color: var(--muted); padding: 70px 0 30px; border-top: 1px solid var(--line-2); }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; }
.footer h4 { color: var(--ink); font-size: .95rem; margin-bottom: 14px; }
.footer a { display: block; padding: 5px 0; color: var(--muted); font-size: .92rem; }
.footer a:hover { color: var(--ink); }
.footer__brand p { font-size: .92rem; max-width: 32ch; }
.footer__fund { margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--line-2); display: grid; grid-template-columns: 1fr 1fr; gap: 16px 40px; max-width: 980px; }
.footer__fund p { font-size: .76rem; line-height: 1.6; color: var(--muted); }
.footer__eu { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line-2); font-size: .82rem; color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal, .check, .bubble { opacity: 1 !important; transform: none !important; transition: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .feature-pair { grid-template-columns: 1fr; }
  .feature-trio { grid-template-columns: 1fr; }
  .modules { grid-template-columns: 1fr 1fr; gap: 0 32px; }
  .onboard__grid { grid-template-columns: 1fr; gap: 32px; }
  .quotes { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .nav, .nav__cta .btn--ghost { display: none; }
  .nav-toggle { display: flex; }
  .nav.open { display: flex; position: absolute; top: 72px; left: 0; right: 0; flex-direction: column; align-items: flex-start; gap: 4px; background: var(--surface); padding: 16px 24px; border-bottom: 1px solid var(--line); }
  .field-row { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__fund { grid-template-columns: 1fr; }
  body { font-size: 16px; }
}
