/* ============================================================
   Niko — Home
   Styles specific to index.html (hero, work, about, contact).
   ============================================================ */

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 56px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 64px;
  align-items: center;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--pad-x);
  container-type: inline-size;
}
@container (max-width: 500px) {
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
}

.hero-eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mid);
  margin-bottom: 28px;
  display: inline-flex; align-items: center; gap: 10px;
}
.hero-eyebrow::before {
  content: "";
  width: 24px; height: 1px;
  background: var(--ink-mid);
  display: inline-block;
}

.hero-title {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(56px, 9vw, 120px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 0 0 24px;
  color: var(--ink);
  text-wrap: balance;
}
.hero-title .lastname { display: block; }

.hero-subtitle {
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.3;
  font-weight: 500;
  color: var(--forest);
  margin: 0 0 20px;
  letter-spacing: -0.01em;
}

.hero-lede {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink);
  opacity: 0.82;
  max-width: 44ch;
  margin: 0 0 28px;
  text-wrap: pretty;
}

.hero-coords {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-mid);
  font-variant-numeric: tabular-nums;
  margin: 0 0 40px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.hero-coords .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--forest); display: inline-block; }

.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

/* Topographic panel */
.hero-map {
  position: relative;
  aspect-ratio: 1 / 1.05;
  width: 100%;
  border: 1px solid var(--hairline);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-soft);
}
.hero-map .contours {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
}
.hero-map .crosshair {
  position: absolute;
  left: 50%; top: 50%;
  width: 16px; height: 16px;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.hero-map .crosshair::before,
.hero-map .crosshair::after {
  content: "";
  position: absolute;
  background: var(--ink);
}
.hero-map .crosshair::before { left: 50%; top: 0; bottom: 0; width: 1px; transform: translateX(-50%); }
.hero-map .crosshair::after { top: 50%; left: 0; right: 0; height: 1px; transform: translateY(-50%); }
.hero-map .crosshair .pin {
  position: absolute;
  left: 50%; top: 50%;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--blue);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--blue) 25%, transparent);
}

.map-legend {
  position: absolute;
  left: 12px; bottom: 12px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--ink-mid);
  text-transform: uppercase;
  display: flex;
  gap: 14px;
}
.map-legend span { display: inline-flex; align-items: center; gap: 5px; }
.map-legend .swatch { width: 8px; height: 8px; border: 1px solid var(--forest); border-radius: 1px; }
.map-legend .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--forest); display: inline-block; }

.map-corner {
  position: absolute;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--ink-mid);
  text-transform: uppercase;
}
.map-corner.tl { top: 12px; left: 12px; }
.map-corner.tr { top: 12px; right: 12px; }
.map-corner.br { bottom: 12px; right: 12px; }

/* Scroll cue */
.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mid);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  transition: opacity 300ms var(--ease);
}
.scroll-cue .line {
  width: 1px; height: 28px;
  background: linear-gradient(to bottom, var(--ink-mid), transparent);
  animation: scrollLine 2.4s var(--ease) infinite;
}
@keyframes scrollLine {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  50.01% { transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}
@media (prefers-reduced-motion: reduce) { .scroll-cue .line { animation: none; } }

/* ============================================================
   Sections
   ============================================================ */
section { padding: clamp(32px, 5vw, 64px) 0; }

/* .section-head, .section-title, .section-label moved to base.css so app pages can use them */

/* ============================================================
   Work
   ============================================================ */
.work-list { display: flex; flex-direction: column; gap: clamp(48px, 6vw, 80px); container-type: inline-size; }

.app {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
  background: color-mix(in oklab, var(--bg) 82%, transparent);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: clamp(24px, 4vw, 40px);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}
.app.reverse { grid-template-columns: 1.1fr 0.9fr; }
.app.reverse .app-visual { order: 2; }
.app.reverse .app-content { order: 1; }

@container (max-width: 700px) {
  .app, .app.reverse { grid-template-columns: 1fr; gap: 24px; }
  .app.reverse .app-visual { order: 0; }
  .app.reverse .app-content { order: 0; }
  .app-visual { padding-bottom: 0; }
}

.app-visual {
  position: relative;
  width: 100%;
  max-width: 260px;
  justify-self: center;
  padding-bottom: 0px;
}
.app-icon-link { display: block; }
.app-icon {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 22.37%;
  overflow: hidden;
  box-shadow:
    0 1px 2px rgba(0,0,0,0.4),
    0 16px 40px -16px rgba(0,0,0,0.6),
    inset 0 0 0 1px rgba(255,255,255,0.08);
  transition: transform 400ms var(--ease), box-shadow 400ms var(--ease);
}
.app-icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.app:hover .app-icon {
  transform: translateY(-4px);
  box-shadow:
    0 2px 4px rgba(0,0,0,0.5),
    0 28px 60px -20px rgba(82, 183, 136, 0.25),
    inset 0 0 0 1px rgba(255,255,255,0.1);
}

/* GPS Mapper icon */
.icon-grids {
  background: linear-gradient(150deg, #1B4332 0%, #2D6A4F 60%, #40916C 100%);
}
.icon-grids svg { position: absolute; inset: 0; }

/* Blackjack icon */
.icon-blackjack {
  background: radial-gradient(ellipse at 30% 25%, #2E5EAA 0%, #1A3B75 55%, #0C1E3E 100%);
}
.icon-blackjack svg { position: absolute; inset: 0; }

.app-view-more {
  display: block;
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--forest);
  text-align: center;
  transition: opacity 200ms var(--ease);
}
.app-view-more:hover { opacity: 0.7; }
.app-view-more .arrow {
  display: inline-block;
  transition: transform 200ms var(--ease);
}
.app-view-more:hover .arrow { transform: translateX(3px); }

.app-caption {
  margin-top: 16px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--ink-mid);
  text-transform: uppercase;
  text-align: center;
}

.app-content { max-width: 560px; }

.app-category {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--blue);
  text-transform: uppercase;
  margin-bottom: 20px;
  display: inline-block;
}

.app-title {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(28px, 3.2vw, 40px);
  letter-spacing: -0.03em;
  line-height: 1.02;
  margin: 0 0 12px;
  color: var(--ink);
  text-wrap: balance;
}

.app-subtitle {
  font-size: clamp(16px, 1.6vw, 18px);
  line-height: 1.35;
  color: var(--ink);
  opacity: 0.7;
  margin: 0 0 14px;
  font-weight: 400;
  text-wrap: pretty;
}

.app-body {
  font-size: 15px;
  line-height: 1.55;
  margin: 0 0 20px;
  color: var(--ink);
  opacity: 0.86;
  max-width: 54ch;
  text-wrap: pretty;
}

.app-features {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 20px;
  font-size: 13px;
  color: var(--ink);
  border-top: 1px solid var(--hairline);
}
.app-features li {
  padding: 7px 0;
  border-bottom: 1px solid var(--hairline);
  font-variant-numeric: tabular-nums;
  display: flex;
  align-items: center;
  gap: 10px;
}
.app-features li::before {
  content: "";
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--forest);
  flex-shrink: 0;
}

.app-links { display: flex; gap: 20px; flex-wrap: wrap; align-items: center; }
.link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 15px;
  font-weight: 500;
  transition: color 150ms var(--ease);
}
.link .arrow { transition: transform 200ms var(--ease); display: inline-block; }
.link:hover .arrow { transform: translateX(3px); }
.link-primary { color: var(--blue); }
.link-primary:hover { color: color-mix(in oklab, var(--blue) 70%, var(--ink)); }
.link-secondary { color: var(--ink-mid); }
.link-secondary:hover { color: var(--ink); }

/* ============================================================
   About
   ============================================================ */
.about-grid {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: clamp(24px, 4vw, 48px);
  align-items: stretch;
  background: color-mix(in oklab, var(--bg) 82%, transparent);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: clamp(24px, 4vw, 40px);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  container-type: inline-size;
}
@container (max-width: 600px) { .about-grid { grid-template-columns: 1fr; } }

.about-grid > div:first-child {
  display: flex;
}
.portrait {
  flex: 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--hairline-strong);
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.5),
    0 24px 48px -12px rgba(82, 183, 136, 0.2),
    0 0 0 1px rgba(82, 183, 136, 0.08);
  transition: box-shadow 400ms var(--ease), transform 400ms var(--ease);
}
.portrait:hover {
  transform: translateY(-3px);
  box-shadow:
    0 4px 8px rgba(0, 0, 0, 0.5),
    0 32px 64px -16px rgba(82, 183, 136, 0.3),
    0 0 0 1px rgba(82, 183, 136, 0.15);
}
.portrait-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}


.about-headline {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.025em;
  margin: 0 0 32px;
  color: var(--ink);
  max-width: 22ch;
  text-wrap: balance;
}
.about-headline em {
  font-style: normal;
  color: var(--forest);
}

.about-body {
  padding: 0;
}
.about-body p {
  font-size: 17px;
  line-height: 1.65;
  margin: 0 0 20px;
  max-width: 58ch;
  color: var(--ink);
  opacity: 0.86;
  text-wrap: pretty;
}

.tools {
  margin-top: 40px;
}
.tools-label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-mid);
  text-transform: uppercase;
  margin-bottom: 14px;
}
.tools-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.tool {
  padding: 8px 16px;
  font-size: 14px;
  font-family: var(--sans);
  color: var(--ink);
  background: color-mix(in oklab, var(--ink) 8%, transparent);
  border: 1px solid var(--hairline);
  border-radius: 100px;
  white-space: nowrap;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.tool:hover {
  background: color-mix(in oklab, var(--forest) 15%, transparent);
  border-color: var(--forest);
}

/* ============================================================
   Contact
   ============================================================ */
.contact {
  text-align: center;
}
.contact-inner {
  max-width: 780px;
  margin: 0 auto;
  padding: clamp(32px, 5vw, 64px);
  background: color-mix(in oklab, var(--bg) 82%, transparent);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}
.contact-headline {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  margin: 24px 0 20px;
  color: var(--ink);
  text-wrap: balance;
}
.contact-lede {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink);
  opacity: 0.72;
  margin: 0 auto 56px;
  max-width: 48ch;
  text-wrap: pretty;
}

.email-card {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  border: 1px solid var(--hairline-strong);
  border-radius: 999px;
  background: var(--bg);
  transition: border-color 200ms var(--ease), transform 200ms var(--ease);
  margin-bottom: 20px;
}
.contact-disclaimer {
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-mid);
  margin: 0 auto 56px;
  max-width: 52ch;
  text-wrap: pretty;
}
.email-card:hover { border-color: var(--ink); }
.email-address {
  font-family: var(--sans);
  font-size: clamp(20px, 2.6vw, 28px);
  font-weight: 500;
  color: var(--forest);
  letter-spacing: -0.015em;
}
.copy-btn {
  background: none;
  border: 1px solid var(--hairline-strong);
  color: var(--ink);
  padding: 6px 12px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  cursor: pointer;
  text-transform: uppercase;
  transition: all 200ms var(--ease);
  min-width: 70px;
  font-variant-numeric: tabular-nums;
}
.copy-btn:hover { border-color: var(--ink); }
.copy-btn.is-copied { background: var(--forest); color: var(--bg); border-color: var(--forest); }

.social-links {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  font-size: 15px;
  font-weight: 500;
}
.social-links a {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--ink);
  opacity: 0.78;
  transition: opacity 150ms var(--ease), color 150ms var(--ease);
}
.social-links a:hover { opacity: 1; color: var(--blue); }
.social-links .arrow { display: inline-block; transition: transform 200ms var(--ease); }
.social-links a:hover .arrow { transform: translate(2px, -2px); }

/* ============================================================
   Word reveal (contact title animation)
   ============================================================ */
.word-reveal {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
}
.word-inner {
  display: inline-block;
}

/* ============================================================
   Viewport overrides
   ============================================================ */
@media (aspect-ratio < 3/4) {
  .hero { min-height: auto; padding: clamp(80px, 12vh, 140px) 0; }
  section { padding: clamp(40px, 6vh, 80px) 0; }
}
@media (aspect-ratio < 1/2) {
  .hero-map { display: none; }
}
