/* ==========================================================================
   Shark Ecom — base.css
   Спільне для всіх сторінок: токени, ресет, шапка, кнопки, типографіка, футер
   ========================================================================== */

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

:root {
  --bg: #07090f;
  --surface: #0e1018;
  --surface2: #141720;
  --accent: #1e8fff;
  --accent-dim: rgba(30,143,255,0.12);
  --accent-border: rgba(30,143,255,0.3);
  --text: #dde2f0;

  /* --muted піднято з #5a6480 до #868fa8:
     старе значення давало контраст 3.4:1 на --bg і не проходило WCAG AA */
  --muted: #868fa8;
  --muted-dim: #5a6480;   /* лише для декору, не для тексту */

  --border: rgba(255,255,255,0.07);
  --border-strong: rgba(255,255,255,0.14);

  --nav-h: 73px;
  --pad-x: 48px;
  --radius: 10px;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.no-scroll { overflow: hidden; }

img { max-width: 100%; }

::selection { background: var(--accent); color: #fff; }

/* Видимий фокус з клавіатури — раніше не було зовсім */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--accent);
  color: #fff;
  padding: 10px 18px;
  border-radius: 0 0 8px 0;
  font-size: 14px;
}
.skip-link:focus { left: 0; }

/* ==========================================================================
   NAV
   ========================================================================== */

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px var(--pad-x);
  background: rgba(7,9,15,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

@supports not ((backdrop-filter: blur(12px)) or (-webkit-backdrop-filter: blur(12px))) {
  .site-nav { background: rgba(7,9,15,0.97); }
}

.logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo img {
  height: 32px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
  margin-left: auto;
}

.nav-links a {
  font-size: 14px;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
  letter-spacing: 0.02em;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--text); }

.nav-cta {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 9px 20px;
  transition: border-color 0.2s, background 0.2s;
  white-space: nowrap;
}

.nav-cta:hover { border-color: var(--accent); background: var(--accent-dim); }

/* Бургер */
.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  margin-right: -8px;
  background: transparent;
  border: none;
  cursor: pointer;
  position: relative;
  color: var(--text);
}

.nav-toggle span {
  position: absolute;
  left: 11px;
  width: 20px;
  height: 1.5px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 21px; }
.nav-toggle span:nth-child(3) { top: 27px; }

.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Мобільна шторка */
.nav-drawer {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  z-index: 99;
  background: var(--bg);
  padding: 32px 24px 48px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transform: translateY(-8px);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
  overflow-y: auto;
}

.nav-drawer.open {
  opacity: 1;
  transform: none;
  pointer-events: auto;
  visibility: visible;
}

.nav-drawer a {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 26px;
  letter-spacing: -0.5px;
  color: var(--text);
  text-decoration: none;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.nav-drawer a:last-of-type { border-bottom: none; }

.nav-drawer .drawer-cta {
  margin-top: 24px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  background: var(--accent);
  border-radius: var(--radius);
  padding: 15px 24px;
  text-align: center;
  border-bottom: none;
}

/* ==========================================================================
   ТИПОГРАФІКА
   ========================================================================== */

h1 {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(36px, 5vw, 68px);
  line-height: 1.0;
  letter-spacing: -2px;
  color: #fff;
  max-width: 860px;
  margin-bottom: 28px;
}

h1 .accent { color: var(--accent); }
h1 .br-desktop { display: block; height: 0; }

h2 {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(30px, 4vw, 48px);
  color: #fff;
  letter-spacing: -1px;
  line-height: 1.1;
  margin-bottom: 16px;
}

h3 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(21px, 2.4vw, 27px);
  color: #fff;
  letter-spacing: -0.4px;
  line-height: 1.25;
}

section { padding: 100px var(--pad-x); }

.section-tag {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.section-intro {
  font-size: 17px;
  font-weight: 300;
  color: var(--muted);
  max-width: 480px;
  margin-bottom: 56px;
  line-height: 1.7;
}

.divider {
  height: 1px;
  background: var(--border);
  margin: 0 var(--pad-x);
}

/* ==========================================================================
   КНОПКИ
   ========================================================================== */

.btn-primary {
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  background: var(--accent);
  border: none;
  border-radius: var(--radius);
  padding: 14px 28px;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.2s, transform 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-primary:hover { opacity: 0.85; transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.btn-primary svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.btn-ghost {
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 28px;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-ghost:hover { color: var(--text); border-color: var(--border-strong); }

/* ==========================================================================
   FOOTER
   ========================================================================== */

footer {
  border-top: 1px solid var(--border);
  padding: 32px var(--pad-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.footer-logo img {
  height: 24px;
  width: auto;
  display: block;
  opacity: 0.85;
}

.footer-meta {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 13px;
  color: var(--muted);
  flex-wrap: wrap;
  justify-content: center;
}

.footer-email {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-email:hover { color: var(--text); }

.footer-tg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition: color 0.2s, transform 0.2s;
}

.footer-tg:hover { color: var(--accent); transform: translateY(-1px); }

.footer-tg svg { width: 16px; height: 16px; display: block; }

.footer-divider {
  width: 1px;
  height: 14px;
  background: var(--border);
}

/* ==========================================================================
   RESPONSIVE (спільне)
   ========================================================================== */

@media (max-width: 900px) {
  :root { --pad-x: 24px; --nav-h: 69px; }

  .site-nav { padding: 18px var(--pad-x); }
  .nav-links, .nav-cta { display: none; }
  .nav-toggle { display: block; margin-left: auto; }

  footer { flex-direction: column; gap: 16px; text-align: center; }
}

/* ==========================================================================
   MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
