/* ═══════════════════════════════════════════════════════════
   WebAgency — Universal Design System
   Animation, Layout, Navigation, Typography, Buttons, Media
   ═══════════════════════════════════════════════════════════ */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

ul, ol { list-style: none; }

/* ─── Typography Scale (clamp = fluid) ──────────────────── */
:root {
  --text-xs:   clamp(11px, 1vw,   13px);
  --text-sm:   clamp(13px, 1.2vw, 15px);
  --text-base: clamp(15px, 1.4vw, 17px);
  --text-lg:   clamp(18px, 2vw,   22px);
  --text-xl:   clamp(24px, 3vw,   32px);
  --text-2xl:  clamp(32px, 5vw,   56px);
  --text-3xl:  clamp(48px, 8vw,   96px);
  --text-hero: clamp(64px, 12vw,  140px);
}

/* ─── Layout: Container ─────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 768px)  { .container { padding: 0 48px; } }
@media (min-width: 1280px) { .container { padding: 0 64px; } }

/* ─── Layout: Section Spacing ────────────────────────────── */
.section {
  padding: 80px 0;
}
@media (min-width: 1024px) {
  .section { padding: 120px 0; }
}

.hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

/* ─── Layout: Grid Patterns ──────────────────────────────── */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 768px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.grid-editorial {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}
@media (min-width: 1024px) {
  .grid-editorial { grid-template-columns: 3fr 2fr; }
}

/* ─── Navigation (transparent → opaque) ──────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: transparent;
  transition: background 0.35s ease, box-shadow 0.35s ease;
}
.nav.scrolled {
  background: var(--bg);
  box-shadow: 0 1px 0 var(--border, rgba(0,0,0,0.08));
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 24px;
  max-width: 1280px;
  margin: 0 auto;
}
@media (min-width: 768px) {
  .nav-inner { padding: 0 48px; }
}
.nav-logo {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.nav-links {
  display: none;
  gap: 32px;
  align-items: center;
}
@media (min-width: 768px) {
  .nav-links { display: flex; }
}
.nav-link {
  font-size: var(--text-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  transition: opacity 0.2s ease;
}
.nav-link:hover { opacity: 0.65; }

/* Hamburger */
.nav-hamburger {
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  z-index: 210;
  background: none;
  border: none;
  padding: 8px;
}
@media (min-width: 768px) {
  .nav-hamburger { display: none; }
}
.nav-hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.nav-hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.nav-hamburger.active span:nth-child(2) {
  opacity: 0;
}
.nav-hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: var(--bg);
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}
.mobile-menu.open {
  transform: translateX(0);
}
.mobile-menu a {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 300;
}

/* ─── CTA Button System ──────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--accent, #1A1A18);
  color: var(--bg, #fff);
  border: none;
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
  font-family: var(--font-body);
}
.btn-primary:hover {
  opacity: 0.88;
  transform: translateY(-1px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 27px;
  background: transparent;
  border: 1.5px solid currentColor;
  color: currentColor;
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  font-family: var(--font-body);
}
.btn-secondary:hover {
  background: var(--text);
  color: var(--bg);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: gap 0.2s ease;
  cursor: pointer;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
  color: currentColor;
  font-family: var(--font-body);
}
.btn-ghost:hover {
  gap: 12px;
}

/* ─── Scroll Reveal Animation ────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
.reveal-parent .reveal:nth-child(1) { transition-delay: 0s; }
.reveal-parent .reveal:nth-child(2) { transition-delay: 0.1s; }
.reveal-parent .reveal:nth-child(3) { transition-delay: 0.1s; }
.reveal-parent .reveal:nth-child(4) { transition-delay: 0.15s; }
.reveal-parent .reveal:nth-child(5) { transition-delay: 0.2s; }

/* ─── Page Load Animation ────────────────────────────────── */
.hero-eyebrow { animation: fadeUp 0.5s ease 0.1s both; }
.hero-headline { animation: fadeUp 0.6s ease 0.25s both; }
.hero-sub      { animation: fadeUp 0.5s ease 0.45s both; }
.hero-cta      { animation: fadeUp 0.5s ease 0.65s both; }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── Hover Micro-interactions ───────────────────────────── */
.card {
  transition: transform 0.3s ease;
}
.card:hover {
  transform: translateY(-4px);
}

.img-wrap { overflow: hidden; }
.img-wrap img {
  transition: transform 0.6s ease;
}
.img-wrap:hover img {
  transform: scale(1.05);
}

/* ─── Image Aspect Ratios ────────────────────────────────── */
.img-aspect-hero    { aspect-ratio: 16/9; }
.img-aspect-card    { aspect-ratio: 4/3; }
.img-aspect-portrait { aspect-ratio: 3/4; }
.img-aspect-square  { aspect-ratio: 1/1; }

.img-aspect-hero img,
.img-aspect-card img,
.img-aspect-portrait img,
.img-aspect-square img {
  width: 100%; height: 100%;
  object-fit: cover;
}

/* ─── Utility ────────────────────────────────────────────── */
.text-center { text-align: center; }
.text-muted  { color: var(--muted); }
.text-upper  { text-transform: uppercase; letter-spacing: 0.12em; }
.mb-0  { margin-bottom: 0; }
.mb-1  { margin-bottom: 8px; }
.mb-2  { margin-bottom: 16px; }
.mb-3  { margin-bottom: 24px; }
.mb-4  { margin-bottom: 32px; }
.mb-5  { margin-bottom: 48px; }
.mb-6  { margin-bottom: 64px; }
.mt-auto { margin-top: auto; }

/* ─── Back-to-Agency Banner ──────────────────────────────── */
.demo-banner {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 300;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #fff;
  padding: 12px 28px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  transition: transform 0.2s ease;
}
.demo-banner:hover {
  transform: translateX(-50%) translateY(-2px);
}
.demo-banner a {
  color: #E8FF00;
  text-decoration: underline;
  text-underline-offset: 2px;
}
