/* Coconut Joe Ltd — daylight: white paper, dark ink, palm green and a pale sky blue. One typeface. Light, single theme by choice. */
@font-face {
  font-family: "Archivo";
  src: url("assets/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  /* layout: text on paper at the left, the photo bleeding off the right
     edge; below it plain rows separated by hairlines, no cards */
  --paper: #fbfbf8;
  --ink: #101614;
  --soft: #55605b;        /* secondary text */
  --line: #dcdfd8;        /* hairlines */
  --palm: #17603a;        /* accent, links and marks */
  --sky: #e6effb;         /* tinted panel, from the photo's sky */
  --font: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --gutter: clamp(20px, 5vw, 72px);
  --wide: 1240px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
a:focus-visible {
  outline: 2px solid var(--palm);
  outline-offset: 4px;
}
h1, h2, h3 {
  font-weight: 650;
  font-stretch: 108%;
  line-height: 1;
  letter-spacing: -0.03em;
  margin: 0;
  text-wrap: balance;
}
p { margin: 0; }
.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }
.label { font-size: 15px; color: var(--soft); }

/* ---------- header ---------- */
.top {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: clamp(16px, 2.4vw, 26px) clamp(18px, 3vw, 40px);
}
.top.solid { border-bottom: 1px solid var(--line); padding-inline: var(--gutter); }
.mark {
  font-weight: 750; font-stretch: 112%;
  font-size: 20px; letter-spacing: -0.02em;
  text-decoration: none; white-space: nowrap;
}
.top nav {
  display: flex; align-items: center; gap: 4px;
  background: rgba(255, 255, 255, .16);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-radius: 999px; padding: 5px;
}
.top nav a { font-size: 15px; text-decoration: none; padding: 9px 16px; border-radius: 999px; }
.top nav a.pill { background: #fff; color: var(--ink); }
.top.solid nav { background: #eeefe9; }
.top.solid nav a.pill { background: var(--ink); color: #fff; }

/* ---------- hero: one rounded frame, photo behind white type ---------- */
.shell { padding: clamp(8px, 1.1vw, 14px); }
.hero {
  position: relative; isolation: isolate;
  overflow: clip;
  border-radius: clamp(20px, 2.4vw, 30px);
  min-height: min(calc(100svh - 28px), 880px);
  display: flex; flex-direction: column; justify-content: space-between;
  background: #1a1712; color: #fff;
}
.hero picture { position: absolute; inset: 0; z-index: -2; display: block; }
.hero .photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 34%;
  transform-origin: 50% 34%;
}
@media (min-width: 861px) {
  /* wider than the frame, so the coconut sits right of the headline */
  .hero .photo { width: 124%; object-position: 50% 40%; transform-origin: 62% 44%; }
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(16,14,10,.5) 0%, rgba(16,14,10,.16) 32%, rgba(16,14,10,.26) 60%, rgba(16,14,10,.74) 100%);
}
.hero .say {
  display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap;
  gap: 28px 48px;
  padding: clamp(20px, 3vw, 40px);
}
.hero h1 {
  font-size: clamp(46px, 8.2vw, 108px);
  font-weight: 700; line-height: .9; letter-spacing: -0.045em;
  max-width: 7.2em;
}
.hero .side { display: flex; flex-direction: column; gap: 18px; align-items: flex-start; width: min(100%, 330px); padding-bottom: 6px; }
.hero .side p { font-size: clamp(17px, 1.5vw, 19px); line-height: 1.45; }
.btn {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 16px;
  background: #fff; color: var(--ink);
  padding: 14px 24px; border-radius: 999px;
}
.btn:hover { background: var(--sky); }

/* Motion runs on the browser's own scroll timeline, so it stays smooth on
   phones. Browsers without it simply show the page without motion. */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .hero .photo {
      animation: hero-drift linear both;
      animation-timeline: view();
      animation-range: exit 0% exit 100%;
    }
    .rise {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 55%;
    }
  }
}
@keyframes hero-drift { to { transform: scale(1.1) translateY(4%); } }
@media (min-width: 861px) { @keyframes hero-drift { to { transform: scale(1.16) translateY(5%); } } }
@keyframes rise { from { opacity: .35; transform: translateY(36px); } to { opacity: 1; transform: none; } }

/* ---------- statement ---------- */
.about { padding: clamp(72px, 12vw, 170px) 0 clamp(64px, 10vw, 140px); }
.about .grid { display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr); gap: 20px 40px; }
.about p.big {
  font-size: clamp(26px, 3.5vw, 46px);
  font-weight: 500; line-height: 1.16; letter-spacing: -0.022em;
  max-width: 24ch;
  text-wrap: balance;
}
.about p.more { margin-top: 26px; max-width: 54ch; color: var(--soft); }

/* ---------- products ---------- */
.work { padding-bottom: clamp(12px, 1.4vw, 18px); }
.work > .wrap > .label { display: block; padding-bottom: 18px; }
.work .wrap { padding-inline: clamp(8px, 1.1vw, 14px); max-width: none; }
.work > .wrap > .label { padding-left: clamp(12px, 3vw, 40px); }
.product {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 64px);
  align-items: center;
  background: #f1f1ec;
  border-radius: clamp(20px, 2.4vw, 30px);
  padding: clamp(18px, 3vw, 40px);
}
.product + .product { margin-top: clamp(12px, 1.4vw, 18px); }
.product .copy { padding: clamp(6px, 1.5vw, 20px); }
.product .copy { display: flex; flex-direction: column; gap: 16px; align-items: flex-start; }
.product h3 { font-size: clamp(40px, 5.6vw, 76px); font-weight: 700; }
.product .text { max-width: 44ch; }
.product .facts { color: var(--soft); font-size: 16px; }
.go {
  margin-top: 8px;
  font-weight: 600; text-decoration: none; color: var(--palm);
  border-bottom: 2px solid currentColor; padding-bottom: 3px;
}
.go:hover { color: var(--ink); }
.go.soon { color: var(--soft); border-bottom-style: dotted; cursor: default; font-weight: 500; }
.go.soon:hover { color: var(--soft); }
.stage { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--sky); border-radius: clamp(14px, 1.8vw, 22px); }
.stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* Remotehand stage: the approval prompt, drawn in CSS */
.stage.rh { display: flex; align-items: center; justify-content: center; padding: clamp(18px, 4vw, 48px); }
.prompt {
  width: min(100%, 400px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  box-shadow: 0 24px 50px -24px rgba(16, 40, 80, .35);
  display: grid; gap: 12px;
}
.prompt .bar { font-size: 14px; color: var(--soft); }
.prompt code {
  display: block; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 14px; color: var(--ink);
  background: #f1f3ef; border-radius: 7px; padding: 11px 12px;
  overflow-wrap: anywhere;
}
.prompt .btns { display: flex; gap: 8px; }
.prompt .btns span {
  flex: 1; text-align: center; font-size: 15px; font-weight: 600;
  padding: 9px 0; border-radius: 7px; border: 1px solid var(--line); color: var(--soft);
}
.prompt .btns .ok { background: var(--ink); color: #fff; border-color: var(--ink); }

/* ---------- contact ---------- */
.contact { padding: 0 clamp(8px, 1.1vw, 14px) clamp(8px, 1.1vw, 14px); }
.contact .grid {
  max-width: none;
  background: var(--ink); color: #fff;
  border-radius: clamp(20px, 2.4vw, 30px);
  padding: clamp(40px, 8vw, 110px) clamp(20px, 3vw, 40px);
  display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr); gap: 20px 40px;
}
.contact .label { color: #a9b0aa; }
.contact h2 { font-size: clamp(34px, 5.4vw, 76px); font-weight: 700; max-width: 14ch; }
.contact p { margin-top: 20px; max-width: 40ch; color: #c5cbc6; }
.contact .mail {
  display: inline-block; margin-top: 28px;
  font-size: clamp(20px, 3vw, 34px); font-weight: 600; letter-spacing: -0.02em;
  color: #fff; text-decoration: none;
  border-bottom: 2px solid #6fbf8f; padding-bottom: 3px;
  overflow-wrap: anywhere;
}
.contact .mail:hover { color: #6fbf8f; }

/* ---------- footer ---------- */
.foot { padding: 26px 0 40px; color: var(--soft); font-size: 14.5px; }
.foot .row { display: flex; flex-wrap: wrap; gap: 14px 40px; justify-content: space-between; }
.foot address { font-style: normal; max-width: 64ch; }
.foot nav { display: flex; gap: 22px; flex-wrap: wrap; }
.foot a { color: var(--ink); text-underline-offset: 3px; }

/* ---------- legal pages ---------- */
.doc { max-width: 740px; margin: 0 auto; padding: clamp(44px, 8vw, 90px) var(--gutter) clamp(64px, 10vw, 120px); }
.doc h1 { font-size: clamp(40px, 6vw, 68px); font-weight: 700; margin: 10px 0 10px; }
.doc .updated { color: var(--soft); font-size: 15px; margin-bottom: 36px; }
.doc h2 { font-size: 24px; font-stretch: 100%; letter-spacing: -0.015em; margin: 44px 0 12px; }
.doc p + p { margin-top: 12px; }
.doc ul { padding-left: 20px; margin: 10px 0 0; display: grid; gap: 6px; }
.doc a { color: var(--palm); text-underline-offset: 3px; }
.doc dl { display: grid; grid-template-columns: minmax(120px, 200px) minmax(0, 1fr); gap: 10px 20px; margin: 0; }
.doc dt { color: var(--soft); }
.doc dd { margin: 0; }

/* ---------- small screens ---------- */
@media (max-width: 860px) {
  .about .grid, .contact .grid { grid-template-columns: minmax(0, 1fr); }
  .product { grid-template-columns: minmax(0, 1fr); }
  .product .stage { order: -1; }
}
@media (max-width: 520px) {
  .top nav a.hide-s { display: none; }
  .doc dl { grid-template-columns: minmax(0, 1fr); gap: 2px 0; }
  .doc dd { margin-bottom: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
