:root {
  --bg-canvas: #1c1f24;
  --bg-surface: #293139;
  --bg-surface-translucent: rgba(41, 49, 57, 0.78);
  --bg-surface-hover: rgba(53, 63, 73, 0.88);
  --text-primary: #e5e7eb;
  --text-muted: #9ca3af;
  --accent-primary: #14b8a6;
  --accent-secondary: #0d9488;
  --border-subtle: rgba(20, 184, 166, 0.28);
  --border-glass: rgba(229, 231, 235, 0.12);
  --accent-dark-label: #0f172a;
}

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

html {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  line-height: 1.6;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--accent-primary);
  color: var(--accent-dark-label);
  padding: 0.5rem 1rem;
  font-weight: 800;
  text-decoration: none;
  z-index: 9999;
  border: 1px solid #000;
}
.skip-link:focus {
  top: 1rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: system-ui, "Segoe UI", -apple-system, sans-serif;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: #ffffff;
  line-height: 1.15;
  overflow-wrap: anywhere;
  hyphens: auto;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }

p {
  color: var(--text-primary);
  font-size: 1.025rem;
  line-height: 1.7;
}

a {
  color: var(--accent-primary);
  text-decoration: none;
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), color 0.2s ease;
}
a:hover {
  text-decoration: underline;
}
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 3px;
}

/* Header */
.site-header {
  position: static;
  width: 100%;
  background: #171a1e;
  border-bottom: 1px solid var(--border-glass);
  padding: 10px 1.5rem;
  z-index: 100;
}
.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1240px;
  margin: 0 auto;
}
.brand-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: #ffffff;
  text-decoration: none;
  text-transform: uppercase;
}
.brand-mark {
  display: inline-block;
  width: 14px;
  height: 14px;
  background-color: var(--accent-primary);
}
.brand-link:hover {
  text-decoration: none;
  opacity: 0.9;
}

/* Nav Desktop */
.nav-wrapper {
  max-width: 1240px;
  margin: 0.5rem auto 0 auto;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 0.5rem;
}
.desktop-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  list-style: none;
}
.desktop-nav a {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0.3rem 0.5rem;
  border-bottom: 2px solid transparent;
}
.desktop-nav a:hover,
.desktop-nav a.active {
  color: var(--accent-primary);
  border-bottom: 2px solid var(--accent-primary);
  text-decoration: none;
}

/* 3-dot Mobile Menu Button */
.menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
  font-size: 1.3rem;
  padding: 0.2rem 0.6rem;
  cursor: pointer;
  line-height: 1;
}

/* Mobile Nav Drawer */
.mobile-nav-panel {
  display: none;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  margin-top: 0.75rem;
  padding: 1rem;
}
.mobile-nav-panel.open {
  display: flex;
}
.mobile-nav-panel a {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-size: 0.9rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
}
.mobile-nav-panel a:last-child {
  border-bottom: none;
}

/* Layout Core */
main {
  flex: 1;
  width: 100%;
}
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Sequence Line Architecture */
.sequence-spine {
  position: relative;
  padding: 2.5rem 0 4rem 0;
}
.sequence-spine::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 2rem;
  width: 1px;
  background-color: var(--accent-primary);
  opacity: 0.45;
  pointer-events: none;
}
@media (min-width: 860px) {
  .sequence-spine::before {
    left: 4.5rem;
  }
}

.seq-section {
  position: relative;
  margin-bottom: 4rem;
  padding-left: 3rem;
}
@media (min-width: 860px) {
  .seq-section {
    padding-left: 6.5rem;
  }
}

.seq-node {
  position: absolute;
  left: 1.15rem;
  top: 0;
  transform: translateX(-50%);
  background: var(--accent-primary);
  color: var(--accent-dark-label);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.45rem;
  border: 1px solid #1c1f24;
  z-index: 2;
}
@media (min-width: 860px) {
  .seq-node {
    left: 4.5rem;
  }
}

/* Faint Grid Backgrounds */
.grid-bg-active {
  background-image: 
    linear-gradient(to right, rgba(20, 184, 166, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(20, 184, 166, 0.05) 1px, transparent 1px);
  background-size: 32px 32px;
}

/* Translucent Glass Panels */
.glass-panel {
  background: var(--bg-surface);
  background: var(--bg-surface-translucent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-glass);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  padding: clamp(1.5rem, 3.5vw, 2.5rem);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease, background-color 0.25s ease;
}
.glass-panel:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-subtle);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--accent-primary);
  background: transparent;
  color: var(--accent-primary);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  min-height: 44px;
}
.btn:hover {
  background: var(--accent-primary);
  color: var(--accent-dark-label);
  text-decoration: none;
  transform: translateY(-2px);
}
.btn-primary {
  background: var(--accent-primary);
  color: var(--accent-dark-label);
  border-color: var(--accent-primary);
}
.btn-primary:hover {
  background: #0d9488;
  border-color: #0d9488;
  color: #ffffff;
}

/* Hero Section */
.hero-block {
  padding: 3rem 0;
  border-bottom: 1px solid var(--border-glass);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 960px) {
  .hero-grid {
    grid-template-columns: 1.15fr 0.85fr;
  }
}
.hero-tagline {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-primary);
  margin-bottom: 0.75rem;
}
.hero-content p {
  margin: 1.25rem 0 2rem 0;
  max-width: 62ch;
  color: #cbd5e1;
}
.hero-visual {
  position: relative;
}
.hero-media-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #111417;
  border: 1px solid var(--border-glass);
  overflow: hidden;
}
.hero-media-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-fact-overlay {
  margin-top: -2.5rem;
  margin-left: 1rem;
  margin-right: 1rem;
  position: relative;
  z-index: 3;
}
.facts-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.facts-list li {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  font-size: 0.875rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 0.5rem;
}
.facts-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.fact-marker {
  background: var(--accent-primary);
  color: var(--accent-dark-label);
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.1rem 0.35rem;
}

/* 4-Grid Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.topic-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.card-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #13161a;
  overflow: hidden;
  border-bottom: 1px solid var(--border-glass);
}
.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.topic-card:hover .card-img-wrap img {
  transform: scale(1.03);
}
.card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.card-body h3 {
  margin-bottom: 0.75rem;
}
.card-body p {
  font-size: 0.95rem;
  color: var(--text-muted);
  flex: 1;
  margin-bottom: 1.25rem;
}

/* Beat count diagram */
.beat-diagram {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 0.5rem;
  margin: 1.5rem 0;
}
.beat-cell {
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid var(--border-subtle);
  padding: 0.75rem 0.25rem;
  text-align: center;
}
.beat-cell.accent-beat {
  background: rgba(20, 184, 166, 0.35);
  border-color: var(--accent-primary);
  font-weight: 800;
}
.beat-num {
  font-size: 1.2rem;
  font-weight: 800;
  display: block;
  color: #fff;
}
.beat-desc {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* Intensity Comparison Rows */
.intensity-table-wrap {
  overflow-x: auto;
  margin: 1.5rem 0;
  border: 1px solid var(--border-glass);
}
.intensity-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}
.intensity-table th, .intensity-table td {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-glass);
}
.intensity-table th {
  background: #171b20;
  color: var(--accent-primary);
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
}
.intensity-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* Standard Editorial Content */
.reading-column {
  max-width: 72ch;
  margin: 0 auto;
}
.reading-column h2 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}
.reading-column h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}
.reading-column p {
  margin-bottom: 1.25rem;
}
.reading-column ul, .reading-column ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}
.reading-column li {
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

/* FAQ Block */
.faq-item {
  border-bottom: 1px solid var(--border-glass);
  padding: 1.5rem 0;
}
.faq-item:first-child {
  padding-top: 0;
}
.faq-item:last-child {
  border-bottom: none;
}
.faq-q {
  color: #ffffff;
  font-weight: 800;
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}
.faq-a {
  color: #cbd5e1;
  font-size: 0.975rem;
  line-height: 1.65;
}

/* Interactive drafting box (Contact tool) */
.tool-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 2rem;
  margin: 2rem 0;
}
.form-field {
  margin-bottom: 1.25rem;
}
.form-field label {
  display: block;
  font-weight: 800;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
  color: var(--text-primary);
}
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  background: #191c21;
  border: 1px solid var(--border-glass);
  color: #ffffff;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 0.95rem;
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  border-color: var(--accent-primary);
}
.tool-preview {
  background: #13161a;
  border: 1px solid var(--border-glass);
  padding: 1.25rem;
  font-family: monospace;
  font-size: 0.85rem;
  color: #a5f3fc;
  min-height: 100px;
  white-space: pre-wrap;
  margin-bottom: 1.25rem;
  overflow-wrap: anywhere;
}
.tool-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Scroll Animation Helper */
.fade-up {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.45s ease-out, transform 0.45s ease-out;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Footer */
.site-footer {
  background: #14171a;
  border-top: 1px solid var(--border-glass);
  padding: 3.5rem 1.5rem 2.5rem 1.5rem;
  margin-top: 5rem;
  color: var(--text-muted);
  font-size: 0.875rem;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}
@media (min-width: 800px) {
  .footer-inner {
    grid-template-columns: 2fr 1fr 1fr;
  }
}
.footer-brand {
  font-weight: 800;
  font-size: 1.1rem;
  color: #ffffff;
  margin-bottom: 0.5rem;
  display: block;
}
.footer-col h4 {
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-primary);
  margin-bottom: 0.75rem;
}
.footer-links {
  list-style: none;
}
.footer-links li {
  margin-bottom: 0.4rem;
}
.footer-links a {
  color: var(--text-muted);
}
.footer-links a:hover {
  color: var(--accent-primary);
}
.footer-legal-bar {
  max-width: 1200px;
  margin: 2.5rem auto 0 auto;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
}

/* Responsiveness overrides */
@media (max-width: 768px) {
  .desktop-nav {
    display: none;
  }
  .menu-toggle {
    display: block;
  }
  .beat-diagram {
    grid-template-columns: repeat(4, 1fr);
  }
}

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