/* ═══════════════════════════════════════════════════════
   index.css  —  Home page (index.html / aboutme.html)
   ═══════════════════════════════════════════════════════ */

/* ── PALETTE ── */
:root {
  --pink:         #F1C2C2;
  --orange:       #E8541A;
  --orange-light: #FF6B2B;
  --dark:         #1a1a1a;
  --taupe:        #8B7355;
  --white:        #ffffff;

  /* Cursor */
  --cursor-color:       var(--pink);
  --cursor-trail-color: var(--pink);

  /* Page transition */
  --page-transition-bg: #1a1a1a;

  /* Nav */
  --nav-bg: linear-gradient(to bottom, rgba(232,84,26,0.95) 0%, rgba(232,84,26,0.6) 50%, transparent 100%);
  --nav-bg-scrolled: rgba(26,26,26,0.96);
  --nav-cta-scrolled-color: var(--orange);
  --nav-cta-scrolled-hover-bg: var(--orange);
  --nav-cta-scrolled-hover-color: var(--white);
  --nav-mobile-bg: rgba(26,26,26,0.97);

  /* Footer */
  --footer-bg:     var(--dark);
  --footer-accent: var(--orange);

  /* Arrive animation */
  --arrive-y:       40px;
  --arrive-scale:   0.96;
  --arrive-rotate:  -1deg;
}

body { background: var(--white); color: var(--white); }

/* ── HOME NAV OVERRIDE ──
   index.html places <ul class="nav-links"> outside <nav>
   so it needs fixed positioning at desktop. ── */
.nav-links {
  position: fixed;
  top: 1.5rem;
  right: 3rem;
  z-index: 9001;
  background: none;
}

/* Mobile: override back to fullscreen overlay */
@media (max-width: 768px) {
  .nav-links {
    top: 0; left: 0; right: 0; bottom: 0;
    width: 100%; height: 100%;
    background: rgba(26,26,26,0.97);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2.5rem;
    z-index: 8999;
  }
}

/* ── HERO ── */
#hero {
  position: sticky;
  top: 0;
  z-index: 0;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
  display: flex;
  align-items: center;
  background: #1a1a1a;
}
.hero-video-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  will-change: transform;
}
.hero-row { display: block; will-change: transform, opacity; }
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(139,115,85,0.82) 0%, rgba(180,80,20,0.70) 40%, rgba(100,40,10,0.55) 100%);
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 3;
  padding: 0 5vw;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}
.hero-title {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(4rem, 11vw, 9rem);
  color: var(--white);
  line-height: 0.9;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
}
.hero-bio {
  font-family: 'Cousine', monospace;
  font-size: 0.85rem;
  line-height: 1.8;
  color: rgba(255,255,255,0.9);
  max-width: 580px;
  margin-bottom: 2.5rem;
}
.btn-primary {
  display: inline-block;
  background: var(--orange);
  color: var(--white);
  font-family: 'Cousine', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 1.2rem 3.5rem;
  border-radius: 999px;
  text-decoration: none;
  border: none;
  cursor: none;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 4px 15px rgba(232,84,26,0.3);
}
.btn-primary:hover {
  background: var(--orange-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(232,84,26,0.4);
}
.hero-mascot {
  position: absolute;
  right: -2%;
  bottom: 0;
  z-index: 4;
  width: clamp(120px, 15vw, 220px);
  pointer-events: none;
}
.hero-mascot img {
  width: 100%;
  height: auto;
  display: block;
}

/* ── TICKER ── */
.ticker-strip {
  background: var(--orange);
  overflow: hidden;
  padding: 0.8rem 0;
  position: relative;
  z-index: 6;
  margin-top: -60px;
}
.ticker-track {
  display: flex;
  white-space: nowrap;
  animation: ticker 26s linear infinite;
  width: max-content;
}
.ticker-item {
  font-family: 'Cousine', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--white);
  padding: 0 2.5rem;
}
.ticker-sep { color: rgba(255,255,255,0.55); margin: 0 0.25rem; }
@keyframes ticker {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── CONTENT WRAPPER ── */
.content-wrapper {
  background: var(--white);
  position: relative;
  z-index: 5;
  margin-top: -160px;
  padding-top: 9rem;
  clip-path: polygon(0 55px, 25% 30px, 50% 52px, 75% 28px, 100% 45px, 100% 100%, 0 100%);
  filter: drop-shadow(0 -14px 28px rgba(0,0,0,0.45));
}

/* ── PROJECTS ── */
#projects {
  background: var(--white);
  color: var(--dark);
  padding: 0 5vw;
  position: relative;
  z-index: 6;
}
.projects-header-flex {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  margin-bottom: 4rem;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  gap: 1rem;
}
.vertical-title.reveal        { transform: rotate(180deg) translateY(28px); }
.vertical-title.reveal.visible { transform: rotate(180deg); }

.vertical-title {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  color: #eab498;
  letter-spacing: 0.05em;
  margin-top: 10px;
  font-style: italic;
  position: relative;
  z-index: 5;
  margin-bottom: -10rem;
}
.horizontal-title-area {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}
.projects-title {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(4rem, 8vw, 7.5rem);
  color: var(--orange);
  line-height: 0.85;
  letter-spacing: -0.02em;
  margin: 0 0 1.5rem;
  font-weight: 400;
}
.projects-subtitle {
  font-family: 'Cousine', monospace;
  font-size: 0.75rem;
  color: var(--taupe);
  line-height: 1.8;
  text-transform: lowercase;
}
.projects-bubble-section {
  position: relative;
  background: none;
  margin: 0 -5vw;
  padding: 12rem 6vw 16rem;
  clip-path: polygon(0 5%, 100% 0, 100% 100%, 0 100%);
  overflow: hidden;
}
.projects-bubble-section::before {
  content: '';
  position: absolute;
  inset: -30px;
  background: url('../assets/productbackg.jpg') no-repeat center center / cover;
  filter: blur(5px) brightness(0.78);
  z-index: 0;
}
.project-cards {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
}
.project-card {
  background: rgba(255,255,255,0.15);
  border-radius: 1.5rem;
  overflow: hidden;
  transition: transform 0.35s ease;
  display: flex;
  flex-direction: column;
  will-change: transform;
}
.project-card:hover { transform: translateY(-12px); }
.project-card-body {
  padding: 2.8rem 2.2rem 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
}
.project-card-name {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(2.4rem, 3.2vw, 3.5rem);
  color: var(--white);
  letter-spacing: -0.02em;
  line-height: 1.05;
  font-weight: 400;
  font-style: italic;
}
.project-card-desc {
  font-family: 'Cousine', monospace;
  font-size: 0.72rem;
  color: var(--white);
  line-height: 1.65;
  max-width: 26ch;
  opacity: 0.8;
}
.project-card-img {
  width: 100%;
  height: 400px;
  object-fit: contain;
  display: block;
  padding: 0 0.75rem 2rem;
}
.project-card-imgs { display: flex; gap: 0; width: 100%; overflow: hidden; }
.project-card-imgs .project-card-img { width: 50%; flex: 1; padding: 0 0.4rem; }
.btn-case {
  display: inline-block;
  background: var(--orange);
  color: var(--white);
  font-family: 'Cousine', monospace;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1rem 2.4rem;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}
.btn-case:hover { background: var(--orange-light); transform: translateY(-2px); }

/* ── DARK WRAPPER ── */
.dark-wrapper {
  background-color: var(--dark);
  color: var(--white);
  padding-top: 10rem;
  position: relative;
  z-index: 6;
  margin-top: -120px;
  clip-path: polygon(0% 75px, 7% 95px, 37% 30px, 100% 120px, 100% 100%, 0% 100%);
}

/* ── ABOUT ── */
#about { padding: 4rem 5vw 7rem; }
.about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  max-width: 1100px;
  margin: 0 auto;
}
.about-left { padding-right: 2rem; }
.about-eyebrow {
  font-family: 'Cousine', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 1rem;
}
.about-title {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(3rem, 6vw, 5rem);
  color: var(--orange);
  line-height: 1;
  margin-bottom: 2rem;
  letter-spacing: -0.02em;
}
.about-body {
  font-family: 'Cousine', monospace;
  font-size: 0.88rem;
  line-height: 1.9;
  color: rgba(255,255,255,0.75);
  max-width: 100%;
  margin-bottom: 2.5rem;
}
.about-right { display: flex; justify-content: center; }
.about-portrait-placeholder {
  width: 360px;
  height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cousine', monospace;
  font-size: 0.7rem;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.1em;
  overflow: visible;
}

.about-portrait-placeholder img {
  width: 100%;
  height: auto;
  display: block;
  opacity: 0;
  transform: translateY(-60px);
}

/* 1) drops in, 2) floats — two animations run in sequence */
#char-pink.char-active {
  animation:
    char-enter 0.85s cubic-bezier(0.34, 1.4, 0.64, 1) forwards,
    char-float 3.2s ease-in-out 0.85s infinite;
}

@keyframes char-enter {
  from { opacity: 0; transform: translateY(-60px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes char-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(18px); }
}

/* ── SKILLS ── */
#skills {
  padding: 0;
  padding-bottom: 30px;
  display: grid;
  grid-template-columns: 50% 50%;
  background: var(--dark);
}
.skills-scroll-viewport {
  height: 45vh;
  overflow-y: scroll;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
}
.skills-scroll-viewport::-webkit-scrollbar { display: none; }

.skills-sticky-left {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 2rem 3rem 2rem 21vw;
  position: relative;
}
.skills-sticky-left::after {
  content: '';
  position: absolute;
  right: 0;
  top: 20%;
  bottom: 20%;
  width: 1px;
  background: rgba(255,255,255,0.07);
}
.skills-sticky-left h2 {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(2.5rem, 5vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--orange);
  white-space: nowrap;
  text-align: center;
}

.skill-item {
  height: 45vh;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  display: flex;
  align-items: flex-start;
  padding: 0 8%;
}
.skill-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  will-change: opacity, transform;
  margin-top: calc(22.5vh - clamp(2.5rem, 5vw, 5.5rem) / 2);
}
.skill-name {
  display: block;
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(2.5rem, 5vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--white);
}
.skill-sub {
  font-family: 'Cousine', monospace;
  font-size: clamp(0.7rem, 1vw, 0.82rem);
  color: rgba(255,255,255,0.5);
  line-height: 1.75;
  max-width: 42ch;
  will-change: opacity, transform;
}
.skill-intro .skill-content { flex-direction: column; gap: 1.2rem; }
.skill-intro-chevron {
  display: block;
  width: 14px;
  height: 14px;
  border-right: 1.5px solid rgba(255,255,255,0.3);
  border-bottom: 1.5px solid rgba(255,255,255,0.3);
  transform: rotate(45deg);
  margin: 0 auto;
  animation: skillChevronBounce 1.5s ease-in-out infinite;
}
@keyframes skillChevronBounce {
  0%, 100% { transform: rotate(45deg) translate(0,0);     opacity: 0.3; }
  50%       { transform: rotate(45deg) translate(3px,3px); opacity: 0.65; }
}

/* ── CONTACT TEASER ── */
#contact {
  background: linear-gradient(to bottom, var(--dark) 80px, var(--orange) 80px);
  padding: 12rem 5vw 8rem;
  position: relative;
  overflow: hidden;
  text-align: center;
}
#contact::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 80px;
  background: var(--dark);
  clip-path: ellipse(75% 100% at 50% 0%);
}
.contact-title {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-size: clamp(3rem, 8vw, 6.5rem);
  color: var(--white);
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}
.contact-sub {
  font-family: 'Cousine', monospace;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 3rem;
  letter-spacing: 0.05em;
  line-height: 1.8;
}
.btn-dark {
  display: inline-block;
  background: var(--dark);
  color: var(--white);
  font-family: 'Cousine', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 1.2rem 3.5rem;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}
.btn-dark:hover { background: #2d2d2d; transform: translateY(-2px); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .hero-mascot {
    width: clamp(120px, 15vw, 220px);
    right: 0;
    bottom: 7%;
  }
  .project-cards { grid-template-columns: 1fr; }
  .about-inner { grid-template-columns: 1fr; }
  .about-left { padding-left: 0; }
  .about-right { order: -1; }
  .about-portrait-placeholder { width: 160px; height: 160px; }
  .projects-header-flex { flex-direction: column; align-items: center; text-align: center; }
  .vertical-title { writing-mode: horizontal-tb; transform: none; margin: 0 0 1rem; }
  .vertical-title.reveal { transform: translateY(28px); }
  .vertical-title.reveal.visible { transform: none; }
  .horizontal-title-area { align-items: center; text-align: center; }
  #skills { grid-template-columns: 1fr; }
  .skills-sticky-left {
    justify-content: center;
    padding: 2.5rem 2rem 2rem;
    border-bottom: 1px solid rgba(255,255,255,0.07);
  }
  .skills-sticky-left::after { display: none; }
  .skills-scroll-viewport { height: 50vh; }
  .skill-item { height: 50vh; justify-content: center; padding: 0 6%; }
  .skill-content { margin-top: calc(25vh - clamp(2.5rem, 5vw, 5.5rem) / 2); }
}

@media (prefers-reduced-motion: reduce) {
  #hero { position: relative; top: auto; }
  .ticker-track { animation: none; }
  nav, .btn-primary, .btn-case, .btn-dark, .project-card { transition: none; }
}
