/* ═══════════════════════════════════════════
   Danitza Villarroel Orrego — Dark & Gold Theme
   ═══════════════════════════════════════════ */

:root {
  --gold: #c9a84c;
  --gold-light: #e8c97a;
  --gold-dim: rgba(201, 168, 76, 0.15);
  --cream: #f0e8d5;
  --dark: #0a0806;
  --dark-mid: #110e09;
  --dark-warm: #1c1710;
  --text-muted: rgba(240, 232, 213, 0.5);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--dark);
  color: var(--cream);
  font-family: 'Cormorant Garamond', serif;
  overflow-x: hidden;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.3s;
}

a:hover { color: var(--gold-light); }

/* ─── NOISE OVERLAY ─── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  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.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.6;
}

/* ─── HERO ─── */
#hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  overflow: hidden;
}

.hero-left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px 60px 80px 80px;
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 100;
  font-size: 0.7rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 32px;
  opacity: 0;
  animation: fadeUp 1s 0.3s forwards;
}

.hero-name {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3rem, 5vw, 5.5rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  opacity: 0;
  animation: fadeUp 1s 0.5s forwards;
}

.hero-name span {
  color: var(--gold);
  display: block;
}

.hero-subtitle {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1.1rem, 1.8vw, 1.5rem);
  font-weight: 300;
  color: var(--text-muted);
  margin-bottom: 48px;
  opacity: 0;
  animation: fadeUp 1s 0.7s forwards;
}

.hero-location {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 200;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0;
  animation: fadeUp 1s 0.9s forwards;
}

.hero-location::before {
  content: '';
  width: 30px;
  height: 1px;
  background: var(--gold);
}

.hero-right {
  position: relative;
  overflow: visible;
}

.hero-visual {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 80% at 60% 40%, rgba(201, 168, 76, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 80% 70%, rgba(201, 168, 76, 0.06) 0%, transparent 60%);
}

.staff-lines {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  opacity: 0.12;
}

.staff-lines svg { width: 100%; height: auto; }

.floating-notes {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.note {
  position: absolute;
  font-size: 2rem;
  color: var(--gold);
  opacity: 0;
  animation: floatNote var(--dur, 6s) var(--delay, 0s) ease-in-out infinite;
}

@keyframes floatNote {
  0% { opacity: 0; transform: translateY(20px) rotate(var(--rot, -10deg)); }
  20% { opacity: 0.25; }
  80% { opacity: 0.25; }
  100% { opacity: 0; transform: translateY(-80px) rotate(calc(var(--rot, -10deg) + 15deg)); }
}

.big-initial {
  position: absolute;
  bottom: -10%;
  right: -5%;
  font-family: 'Playfair Display', serif;
  font-size: 40vw;
  font-weight: 900;
  color: rgba(201, 168, 76, 0.04);
  line-height: 1;
  pointer-events: none;
  user-select: none;
  letter-spacing: -0.05em;
}

/* ─── HERO PHOTO ─── */
.hero-photo-frame {
  position: absolute;
  top: 30%;
  left: 10%;
  width: 340px;
  height: 430px;
  z-index: 3;
  opacity: 0;
  animation: fadeUpPhoto 1.2s 1s forwards;
}

.hero-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  filter: grayscale(15%) contrast(1.05);
  border: 1px solid rgba(201, 168, 76, 0.3);
}

.hero-photo-frame::before {
  content: '';
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(201, 168, 76, 0.15);
  pointer-events: none;
  z-index: 1;
}

/* Scroll indicator */
.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 80px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Josefin Sans', sans-serif;
  font-size: 0.65rem;
  font-weight: 200;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0;
  animation: fadeUp 1s 1.4s forwards;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

/* ─── DIVIDER ─── */
.divider {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 60px 80px 0;
}

.divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
}

.divider-glyph {
  color: var(--gold);
  font-size: 1.2rem;
}

/* ─── INTRO ─── */
#intro {
  padding: 80px 80px 100px;
}

.intro-quote {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1.6rem, 2.5vw, 2.4rem);
  font-weight: 400;
  line-height: 1.5;
  color: var(--cream);
  margin-bottom: 40px;
  position: relative;
  padding-left: 40px;
}

.intro-quote::before {
  content: '\201C';
  position: absolute;
  left: 0;
  top: -10px;
  font-size: 5rem;
  color: var(--gold);
  line-height: 1;
  font-family: 'Playfair Display', serif;
  opacity: 0.6;
}

.intro-text {
  font-size: 1.15rem;
  line-height: 1.9;
  color: rgba(240, 232, 213, 0.75);
  font-weight: 300;
  margin-bottom: 20px;
}

.intro-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.intro-photo img {
  width: 100%;
  height: auto;
  border: 1px solid rgba(201, 168, 76, 0.3);
  filter: grayscale(15%) contrast(1.05);
}

.intro-photo::before {
  content: '';
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(201, 168, 76, 0.15);
  pointer-events: none;
}

.intro-photo {
  position: relative;
}

/* ─── SECTION LABEL ─── */
.section-label {
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 100;
  font-size: 0.65rem;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 60px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.section-label::before {
  content: '';
  width: 40px;
  height: 1px;
  background: var(--gold);
}

/* ─── TIMELINE ─── */
#trayectoria {
  padding: 80px 80px 100px;
  background: var(--dark-mid);
  position: relative;
  overflow: hidden;
}

#trayectoria::before {
  content: 'TRAYECTORIA';
  position: absolute;
  right: -20px;
  top: 50%;
  transform: translateY(-50%) rotate(90deg);
  font-family: 'Josefin Sans', sans-serif;
  font-size: 6rem;
  font-weight: 100;
  letter-spacing: 0.5em;
  color: rgba(201, 168, 76, 0.04);
  white-space: nowrap;
  pointer-events: none;
}

.timeline {
  position: relative;
  max-width: 800px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold) 10%, var(--gold) 90%, transparent);
  opacity: 0.3;
}

.timeline-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 40px;
  padding: 0 0 56px 40px;
  position: relative;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -4px;
  top: 8px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 16px rgba(201, 168, 76, 0.6);
}

.timeline-year {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--gold);
  opacity: 0.7;
  line-height: 1;
  padding-top: 4px;
}

.timeline-content h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--cream);
}

.timeline-content p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: rgba(240, 232, 213, 0.6);
  font-weight: 300;
}

/* ─── LOGROS GRID ─── */
#logros {
  padding: 100px 80px;
}

.logros-heading {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 4vw, 4rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 70px;
  max-width: 600px;
}

.logros-heading em {
  color: var(--gold);
  font-style: italic;
}

.logros-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: rgba(201, 168, 76, 0.15);
}

.logro-card {
  background: var(--dark);
  padding: 48px 40px;
  position: relative;
  transition: background 0.4s;
  overflow: hidden;
}

.logro-card:hover {
  background: var(--dark-warm);
}

.logro-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(to right, var(--gold), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s;
}

.logro-card:hover::after {
  transform: scaleX(1);
}

.logro-icon {
  font-size: 2rem;
  margin-bottom: 24px;
  display: block;
}

.logro-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--cream);
  line-height: 1.3;
}

.logro-card p {
  font-size: 0.9rem;
  line-height: 1.8;
  color: rgba(240, 232, 213, 0.55);
  font-weight: 300;
}

.logro-year-tag {
  display: inline-block;
  font-family: 'Josefin Sans', sans-serif;
  font-size: 0.6rem;
  font-weight: 200;
  letter-spacing: 0.3em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 16px;
}

/* ─── ROLES / PERFIL PROFESIONAL ─── */
#roles {
  padding: 80px 80px 100px;
  background: var(--dark-mid);
}

.roles-header {
  margin-bottom: 60px;
}

.roles-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 3vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
}

.roles-header h2 span { color: var(--gold); }

.roles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}

.role-category {
  padding: 40px 32px;
  border: 1px solid rgba(201, 168, 76, 0.12);
  position: relative;
  transition: border-color 0.4s;
}

.role-category:hover {
  border-color: rgba(201, 168, 76, 0.35);
}

.role-category::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(to right, var(--gold), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s;
}

.role-category:hover::after {
  transform: scaleX(1);
}

.role-category-icon {
  font-size: 2rem;
  margin-bottom: 24px;
}

.role-category h3 {
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 300;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 28px;
}

.role-category ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.role-category li {
  font-size: 0.95rem;
  line-height: 1.7;
  color: rgba(240, 232, 213, 0.7);
  font-weight: 300;
  padding-left: 20px;
  position: relative;
}

.role-category li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 6px;
  height: 1px;
  background: var(--gold);
}

@keyframes spinSlow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ─── ALIMAPU ─── */
#alimapu {
  padding: 100px 80px;
  position: relative;
  overflow: hidden;
}

.alimapu-inner {
  max-width: 820px;
  position: relative;
  z-index: 2;
}

.alimapu-inner h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.5rem, 4vw, 4.5rem);
  font-weight: 900;
  color: var(--gold);
  margin-bottom: 8px;
  line-height: 1;
}

.alimapu-inner h3 {
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 100;
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 40px;
}

.alimapu-inner p {
  font-size: 1.15rem;
  line-height: 1.9;
  color: rgba(240, 232, 213, 0.7);
  font-weight: 300;
  margin-bottom: 24px;
}

.stats-row {
  display: flex;
  gap: 60px;
  margin-top: 60px;
  padding-top: 60px;
  border-top: 1px solid rgba(201, 168, 76, 0.2);
}

.stat h4 {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 8px;
}

.stat p {
  font-family: 'Josefin Sans', sans-serif;
  font-size: 0.65rem;
  font-weight: 200;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}

/* ─── CONTACTO ─── */
#contacto {
  padding: 80px 80px 100px;
  background: var(--dark-mid);
}

.contacto-intro {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 50px;
}

.contacto-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: rgba(201, 168, 76, 0.15);
  max-width: 700px;
}

.contacto-card {
  background: var(--dark);
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  transition: background 0.4s;
  color: var(--cream);
}

.contacto-card:hover {
  background: var(--dark-warm);
  color: var(--cream);
}

.contacto-icon {
  color: var(--gold);
  margin-bottom: 4px;
}

.contacto-label {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 700;
}

.contacto-handle {
  font-family: 'Josefin Sans', sans-serif;
  font-size: 0.6rem;
  font-weight: 200;
  letter-spacing: 0.2em;
  color: var(--text-muted);
}

/* ─── FOOTER ─── */
footer {
  padding: 60px 80px;
  background: var(--dark-warm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(201, 168, 76, 0.15);
}

.footer-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 700;
}

.footer-name span { color: var(--gold); }

.footer-tagline {
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 100;
  font-size: 0.65rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 6px;
}

.footer-right {
  text-align: right;
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.8;
}

/* ─── COPYRIGHT ─── */
.copyright {
  text-align: center;
  padding: 20px 40px;
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 200;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  color: rgba(240, 232, 213, 0.35);
  background: var(--dark);
}

.copyright a {
  color: var(--gold);
  text-decoration: none;
  transition: opacity 0.3s;
}

.copyright a:hover {
  opacity: 0.7;
}

/* ─── ANIMATIONS ─── */
@keyframes fadeUpPhoto {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s, transform 0.8s;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── RESPONSIVE ─── */
@media (max-width: 900px) {
  #hero { grid-template-columns: 1fr; }
  .hero-right { display: none; }
  .hero-left { padding: 80px 40px; }
  .intro-columns { grid-template-columns: 1fr; }
  .intro-photo { max-width: 400px; margin: 0 auto; }

  #intro,
  #trayectoria,
  #logros,
  #alimapu,
  #contacto,
  footer { padding-left: 40px; padding-right: 40px; }

  .logros-grid { grid-template-columns: 1fr; }
  .contacto-grid { grid-template-columns: 1fr; }

  #roles { padding: 60px 40px; }
  .roles-grid { grid-template-columns: 1fr; }
  .stats-row { flex-wrap: wrap; gap: 40px; }
  .scroll-hint { left: 40px; }
  .divider { padding-left: 40px; padding-right: 40px; }

  footer {
    flex-direction: column;
    text-align: center;
    gap: 24px;
  }

  .footer-right { text-align: center; }
}

@media (max-width: 600px) {
  .timeline-item {
    grid-template-columns: 80px 1fr;
    gap: 20px;
    padding-left: 24px;
  }

  .timeline-year { font-size: 1.3rem; }

  .hero-name { font-size: clamp(2.5rem, 10vw, 4rem); }

  .stats-row { gap: 30px; }
  .stat h4 { font-size: 2.2rem; }
}
