/* ---------------------------------------------------------------------------
   Caprapp — marketing site
   The palette is the app's own (src/core/theme.js), so the site and the
   product look like the same thing made by the same people.
   --------------------------------------------------------------------------- */

:root {
  --ms-green: #14453d;
  --myrtle: #3d7068;
  --ocean: #43c59e;
  --brown: #291711;
  --nut: #7a4419;
  --yellow: #ffcf56;
  --capri: #48beff;
  --aqua: #3dfaff;
  --red: #721817;
  --dark-red: #400406;

  /* The app's card surface, and the paper it sits on */
  --card: #ffffff;
  --paper: #f6f2ef;
  --lilac: #efe7f2;
  --ink: var(--brown);
  --muted: #6b6259;

  --radius: 16px;
  --radius-lg: 28px;
  --shadow: 0 2px 10px rgba(41, 23, 17, 0.08);
  --shadow-lg: 0 18px 50px rgba(20, 69, 61, 0.18);
  --wrap: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- header ------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(20, 69, 61, 0.97);
  backdrop-filter: blur(10px);
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 12px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.2px;
  text-decoration: none;
  font-size: 18px;
  white-space: nowrap;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--ocean);
  display: grid;
  place-items: center;
  font-size: 18px;
}

.header-spacer { flex: 1; }

/* the two audiences — the site's main control */
.tabs {
  display: flex;
  gap: 6px;
  background: rgba(255, 255, 255, 0.12);
  padding: 4px;
  border-radius: 999px;
}

.tab {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.82);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease;
}

.tab[aria-selected="true"] {
  background: var(--yellow);
  color: var(--brown);
}

.lang {
  display: flex;
  gap: 2px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  padding: 3px;
}

.lang button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
}

.lang button[aria-pressed="true"] {
  background: #fff;
  color: var(--ms-green);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 13px 26px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary { background: var(--yellow); color: var(--brown); box-shadow: var(--shadow); }
.btn-ghost { background: rgba(255, 255, 255, 0.14); color: #fff; }
.btn-dark { background: var(--brown); color: var(--yellow); }
.btn-sm { padding: 9px 18px; font-size: 15px; }

/* --- hero --------------------------------------------------------------- */

.hero {
  background:
    radial-gradient(1100px 520px at 80% -8%, rgba(67, 197, 158, 0.28), transparent 60%),
    var(--ms-green);
  color: #fff;
  padding: 72px 0 90px;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 14px;
}

h1 {
  font-size: clamp(34px, 4.6vw, 56px);
  line-height: 1.05;
  letter-spacing: -1.2px;
  margin: 0 0 18px;
  font-weight: 800;
}

.hero p.lede {
  font-size: 19px;
  color: rgba(255, 255, 255, 0.86);
  margin: 0 0 28px;
  max-width: 52ch;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

.store-note {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 14px;
}

/* the phone collage */
.phones {
  position: relative;
  display: flex;
  justify-content: center;
  gap: 18px;
}

.phone {
  border-radius: 30px;
  background: #0d2c27;
  padding: 8px;
  box-shadow: var(--shadow-lg);
  width: 210px;
  flex: 0 0 auto;
}

.phone img { border-radius: 23px; }

.phone.tilt-a { transform: rotate(-4deg) translateY(10px); }
.phone.tilt-b { transform: rotate(3deg); z-index: 2; }

/* --- panels / sections --------------------------------------------------- */

.panel { display: none; }
.panel.is-active { display: block; }

section.band { padding: 76px 0; }
section.band.alt { background: #fff; }
section.band.deep { background: var(--ms-green); color: #fff; }

.section-head { max-width: 720px; margin-bottom: 40px; }

.section-head .kicker {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--nut);
  margin-bottom: 10px;
}

.band.deep .section-head .kicker { color: var(--yellow); }

h2 {
  font-size: clamp(27px, 3vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.6px;
  margin: 0 0 14px;
  font-weight: 800;
}

h3 {
  font-size: 21px;
  margin: 0 0 8px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

p { margin: 0 0 14px; }

.muted { color: var(--muted); }
.band.deep .muted { color: rgba(255, 255, 255, 0.72); }

/* a feature: prose on one side, a phone on the other */
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  margin-bottom: 72px;
}

.feature:last-child { margin-bottom: 0; }
.feature.flip .feature-media { order: -1; }

.feature-media {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.feature-media .phone { width: 240px; }

.feature h2 { margin-bottom: 16px; }

/* the granular bits under a feature */
.bullets { list-style: none; padding: 0; margin: 18px 0 0; }

.bullets li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 11px;
  color: var(--muted);
}

.band.deep .bullets li { color: rgba(255, 255, 255, 0.78); }

.bullets li::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 10px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ocean);
}

.bullets li b { color: var(--ink); font-weight: 700; }
.band.deep .bullets li b { color: #fff; }

/* a grid of smaller capability cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}

.band.deep .card { background: rgba(255, 255, 255, 0.07); }

.card .ico {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 20px;
  margin-bottom: 14px;
  background: var(--lilac);
}

.card h3 { font-size: 18px; }
.card p { font-size: 15px; color: var(--muted); margin: 0; }
.band.deep .card p { color: rgba(255, 255, 255, 0.75); }

/* chips echoing the app's own */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }

.chip {
  background: var(--lilac);
  color: var(--brown);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 14px;
  font-weight: 600;
}

.band.deep .chip { background: rgba(255, 255, 255, 0.14); color: #fff; }

/* a pull quote from the product itself */
.quote {
  border-left: 4px solid var(--yellow);
  padding: 6px 0 6px 20px;
  margin: 22px 0 0;
  font-size: 16px;
  font-style: italic;
  color: var(--muted);
}

.band.deep .quote { color: rgba(255, 255, 255, 0.8); }

/* coming-soon placeholders */
.soon {
  border: 2px dashed rgba(61, 112, 104, 0.4);
  border-radius: var(--radius);
  padding: 28px;
  background: transparent;
}

.soon .tag {
  display: inline-block;
  background: var(--yellow);
  color: var(--brown);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}

/* --- closing call to action --------------------------------------------- */

.cta {
  background: linear-gradient(135deg, var(--ms-green), #1d6357);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 56px 44px;
  text-align: center;
  margin: 0 0 76px;
  box-shadow: var(--shadow-lg);
}

.cta h2 { margin-bottom: 12px; }
.cta p { color: rgba(255, 255, 255, 0.82); max-width: 56ch; margin: 0 auto 26px; }
.cta .hero-actions { justify-content: center; }

footer {
  background: var(--brown);
  color: rgba(255, 255, 255, 0.72);
  padding: 40px 0;
  font-size: 15px;
}

footer { padding: 56px 0 0; }

/* Four columns on a desktop, two on a tablet, one on a phone — the same
   shape the garden user webapp's footer takes. */
.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 36px;
  padding-bottom: 44px;
}

footer .brand { color: #fff; }
footer .lang { margin-top: 18px; display: inline-flex; }

.footer-head {
  margin: 0 0 14px;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-tag { margin: 14px 0 0; max-width: 34ch; }
.footer-head + .footer-tag { margin-top: 0; }

.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-links a { color: inherit; text-decoration: none; }
.footer-links a:hover { color: #fff; text-decoration: underline; }

footer .btn { margin-top: 16px; }

.footer-base { border-top: 1px solid rgba(255, 255, 255, 0.14); }
.footer-base-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  padding-top: 20px;
  padding-bottom: 20px;
  font-size: 14px;
}
.footer-base-row b { color: #fff; }

/* --- responsive ---------------------------------------------------------- */

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px; }
  .hero-grid, .feature { grid-template-columns: 1fr; gap: 36px; }
  .feature.flip .feature-media { order: 0; }
  .hero { padding: 48px 0 60px; }
  section.band { padding: 56px 0; }
  .phone { width: 180px; }
  .feature-media .phone { width: 200px; }
  .cta { padding: 40px 24px; }
}

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
  .header-row { flex-wrap: wrap; gap: 12px; }
  .header-spacer { display: none; }
  .tabs { order: 3; width: 100%; justify-content: center; }
  .header-row .btn { display: none; }
}

/* A linked section stops below the sticky header, not behind it */
section[id] { scroll-margin-top: 88px; }

/* --- screenshots of the real thing --------------------------------------- */

/* A browser frame around a screenshot, so a picture of the website reads as
   the website rather than as an illustration of one. */
.shot {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: #0d2c27;
  box-shadow: var(--shadow-lg);
  max-width: 100%;
  flex: 1 1 420px;
}

.shot-bar {
  display: flex;
  gap: 6px;
  padding: 10px 12px;
  background: #0d2c27;
}

.shot-bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
}

.shot img { display: block; width: 100%; height: auto; }

/* The hero pairs the website with the app, one leaning on the other */
.hero-media { position: relative; }
.hero-media .shot-hero { max-width: 560px; margin-left: auto; }

.phone-inset {
  position: absolute;
  right: -6px;
  bottom: -38px;
  width: 148px;
  border-radius: 22px;
  padding: 6px;
}

.phone-inset img { border-radius: 17px; }

/* The same screen on two screens: the phone leans on the corner of the desktop
   shot rather than queueing underneath it, which is what a plain flex wrap did
   and it read as a mistake. */
.feature-media.pair {
  position: relative;
  display: block;
  padding-bottom: 26px;
  padding-right: 42px;
}

.feature-media.pair .shot { flex: none; width: 100%; }

.feature-media.pair .phone {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 132px;
  padding: 6px;
  border-radius: 22px;
}

.feature-media.pair .phone img { border-radius: 17px; }

/* --- how a digital garden works ------------------------------------------ */

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: 46px;
}

.step {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 20px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.07);
  position: relative;
}

/* The arrow between one step and the next, drawn rather than written */
.step + .step::before {
  content: "";
  position: absolute;
  left: -13px;
  top: 34px;
  width: 8px;
  height: 8px;
  border-top: 2px solid rgba(255, 255, 255, 0.35);
  border-right: 2px solid rgba(255, 255, 255, 0.35);
  transform: rotate(45deg);
}

.step-icon {
  width: 44px;
  height: 44px;
  color: var(--ocean);
  margin-bottom: 4px;
}

.step-icon svg { width: 100%; height: 100%; }
.step b { font-size: 16px; }
.band.deep .step .muted { color: rgba(255, 255, 255, 0.72); font-size: 14px; }

/* --- the two ways a harvest is shared ------------------------------------ */

.diagram { margin-top: 46px; }
.diagram h3 { margin: 0 0 18px; font-size: 20px; }

.diagram-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.diagram-card {
  background: rgba(255, 255, 255, 0.07);
  border-radius: var(--radius);
  padding: 20px;
}

.diagram-card svg { width: 100%; height: auto; display: block; }
.diagram-card p { margin: 14px 0 0; font-size: 15px; color: rgba(255, 255, 255, 0.82); }

.diagram-card .soil { fill: rgba(255, 255, 255, 0.1); stroke: rgba(255, 255, 255, 0.3); stroke-width: 2; }
.diagram-card .soil.dim { opacity: 0.4; }
.diagram-card .plants circle { fill: var(--ocean); }
.diagram-card .plants.faint circle { fill: rgba(255, 255, 255, 0.28); }
.diagram-card .arrow { stroke: rgba(255, 255, 255, 0.5); stroke-width: 2.4; fill: none; stroke-linecap: round; }
.diagram-card .share rect { fill: var(--ocean); opacity: 0.85; }
.diagram-card .share text { fill: #0d2c27; font-size: 13px; font-weight: 800; text-anchor: middle; }
.diagram-card .brace { stroke: var(--yellow); stroke-width: 3; stroke-linecap: round; }

/* --- everything a garden can do, at a glance ------------------------------ */

/* The overview that opens the garden side. Seven things, two of which do not
   exist yet and say so, each a way into the section that explains it. */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(268px, 1fr));
  gap: 18px;
  margin-top: 44px;
}

.tile {
  position: relative;
  background: var(--card);
  border: 1px solid rgba(61, 112, 104, 0.16);
  border-radius: var(--radius);
  padding: 24px 22px 20px;
  box-shadow: var(--shadow);
}

.tile h3 { margin: 12px 0 8px; font-size: 18px; }
.tile p { margin: 0; font-size: 14.5px; }
.tile-icon { font-size: 26px; line-height: 1; }

/* Not built yet: dashed, quieter, and labelled — an overview that promises
   seven things and ships five is a lie told in a grid */
.tile-soon {
  background: transparent;
  border-style: dashed;
  box-shadow: none;
}

.tile .tag {
  position: absolute;
  top: 18px;
  right: 18px;
  background: var(--yellow);
  color: var(--brown);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 4px 9px;
  border-radius: 999px;
}

.tile-link {
  display: inline-block;
  margin-top: 14px;
  font-weight: 700;
  font-size: 14px;
  color: var(--myrtle);
  text-decoration: none;
}

.tile-link:hover { text-decoration: underline; }

/* --- a service that is not built yet ------------------------------------- */

.soon-wide { max-width: 760px; }
.soon-wide .bullets { margin-top: 14px; }
.soon .also { margin: 18px 0 0; padding-top: 16px; border-top: 1px solid rgba(61, 112, 104, 0.25); }

@media (max-width: 900px) {
  /* Below the two-column break there is room to stand them side by side */
  .feature-media.pair { padding: 0; display: flex; align-items: flex-end; justify-content: center; gap: 16px; }
  .feature-media.pair .shot { width: auto; flex: 1 1 300px; }
  .feature-media.pair .phone { position: static; width: 120px; }
  .steps { grid-template-columns: 1fr 1fr; }
  .step + .step::before { display: none; }
  .diagram-grid { grid-template-columns: 1fr; }
  .phone-inset { position: static; width: 150px; margin: -18px auto 0; }
  .hero-media { display: flex; flex-direction: column; align-items: center; }
  .hero-media .shot-hero { margin: 0; }
}

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

  /* Two phones at 200px each do not fit on a phone, so they were queueing one
     under the other and turning a section into a tower. Half the width each,
     and they stand together the way they are meant to. */
  .feature-media { gap: 12px; flex-wrap: nowrap; }
  .feature-media .phone { width: 48%; min-width: 0; }
  .feature-media.pair { gap: 12px; }
  .feature-media.pair .phone { width: 34%; }
}

/* --- twelve months of a hen, in one drawing -------------------------------- */

/* A photograph every three months is what a garden actually posts; stacked on
   an animal's page they become a time-lapse. This is that idea, drawn rather
   than photographed — nobody should mistake a marketing page for evidence of a
   particular bird. Four stages cross-fade on a loop; the captions beside it are
   the dates the pictures were taken. */

.timelapse-title { font-size: 20px; margin: 46px 0 18px; }

.timelapse {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 28px;
  align-items: center;
  background: var(--card);
  border: 1px solid rgba(61, 112, 104, 0.16);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow);
}

.band.deep .timelapse { background: rgba(255, 255, 255, 0.07); border-color: rgba(255, 255, 255, 0.14); }

.timelapse-stage {
  background: linear-gradient(180deg, #f4efe7 0%, #e8dcc9 100%);
  border-radius: var(--radius);
  padding: 8px;
}

.timelapse-stage svg { width: 100%; height: auto; display: block; }

.timelapse .ground { fill: rgba(41, 23, 17, 0.12); }
.timelapse .body { fill: #d9a441; }
.timelapse .tail { fill: #b9761f; }
.timelapse .comb,
.timelapse .wattle { fill: #c0392b; }
.timelapse .beak { fill: #f0b429; }
.timelapse .eye { fill: #2b1b10; }
.timelapse .leg { stroke: #b9761f; stroke-width: 4; stroke-linecap: round; }
.timelapse .egg { fill: #fdf6e6; stroke: rgba(41, 23, 17, 0.2); }
.timelapse .perch { fill: #8a5a2b; }

/* Each stage holds, then hands over to the next */
.timelapse .chick { opacity: 0; animation: grow-up 12s infinite; }
.timelapse .step-1 { animation-delay: 0s; }
.timelapse .step-2 { animation-delay: 3s; }
.timelapse .step-3 { animation-delay: 6s; }
.timelapse .step-4 { animation-delay: 9s; }

@keyframes grow-up {
  0%, 2% { opacity: 0; }
  4%, 23% { opacity: 1; }
  27%, 100% { opacity: 0; }
}

.timelapse-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.timelapse-steps li {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  align-items: baseline;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(61, 112, 104, 0.16);
}

.band.deep .timelapse-steps li { border-bottom-color: rgba(255, 255, 255, 0.14); }
.timelapse-steps li:last-child { border-bottom: 0; padding-bottom: 0; }
.timelapse-steps b { font-size: 15px; }
.timelapse-steps span { font-size: 14.5px; color: var(--muted); }
.band.deep .timelapse-steps span { color: rgba(255, 255, 255, 0.78); }

.timelapse-note { grid-column: 1 / -1; margin: 4px 0 0; font-size: 14px; }

/* Somebody who asked for less movement gets the grown hen, standing still */
@media (prefers-reduced-motion: reduce) {
  .timelapse .chick { animation: none; opacity: 0; }
  .timelapse .step-4 { opacity: 1; }
}

@media (max-width: 760px) {
  .timelapse { grid-template-columns: 1fr; }
  .timelapse-stage { max-width: 260px; margin: 0 auto; }
}
