/* ==========================================================================
   valonsorodriguez.com — V3 Apple Editorial & Deep Botanical Minimalist
   Philosophy: Fluid space, zero box clutter, organic dark gradients, 3D depth
   ========================================================================== */

:root {
  --bg-obsidian: #080A09;
  --bg-forest-deep: #0B110E;
  --bg-stone-dark: #101412;
  --bg-contrast-cut: #141A17;
  --text-primary: #F5F5F7;     /* Apple off-white */
  --text-secondary: #86868B;   /* Apple neutral gray */
  --text-muted: #515452;
  --accent-emerald: #34D399;   /* Overleaf / Botanical emerald */
  --accent-sage: #A7F3D0;
  --accent-gold: #E5C158;
  --hairline: rgba(255, 255, 255, 0.08);
}

* {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
  background-color: var(--bg-obsidian);
  color: var(--text-secondary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "SF Pro Display", sans-serif;
}

::selection {
  background: rgba(52, 211, 153, 0.22);
  color: #F5F5F7;
}

body {
  margin: 0;
  background-color: var(--bg-obsidian);
  color: var(--text-secondary);
  overflow-x: hidden;
}

/* --------------------------------------------------------------------------
   1. APPLE PRO TYPOGRAPHY
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, .apple-heading {
  color: var(--text-primary);
  letter-spacing: -0.035em;
  font-weight: 700;
}

.text-gradient-editorial {
  background: linear-gradient(180deg, #FFFFFF 0%, #E2E8F0 65%, #86868B 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-sage {
  background: linear-gradient(135deg, #D1FAE5 0%, #34D399 55%, #10B981 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.font-mono-code {
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
}

/* --------------------------------------------------------------------------
   2. ORGANIC SECTION BACKGROUNDS & EDITORIAL CUTS (NO GRIDS)
   -------------------------------------------------------------------------- */
.section-hero-atmosphere {
  position: relative;
  min-height: calc(100vh - 3.5rem);
  min-height: calc(100dvh - 3.5rem);
  background:
    radial-gradient(ellipse 90% 65% at 50% -5%, rgba(16, 185, 129, 0.15) 0%, rgba(12, 24, 18, 0.4) 45%, #080A09 85%);
  overflow-x: clip;
}

.section-wheel-atmosphere {
  background: transparent;
}

.section-modules-cut {
  background: linear-gradient(180deg, #080A09 0%, #0B110E 50%, #080A09 100%);
  border-top: none;
  border-bottom: 1px solid var(--hairline);
  position: relative;
}

.section-chuleta-cut {
  background: linear-gradient(180deg, #0D1310 0%, #121A16 50%, #0D1310 100%);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}

.section-template-keynote {
  background:
    radial-gradient(ellipse 75% 50% at 50% 25%, rgba(229, 193, 88, 0.07) 0%, rgba(16, 185, 129, 0.05) 40%, #070908 80%);
}

/* --------------------------------------------------------------------------
   3. MINIMALIST NAVIGATION & EXPANDABLE TOP DRAWERS
   -------------------------------------------------------------------------- */
.apple-nav {
  background: rgba(8, 10, 9, 0.78);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-dropdown-sheet {
  background: rgba(12, 16, 14, 0.96);
  backdrop-filter: saturate(180%) blur(24px);
  -webkit-backdrop-filter: saturate(180%) blur(24px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.social-icon-link {
  color: #86868B;
  transition: color 0.2s ease, transform 0.2s ease;
}

.social-icon-link:hover {
  color: #F5F5F7;
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   4. 3D FIFA / APPLE COVERFLOW WHEEL (Horizontal 3D Video Selector)
   -------------------------------------------------------------------------- */
.wheel-viewport {
  perspective: 1400px;
  position: relative;
  width: 100%;
  height: clamp(255px, 36vh, 520px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  user-select: none;
}

.wheel-stage {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wheel-card {
  position: absolute;
  /* Fluid responsive scaling: zooms out on laptops (height-aware) and zooms in on 27" screens */
  width: clamp(270px, min(38vw, 50vh), 660px);
  aspect-ratio: 16 / 9;
  border-radius: clamp(12px, 1.3vw, 24px);
  overflow: hidden;
  cursor: pointer;
  transition:
    transform 0.52s cubic-bezier(0.2, 0.85, 0.25, 1),
    filter 0.52s cubic-bezier(0.2, 0.85, 0.25, 1),
    opacity 0.52s cubic-bezier(0.2, 0.85, 0.25, 1),
    box-shadow 0.52s ease;
  will-change: transform, filter, opacity;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: #0D1210;
}

.wheel-card-active {
  box-shadow:
    0 30px 80px -15px rgba(0, 0, 0, 0.85),
    0 0 50px -10px rgba(52, 211, 153, 0.22);
  border-color: rgba(255, 255, 255, 0.28);
}

/* --------------------------------------------------------------------------
   5. SCULPTURAL 3D FLOATING PAGES (Chuleta & Plantilla)
   -------------------------------------------------------------------------- */
.floating-sheet-left {
  transform: perspective(1200px) rotateY(8deg) rotateX(2deg) rotateZ(-1.5deg);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 35px 70px -20px rgba(0, 0, 0, 0.85);
}

.floating-sheet-right {
  transform: perspective(1200px) rotateY(-8deg) rotateX(2deg) rotateZ(1.5deg);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 35px 70px -20px rgba(0, 0, 0, 0.85);
}

.floating-sheet-left:hover,
.floating-sheet-right:hover {
  transform: perspective(1200px) rotateY(0deg) rotateX(0deg) rotateZ(0deg) scale(1.02);
  z-index: 20;
}

/* --------------------------------------------------------------------------
   6. HORIZONTAL SCROLLABLE TIMELINE (Sobre Mí)
   -------------------------------------------------------------------------- */
.timeline-scroll-container {
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: rgba(52, 211, 153, 0.35) rgba(255, 255, 255, 0.04);
  padding-bottom: 1.5rem;
}

.timeline-scroll-container::-webkit-scrollbar {
  height: 6px;
}

.timeline-scroll-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 9999px;
}

.timeline-scroll-container::-webkit-scrollbar-thumb {
  background: rgba(52, 211, 153, 0.35);
  border-radius: 9999px;
}

.timeline-node {
  scroll-snap-align: start;
}

/* --------------------------------------------------------------------------
   7. APPLE-STYLE BUTTONS & BORDERLESS EXPANDABLES
   -------------------------------------------------------------------------- */
.btn-apple-white,
a.btn-apple-white.gumroad-button,
a.btn-apple-white[data-gumroad-single-product] {
  background: #F5F5F7 !important;
  color: #080A09 !important;
  font-weight: 600 !important;
  border-radius: 9999px !important;
  border: none !important;
  background-image: none !important;
  text-shadow: none !important;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease !important;
}

.btn-apple-white:hover,
a.btn-apple-white.gumroad-button:hover,
a.btn-apple-white[data-gumroad-single-product]:hover {
  background: #FFFFFF !important;
  transform: scale(1.02);
  box-shadow: 0 0 35px rgba(255, 255, 255, 0.2) !important;
}

.btn-apple-emerald,
a.btn-apple-emerald.gumroad-button,
a.btn-apple-emerald[data-gumroad-single-product] {
  background: #10B981 !important;
  color: #05110B !important;
  font-weight: 600 !important;
  border-radius: 9999px !important;
  border: none !important;
  background-image: none !important;
  text-shadow: none !important;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease !important;
}

.btn-apple-emerald:hover,
a.btn-apple-emerald.gumroad-button:hover,
a.btn-apple-emerald[data-gumroad-single-product]:hover {
  background: #34D399 !important;
  transform: scale(1.02);
  box-shadow: 0 0 35px rgba(52, 211, 153, 0.3) !important;
}

.btn-apple-ghost,
a.btn-apple-ghost.gumroad-button,
a.btn-apple-ghost[data-gumroad-single-product] {
  background: rgba(255, 255, 255, 0.06) !important;
  color: #F5F5F7 !important;
  font-weight: 500 !important;
  border-radius: 9999px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  background-image: none !important;
  text-shadow: none !important;
  transition: background-color 0.2s ease, border-color 0.2s ease !important;
}

.btn-apple-ghost:hover,
a.btn-apple-ghost.gumroad-button:hover,
a.btn-apple-ghost[data-gumroad-single-product]:hover {
  background: rgba(255, 255, 255, 0.11) !important;
  border-color: rgba(255, 255, 255, 0.24) !important;
}

/* ==========================================================================
   Zero Gumroad Visual Injection (Enforce Clean Editorial Aesthetics)
   ========================================================================== */
.gumroad-button-logo,
.gumroad-button::after,
.gumroad-button::before,
[class*="gumroad-button-logo"],
.gumroad-loading-indicator {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Syntax tokens for minimal code block */
.tex-cmd { color: #6EE7B7; }
.tex-arg { color: #E2E8F0; }
.tex-opt { color: #FCD34D; }
.tex-comment { color: #52525B; font-style: italic; }

/* Modal backdrop */
.modal-backdrop {
  background: rgba(6, 8, 7, 0.88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

/* Apple Cinematic Video Theater Modal */
.theater-modal-active {
  display: flex !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.theater-modal-active .theater-modal-box {
  transform: scale(1) !important;
}
