/* ============================================================
   Daniel Jimenez — Portfolio v2
   Inspired by gabrielanamie.com
   Fonts: Cormorant Garamond (display) + Inter (UI)
   ============================================================ */

/* ---- Reset ------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 16px;
}

body {
  background-color: #f9f8f7;
  color: #111;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* ---- Custom Properties ------------------------------------- */
:root {
  --bg:        #f9f8f7;
  --bg-dark:   #0d0d0d;
  --ink:       #111111;
  --muted:     #888888;
  --accent:    #c5ab8a;
  --nav-h:     64px;
  --side-pad:  48px;
  --max-w:     1400px;
}

@media (max-width: 768px) {
  :root { --side-pad: 24px; --nav-h: 56px; }
}

/* ---- Navigation -------------------------------------------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--side-pad);
  pointer-events: none;
}

.nav-logo, .nav-links a { pointer-events: auto; }

.nav-logo {
  font-family: 'Inter', system-ui, sans-serif;
  font-size:  0.68rem;
  font-weight:  400;
  letter-spacing:  0.2em;
  text-transform: uppercase;
  color: #fff;
  mix-blend-mode: difference;
}

.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #fff;
  mix-blend-mode: difference;
  transition: opacity 0.2s;
}

.nav-links a:hover { opacity: 0.5; }

@media (max-width: 600px) {
  .nav-links { gap: 20px; }
  .nav-links a { font-size: 0.62rem; }
}

/* ---- Hero — Full-screen reel ------------------------------- */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  background: #0d0d0d;
  overflow: hidden;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.hero-video.loaded {
  opacity: 1;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,0.6) 100%);
  pointer-events: none;
}

.hero-caption {
  position: absolute;
  bottom: var(--side-pad);
  left: var(--side-pad);
  z-index: 2;
}

.hero-caption-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.5rem, 2.6vw, 2.8rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: #fff;
}

.hero-caption-sub {
  margin-top: 10px;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
}


/* ---- Section shared --------------------------------------- */
.section {
  padding: 120px var(--side-pad);
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-label {
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 60px;
}

/* ---- Works Grid ------------------------------------------- */
#work { padding-top: 0; }

.works-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4px;
}

@media (max-width: 768px) {
  .works-grid { grid-template-columns: 1fr; }
}

.work-item--featured { grid-column: 1 / -1; }

.work-item {
  position: relative;
  overflow: hidden;
  background: #ddd;
  cursor: pointer;
}

.work-item:hover .work-media { transform: scale(1.04); }
.work-item:hover .work-overlay { opacity: 1; }

.work-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  display: block;
}

.work-item--featured { aspect-ratio: 16 / 7; }
.work-item--wide     { aspect-ratio: 16 / 9; }
.work-item--tall     { aspect-ratio: 4 / 5; }
.work-item--square   { aspect-ratio: 1 / 1; }
.work-item--portrait { aspect-ratio: 3 / 4; }

.work-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.35);
  opacity: 0;
  transition: opacity 0.4s ease;
  display: flex;
  align-items: flex-end;
  padding: 32px;
}

.work-info { color: #fff; }

.work-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.7rem;
  font-weight: 400;
  line-height: 1.1;
  margin-bottom: 6px;
}

.work-category {
  font-size: 0.63rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
}

.work-item video.work-media { pointer-events: none; }

/* ---- About ------------------------------------------------ */
#about { border-top: 1px solid rgba(0,0,0,0.07); }

.about-inner {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: clamp(48px, 8vw, 140px);
  align-items: start;
}

@media (max-width: 860px) {
  .about-inner { grid-template-columns: 1fr; }
}

.about-portrait {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  filter: grayscale(10%);
}

.about-text-col { padding-top: 4px; }

.about-heading {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(2rem, 3.5vw, 3.4rem);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin-bottom: 36px;
}

.about-body {
  font-size: 0.9rem;
  line-height: 1.9;
  color: #444;
  max-width: 480px;
}

.about-body p + p { margin-top: 20px; }

.about-meta {
  margin-top: 52px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  border-top: 1px solid rgba(0,0,0,0.08);
  padding-top: 36px;
}

.about-meta-row {
  display: flex;
  gap: 24px;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.about-meta-label { color: var(--muted); min-width: 90px; }
.about-meta-value  { color: var(--ink); }

/* ---- Services --------------------------------------------- */
#services, #services-bottom {
  border-top: 1px solid rgba(0,0,0,0.07);
  background: #f0ede8;
}

.services-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 80px var(--side-pad);
}

/* Two-column split: bio left, skills right — vertically centered */
.services-split {
  display: grid;
  grid-template-columns: 1fr 4fr;
  gap: 40px;
  align-items: center;
}

.services-bio .section-label {
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  line-height: 2;
  margin-bottom: 0;
}

.services-skills .section-label {
  margin-bottom: 24px;
}

@media (max-width: 900px) {
  .services-split {
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: start;
  }
}

/* Skill accordion (top services) — 3-column grid (3 cols x 2 rows) */
.skill-accordion {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0 32px;
}

.skill-item {
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.skill-item summary {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 14px 0;
  cursor: pointer;
  list-style: none;
}

.skill-item summary::-webkit-details-marker { display: none; }
.skill-item summary::marker { display: none; content: ''; }

.skill-item summary .service-num {
  margin-bottom: 0;
}

.skill-item summary .service-title {
  margin-bottom: 0;
  font-size: 0.95rem;
}

.skill-item .service-desc {
  padding: 0 0 14px 0;
  margin-top: -4px;
  max-width: 100%;
}

@media (max-width: 1100px) {
  .skill-accordion { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 650px) {
  .skill-accordion { grid-template-columns: 1fr; }
}

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

@media (max-width: 900px) {
  .services-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .services-grid { grid-template-columns: 1fr; }
}

.service-num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 16px;
}

.service-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.45rem;
  font-weight: 500;
  margin-bottom: 12px;
}

.service-desc {
  font-size: 0.8rem;
  line-height: 1.8;
  color: #555;
}

/* ---- Experience Accordion --------------------------------- */
.experience-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.exp-item {
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.exp-item summary {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 24px 0;
  cursor: pointer;
  list-style: none;
}

.exp-item summary::-webkit-details-marker { display: none; }
.exp-item summary::marker { display: none; content: ''; }

.exp-item summary .service-num {
  margin-bottom: 0;
}

.exp-item summary .service-title {
  margin-bottom: 0;
  font-size: 1.25rem;
}

.exp-meta {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-left: auto;
  white-space: nowrap;
}

.exp-item .service-desc {
  padding: 0 0 24px 0;
  margin-top: -8px;
  max-width: 640px;
}

@media (max-width: 560px) {
  .exp-item summary { flex-wrap: wrap; }
  .exp-meta { margin-left: 0; width: 100%; margin-top: 4px; }
}

/* ---- Contact ---------------------------------------------- */
#contact {
  border-top: 1px solid rgba(255,255,255,0.05);
  background: #0d0d0d;
  color: #fff;
}

.contact-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 140px var(--side-pad);
}

.contact-heading {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(2.8rem, 6vw, 7rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 56px;
}

.contact-heading em {
  font-style: italic;
  color: rgba(255,255,255,0.35);
}

.contact-cta {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.contact-link {
  display: inline-block;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.1rem, 2vw, 1.7rem);
  color: rgba(255,255,255,0.8);
  border-bottom: 1px solid rgba(255,255,255,0.15);
  padding-bottom: 4px;
  transition: color 0.2s, border-color 0.2s;
  width: fit-content;
}

.contact-link:hover { color: #fff; border-color: rgba(255,255,255,0.5); }

.contact-social {
  margin-top: 72px;
  display: flex;
  gap: 36px;
}

.contact-social a {
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  transition: color 0.2s;
}

.contact-social a:hover { color: #fff; }

/* ---- Footer ----------------------------------------------- */
.footer {
  background: #0d0d0d;
  border-top: 1px solid rgba(255,255,255,0.05);
  padding: 26px var(--side-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: rgba(255,255,255,0.2);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ---- Reveal on scroll ------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}

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

/* ---- Scrollbar ------------------------------------------- */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 2px; }

