/* ═══════════════════════════════════════════════
   Sewinfla Technical Site — Design System v3
   Dark-first, zero-JS, world-class engineering aesthetic
   ═══════════════════════════════════════════════ */

/* ── Google Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@500;600;700&family=Oswald:wght@400;500;600;700&display=swap');

/* ═══════════════════════════════════════════════
   1. CUSTOM PROPERTIES
   ═══════════════════════════════════════════════ */
:root {
  /* ── Colors ── */
  --bg-deep: #0a0e16;
  --bg-card: #111827;
  --bg-hover: #1a2333;
  --bg-inset: #070a10;
  
  --text-primary: #f0f0f5;
  --text-secondary: #a0a5b8;
  --text-tertiary: #606578;
  
  --accent: #2563eb;
  --accent-glow: #60a5fa;
  --accent-dark: #1d4ed8;
  
  --brand-gradient: linear-gradient(135deg, #1e3a6e, #2563eb, #60a5fa);
  --brand-gradient-subtle: linear-gradient(135deg, rgba(37,99,235,0.12), rgba(37,99,235,0.06));
  
  --success: #34d399;
  --warning: #fbbf24;
  --error: #f87171;
  
  --border-subtle: rgba(37,99,235,0.06);
  --border-default: rgba(37,99,235,0.10);
  --border-emphasis: rgba(37,99,235,0.18);
  
  /* ── Typography ── */
  --font-heading: 'Oswald', 'Helvetica Neue', 'Arial Narrow', sans-serif;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
  
  /* ── Spacing (4px baseline) ── */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;
  --space-24: 96px;
  
  /* ── Layout ── */
  --max-width: 1200px;
  --nav-height: 72px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  
  /* ── Transitions ── */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --duration-fast: 150ms;
  --duration-normal: 300ms;
  --duration-slow: 500ms;
}

/* ═══════════════════════════════════════════════
   2. RESET & BASE
   ═══════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0.01em;
  color: var(--text-secondary);
  background: var(--bg-deep);
  min-height: 100vh;
}

/* ── Typography Scale ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  text-wrap: balance;
  line-height: 1.2;
  text-transform: uppercase;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.15;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.25;
}

h3 {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 600;
  letter-spacing: 0.03em;
  line-height: 1.3;
}

p {
  max-width: 65ch;
  margin-bottom: 1.2em;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--accent);
  text-decoration: none;
  position: relative;
  transition: color var(--duration-fast) var(--ease-out);
}

a:hover {
  color: var(--accent-dark);
}

/* ── Link underline animation ── */
.text-link {
  background-image: var(--brand-gradient);
  background-size: 0% 1px;
  background-position: 0% 100%;
  background-repeat: no-repeat;
  transition: background-size var(--duration-normal) var(--ease-out);
}

.text-link:hover {
  background-size: 100% 1px;
}

/* ── Mono / Spec text ── */
.spec, .mono, code, .data-point {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.3;
  letter-spacing: 0;
  font-weight: 500;
}

.caption {
  font-family: var(--font-body);
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.04em;
  font-weight: 500;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.small {
  font-size: 13px;
  line-height: 1.6;
  letter-spacing: 0.005em;
}

/* ═══════════════════════════════════════════════
   3. LAYOUT
   ═══════════════════════════════════════════════ */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.section {
  padding: var(--space-24) 0;
}

.section-sm {
  padding: var(--space-16) 0;
}

/* ═══ Section Background Variants ═══ */
.section--dark {
  background: var(--bg-deep);
}

/* Cards in light sections — switch to white bg */
.section--white .card,
.section--tinted .card {
  background: #ffffff;
  border-color: #e5e7eb;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.section--white .card:hover,
.section--tinted .card:hover {
  box-shadow: 0 8px 30px rgba(37,99,235,0.08), 0 0 1px rgba(37,99,235,0.2);
}

.section--white .card--inset,
.section--tinted .card--inset {
  background: #f9fafb;
  border-color: #e5e7eb;
}

.section--white .spec-item,
.section--tinted .spec-item {
  background: #f9fafb;
  border-color: #e5e7eb;
}

/* Product & Article cards in light sections */
.section--white .product-card,
.section--tinted .product-card,
.section--white .article-card,
.section--tinted .article-card {
  background: #ffffff;
  border-color: #e5e7eb;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.section--white .product-card__tag,
.section--tinted .product-card__tag {
  background: #f3f4f6;
  color: #4b5563;
}

/* Case cards in light sections */
.section--white .case-card,
.section--tinted .case-card {
  background: #ffffff;
  border-color: #e5e7eb;
}

.section--white .tip-box,
.section--tinted .tip-box,
.section--white .summary-box,
.section--tinted .summary-box {
  background: #f9fafb;
  border-color: #e5e7eb;
}

.section--white .comp-table__header,
.section--tinted .comp-table__header {
  background: #f3f4f6;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-3);
}

.section-title {
  margin-bottom: var(--space-4);
}

.section-subtitle {
  font-size: 17px;
  color: var(--text-secondary);
  margin-bottom: var(--space-12);
  max-width: 48ch;
}

/* ── Bento Grid ── */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
}

.bento-card--1x1 { grid-column: span 1; }
.bento-card--2x1 { grid-column: span 2; }
.bento-card--2x2 { grid-column: span 2; grid-row: span 2; }
.bento-card--4x1 { grid-column: span 4; }

@media (max-width: 768px) {
  .bento-grid {
    grid-template-columns: 1fr;
  }
  .bento-card--1x1,
  .bento-card--2x1,
  .bento-card--2x2,
  .bento-card--4x1 {
    grid-column: span 1;
    grid-row: auto;
  }
  .section { padding: var(--space-16) 0; }
}

/* ── Card ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  transition: transform var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out),
              border-color var(--duration-normal) var(--ease-out);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(37,99,235,0.15), 0 0 1px rgba(37,99,235,0.25);
  border-color: transparent;
  border-image: var(--brand-gradient) 1;
}

.card--inset {
  background: var(--bg-inset);
}

.card--flat {
  background: transparent;
  border: 1px solid var(--border-subtle);
}

/* ═══════════════════════════════════════════════
   4. NAVIGATION (Glass)
   ═══════════════════════════════════════════════ */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  background: rgba(17,24,39,0.95);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border-subtle);
}

.nav-inner {
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo img {
  height: 54px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  gap: var(--space-8);
  list-style: none;
}

.nav-links a {
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color var(--duration-fast) var(--ease-out);
  padding: var(--space-2) 0;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-glow);
}

/* Mobile nav */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
}

/* ═══════════════════════════════════════════════
   5. BUTTONS
   ═══════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-out),
              opacity var(--duration-fast) var(--ease-out);
  text-decoration: none;
}

.btn:hover {
  transform: scale(1.02);
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: #475569;
  color: #fff;
}

.btn--primary:hover {
  background: #64748b;
  color: #fff;
  box-shadow: 0 0 20px rgba(71,85,105,0.3);
}

.btn--outline {
  background: #475569;
  border-color: transparent;
  color: #fff;
}

.btn--outline:hover {
  background: #64748b;
  border-color: transparent;
  color: #fff;
  box-shadow: 0 0 20px rgba(71,85,105,0.25);
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-default);
  color: var(--text-secondary);
}

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

.btn--large {
  padding: var(--space-4) var(--space-8);
  font-size: 16px;
}

.btn-group {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════
   6. SPEC TABLE
   ═══════════════════════════════════════════════ */
.spec-table {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--space-4);
}

.spec-item {
  padding: var(--space-4);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
}

.spec-item__label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-1);
}

.spec-item__value {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

/* ── Number Banner ── */
.number-banner {
  display: flex;
  justify-content: center;
  gap: var(--space-16);
  flex-wrap: wrap;
  padding: var(--space-12) 0;
}

.number-banner__item {
  text-align: center;
}

.number-banner__value {
  font-family: var(--font-mono);
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.number-banner__label {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--text-tertiary);
  margin-top: var(--space-1);
}

/* ═══════════════════════════════════════════════
   7. HERO
   ═══════════════════════════════════════════════ */
.hero {
  padding: var(--space-24) 0;
  text-align: center;
}

.hero .hero-title {
  margin-bottom: var(--space-4);
}

.hero .hero-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 52ch;
  margin: 0 auto var(--space-8);
  line-height: 1.6;
}

/* ═══════════════════════════════════════════════
   8. PRODUCT CARD
   ═══════════════════════════════════════════════ */
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform var(--duration-normal) var(--ease-out),
              border-color var(--duration-normal) var(--ease-out);
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: transparent;
  border-image: var(--brand-gradient) 1;
}

.product-card__image {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--bg-deep);
}

.product-card__body {
  padding: var(--space-4);
}

.product-card__name {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.product-card__specs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}

.product-card__tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-tertiary);
  background: var(--bg-hover);
  padding: 2px 8px;
  border-radius: 4px;
}

.product-card__price {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-3);
}

.product-card__actions {
  display: flex;
  gap: var(--space-2);
}

/* ── Product Grid ── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-4);
}

/* ═══════════════════════════════════════════════
   9. ARTICLE CARD
   ═══════════════════════════════════════════════ */
.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform var(--duration-normal) var(--ease-out);
}

.article-card:hover {
  transform: translateY(-4px);
}

.article-card__image {
  width: 100%;
  aspect-ratio: 16/10;
  object-fit: cover;
}

.article-card__body {
  padding: var(--space-4);
}

.article-card__meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}

.article-card__category {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent-glow);
}

.article-card__time {
  font-size: 13px;
  color: var(--text-tertiary);
}

.article-card__title {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: var(--space-1);
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

@media (max-width: 768px) {
  .article-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════
   10. ARTICLE PAGE
   ═══════════════════════════════════════════════ */
.article-page {
  max-width: 720px;
  margin: 0 auto;
  padding: var(--space-16) var(--space-6);
}

.article-header {
  margin-bottom: var(--space-12);
}

.article-header__meta {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
}

.article-header__category {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent);
}

.article-header__time {
  font-size: 13px;
  color: var(--text-tertiary);
}

.article-body h2 {
  margin-top: var(--space-12);
  margin-bottom: var(--space-4);
}

.article-body h3 {
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.article-body p {
  margin-bottom: 1.2em;
}

.tip-box {
  background: var(--bg-card);
  border-left: 3px solid var(--accent);
  padding: var(--space-4) var(--space-6);
  margin: var(--space-6) 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.tip-box__label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent-glow);
  margin-bottom: var(--space-2);
}

.summary-box {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  margin: var(--space-8) 0;
}

.summary-box h4 {
  font-size: 14px;
  margin-bottom: var(--space-3);
  color: var(--text-primary);
}

.summary-box ul {
  list-style: none;
}

.summary-box li {
  position: relative;
  padding-left: var(--space-4);
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: var(--space-2);
}

.summary-box li::before {
  content: '•';
  color: var(--accent);
  position: absolute;
  left: 0;
  font-weight: 700;
}

.product-cta {
  background: var(--bg-card);
  border: 1px solid var(--border-emphasis);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  margin: var(--space-8) 0;
  display: flex;
  align-items: center;
  gap: var(--space-6);
}

.product-cta__image {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════
   11. CASE CARD
   ═══════════════════════════════════════════════ */
.case-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
}

@media (max-width: 768px) {
  .case-grid { grid-template-columns: 1fr; }
}

.case-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4/3;
}

.case-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.case-card__label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-4);
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

/* ═══════════════════════════════════════════════
   12. LOGO WALL
   ═══════════════════════════════════════════════ */
.logo-wall {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--space-12);
  padding: var(--space-8) 0;
  opacity: 0.5;
}

.logo-wall img {
  height: 32px;
  width: auto;
  filter: brightness(0) invert(1);
}

/* ═══════════════════════════════════════════════
   13. TABLE
   ═══════════════════════════════════════════════ */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-align: left;
  padding: var(--space-2) var(--space-4);
  border-bottom: 1px solid var(--border-default);
}

.data-table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.data-table tr:hover td {
  background: var(--bg-hover);
}

/* ═══════════════════════════════════════════════
   14. FORM
   ═══════════════════════════════════════════════ */
.form-group {
  margin-bottom: var(--space-4);
}

.form-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: var(--space-2);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  background: var(--bg-inset);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 14px;
  transition: border-color var(--duration-fast) var(--ease-out);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent);
}

.form-textarea {
  min-height: 120px;
  resize: vertical;
}

/* ═══════════════════════════════════════════════
   15. FILTER TABS
   ═══════════════════════════════════════════════ */
.filter-tabs {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-8);
}

.filter-tab {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-tertiary);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  cursor: pointer;
  background: transparent;
  transition: all var(--duration-fast) var(--ease-out);
}

.filter-tab:hover,
.filter-tab.active {
  color: var(--text-primary);
  border-color: var(--accent);
  background: rgba(37,99,235,0.1);
}

/* ═══════════════════════════════════════════════
   16. COMPARISON TABLE
   ═══════════════════════════════════════════════ */
.comp-table {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.comp-table__header {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  padding: var(--space-4);
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-default);
  text-align: center;
}

.comp-table__header--highlight {
  background: var(--brand-gradient-subtle);
  border: 1px solid var(--accent);
}

.comp-table__row {
  display: contents;
}

.comp-table__cell {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
}

.comp-table__cell:first-child {
  text-align: left;
  font-weight: 500;
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .comp-table {
    grid-template-columns: 1fr;
  }
  .comp-table__header,
  .comp-table__cell {
    text-align: left;
  }
}

/* ═══════════════════════════════════════════════
   17. CSS-ONLY ANIMATIONS
   ═══════════════════════════════════════════════ */

/* Scroll-driven fade-in */
@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  animation: fade-in-up 0.6s var(--ease-out) both;
  animation-timeline: view();
  animation-range: entry 0% entry 100%;
}

/* Stagger children */
.stagger > * {
  animation: fade-in-up 0.6s var(--ease-out) both;
  animation-timeline: view();
  animation-range: entry 0% entry 100%;
}

.stagger > *:nth-child(1) { animation-delay: 0ms; }
.stagger > *:nth-child(2) { animation-delay: 100ms; }
.stagger > *:nth-child(3) { animation-delay: 200ms; }
.stagger > *:nth-child(4) { animation-delay: 300ms; }
.stagger > *:nth-child(5) { animation-delay: 400ms; }
.stagger > *:nth-child(6) { animation-delay: 500ms; }

/* ── Card hover glow ── */
.card-glow {
  position: relative;
  overflow: hidden;
}

.card-glow::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid transparent;
  transition: border-color var(--duration-normal) var(--ease-out);
  pointer-events: none;
}

.card-glow:hover::after {
  border-color: transparent;
  border-image: var(--brand-gradient) 1;
}

/* ═══════════════════════════════════════════════
   18. FOOTER
   ═══════════════════════════════════════════════ */
.footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  padding: var(--space-16) 0 var(--space-8);
  margin-top: var(--space-24);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-12);
  margin-bottom: var(--space-12);
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-4);
}

.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--text-tertiary);
  margin-bottom: var(--space-2);
  transition: color var(--duration-fast) var(--ease-out);
}

.footer-col a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-6);
  border-top: 1px solid var(--border-subtle);
  font-size: 13px;
  color: var(--text-tertiary);
}

.footer-social {
  display: flex;
  gap: var(--space-4);
}

@media (max-width: 768px) {
  .footer-bottom {
    flex-direction: column;
    gap: var(--space-3);
    text-align: center;
  }
}

/* ═══════════════════════════════════════════════
   19. UTILITY
   ═══════════════════════════════════════════════ */
.text-center { text-align: center; }
.text-accent { color: var(--accent); }
.text-brand {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.brand-line {
  height: 1px;
  border: none;
  background: var(--brand-gradient);
  margin: var(--space-8) 0;
}
.brand-border {
  border: 1px solid;
  border-image: var(--brand-gradient) 1;
}
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-mono { font-family: var(--font-mono); }
.mt-4 { margin-top: var(--space-4); }
.mt-8 { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-8 { margin-bottom: var(--space-8); }
