/* =============================================================
   ATOL DESIGN SYSTEM — canonical tokens (colors_and_type.css)
   + page styles for atsi.cz (Atol Signals)
   ============================================================= */

@font-face {
  font-family: 'Satoshi Variable';
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
  src: url('../fonts/Satoshi-Variable.ttf') format('truetype-variations'),
       url('../fonts/Satoshi-Variable.ttf') format('truetype');
}

:root {
  /* ---- ATOL BLUE (primary accent · step 600) ---- */
  --atol-50:  #edeefc;
  --atol-100: #d9dcf7;
  --atol-200: #bac0ef;
  --atol-300: #8e97e5;
  --atol-400: #616ed8;
  --atol-500: #3a4bd1;
  --atol-600: #1a2ed1;
  --atol-700: #1627ad;
  --atol-800: #111d84;
  --atol-900: #0c1560;
  --atol-950: #080e3f;

  /* ---- LIME / SECONDARY accent (step 300) ---- */
  --lime-300: #e0ff70;

  /* ---- SEMANTIC ---- */
  --accent:         var(--atol-600);
  --accent-hover:   var(--atol-700);
  --accent-active:  var(--atol-800);
  --accent-light:   var(--atol-50);
  --accent-text:    #FFFFFF;
  --secondary:      var(--lime-300);
  --secondary-text: #0A0A0A;

  /* ---- THEME NEUTRALS (Light) ---- */
  --bg:           #FFFFFF;
  --surface:      #F5F5F5;
  --brutal-gray:  #E5E5E5;
  --border:       #1A1A1A;
  --hairline:     #EEEEEE;
  --shadow:       #000000;

  /* ---- TEXT ---- */
  --text-primary:   #0A0A0A;
  --text-secondary: #666666;

  /* ---- TYPOGRAPHY ---- */
  --font-heading: 'Satoshi Variable', Satoshi, system-ui, -apple-system, sans-serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', SFMono-Regular, Menlo, Consolas, monospace;

  --fs-display: 120px;
  --fs-h1:       72px;
  --fs-h2:       56px;
  --fs-h3:       42px;
  --fs-h4:       28px;
  --fs-body-lg:  20px;
  --fs-body:     18px;
  --fs-body-sm:  15px;
  --fs-caption:  14px;
  --fs-micro:    11px;

  --tr-display: -0.03em;
  --tr-h1:      -0.02em;
  --tr-h2:      -0.02em;
  --tr-h3:      -0.01em;
  --tr-h4:      -0.01em;
  --tr-body:    -0.005em;
  --tr-caption:  0.01em;
  --tr-label:    0.08em;

  --lh-display: 0.85;
  --lh-h1:      0.90;
  --lh-h2:      0.90;
  --lh-h3:      0.95;
  --lh-h4:      1.20;
  --lh-body:    1.50;
  --lh-body-lg: 1.60;

  /* ---- SPACING (8px baseline) ---- */
  --space-1:   4px;
  --space-2:   8px;
  --space-3:  16px;
  --space-4:  24px;
  --space-5:  32px;
  --space-6:  48px;
  --space-7:  64px;
  --space-8:  96px;
  --space-9: 120px;
  --space-10:160px;

  /* ---- STRUCTURE ---- */
  --radius-pill: 9999px;
  --max-width:   1440px;
  --gutter:      24px;

  /* ---- MOTION ---- */
  --dur-fast: 150ms;
  --dur-norm: 250ms;
  --ease-std: cubic-bezier(0.25, 0.1, 0.25, 1);
}

/* ---- Base ---- */
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; }

html, body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  letter-spacing: var(--tr-body);
  color: var(--text-primary);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, .h1 {
  font-family: var(--font-heading); font-size: var(--fs-h1);
  font-weight: 500; line-height: var(--lh-h1); letter-spacing: var(--tr-h1);
  margin: 0;
}
h2, .h2 {
  font-family: var(--font-heading); font-size: var(--fs-h2);
  font-weight: 500; line-height: var(--lh-h2); letter-spacing: var(--tr-h2);
  margin: 0;
}
h3, .h3 {
  font-family: var(--font-heading); font-size: var(--fs-h3);
  font-weight: 400; line-height: var(--lh-h3); letter-spacing: var(--tr-h3);
  margin: 0;
}
h4, .subhead {
  font-family: var(--font-heading); font-size: var(--fs-h4);
  font-weight: 400; line-height: var(--lh-h4); letter-spacing: var(--tr-h4);
  margin: 0;
}
p { margin: 0; }
.label {
  font-family: var(--font-body); font-size: var(--fs-micro);
  font-weight: 500; line-height: 1.4; letter-spacing: var(--tr-label);
  text-transform: uppercase; color: var(--text-secondary);
}
.mono {
  font-family: var(--font-mono); font-size: 13px; letter-spacing: 0;
}

/* =============================================================
   PAGE — atsi.cz
   ============================================================= */

.wrap {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---- Nav (kit: AtolNav) ---- */
.nav {
  border-bottom: 1px solid var(--hairline);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 200;
}
.nav-inner {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}
.wordmark {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--accent);
  text-decoration: none;
  white-space: nowrap;
}
.nav-menu {
  display: flex;
  gap: 36px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-menu a {
  font-family: var(--font-body);
  font-size: var(--fs-caption);
  font-weight: 500;
  letter-spacing: var(--tr-body);
  color: var(--text-primary);
  text-decoration: none;
  white-space: nowrap;
}
.nav-menu a:hover,
.nav-menu a.is-active { color: var(--accent); }

/* ---- Buttons (pill, Inter 14/500) ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: var(--fs-caption);
  font-weight: 500;
  letter-spacing: var(--tr-body);
  text-decoration: none;
  transition: background-color var(--dur-fast) var(--ease-std),
              color var(--dur-fast) var(--ease-std);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-text);
}
.btn-primary:hover  { background: var(--accent-hover); }
.btn-primary:active { background: var(--accent-active); }
.btn-secondary {
  background: transparent;
  border: 1px solid #D9D9D9;
  color: var(--text-primary);
}
.btn-secondary:hover {
  background: var(--text-primary);
  border-color: var(--text-primary);
  color: #ffffff;
}
.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Hero (kit: Hero) ---- */
.hero {
  padding-block: var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}
.hero-top {
  display: grid;
  grid-template-columns: 1fr 448px;
  gap: var(--gutter);
  align-items: end;
  width: 100%;
}
.hero-side {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}
.hero-sub {
  font-size: var(--fs-body);
  line-height: var(--lh-body-lg);
  letter-spacing: var(--tr-body);
  color: var(--text-secondary);
  margin: 0;
}
.hero-cta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

/* ---- Hero pattern block (kit: readout above, hairline frame) ---- */
.hero-pattern-block { width: 100%; }
.pattern-readout {
  font-family: var(--font-mono);
  font-size: var(--fs-micro);
  letter-spacing: 0.02em;
  color: var(--accent);
  margin-bottom: 2px;
}
.pattern-frame {
  border: 1px solid var(--hairline);
  background: var(--bg);
  height: 520px;
}
.pattern-frame canvas {
  width: 100%;
  height: 100%;
}

/* ---- Feature grid ---- */
.features {
  padding-block: var(--space-8);
}
.features-head {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--gutter);
  margin-bottom: var(--space-7);
}
.features-head .label { grid-column: 1 / 4; }
.features-head h2 { grid-column: 4 / 12; }
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
}
.feature-cell {
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.feature-cell + .feature-cell { border-left: 1px solid var(--border); }
.feature-num {
  font-family: var(--font-heading);
  font-size: var(--fs-h2);
  font-weight: 700;
  letter-spacing: var(--tr-h2);
  color: #D0D0D0;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.feature-title {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: var(--tr-h4);
}
.feature-body {
  font-size: var(--fs-body-sm);
  line-height: var(--lh-body-lg);
  color: var(--text-secondary);
}

/* ---- Status strip ---- */
.status {
  border-top: 1px solid var(--hairline);
  padding-block: var(--space-6);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}
.status .mono { color: var(--text-secondary); }

/* ---- Footer (full accent) ---- */
.footer {
  background: var(--accent);
  color: var(--accent-text);
}
.footer-inner {
  padding-block: var(--space-8) var(--space-6);
}
.footer .label { color: #ffffffb3; }
.footer-contact {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-4);
  margin-top: var(--space-4);
}
.footer-email {
  font-family: var(--font-heading);
  font-size: 40px;
  font-weight: 500;
  letter-spacing: var(--tr-h2);
  line-height: 1.1;
  color: var(--accent-text);
  text-decoration: none;
  word-break: break-all;
}
.footer-email:hover { color: #ffffffb3; }
.to-top {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-pill);
  border: 1px solid #ffffff;
  background: transparent;
  color: #ffffff;
  font-size: 16px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  transition: background-color var(--dur-fast) var(--ease-std),
              color var(--dur-fast) var(--ease-std);
}
.to-top:hover { background: #ffffff; color: var(--accent); }
.footer-meta {
  margin-top: var(--space-7);
  padding-top: var(--space-4);
  border-top: 1px solid #ffffff33;
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
  font-size: var(--fs-caption);
  letter-spacing: var(--tr-caption);
  color: #ffffffb3;
}

/* ---- Responsive ---- */
@media (max-width: 760px) {
  .nav-menu { display: none; }
}

@media (max-width: 960px) {
  h1, .h1 { font-size: var(--fs-h3); }
  h2, .h2 { font-size: var(--fs-h4); }
  .hero { padding-block: var(--space-7) var(--space-6); gap: var(--space-5); }
  .hero-top { grid-template-columns: 1fr; align-items: start; }
  .pattern-frame { height: 242px; }
  .features-head { display: block; }
  .features-head .label { margin-bottom: var(--space-3); }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-cell + .feature-cell {
    border-left: none;
    border-top: 1px solid var(--border);
  }
  .footer-email { font-size: 26px; }
  .pattern-band canvas { height: 200px; }
}

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
