/* ============================================================
   KartvelOps — design tokens & base
   Style: Trust & Authority (navy / azure / paper)
   Type: IBM Plex Serif (display) + IBM Plex Sans (body)
         + IBM Plex Mono (ops voice)
         + Noto Sans/Serif Georgian (ka)
   ============================================================ */

:root {
  /* color tokens */
  --ink: #020617;
  --navy: #0F172A;
  --navy-2: #16233D;
  --slate: #334155;
  --slate-3: #64748B;
  --slate-mist: #5B6B80;    /* muted text on mist surfaces: >=4.5:1 */
  --paper: #F8FAFC;
  --mist: #EDF1F6;
  --white: #FFFFFF;
  --border: #E2E8F0;
  --border-strong: #8494A8;   /* input boundaries: >=3:1 on white */
  --border-dark: #26334D;
  --azure: #0369A1;
  --azure-deep: #075985;
  --azure-bright: #38BDF8;
  --azure-tint: #EAF4FA;
  --text-dark: #C7D2E1;       /* body text on navy surfaces */
  --muted-dark: #8DA0B9;      /* small/dim text on navy: >=4.5:1 */
  --ok: #34D399;

  /* type */
  --font-display: "IBM Plex Serif", "Noto Serif Georgian", Georgia, serif;
  --font-sans: "IBM Plex Sans", "Noto Sans Georgian", system-ui, -apple-system, sans-serif;
  --font-mono: "IBM Plex Mono", "Noto Sans Georgian", ui-monospace, monospace;

  /* type scale */
  --text-xs: 13px;
  --text-sm: 15px;
  --text-base: 17px;
  --text-md: 19px;
  --text-lg: 21px;
  --text-xl: clamp(30px, 3.6vw, 42px);
  --text-hero: clamp(34px, 4.4vw, 52px);

  /* rhythm */
  --container: 1120px;
  --radius: 10px;
  --section-y: clamp(64px, 10vw, 120px);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--slate);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1, h2 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: -0.01em;
}
h3 { color: var(--ink); line-height: 1.25; letter-spacing: -0.01em; }
/* Georgian is unicameral — negative tracking hurts it */
html[lang="ka"] h1, html[lang="ka"] h2, html[lang="ka"] h3 { letter-spacing: 0; }

a { color: var(--azure); text-decoration: none; }
a:hover { color: var(--azure-deep); }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(20px, 4vw, 32px);
}

/* accessibility */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--white);
  padding: 10px 18px; z-index: 200; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: var(--white); }

:focus-visible {
  outline: 2px solid var(--azure);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ============ shared elements ============ */

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--azure);
  margin-bottom: 14px;
}
html[lang="ka"] .eyebrow { letter-spacing: 0.06em; }
.eyebrow-dark { color: var(--azure-bright); }

.section { padding-block: var(--section-y); }
.section-mist { background: var(--mist); }
.section-navy { background: var(--navy); color: var(--text-dark); }

.section-title {
  font-size: var(--text-xl);
  max-width: 24ch;
  margin-bottom: clamp(28px, 4vw, 48px);
}
html[lang="ka"] .section-title { max-width: 28ch; }
.section-navy .section-title { color: var(--white); }

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  padding: 13px 26px;
  min-height: 46px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 200ms var(--ease-out), color 200ms var(--ease-out),
              border-color 200ms var(--ease-out), transform 200ms var(--ease-out);
  touch-action: manipulation;
}
.btn:active { transform: scale(0.98); }
.btn-sm { padding: 9px 18px; font-size: 14px; min-height: 44px; }
.btn-block { width: 100%; }

.btn-primary { background: var(--navy); color: var(--white); }
.btn-primary:hover { background: var(--azure-deep); color: var(--white); }

.btn-invert { background: var(--white); color: var(--ink); }
.btn-invert:hover { background: var(--azure-bright); color: var(--ink); }

.btn-ghost { background: transparent; color: var(--white); border-color: var(--border-dark); }
.btn-ghost:hover { border-color: var(--azure-bright); color: var(--azure-bright); }

/* ============ header ============ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 240ms var(--ease-out);
}
.site-header.scrolled { border-bottom-color: var(--border-dark); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--white);
}
.brand:hover { color: var(--white); }
.brand-mark { width: 34px; height: 34px; flex: none; }
.brand-word {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--white);
}
.brand-ops { font-family: var(--font-mono); font-weight: 500; color: var(--azure-bright); }

.site-nav { display: flex; gap: 26px; }
.site-nav a {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-dark);
  padding-block: 6px;
  transition: color 180ms var(--ease-out);
}
.site-nav a:hover { color: var(--white); }

.header-actions { display: flex; align-items: center; gap: 12px; }

.lang-toggle {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 500;
  background: transparent;
  color: var(--text-dark);
  border: 1px solid var(--border-dark);
  border-radius: 7px;
  padding: 12px 14px;
  min-height: 44px;
  cursor: pointer;
  transition: border-color 180ms var(--ease-out), color 180ms var(--ease-out);
}
.lang-toggle:hover { border-color: var(--azure-bright); }
.lang-sep { color: var(--muted-dark); margin-inline: 5px; }
.lang-opt { color: var(--muted-dark); }
.lang-opt.active { color: var(--azure-bright); }

/* hamburger — appears when .site-nav hides */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  width: 44px;
  height: 44px;
  padding: 0 10px;
  background: transparent;
  border: 1px solid var(--border-dark);
  border-radius: 7px;
  cursor: pointer;
  transition: border-color 180ms var(--ease-out);
}
.menu-toggle:hover { border-color: var(--azure-bright); }
.menu-bar {
  display: block;
  height: 2px;
  border-radius: 1px;
  background: var(--text-dark);
  transition: transform 220ms var(--ease-out), background-color 180ms var(--ease-out);
}
.menu-toggle[aria-expanded="true"] .menu-bar:first-child { transform: translateY(4.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-bar:last-child { transform: translateY(-4.5px) rotate(-45deg); }
.menu-toggle[aria-expanded="true"] .menu-bar { background: var(--azure-bright); }

.mobile-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--navy);
  border-bottom: 1px solid var(--border-dark);
  padding: 8px clamp(20px, 4vw, 32px) 24px;
  box-shadow: 0 24px 48px -24px rgba(2, 6, 23, 0.6);
}
.mobile-nav { display: flex; flex-direction: column; }
.mobile-nav a {
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--text-dark);
  padding: 14px 2px;
  border-bottom: 1px solid var(--border-dark);
}
.mobile-nav a:hover { color: var(--white); }
.mobile-menu .btn { margin-top: 18px; }

html.js .mobile-menu:not([hidden]) {
  animation: menu-drop 240ms var(--ease-out);
}
@keyframes menu-drop {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============ hero ============ */

.hero {
  position: relative;
  background: var(--navy);
  color: var(--text-dark);
  padding-block: clamp(64px, 9vw, 110px) clamp(28px, 4vw, 44px);
  overflow: hidden;
}

.hero-grid {
  position: relative;   /* the mark anchors to the content column, not the viewport */
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: clamp(32px, 6vw, 72px);
}
.hero-copy { position: relative; z-index: 1; max-width: 58ch; }

.hero-title {
  color: var(--white);
  font-size: var(--text-hero);
  margin-bottom: 22px;
  max-width: 24ch;
}
html[lang="ka"] .hero-title { font-size: clamp(30px, 4.6vw, 50px); max-width: 24ch; }

.hero-lead {
  font-size: var(--text-md);
  max-width: 52ch;
  margin-bottom: 34px;
}

.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; }

.hero .eyebrow { color: var(--azure-bright); }

/* the borjgali — signature mark, monumental: cropped off the hero's right edge */
.hero-visual {
  position: absolute;
  top: 50%;
  right: -200px;
  transform: translateY(-50%);
  width: min(36vw, 560px);
  pointer-events: none;
  opacity: 0;
  animation: bj-appear 900ms var(--ease-out) 250ms forwards;
}
.borjgali-hero { width: 100%; height: auto; }
.borjgali-hero .bj-orbit { display: none; }
@keyframes bj-appear { to { opacity: 0.9; } }

/* keep the status strip readable above the mark's arms */
.hero .container:last-child { position: relative; z-index: 1; }

.bj-orbit {
  fill: none;
  stroke: var(--border-dark);
  stroke-width: 1;
  stroke-dasharray: 3 5;
}
.bj-arms { animation: bj-spin 80s linear infinite; transform-origin: 0 0; }
.bj-arm path {
  fill: none;
  stroke: var(--azure-bright);
  stroke-width: 2;
  stroke-linecap: round;
}
.bj-node { fill: var(--white); }
.bj-core { fill: none; stroke: var(--azure-bright); stroke-width: 2; }
.bj-dot { fill: var(--white); }

@keyframes bj-spin { to { transform: rotate(360deg); } }

/* header/footer mark: static (motion lives in the hero only) */
.brand-mark .bj-arms { animation: none; }

/* status strip */
.status-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
  align-items: center;
  border-top: 1px solid var(--border-dark);
  margin-top: clamp(36px, 6vw, 64px);
  padding-top: 20px;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
}
.status-item { display: inline-flex; align-items: center; gap: 9px; color: var(--text-dark); }
.status-dim { color: var(--muted-dark); }
.status-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.5);
  animation: pulse 2.4s var(--ease-out) infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.45); }
  70% { box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

/* ============ trust markers ============ */

.trust { border-bottom: 1px solid var(--border); background: var(--white); }
.trust-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.trust-item {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 26px 20px;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink);
  border-left: 1px solid var(--border);
}
.trust-item:first-child { border-left: none; padding-left: 0; }
.trust-key {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--azure);
}

/* ============ services ============ */

.cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: border-color 220ms var(--ease-out), transform 220ms var(--ease-out),
              box-shadow 220ms var(--ease-out);
}

/* one mono-numeral language across trust strip, services and process */
.card-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--azure);
  border-top: 2px solid var(--azure);
  padding-top: 10px;
  width: 44px;
  margin-bottom: 18px;
}

.card h3 { font-size: var(--text-lg); font-weight: 600; margin-bottom: 10px; }
.card p { font-size: var(--text-sm); line-height: 1.7; }

/* ============ point of view ============ */

.pov-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}
.pov-copy p { max-width: 52ch; }
.pov-copy p + p { margin-top: 18px; }

.pov-compare {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
  gap: 14px;
}
.pov-panel {
  border-radius: var(--radius);
  padding: 22px 20px;
  font-family: var(--font-mono);
}
.pov-panel-title {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 14px;
}
html[lang="ka"] .pov-panel-title { letter-spacing: 0.05em; }
.pov-panel ul { list-style: none; }
.pov-panel li {
  font-size: var(--text-xs);
  padding-block: 8px;
  line-height: 1.5;
}
.pov-panel-old { background: var(--navy-2); }
.pov-panel-old .pov-panel-title { color: var(--muted-dark); }
.pov-panel-old li { color: var(--text-dark); border-bottom: 1px solid var(--border-dark); }
.pov-panel-old li:last-child { border-bottom: none; }

.pov-panel-new { background: var(--white); border: 1px solid #B9D7EA; }
.pov-panel-new .pov-panel-title { color: var(--azure); }
.pov-panel-new li { color: var(--ink); border-bottom: 1px solid var(--azure-tint); }
.pov-panel-new li:last-child { border-bottom: none; }

.pov-arrow { display: flex; align-items: center; }
.pov-arrow svg {
  width: 22px; height: 22px;
  fill: none;
  stroke: var(--azure);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ============ process ============ */

.steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(24px, 4vw, 48px);
}
.step { display: flex; flex-direction: column; gap: 14px; }
.step-num {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--azure);
  border-top: 2px solid var(--azure);
  padding-top: 12px;
  width: 100%;
}
.step h3 { font-size: var(--text-lg); font-weight: 600; margin-bottom: 8px; }
.step p { font-size: var(--text-sm); line-height: 1.7; }

/* ============ why us ============ */

.why-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.why-lead { max-width: 46ch; }

.why-list { list-style: none; }
.why-list li {
  display: flex;
  gap: 14px;
  padding-block: 18px;
  border-bottom: 1px solid var(--border-dark);
  font-size: 16px;
  color: var(--text-dark);
}
.why-list li:first-child { padding-top: 6px; }
.why-list li::before {
  content: "";
  flex: none;
  width: 7px; height: 7px;
  margin-top: 9px;
  background: var(--azure-bright);
  border-radius: 1px;
}

/* ============ founders ============ */

.team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.founder {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
}
.founder-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.founder-glyph {
  width: 26px; height: 26px;
  flex: none;
  fill: none;
  stroke: var(--navy);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.founder-glyph .icon-accent { stroke: var(--azure); }
.founder-role {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--azure);
}
html[lang="ka"] .founder-role { letter-spacing: 0.04em; }
.founder-name {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: 8px;
}
.founder-bio { font-size: 16px; line-height: 1.7; }

.team-note {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  font-size: var(--text-sm);
  color: var(--slate-3);
  max-width: 72ch;
}

/* ============ contact ============ */

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}

.contact-details { margin-top: 30px; }
.contact-details > div {
  display: flex;
  gap: 18px;
  padding-block: 13px;
  border-bottom: 1px solid var(--border);
  font-size: var(--text-sm);
}
.contact-details dt {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--slate-mist);
  min-width: 92px;
  padding-top: 2px;
}
.contact-details dd { color: var(--ink); font-weight: 500; }

.contact-form {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 36px);
}
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 7px;
}
.field input, .field textarea {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 12px 14px;
  min-height: 46px;
  transition: border-color 180ms var(--ease-out), box-shadow 180ms var(--ease-out);
}
.field textarea { resize: vertical; }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--azure);
  box-shadow: 0 0 0 3px rgba(3, 105, 161, 0.14);
}
.form-note {
  font-size: 13.5px;
  color: var(--slate-3);
  margin-top: 14px;
  text-align: center;
}

/* ============ footer ============ */

.site-footer {
  background: var(--ink);
  padding-block: 36px;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.brand-footer .brand-word { font-size: 16px; }
.brand-footer .brand-mark { width: 26px; height: 26px; }
.footer-meta {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--muted-dark);
}

/* ============ motion ============ */

/* page-load choreography (hero) */
.hero-load {
  opacity: 0;
  transform: translateY(16px);
  animation: rise 700ms var(--ease-out) forwards;
  animation-delay: var(--d, 0ms);
}
@keyframes rise {
  to { opacity: 1; transform: translateY(0); }
}

/* scroll reveals — only hidden when JS is present to add .in back */
html.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 640ms var(--ease-out), transform 640ms var(--ease-out);
  transition-delay: var(--d, 0ms);
}
html.js .reveal.in { opacity: 1; transform: translateY(0); }

/* pointer-only hover lift (touch devices skip it) */
@media (hover: hover) {
  .card:hover {
    border-color: #B9D7EA;
    transform: translateY(-3px);
    box-shadow: 0 12px 32px -16px rgba(2, 6, 23, 0.18);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-load { animation: none; opacity: 1; transform: none; }
  .hero-visual { animation: none; opacity: 0.9; }
  html.js .reveal { transition: none; opacity: 1; transform: none; }
  .bj-arms { animation: none; }
  .status-dot { animation: none; }
  html.js .mobile-menu:not([hidden]) { animation: none; }
  .card:hover { transform: none; }
  .btn:active { transform: none; }
}

/* ============ responsive ============ */

/* tablet: nav collapses to menu, grids hold a 2-up middle tier */
@media (min-width: 1025px) {
  .mobile-menu { display: none; }   /* never overlays desktop, even if left open */
}
@media (max-width: 1024px) {
  .site-nav { display: none; }
  .menu-toggle { display: flex; }
}

@media (max-width: 900px) {
  /* the monumental mark returns to a small in-flow emblem above the headline */
  .hero-visual {
    position: static;
    transform: none;
    width: 120px;
  }
  .hero-grid > .hero-visual { order: -1; }
  .trust-row { grid-template-columns: 1fr 1fr; }
  .trust-item { border-left: none; padding-left: 0; }
  .pov-grid { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
  .why-grid, .contact-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .cards-grid, .team-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .header-cta { display: none; }   /* the CTA lives in the menu panel */
  .hero-ctas .btn { width: 100%; }
  .pov-compare { grid-template-columns: 1fr; }
  .pov-arrow { justify-content: center; }
  .pov-arrow svg { transform: rotate(90deg); }
}

@media (max-width: 480px) {
  .trust-row { grid-template-columns: 1fr; }
  .trust-item { padding-block: 14px; }
}

/* ============================================================
   WINE CTA ACCENT — Georgian-wine warm accent, primary CTAs only.
   ROLLBACK: delete this entire block (or git revert the commit
   titled "Add wine CTA accent"). Everything above is untouched.
   White on #9E3B34 = 6.7:1, on #7E2E28 = 9.4:1 (AA pass).
   ============================================================ */
:root { --wine: #9E3B34; --wine-deep: #7E2E28; }
.btn-primary { background: var(--wine); }
.btn-primary:hover { background: var(--wine-deep); }
.btn-invert { background: var(--wine); color: var(--white); }
.btn-invert:hover { background: var(--wine-deep); color: var(--white); }
