/* ============================================================
   ADAT ANALYTICS — LAYOUT
   Reset · Nav · Footer · Section scaffolding
   ============================================================ */

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* Container */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-md);
}

/* Nav */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--c-bg-dark);
  display: flex;
  align-items: center;
}

nav::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad-h);
}

.nav-inner {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-md);
  display: flex;
  align-items: center;
  gap: var(--sp-lg);
}

.nav-logo {
  font-family: var(--f-mono);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--c-teal);
  letter-spacing: 0.06em;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--sp-md);
  margin-left: auto;
  list-style: none;
}

.nav-links a {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--c-text-muted);
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--c-text); }

.nav-cta {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--c-bg-dark);
  background: var(--c-teal);
  padding: 0.45rem 1.1rem;
  border-radius: var(--r-sm);
  transition: opacity 0.2s;
  flex-shrink: 0;
}

.nav-cta:hover { opacity: 0.85; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
  flex-direction: column;
  gap: 5px;
  padding: 0.25rem;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--c-text);
  transition: all 0.25s;
}

/* Sections */
section { padding: var(--sp-xl) 0; }
section.alt { background: var(--c-bg-dark); }

.section-label {
  font-family: var(--f-mono);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-teal);
  margin-bottom: var(--sp-sm);
}

.section-headline {
  font-family: var(--f-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 300;
  line-height: 1.15;
  color: var(--c-text);
  margin-bottom: var(--sp-sm);
}

.section-sub {
  font-size: 1rem;
  color: var(--c-text-muted);
  max-width: 560px;
  line-height: 1.75;
}

/* Footer */
footer {
  background: var(--c-bg-dark);
  padding: var(--sp-lg) 0;
  position: relative;
}

footer::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad-h);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-md);
  flex-wrap: wrap;
}

.footer-logo {
  font-family: var(--f-mono);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--c-teal);
  letter-spacing: 0.06em;
}

.footer-links {
  display: flex;
  gap: var(--sp-md);
  list-style: none;
  flex-wrap: wrap;
}

.footer-links a {
  font-family: var(--f-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--c-text-muted);
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--c-teal); }

.footer-copy {
  font-family: var(--f-mono);
  font-size: 0.65rem;
  color: var(--c-text-dim);
  letter-spacing: 0.04em;
  width: 100%;
  margin-top: var(--sp-sm);
}

/* Responsive */
@media (max-width: 768px) {
  .nav-links, .nav-cta { display: none; }
  .nav-toggle { display: flex; }

  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    background: var(--c-bg-dark);
    padding: var(--sp-md);
    gap: var(--sp-sm);
    border-bottom: 1px solid var(--c-border);
    z-index: 99;
  }

  section { padding: var(--sp-lg) 0; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
