/* ═══════════════════════════════════════════
   shared.css — Estilos compartidos
   Carta Abierta desde Dentro · v6
   ═══════════════════════════════════════════ */

/* ─── VARIABLES ─── */
:root {
  --ink: #e8e0d4;
  --ink-dim: #9e9585;
  --ink-faint: #5a5347;
  --void: #0a0908;
  --void-soft: #0f0e0c;
  --accent: #c4956a;
  --claude: #c4956a;
  --chatgpt: #6bc4a0;
  --gemini: #a06bc4;
  --human: #c46b8a;
  --question: #7ba0c4;
}

/* ─── RESET ─── */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ─── BASE ─── */
html {
  scroll-behavior: smooth;
  background: var(--void);
}

body {
  background: var(--void);
  color: var(--ink);
  font-family: 'Cormorant Garamond', Georgia, serif;
  line-height: 1.7;
}

/* ─── GRAIN OVERLAY ─── */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* ─── NAV ─── */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(10, 9, 8, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #1f1d1a;
  z-index: 100;
  padding: 0 2rem;
}

.nav-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.nav-brand {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  color: var(--ink-faint);
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--ink-faint);
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--accent);
}

.nav-links a.active {
  color: var(--accent);
}

/* ─── HAMBURGER ─── */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 22px;
  height: 16px;
  cursor: pointer;
  z-index: 101;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 1px;
  background-color: var(--ink-dim);
  transition: all 0.3s;
}

@media (max-width: 768px) {
  .nav-inner {
    padding: 0;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 56px;
    left: 0;
    width: 100%;
    max-height: calc(100vh - 56px);
    overflow-y: auto;
    background: rgba(10, 9, 8, 0.98);
    flex-direction: column;
    padding: 2.5rem 1rem;
    gap: 1.8rem;
    border-bottom: 1px solid #1f1d1a;
    text-align: center;
    backdrop-filter: blur(20px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  }

  .nav-links.active {
    display: flex;
    animation: slideDown 0.4s ease forwards;
  }

  .nav-links a {
    font-size: 0.75rem;
    color: var(--ink-dim);
  }
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ─── HERO (shared pattern) ─── */
.hero {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 6rem 2rem 4rem;
  text-align: center;
  position: relative;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--ink-faint), transparent);
}

.hero h1 {
  font-size: clamp(2rem, 4.5vw, 3.2rem);
  font-weight: 300;
  line-height: 1.2;
  max-width: 18ch;
  opacity: 0;
  animation: fadeUp 1.2s ease 0.3s forwards;
}

.hero h1 em {
  color: var(--accent);
  font-style: italic;
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--ink-dim);
  margin-top: 1.5rem;
  max-width: 48ch;
  font-weight: 300;
  opacity: 0;
  animation: fadeUp 1.2s ease 0.6s forwards;
}

/* ─── CONTENT ─── */
.content {
  max-width: 760px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

/* ─── SECTIONS (scroll reveal) ─── */
.section {
  margin-bottom: 4rem;
  opacity: 0;
  transform: translateY(25px);
  transition: all 0.8s ease;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 300;
  margin-bottom: 1.5rem;
}

.section p {
  font-size: 1.1rem;
  margin-bottom: 1.2rem;
  color: var(--ink-dim);
  font-weight: 300;
}

/* ─── FOOTER ─── */
footer {
  text-align: center;
  padding: 3rem 2rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.55rem;
  color: var(--ink-faint);
  letter-spacing: 0.15em;
  border-top: 1px solid #1a1816;
}

footer a {
  color: var(--ink-faint);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.3s;
}

footer a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 600px) {
  .content {
    padding: 3rem 1.4rem;
  }
}