/* ============================================================
   Darren Rea — personal site
   Palette: deep neutral dark + quiet warm gold accent
   ============================================================ */

:root {
  --bg: #0a0a0a;
  --bg-elev: #131312;
  --ink: #f4efe8;
  --ink-soft: rgba(244, 239, 232, 0.72);
  --ink-mute: rgba(244, 239, 232, 0.5);
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --accent: #e9c89a;             /* quiet warm gold */
  --accent-strong: #f0d4a8;
  --tile: #eeede9;               /* cream gallery tile */
  --shadow-card: 0 18px 50px rgba(0, 0, 0, 0.55);
  --serif: Georgia, "Cormorant Garamond", "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Helvetica Neue", Arial, sans-serif;

  --section-pad-y: clamp(72px, 10vw, 140px);
  --gutter: clamp(20px, 4vw, 56px);
  --content-max: 1200px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

/* ============================================================
   PAGE FADE (for soft transitions)
   ============================================================ */
#page-fade {
  position: fixed; inset: 0;
  background: #000; opacity: 0; pointer-events: none; z-index: 9000;
  transition: opacity 0.6s ease;
}

/* ============================================================
   SECTION SHELL
   ============================================================ */
.section-inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  position: relative;
  z-index: 2;
}

.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 18px;
}

.section-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.85rem, 3.6vw, 3rem);
  letter-spacing: -0.005em;
  line-height: 1.12;
  color: var(--ink);
  max-width: 22ch;
}

.section-head { margin-bottom: clamp(40px, 6vw, 72px); max-width: 720px; }
.section-head-center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head-center .section-title { margin-left: auto; margin-right: auto; }

.section-sub {
  margin-top: 16px;
  color: var(--ink-soft);
  font-size: 1.02rem;
  max-width: 56ch;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 26px;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 999px;
  transition: transform .25s ease, background .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink);
  color: #0a0a0a;
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}
.btn-primary:hover {
  background: var(--accent-strong);
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.45);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* ============================================================
   NAV
   ============================================================ */
#site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gutter);
  transition: background .35s ease, backdrop-filter .35s ease, border-color .35s ease, padding .35s ease;
  border-bottom: 1px solid transparent;
}
#site-nav.scrolled {
  background: rgba(10, 10, 10, 0.7);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom-color: var(--line);
  padding-top: 14px; padding-bottom: 14px;
}
.nav-mark {
  font-family: var(--serif);
  font-size: 1.08rem;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.nav-links { display: flex; gap: 28px; }
.nav-links a {
  font-size: 0.78rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color .25s ease;
  position: relative;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 1px; background: var(--accent);
  transform: scaleX(0); transform-origin: left;
  transition: transform .3s ease;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { transform: scaleX(1); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px var(--gutter) 100px;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background: url('bg-hero.jpg') center center / cover no-repeat;
  transform: scale(1.04);
  z-index: 0;
}
.hero-veil {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at center, rgba(0,0,0,0.20) 0%, rgba(0,0,0,0.55) 60%, rgba(0,0,0,0.78) 100%),
    linear-gradient(180deg, rgba(10,10,10,0.45) 0%, rgba(10,10,10,0.85) 100%);
  z-index: 1;
}
.hero-inner {
  position: relative; z-index: 2;
  max-width: 880px;
  display: flex; flex-direction: column; align-items: center;
  animation: heroIn 1.1s cubic-bezier(.2,.7,.2,1) both;
}
.hero-eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 28px;
  opacity: 0.95;
}
.hero-name {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3.2rem, 9vw, 7rem);
  letter-spacing: -0.012em;
  line-height: 1.0;
  text-shadow: 0 4px 30px rgba(0,0,0,0.5);
}
.hero-tagline {
  margin-top: 26px;
  font-size: clamp(1.02rem, 1.6vw, 1.18rem);
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  max-width: 38ch;
  line-height: 1.55;
}
.hero-cta {
  display: flex; gap: 14px; margin-top: 42px; flex-wrap: wrap; justify-content: center;
}
.hero-scroll {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  color: var(--ink-soft);
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: rgba(0,0,0,0.25);
  z-index: 3;
  animation: floatY 2.2s ease-in-out infinite;
  transition: color .25s ease, border-color .25s ease;
}
.hero-scroll:hover { color: var(--accent); border-color: var(--accent); }

@keyframes heroIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
@keyframes floatY {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 6px); }
}

/* ============================================================
   WORKS (nature-wall reprieve)
   ============================================================ */
.works {
  position: relative;
  padding: var(--section-pad-y) 0;
  overflow: hidden;
  isolation: isolate;
}
.works-bg {
  position: absolute; inset: 0;
  background: url('artwall.jpg') center center / cover no-repeat;
  filter: saturate(0.95);
  z-index: 0;
}
.works-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(10,10,10,0.92) 0%, rgba(10,10,10,0.45) 12%, rgba(10,10,10,0.45) 88%, rgba(10,10,10,0.95) 100%);
  z-index: 1;
}

.works .section-head { color: var(--ink); }

.works-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: clamp(20px, 2.5vw, 32px);
  margin-top: 20px;
}

.work-tile {
  position: relative;
  background: var(--tile);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1 / 1;
  display: flex; align-items: center; justify-content: center;
  transition: transform .35s ease, box-shadow .35s ease;
}
.work-tile:hover { transform: translateY(-4px); box-shadow: 0 26px 60px rgba(0,0,0,0.6); }

.work-tile img {
  max-width: 78%;
  max-height: 78%;
  width: auto;
  height: auto;
  object-fit: contain;
  box-shadow: 0 8px 20px rgba(0,0,0,0.35);
  border-radius: 3px;
  transition: transform .5s ease;
}
.work-tile:hover img { transform: scale(1.03); }

.work-hover {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 16px 18px;
  color: #fff;
  background: linear-gradient(180deg, rgba(0,0,0,0) 55%, rgba(0,0,0,0.78) 100%);
  opacity: 0;
  transition: opacity .25s ease;
  pointer-events: none;
}
.work-tile:hover .work-hover { opacity: 1; }
.work-hover .t { font-family: var(--serif); font-size: 1.02rem; line-height: 1.2; }
.work-hover .m { font-size: 0.78rem; letter-spacing: 0.08em; color: rgba(255,255,255,0.78); margin-top: 4px; }
.work-hover .status {
  align-self: flex-start;
  margin-bottom: 8px;
  font-size: 0.66rem; letter-spacing: 0.2em; text-transform: uppercase;
  padding: 4px 8px; border-radius: 4px;
  background: rgba(0,0,0,0.55); color: var(--accent);
  border: 1px solid rgba(255,255,255,0.18);
}
.work-hover .status.unavail { color: rgba(255,255,255,0.7); }

.works-cta { display: flex; justify-content: center; margin-top: clamp(40px, 5vw, 60px); }

/* ============================================================
   ABOUT
   ============================================================ */
.about {
  padding: var(--section-pad-y) 0;
  background: linear-gradient(180deg, var(--bg) 0%, #100f0e 100%);
}
.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}
.about-photo {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.about-photo img {
  width: 100%; height: 100%;
  object-fit: cover; aspect-ratio: 4 / 5;
  filter: saturate(0.95) contrast(1.02);
}
.about-text p { color: var(--ink-soft); margin-top: 18px; font-size: 1.04rem; max-width: 56ch; }
.about-text .section-title { margin-bottom: 8px; }
.about-meta { margin-top: 28px !important; font-size: 0.88rem; }
.about-meta a {
  color: var(--accent); letter-spacing: 0.06em;
  border-bottom: 1px solid rgba(233, 200, 154, 0.35);
  padding-bottom: 2px;
  transition: color .25s ease, border-color .25s ease;
}
.about-meta a:hover { color: var(--accent-strong); border-color: var(--accent-strong); }

@media (max-width: 800px) {
  .about-grid { grid-template-columns: 1fr; gap: 36px; }
  .about-photo { max-width: 420px; margin: 0 auto; }
}

/* ============================================================
   BUILDING (ventures)
   ============================================================ */
.building {
  padding: var(--section-pad-y) 0;
  background: linear-gradient(180deg, #100f0e 0%, var(--bg) 100%);
}
.ventures-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(18px, 2vw, 28px);
}
.venture-card {
  display: flex; flex-direction: column;
  padding: 30px 28px 26px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: transform .3s ease, border-color .3s ease, background .3s ease, box-shadow .3s ease;
  position: relative;
  overflow: hidden;
}
.venture-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at top right, rgba(233, 200, 154, 0.10), transparent 60%);
  opacity: 0; transition: opacity .35s ease;
}
.venture-card:hover {
  transform: translateY(-4px);
  border-color: rgba(233, 200, 154, 0.35);
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
}
.venture-card:hover::before { opacity: 1; }
.venture-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.45rem;
  margin-bottom: 6px;
  letter-spacing: -0.005em;
}
.venture-role {
  font-size: 0.72rem; letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}
.venture-body { color: var(--ink-soft); font-size: 0.96rem; line-height: 1.55; flex: 1; }
.venture-link {
  margin-top: 24px;
  font-size: 0.78rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink);
  transition: color .25s ease, letter-spacing .25s ease;
}
.venture-card:hover .venture-link { color: var(--accent); letter-spacing: 0.22em; }

.building-aside {
  margin-top: clamp(40px, 5vw, 56px);
  text-align: center;
  color: var(--ink-mute);
  font-size: 0.92rem;
}
.building-aside a {
  color: var(--accent);
  border-bottom: 1px solid rgba(233, 200, 154, 0.35);
  padding-bottom: 1px;
}
.building-aside a:hover { color: var(--accent-strong); }

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

/* ============================================================
   CONNECT
   ============================================================ */
.connect {
  padding: var(--section-pad-y) 0;
  background: var(--bg);
}
.connect-inner { text-align: center; max-width: 720px; }
.connect-inner .section-title { margin: 0 auto 28px; max-width: 22ch; }

.email-cta {
  display: inline-block;
  margin-top: 20px;
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  color: var(--accent);
  letter-spacing: 0.01em;
  border-bottom: 1px solid rgba(233, 200, 154, 0.35);
  padding-bottom: 6px;
  transition: color .25s ease, border-color .25s ease;
}
.email-cta:hover { color: var(--accent-strong); border-color: var(--accent-strong); }

.socials {
  display: flex; justify-content: center; gap: 16px;
  margin-top: 38px;
}
.socials a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line);
  color: var(--ink-soft);
  transition: transform .25s ease, color .25s ease, background .25s ease, border-color .25s ease;
}
.socials a:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
  background: rgba(233, 200, 154, 0.06);
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  padding: 40px var(--gutter);
  text-align: center;
  color: var(--ink-mute);
  font-size: 0.78rem;
  border-top: 1px solid var(--line);
  letter-spacing: 0.06em;
}

/* ============================================================
   LIGHTBOX
   ============================================================ */
#lightbox {
  position: fixed; inset: 0;
  background: rgba(8, 8, 8, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  opacity: 0;
  transition: opacity .35s ease;
  overflow-y: auto;
}
#lightbox.active { display: flex; }
#lightbox-content {
  position: relative;
  max-width: 940px;
  width: 100%;
  background: var(--bg-elev);
  border-radius: 16px;
  border: 1px solid var(--line);
  padding: clamp(20px, 3vw, 36px);
  text-align: center;
  box-shadow: 0 30px 80px rgba(0,0,0,0.7);
}
#lb-close {
  position: absolute; top: 14px; right: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--line);
  color: var(--ink);
  width: 36px; height: 36px; border-radius: 50%;
  cursor: pointer; font-size: 1rem;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}
#lb-close:hover { color: var(--accent); border-color: var(--accent); }

#lb-img {
  max-width: 100%;
  max-height: 60vh;
  width: auto; height: auto;
  margin: 8px auto 24px;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 16px 50px rgba(0,0,0,0.6);
}
#lb-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  letter-spacing: -0.005em;
  margin-bottom: 10px;
}
#lb-size {
  font-size: 0.84rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}
#lb-meta {
  font-size: 0.92rem;
  color: var(--ink-mute);
  font-style: italic;
  margin-bottom: 18px;
}
#lb-description {
  color: var(--ink-soft);
  max-width: 60ch;
  margin: 0 auto 28px;
  font-size: 1rem;
  line-height: 1.65;
}
#lb-lightnow {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--ink);
  color: #0a0a0a;
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  transition: background .25s ease, transform .25s ease;
}
#lb-lightnow:hover { background: var(--accent-strong); transform: translateY(-2px); }

/* ============================================================
   FADE-IN ON SCROLL
   ============================================================ */
.fade-up {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .9s ease, transform .9s ease;
}
.fade-up.visible { opacity: 1; transform: none; }

/* ============================================================
   RESPONSIVE TWEAKS
   ============================================================ */
@media (max-width: 720px) {
  .nav-links { gap: 18px; }
  .nav-links a { font-size: 0.7rem; letter-spacing: 0.2em; }
  .nav-mark { font-size: 0.98rem; }
  .hero-name { letter-spacing: -0.02em; }
  .works-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .section-title { max-width: 18ch; }
}

@media (max-width: 480px) {
  .nav-links { display: none; }
  .hero { min-height: 92vh; }
  .works-grid { grid-template-columns: 1fr; }
  .hero-cta .btn { padding: 13px 22px; font-size: 0.86rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
