@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;800&family=JetBrains+Mono:wght@400;700&family=Space+Mono:wght@400;700&display=swap');

:root {
  --color-obsidian: #050505;
  --color-black: #000000;
  --color-white: #ffffff;
  --color-light-gray: #e0e0e0;
  --color-gray: #888888;
  --color-gold: #c29d59;
  /* Ratio Gold approximate */
  --color-gold-hover: #dfb96f;

  --font-headers: 'Inter', sans-serif;
  --font-serif: 'Georgia', serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-space: 'Space Mono', monospace;

  --transition-slow: 0.8s ease;
  --transition-fast: 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--color-obsidian);
  color: var(--color-light-gray);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-headers);
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Typography Helpers */
.monospace {
  font-family: var(--font-mono);
}

.gold-text {
  color: var(--color-gold);
}

.technical-subtext {
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.1em;
  color: var(--color-gray);
  text-transform: uppercase;
}

/* Base Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Global Nav */
nav {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
}

.nav-brand {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.1em;
  text-decoration: none;
}

.nav-cta {
  font-family: var(--font-mono);
  font-size: 15px;
  color: var(--color-gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.nav-cta:hover {
  color: var(--color-gold-hover);
}

/* Sections */
section {
  padding: 8rem 0;
  position: relative;
}

/* Section 1: The Terminal (Hero) */
#hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding-top: 6rem;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('assets/rome-bg.jpg');
  background-size: cover;
  background-position: center 20%;
  background-attachment: fixed;
  z-index: 0;
  filter: contrast(120%) grayscale(50%);
}

.hero-bg::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(5, 5, 5, 0.3) 0%, rgba(5, 5, 5, 0.8) 70%, rgba(5, 5, 5, 1) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.hero-content-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 4rem;
  width: 100%;
}

.hero-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 1.5rem;
}

.hero-text .hero-title {
  text-align: left;
}

.hero-text .store-badges {
  margin-top: 1rem;
}

.hero-mockup {
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1000px;
}

/* Device Mockup Styling */
.device-mockup {
  background-color: #000;
  border: 8px solid #1a1a1a;
  /* Matte dark grey/black frame */
  border-radius: 40px;
  overflow: hidden;
  box-shadow: 0 0 40px rgba(194, 157, 89, 0.15), inset 0 0 10px rgba(0, 0, 0, 1);
  /* Faint gold glow behind the dark rest */
  position: relative;
}

.device-mockup::before {
  /* Inner Bezel / Screen gap */
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #000;
  border-radius: 32px;
  pointer-events: none;
  z-index: 2;
}

.device-mockup img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 32px;
}

.device-mockup.angled {
  transform: rotateY(-15deg) rotateX(5deg);
  max-width: 320px;
  box-shadow: -20px 20px 50px rgba(0, 0, 0, 0.8), 0 0 60px rgba(194, 157, 89, 0.2);
}

.device-mockup.inline-mockup {
  max-width: 260px;
  margin: 0 auto 2rem auto;
  border-radius: 30px;
  border-width: 6px;
}

.device-mockup.inline-mockup::before {
  border-radius: 24px;
}

.device-mockup.inline-mockup img {
  border-radius: 24px;
}

.eyebrow {
  color: var(--color-gold);
  font-size: 1rem;
}

.hero-title {
  font-size: 4.5rem;
  font-weight: 800;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: 1.2rem;
  font-weight: 400;
  max-width: 600px;
}

.store-badges {
  display: flex;
  gap: 1.5rem;
  margin-top: 2rem;
}

.store-badge {
  height: 50px;
  background: var(--color-black);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.store-badge:hover {
  border-color: var(--color-gold);
  background: rgba(212, 175, 55, 0.05);
}

/* Section 2: The Friction */
#friction {
  background: var(--color-obsidian);
  text-align: center;
}

.friction-content {
  max-width: 800px;
  margin: 0 auto;
}

.friction-title {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  font-weight: 600;
}

.friction-body {
  font-size: 1.1rem;
  color: var(--color-gray);
  margin-bottom: 3rem;
  line-height: 1.8;
}

.btn-secondary {
  display: inline-block;
  padding: 1rem 2.5rem;
  border: 1px solid var(--color-gold);
  color: var(--color-gold);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: all var(--transition-fast);
  background: transparent;
}

.btn-secondary:hover {
  background: var(--color-gold);
  color: var(--color-black);
}

/* Section 3: The Arsenal */
#arsenal {
  background: var(--color-obsidian);
}

.arsenal-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem;
  margin-bottom: 3rem;
}

.foundation-banner {
  background: var(--color-black);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 3rem 4rem;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 3rem;
  transition: border-color var(--transition-fast);
}

.foundation-banner:hover {
  border-color: rgba(212, 175, 55, 0.3);
}

.banner-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.banner-text .feature-title {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.banner-text .feature-copy {
  color: var(--color-gray);
  font-size: 0.95rem;
  line-height: 1.8;
}

.feature-card {
  background: var(--color-black);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 3rem 2rem;
  border-radius: 4px;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
  position: relative;
  overflow: hidden;
  text-align: center;
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(212, 175, 55, 0.3);
}

.feature-icon-wrapper {
  height: 100px;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Audio Waveform specific styles */
.audio-waveform-container {
  width: 100%;
  height: 60px;
  position: relative;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.waveform-bar {
  width: 3px;
  background-color: var(--color-gold);
  height: 10%;
  border-radius: 2px;
  transition: height 0.1s ease;
}

.audio-waveform-container.playing .waveform-bar {
  animation: pulse-wave 1s infinite alternate;
}

@keyframes pulse-wave {
  0% {
    height: 10%;
  }

  100% {
    height: 100%;
  }
}

/* Generate different animation delays for bars */
.waveform-bar:nth-child(1) {
  animation-delay: 0.1s;
  height: 20%;
}

.waveform-bar:nth-child(2) {
  animation-delay: 0.3s;
  height: 40%;
}

.waveform-bar:nth-child(3) {
  animation-delay: 0.0s;
  height: 70%;
}

.waveform-bar:nth-child(4) {
  animation-delay: 0.4s;
  height: 30%;
}

.waveform-bar:nth-child(5) {
  animation-delay: 0.2s;
  height: 90%;
}

.waveform-bar:nth-child(6) {
  animation-delay: 0.5s;
  height: 50%;
}

.waveform-bar:nth-child(7) {
  animation-delay: 0.1s;
  height: 20%;
}

.feature-title {
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.feature-copy {
  color: var(--color-gray);
  font-size: 0.95rem;
}

/* Protocol Roster Marquee */
.marquee-container {
  width: 100%;
  overflow: hidden;
  background: var(--color-obsidian);
  padding: 1rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  white-space: nowrap;
}

.marquee-content {
  display: inline-block;
  padding-left: 100%;
  animation: marquee 45s linear infinite;
  font-size: 1.1rem;
  letter-spacing: 2px;
}

@keyframes marquee {
  0% {
    transform: translate(0, 0);
  }

  100% {
    transform: translate(-100%, 0);
  }
}

/* Stoic Authority Quote Block */
#quote-block {
  background: var(--color-black);
  padding: 8rem 0;
  text-align: center;
  position: relative;
}

.quote-content {
  max-width: 800px;
  margin: 0 auto;
}

#quote-block blockquote {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  color: var(--color-white);
  line-height: 1.4;
  margin-bottom: 2rem;
  font-style: italic;
}

.quote-author {
  font-family: var(--font-mono);
  color: var(--color-gold);
  letter-spacing: 0.2em;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Section 4: Pricing */
#pricing {
  background: var(--color-black);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.pricing-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('assets/hero_philosopher.jpg');
  background-size: cover;
  background-position: center 25%;
  background-attachment: fixed;
  opacity: 0.15;
  filter: grayscale(100%) contrast(150%);
  z-index: 0;
}

.spiral-ghost-bg {
  position: absolute;
  top: 10%;
  right: -10%;
  width: 800px;
  height: 800px;
  background-image: url('assets/TRP_Icon_Master_Gold_1024_Spiral Ghost.png');
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.05;
  z-index: 0;
  pointer-events: none;
}

.relative-z {
  position: relative;
  z-index: 1;
}

.pricing-header {
  margin-bottom: 4rem;
}

.pricing-title {
  font-size: 2.5rem;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 4rem;
}

.pricing-tier {
  background: var(--color-obsidian);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 3rem 2rem;
  border-radius: 4px;
  position: relative;
  text-align: left;
  display: flex;
  flex-direction: column;
}

.pricing-tier.featured {
  border-color: var(--color-gold);
  background: linear-gradient(to bottom, rgba(212, 175, 55, 0.05), var(--color-obsidian));
}

.urgency-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-gold);
  color: var(--color-black);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 2px;
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.tier-name {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--color-white);
}

.tier-price {
  font-family: var(--font-mono);
  font-size: 2rem;
  color: var(--color-gold);
  margin-bottom: 2rem;
}

.tier-price span {
  font-size: 0.9rem;
  color: var(--color-gray);
}

.tier-features {
  list-style: none;
  font-size: 0.95rem;
  color: var(--color-gray);
  flex-grow: 1;
}

.tier-features li {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
  position: relative;
}

.tier-features li::before {
  content: '>';
  position: absolute;
  left: 0;
  color: var(--color-gold);
  font-family: var(--font-mono);
}

.pricing-cta-container {
  display: flex;
  justify-content: center;
}

/* Section 5: Lead Magnet */
#lead-magnet {
  background: var(--color-obsidian);
  position: relative;
  overflow: hidden;
}

.lead-magnet-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('assets/fluted_column.jpg');
  background-size: cover;
  background-position: center;
  opacity: 0.15;
  filter: grayscale(100%);
  z-index: 0;
}

.lead-content {
  position: relative;
  z-index: 1;
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
  background: rgba(0, 0, 0, 0.7);
  padding: 4rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
}

.lead-title {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.lead-copy {
  color: var(--color-gray);
  margin-bottom: 2.5rem;
}

.capture-form {
  display: flex;
  margin-bottom: 1rem;
}

.capture-input {
  flex-grow: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 1rem 1.5rem;
  color: var(--color-white);
  font-family: var(--font-mono);
  outline: none;
  transition: border-color var(--transition-fast);
}

.capture-input:focus {
  border-color: var(--color-gold);
}

.capture-btn {
  background: var(--color-gold);
  color: var(--color-black);
  border: none;
  padding: 0 2rem;
  font-family: var(--font-mono);
  font-weight: 700;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: opacity var(--transition-fast);
}

.capture-btn:hover {
  opacity: 0.9;
}

.privacy-micro {
  font-size: 0.75rem;
  color: var(--color-gray);
}

/* Footer */
footer {
  background: var(--color-black);
  padding: 6rem 0 3rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.footer-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('assets/Stoa_Colonnade_Obsidian.jpg');
  background-size: cover;
  background-position: center bottom;
  background-attachment: fixed;
  opacity: 0.1;
  filter: grayscale(100%);
  z-index: 0;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.footer-logo {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 0.1em;
}

.footer-links {
  display: flex;
  gap: 2rem;
  list-style: none;
  margin-bottom: 1rem;
}

.social-links {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold);
  transition: opacity var(--transition-fast), filter var(--transition-fast);
  opacity: 0.8;
}

.social-links a svg {
  width: 20px;
  height: 20px;
}

.social-links a:hover {
  opacity: 1;
  filter: drop-shadow(0 0 5px rgba(212, 175, 55, 0.4));
}

.footer-links a {
  color: var(--color-gray);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}

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

.footer-copyright {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.3);
}

.beehiiv-embed-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2rem 0;
  width: 100%;
}

.beehiiv-embed-container iframe {
  font-family: var(--font-space) !important;
}

/* Scroll Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s ease, transform 1s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Golden Ratio Canvas Background */
#golden-ratio-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.15;
}

/* Responsive styling */
@media (max-width: 992px) {
  .hero-content-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }

  .hero-text {
    align-items: center;
    text-align: center;
  }

  .hero-text .hero-title {
    text-align: center;
  }

  .device-mockup.angled {
    transform: rotateY(-5deg) rotateX(2deg);
    max-width: 280px;
  }

  .hero-title {
    font-size: 3.5rem;
  }

  .arsenal-grid {
    grid-template-columns: 1fr;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
  }

  section {
    padding: 6rem 0;
  }

  #quote-block blockquote {
    font-size: 2rem;
  }

  .spiral-ghost-bg {
    width: 500px;
    height: 500px;
    right: -20%;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem;
  }

  .device-mockup.angled {
    transform: none;
    max-width: 260px;
    margin: 0 auto;
  }

  .hero-text {
    gap: 1rem;
  }

  .store-badges {
    flex-direction: column;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }

  .nav-cta {
    display: none;
  }

  .capture-form {
    flex-direction: column;
    gap: 1rem;
  }

  .capture-btn {
    padding: 1rem;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
  }

  #quote-block blockquote {
    font-size: 1.5rem;
  }

  .pricing-tier {
    padding: 2rem 1.5rem;
  }

  .foundation-banner {
    flex-direction: column;
    text-align: center;
    padding: 2rem;
    gap: 1.5rem;
  }
}

/* Page Headers for subpages */
.page-header {
  padding: 12rem 0 4rem;
  background: var(--color-black);
  text-align: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.page-content {
  padding: 4rem 0;
  background: var(--color-obsidian);
}

.document-body {
  max-width: 800px;
  margin: 0 auto;
  color: var(--color-light-gray);
  font-size: 18px;
  line-height: 1.6;
}

.document-body h2 {
  margin: 2rem 0 1rem;
  color: var(--color-gold);
}

.document-body p {
  margin-bottom: 1.5rem;
}