/* =============================================================================
   Alex Zacney — personal site
   Visual system: deep forest green, ivory type, muted sage, cognac + a sparing
   racing-red accent. High-end automotive-editorial meets founder portfolio.
   ========================================================================== */

:root {
  /* Greens — base to deepest */
  --green: #073b1d;
  --green-raised: #0a481f; /* cards / raised surfaces */
  --green-line: #0e5226;
  --green-deep: #042412; /* footer / darkest tiles */

  /* Type */
  --ivory: #f5f1e8;
  --ivory-dim: rgba(245, 241, 232, 0.62); /* secondary text */
  --sage: #9bb4a3; /* muted sage-green */

  /* Accents — used very sparingly */
  --red: #c5402f; /* racing red */
  --cognac: #c39368; /* tobacco / cognac */
  --gold: #cbac6e; /* soft gold — used for the ACZ marks */

  /* Lines */
  --line: rgba(245, 241, 232, 0.14);
  --line-strong: rgba(245, 241, 232, 0.3);

  /* Form */
  --radius: 14px;
  --radius-lg: 20px;
  --container: min(1160px, calc(100vw - 48px));
  --nav-h: 76px;

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ivory);
  background: var(--green);
  background-image: linear-gradient(180deg, #08401f 0%, #063619 55%, #052e15 100%);
  background-attachment: fixed;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

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

a,
button {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 2px solid var(--cognac);
  outline-offset: 3px;
  border-radius: 2px;
}

.container {
  width: var(--container);
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ivory);
  color: var(--green);
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  font-weight: 600;
  z-index: 100;
}
.skip-link:focus {
  left: 0;
}

/* Eyebrow / kicker label — small, tracked, with a sparing red tick. */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sage);
}
.eyebrow::before {
  content: "";
  width: 18px;
  height: 2px;
  background: var(--red);
}

/* =============================================================================
   Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(6, 52, 25, 0.72);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--nav-h);
  gap: 24px;
}

.brand {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
  color: var(--gold);
}

.site-nav .nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  font-size: 0.92rem;
  color: var(--ivory-dim);
  transition: color 180ms ease;
}
.nav-link:hover {
  color: var(--ivory);
}
.nav-link.is-active {
  color: var(--ivory);
}
.nav-link.is-active::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 1.5px;
  background: var(--ivory);
}
.nav-link .ext {
  font-size: 0.7em;
  color: var(--sage);
  transition: transform 180ms ease;
}
.nav-link:hover .ext {
  transform: translate(1px, -1px);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}
.nav-toggle__bar {
  width: 18px;
  height: 1.5px;
  background: var(--ivory);
  transition: transform 220ms ease, opacity 220ms ease;
}

/* =============================================================================
   Buttons & inline CTAs
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 26px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ivory);
  background: transparent;
  cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease,
    border-color 200ms ease, transform 200ms ease;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn--primary {
  background: var(--ivory);
  color: var(--green);
  border-color: var(--ivory);
}
.btn--primary:hover {
  background: transparent;
  color: var(--ivory);
}
.btn--ghost:hover {
  border-color: var(--ivory);
}

/* Quiet text link with arrow */
.link-cta {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ivory);
  width: fit-content;
}
.link-cta .ext {
  color: var(--cognac);
  transition: transform 200ms ease;
}
.link-cta::after {
  content: "";
  display: block;
}
.link-cta {
  position: relative;
  padding-bottom: 3px;
}
.link-cta::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--line-strong);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 240ms ease;
}
.link-cta:hover::before {
  transform: scaleX(1);
}
.link-cta:hover .ext {
  transform: translate(2px, -2px);
}

/* =============================================================================
   Typography helpers
   ========================================================================== */
.display {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.02;
  margin: 0;
}

.section {
  padding: clamp(72px, 11vw, 132px) 0;
}
.section + .section {
  border-top: 1px solid var(--line);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 56px;
}
.section-head h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
  line-height: 1.04;
  letter-spacing: -0.01em;
  margin: 14px 0 0;
}
.section-intro {
  max-width: 34ch;
  margin: 0;
  color: var(--ivory-dim);
  font-size: 1.02rem;
}

/* =============================================================================
   Home — hero
   ========================================================================== */
.hero {
  padding-top: clamp(48px, 8vw, 96px);
  padding-bottom: clamp(64px, 9vw, 120px);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.86fr);
  align-items: center;
  gap: clamp(36px, 6vw, 84px);
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(3.2rem, 8.5vw, 6rem);
  line-height: 0.98;
  letter-spacing: -0.015em;
  margin: 22px 0 0;
  color: var(--gold);
}
.hero-positioning {
  margin: 22px 0 0;
  font-size: clamp(1.1rem, 1.7vw, 1.32rem);
  color: var(--ivory);
  max-width: 30ch;
  line-height: 1.35;
}
.hero-text {
  margin: 22px 0 0;
  max-width: 46ch;
  color: var(--ivory-dim);
  font-size: 1.04rem;
}
.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 36px;
}

.hero-media {
  position: relative;
}
.hero-media__frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
}
.hero-media__frame img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
.hero-media__caption {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sage);
}
.hero-media__caption::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--cognac);
}

/* =============================================================================
   Currently — spec-sheet style grid
   ========================================================================== */
.currently-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.currently-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 30px 28px 34px;
  border-right: 1px solid var(--line);
  min-height: 150px;
}
.currently-item:last-child {
  border-right: 0;
}
.currently-label {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cognac);
}
.currently-note {
  font-size: 1.08rem;
  color: var(--ivory);
  line-height: 1.35;
}

/* =============================================================================
   Project cards
   ========================================================================== */
.subsection + .subsection {
  margin-top: 64px;
}
.subsection-label {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 26px;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sage);
}
.subsection-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}
.project-grid--three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-card {
  display: flex;
  flex-direction: column;
  background: var(--green-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 240ms ease, border-color 240ms ease;
}
.project-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
}

.card-media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
.card-media--photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms ease;
}
.project-card:hover .card-media--photo img {
  transform: scale(1.03);
}
.card-media--logo {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
}
.card-media--logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.card-media--dark {
  background: var(--green-deep);
}
.card-media--light {
  background: var(--ivory);
}
.card-media--placeholder .monogram {
  font-family: var(--serif);
  font-size: 3rem;
  font-weight: 300;
  color: var(--ivory-dim);
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 26px 26px 28px;
  flex: 1;
}
.project-role {
  margin: 0;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cognac);
}
.project-name {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.1;
  margin: 0;
}
.project-desc {
  margin: 0;
  color: var(--ivory-dim);
  font-size: 1rem;
}
.project-body .link-cta {
  margin-top: 14px;
}

/* =============================================================================
   Page hero (Projects / Photos headers)
   ========================================================================== */
.page-hero {
  padding-top: clamp(56px, 8vw, 96px);
  padding-bottom: clamp(40px, 6vw, 64px);
}
.page-hero h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  line-height: 1;
  letter-spacing: -0.015em;
  margin: 18px 0 0;
}
.page-hero p {
  margin: 22px 0 0;
  max-width: 52ch;
  color: var(--ivory-dim);
  font-size: 1.08rem;
}

/* =============================================================================
   Photos
   ========================================================================== */
.photo-hero {
  margin: 0 0 22px;
}
.photo-hero img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
}
.photo-hero figcaption,
.photo-card figcaption {
  margin-top: 12px;
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  color: var(--sage);
}

.photo-masonry {
  columns: 3 280px;
  column-gap: 22px;
}
.photo-card {
  break-inside: avoid;
  margin: 0 0 30px;
}
.photo-card img {
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

/* =============================================================================
   Thoughts-style simple landing (optional, reusable)
   ========================================================================== */
.statement {
  max-width: 30ch;
}

/* =============================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--green-deep);
  border-top: 1px solid var(--line);
  padding: 48px 0 56px;
}
.footer-wrap {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}
.footer-name {
  font-family: var(--serif);
  font-size: 1.3rem;
  margin: 0;
  color: var(--gold);
}
.footer-role {
  margin: 4px 0 0;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}
.footer-links a {
  font-size: 0.92rem;
  color: var(--ivory-dim);
  transition: color 180ms ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.footer-links a:hover {
  color: var(--ivory);
}
.footer-links .ext {
  font-size: 0.7em;
  color: var(--sage);
}

/* =============================================================================
   Responsive
   ========================================================================== */
@media (max-width: 900px) {
  :root {
    --container: min(1160px, calc(100vw - 36px));
  }

  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-media {
    order: -1;
    max-width: 440px;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .section-intro {
    max-width: 100%;
  }

  .currently-list {
    grid-template-columns: 1fr 1fr;
  }
  .currently-item:nth-child(2) {
    border-right: 0;
  }
  .currently-item:nth-child(1),
  .currently-item:nth-child(2) {
    border-bottom: 1px solid var(--line);
  }

  .project-grid,
  .project-grid--three {
    grid-template-columns: 1fr;
  }

  /* Mobile nav: collapse into a panel */
  .nav-toggle {
    display: flex;
  }
  .site-nav {
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: rgba(5, 44, 21, 0.97);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
    max-height: 0;
    overflow: hidden;
    transition: max-height 280ms ease;
  }
  .site-header.is-open .site-nav {
    max-height: 70vh;
  }
  .site-nav .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 16px;
  }
  .nav-link {
    padding: 14px 24px;
    font-size: 1.05rem;
    width: 100%;
    justify-content: flex-start;
  }
  .nav-link.is-active::after {
    left: 24px;
    right: auto;
    width: 22px;
    bottom: 8px;
  }
}

@media (max-width: 560px) {
  .currently-list {
    grid-template-columns: 1fr;
  }
  .currently-item {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    min-height: 0;
  }
  .currently-item:last-child {
    border-bottom: 0;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .photo-masonry {
    columns: 1;
  }
  .footer-wrap {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
