:root {
  --spruce: #153f35;
  --spruce-2: #235f50;
  --blue: #8fb8c8;
  --gold: #dca32d;
  --gold-soft: #f4d889;
  --paper: #f7f4ec;
  --paper-2: #ece7da;
  --ink: #17211e;
  --muted: #5e6a65;
  --line: rgba(23, 33, 30, 0.14);
  --white: #ffffff;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 72px);
  background: rgba(247, 244, 236, 0.9);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-weight: 800;
  font-size: 1.02rem;
}

.brand[aria-disabled="true"] {
  cursor: default;
}

.brand img {
  display: block;
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(21, 63, 53, 0.16);
}

.nav-links {
  display: flex;
  gap: clamp(14px, 3vw, 30px);
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.nav-links a {
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--spruce);
}

main {
  overflow: hidden;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(360px, 0.72fr);
  align-items: center;
  gap: clamp(34px, 7vw, 96px);
  padding: clamp(26px, 4vw, 42px) clamp(20px, 5vw, 72px) clamp(24px, 3vw, 34px);
  background:
    radial-gradient(circle at 78% 22%, rgba(143, 184, 200, 0.46), transparent 34%),
    linear-gradient(135deg, var(--paper), #fffaf0 48%, #edf5f2);
}

.hero-copy {
  max-width: 760px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(4.1rem, 8.7vw, 7.7rem);
  line-height: 0.9;
  letter-spacing: 0;
  color: var(--spruce);
}

.hero-lede {
  max-width: 660px;
  margin-bottom: 20px;
  font-size: clamp(1.45rem, 2.2vw, 1.9rem);
  line-height: 1.12;
  font-weight: 800;
}

.hero-copy p:not(.hero-lede) {
  max-width: 620px;
  color: var(--muted);
  font-size: 1.1rem;
}

.download-panel {
  position: relative;
  display: grid;
  gap: 20px;
  padding: clamp(20px, 3vw, 28px);
  background: var(--spruce);
  color: var(--white);
  border-radius: 8px;
  box-shadow: 0 26px 70px rgba(21, 63, 53, 0.28);
}

.download-panel__top {
  display: flex;
  justify-content: space-between;
  gap: 20px;
}

.download-label {
  margin-bottom: 2px;
  color: var(--gold-soft);
  font-size: 0.84rem;
  font-weight: 800;
  text-transform: uppercase;
}

.download-panel h2 {
  margin-bottom: 0;
  font-size: clamp(2rem, 3.4vw, 2.75rem);
  line-height: 1;
}

.free-badge {
  align-self: start;
  padding: 8px 12px;
  color: var(--spruce);
  background: var(--gold-soft);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
}

.app-store-button {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 78px;
  padding: 14px 18px;
  text-decoration: none;
  color: var(--ink);
  background: var(--white);
  border: 0;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.app-store-button strong,
.app-store-button small {
  display: block;
}

.app-store-button strong {
  font-size: 1.4rem;
  line-height: 1.05;
}

.app-store-button small {
  margin-top: 3px;
  color: var(--muted);
  font-weight: 700;
}

.app-store-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--white);
  flex: 0 0 auto;
}

.app-store-icon svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

.download-note {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.98rem;
}

.download-highlights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.download-highlights span {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 12px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.09);
  font-size: 0.86rem;
  font-weight: 900;
}

.section-heading {
  max-width: 760px;
}

.section-heading h2,
.free-section h2,
.donation-section h2 {
  margin-bottom: 12px;
  color: var(--spruce);
  font-size: clamp(2.3rem, 5vw, 4.6rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.section-heading p,
.free-section p,
.donation-section p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.story-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.55fr) minmax(0, 0.8fr);
  gap: clamp(28px, 6vw, 80px);
  padding: clamp(70px, 10vw, 128px) clamp(20px, 5vw, 72px);
  background: var(--white);
}

.story-copy {
  display: grid;
  gap: 22px;
  max-width: 760px;
}

.story-copy p {
  margin-bottom: 0;
  color: #27342f;
  font-size: clamp(1.16rem, 2vw, 1.48rem);
  line-height: 1.48;
}

.feature-band {
  padding: clamp(70px, 10vw, 126px) clamp(20px, 5vw, 72px);
  background: linear-gradient(180deg, #edf5f2, var(--paper));
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 36px;
}

.feature-grid article {
  min-height: 230px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-bottom: 26px;
  border-radius: 999px;
  background: var(--spruce);
  color: var(--white);
  font-weight: 900;
}

.feature-grid h3 {
  margin-bottom: 10px;
  font-size: 1.2rem;
}

.feature-grid p {
  margin-bottom: 0;
  color: var(--muted);
}

.coffee-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 14px 18px;
  text-decoration: none;
  color: var(--ink);
  background: var(--gold-soft);
  border-radius: 8px;
  font-weight: 900;
  white-space: nowrap;
}

.donation-section {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(260px, 360px);
  align-items: center;
  gap: clamp(32px, 7vw, 96px);
  padding: clamp(70px, 10vw, 128px) clamp(20px, 5vw, 72px);
  background: var(--spruce);
}

.donation-section h2,
.donation-section p {
  color: var(--white);
}

.donation-section p {
  max-width: 740px;
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.78);
}

.qr-card {
  display: block;
  padding: 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 20px 48px rgba(21, 63, 53, 0.12);
}

.qr-card img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 26px clamp(20px, 5vw, 72px);
  color: rgba(255, 255, 255, 0.7);
  background: #0d2721;
  font-size: 0.94rem;
}

.site-footer span:first-child {
  color: var(--white);
  font-weight: 800;
}

.auth-callback {
  min-height: 100vh;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  padding: 32px;
  text-align: center;
  background: var(--paper);
}

.auth-callback h1 {
  margin: 0;
  font-size: clamp(2.5rem, 10vw, 5rem);
  color: var(--green);
}

.auth-callback p {
  max-width: 32rem;
  margin: 0;
  color: var(--muted);
  font-size: 1.15rem;
}

.primary-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 8px;
  background: var(--green);
  color: white;
  font-weight: 800;
  text-decoration: none;
}

/* Auth pages (password reset, etc.) — centered card on the paper canvas,
   themed to match the marketing site rather than the bare browser
   defaults the page was falling back to. */
.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  align-content: center;
  padding: clamp(24px, 6vw, 64px) 20px;
  background:
    radial-gradient(circle at 80% 12%, rgba(143, 184, 200, 0.32), transparent 42%),
    linear-gradient(135deg, var(--paper), #fffaf0 52%, #edf5f2);
}

.auth-shell {
  display: flex;
  flex-direction: column;
  gap: 22px;
  width: 100%;
  max-width: 440px;
}

.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--spruce);
}

.auth-brand img {
  display: block;
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(21, 63, 53, 0.16);
}

.auth-panel {
  display: grid;
  gap: 16px;
  padding: clamp(24px, 5vw, 36px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 26px 70px rgba(21, 63, 53, 0.12);
}

.auth-kicker {
  margin: 0;
  color: var(--spruce-2);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-panel h1 {
  margin: 0;
  font-size: clamp(1.9rem, 5vw, 2.5rem);
  line-height: 1.05;
  color: var(--spruce);
}

.auth-intro {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.auth-form {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.auth-form label {
  font-weight: 700;
  font-size: 0.92rem;
}

.auth-form label + input {
  margin-bottom: 12px;
}

.auth-form input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 1rem;
}

.auth-form input:focus {
  outline: none;
  border-color: var(--spruce-2);
  box-shadow: 0 0 0 3px rgba(35, 95, 80, 0.18);
}

.auth-form input:disabled {
  opacity: 0.55;
}

.auth-form button {
  min-height: 50px;
  margin-top: 4px;
  color: var(--white);
  background: var(--spruce);
  border: 0;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  transition: opacity 120ms ease, transform 80ms ease;
}

.auth-form button:hover:not(:disabled) {
  background: var(--spruce-2);
}

.auth-form button:active:not(:disabled) {
  transform: scale(0.99);
}

.auth-form button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-status {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  /* Server password-policy errors list the required character classes as one
     long comma-joined, space-less token (e.g. "abc...,ABC...,012...,!@#..."),
     which has no normal break opportunity and ran off the right edge, cut off
     with no way to scroll. Allow breaking anywhere so it wraps to the panel. */
  overflow-wrap: anywhere;
}

.auth-status[data-tone="error"] {
  color: #b3261e;
}

.auth-status[data-tone="success"] {
  color: var(--spruce-2);
}

.auth-home-link {
  justify-self: start;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.95rem;
}

.getting-started {
  background: var(--paper);
}

.gs-hero {
  min-height: calc(100vh - 82px);
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(360px, 0.7fr);
  align-items: center;
  gap: clamp(34px, 7vw, 92px);
  padding: clamp(38px, 7vw, 88px) clamp(20px, 5vw, 72px);
  background:
    radial-gradient(circle at 82% 16%, rgba(220, 163, 45, 0.24), transparent 28%),
    radial-gradient(circle at 62% 78%, rgba(143, 184, 200, 0.28), transparent 34%),
    linear-gradient(135deg, var(--paper), #fffaf0 52%, #edf5f2);
}

.gs-hero h1 {
  max-width: 790px;
  margin-bottom: 24px;
  font-size: clamp(3.6rem, 7.8vw, 7.2rem);
  line-height: 0.92;
}

.gs-lede {
  max-width: 690px;
  margin-bottom: 28px;
  color: #27342f;
  font-size: clamp(1.25rem, 2vw, 1.72rem);
  line-height: 1.24;
  font-weight: 750;
}

.gs-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.gs-free-note {
  max-width: 620px;
  margin-top: 14px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
  font-weight: 650;
}

.gs-primary,
.gs-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 15px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 900;
}

.gs-primary {
  color: var(--white);
  background: var(--spruce);
}

.gs-primary:hover {
  background: var(--spruce-2);
}

.gs-secondary {
  color: var(--spruce);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--line);
}

.flow-stage {
  position: relative;
  display: grid;
  gap: 22px;
  align-self: center;
  padding: clamp(22px, 3vw, 34px);
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.88), rgba(247, 244, 236, 0.95)),
    var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 26px 70px rgba(21, 63, 53, 0.18);
}

.flow-stage::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 8px;
  background:
    radial-gradient(circle at 82% 16%, rgba(244, 216, 137, 0.28), transparent 34%),
    radial-gradient(circle at 20% 86%, rgba(143, 184, 200, 0.2), transparent 34%);
  pointer-events: none;
}

.flow-stage__intro,
.flow-map {
  position: relative;
  z-index: 1;
}

.flow-stage__intro {
  display: grid;
  gap: 6px;
  max-width: 440px;
}

.flow-stage__intro strong {
  color: var(--spruce);
  font-size: clamp(1.5rem, 2.4vw, 2.15rem);
  line-height: 1.02;
}

.flow-stage__intro span {
  color: var(--muted);
  font-weight: 750;
}

.flow-map {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(150px, 185px);
  align-items: center;
  gap: clamp(16px, 2vw, 22px);
}

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

.flow-steps::before,
.flow-steps::after {
  content: "";
  position: absolute;
  top: 26px;
  bottom: 26px;
  left: 26px;
  width: 3px;
  border-radius: 999px;
}

.flow-steps::before {
  background: rgba(21, 63, 53, 0.12);
}

.flow-steps::after {
  transform-origin: top;
  background: linear-gradient(180deg, var(--spruce), var(--gold), var(--spruce-2));
  animation: flowPath 16s ease-in-out infinite;
}

.flow-steps li {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 12px;
  min-height: 78px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(23, 33, 30, 0.1);
  border-radius: 8px;
  box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
  animation: flowCardOne 16s ease-in-out infinite;
}

.flow-steps li:nth-child(2) {
  animation-name: flowCardTwo;
}

.flow-steps li:nth-child(3) {
  animation-name: flowCardThree;
}

.flow-steps li:nth-child(4) {
  animation-name: flowCardFour;
}

.flow-step__number {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  color: var(--white);
  background: var(--spruce);
  border-radius: 999px;
  font-weight: 950;
  box-shadow: 0 0 0 6px var(--paper);
}

.flow-steps strong {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-size: 0.98rem;
  line-height: 1.1;
}

.flow-steps p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 650;
}

.flow-phone {
  position: relative;
  justify-self: center;
  width: min(100%, 185px);
  aspect-ratio: 1206 / 2622;
  background: #10140f;
  border: 8px solid #10140f;
  border-radius: 28px;
  box-shadow: 0 24px 64px rgba(21, 63, 53, 0.24);
}

.flow-phone__screen {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 20px;
  opacity: 0;
  transform: scale(0.985);
  animation: flowScreenOne 16s ease-in-out infinite;
}

.flow-screen-2 {
  animation-name: flowScreenTwo;
}

.flow-screen-3 {
  animation-name: flowScreenThree;
}

.flow-screen-4 {
  animation-name: flowScreenFour;
}

.gs-proof {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border-block: 1px solid var(--line);
}

.gs-proof article {
  display: grid;
  gap: 8px;
  padding: clamp(24px, 4vw, 42px);
  background: var(--white);
}

.gs-proof strong {
  color: var(--spruce);
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  line-height: 1.05;
}

.gs-proof span {
  color: var(--muted);
  font-weight: 650;
}

.workflow-section {
  padding: clamp(70px, 10vw, 128px) clamp(20px, 5vw, 72px);
  background: var(--white);
}

.workflow-loop {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 38px;
}

.workflow-loop::before {
  content: "";
  position: absolute;
  top: 28px;
  left: 5%;
  right: 5%;
  height: 3px;
  background:
    linear-gradient(90deg, var(--spruce), var(--gold), var(--spruce-2)) 0 0 / 200% 100%;
  opacity: 0.32;
  animation: progressSweep 4.8s linear infinite;
}

.workflow-step {
  position: relative;
  display: grid;
  gap: 10px;
  min-height: 220px;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.workflow-step span {
  z-index: 1;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  color: var(--white);
  background: var(--spruce);
  border: 6px solid var(--white);
  border-radius: 999px;
  font-weight: 950;
}

.workflow-step strong {
  color: var(--ink);
  font-size: 1.22rem;
  line-height: 1.1;
}

.workflow-step p {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 650;
}

.feature-showcase {
  display: grid;
  grid-template-columns: minmax(260px, 0.64fr) minmax(260px, 0.48fr);
  align-items: center;
  gap: clamp(34px, 8vw, 108px);
  padding: clamp(74px, 11vw, 140px) clamp(20px, 5vw, 72px);
  background: linear-gradient(180deg, var(--paper), #fffaf0);
}

.feature-showcase--dark {
  color: var(--white);
  background:
    radial-gradient(circle at 84% 18%, rgba(143, 184, 200, 0.22), transparent 34%),
    var(--spruce);
}

.feature-showcase--gold {
  background:
    radial-gradient(circle at 18% 82%, rgba(35, 95, 80, 0.14), transparent 34%),
    linear-gradient(180deg, #fff8de, var(--paper));
}

.feature-showcase__copy {
  max-width: 760px;
}

.feature-showcase__copy h2 {
  margin-bottom: 18px;
  color: var(--spruce);
  font-size: clamp(2.5rem, 5.4vw, 5.2rem);
  line-height: 0.96;
}

.feature-showcase--dark .feature-showcase__copy h2 {
  color: var(--white);
}

.feature-showcase__copy p {
  max-width: 660px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: clamp(1.14rem, 1.8vw, 1.44rem);
  font-weight: 650;
}

.feature-showcase--dark .feature-showcase__copy p {
  color: rgba(255, 255, 255, 0.78);
}

.benefit-list {
  display: grid;
  gap: 10px;
  max-width: 560px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.benefit-list li {
  display: flex;
  gap: 10px;
  color: #27342f;
  font-weight: 850;
}

.feature-showcase--dark .benefit-list li {
  color: rgba(255, 255, 255, 0.88);
}

.benefit-list li::before {
  content: "";
  width: 10px;
  height: 10px;
  margin-top: 0.48em;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--gold);
}

.phone-frame {
  justify-self: center;
  width: min(100%, 330px);
  margin: 0;
  padding: 10px;
  background: #10140f;
  border-radius: 34px;
  box-shadow: 0 30px 80px rgba(21, 63, 53, 0.26);
}

.phone-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 25px;
}

.gs-cta {
  display: grid;
  place-items: center;
  gap: 18px;
  padding: clamp(70px, 10vw, 132px) 20px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(244, 216, 137, 0.3), transparent 38%),
    var(--white);
}

.gs-cta img {
  border-radius: 18px;
  box-shadow: 0 18px 44px rgba(21, 63, 53, 0.18);
}

.gs-cta h2 {
  max-width: 820px;
  margin-bottom: 0;
  color: var(--spruce);
  font-size: clamp(2.4rem, 5vw, 4.7rem);
  line-height: 0.98;
}

.gs-cta p {
  max-width: 680px;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 1.16rem;
  font-weight: 650;
}

@keyframes flowScreenOne {
  0%,
  22% {
    opacity: 1;
    transform: scale(1);
  }
  28%,
  94% {
    opacity: 0;
    transform: scale(0.985);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes flowScreenTwo {
  0%,
  20%,
  53%,
  100% {
    opacity: 0;
    transform: scale(0.985);
  }
  25%,
  47% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes flowScreenThree {
  0%,
  45%,
  78%,
  100% {
    opacity: 0;
    transform: scale(0.985);
  }
  50%,
  72% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes flowScreenFour {
  0%,
  70% {
    opacity: 0;
    transform: scale(0.985);
  }
  75%,
  96% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0.985);
  }
}

@keyframes flowCardOne {
  0%,
  22% {
    border-color: rgba(21, 63, 53, 0.28);
    box-shadow: 0 16px 34px rgba(21, 63, 53, 0.14);
    transform: translateX(4px);
  }
  28%,
  94% {
    border-color: rgba(23, 33, 30, 0.1);
    box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
    transform: translateX(0);
  }
  100% {
    border-color: rgba(21, 63, 53, 0.28);
    box-shadow: 0 16px 34px rgba(21, 63, 53, 0.14);
    transform: translateX(4px);
  }
}

@keyframes flowCardTwo {
  0%,
  20%,
  53%,
  100% {
    border-color: rgba(23, 33, 30, 0.1);
    box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
    transform: translateX(0);
  }
  25%,
  47% {
    border-color: rgba(21, 63, 53, 0.28);
    box-shadow: 0 16px 34px rgba(21, 63, 53, 0.14);
    transform: translateX(4px);
  }
}

@keyframes flowCardThree {
  0%,
  45%,
  78%,
  100% {
    border-color: rgba(23, 33, 30, 0.1);
    box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
    transform: translateX(0);
  }
  50%,
  72% {
    border-color: rgba(21, 63, 53, 0.28);
    box-shadow: 0 16px 34px rgba(21, 63, 53, 0.14);
    transform: translateX(4px);
  }
}

@keyframes flowCardFour {
  0%,
  70% {
    border-color: rgba(23, 33, 30, 0.1);
    box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
    transform: translateX(0);
  }
  75%,
  96% {
    border-color: rgba(21, 63, 53, 0.28);
    box-shadow: 0 16px 34px rgba(21, 63, 53, 0.14);
    transform: translateX(4px);
  }
  100% {
    border-color: rgba(23, 33, 30, 0.1);
    box-shadow: 0 10px 26px rgba(21, 63, 53, 0.08);
    transform: translateX(0);
  }
}

@keyframes flowPath {
  0%,
  18% {
    transform: scaleY(0.18);
  }
  24%,
  43% {
    transform: scaleY(0.46);
  }
  49%,
  68% {
    transform: scaleY(0.72);
  }
  74%,
  100% {
    transform: scaleY(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .flow-steps::after,
  .flow-steps li,
  .flow-phone__screen,
  .workflow-loop::before {
    animation: none;
  }

  .flow-phone__screen {
    opacity: 0;
    transform: none;
  }

  .flow-phone__screen:first-child {
    opacity: 1;
  }
}

@media (max-width: 980px) {
  .hero,
  .story-section,
  .free-section,
  .donation-section,
  .gs-hero,
  .feature-showcase {
    grid-template-columns: 1fr;
  }

  .download-panel {
    max-width: 560px;
  }

  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workflow-loop {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workflow-loop::before {
    display: none;
  }

  .gs-proof {
    grid-template-columns: 1fr;
  }

  .coffee-link {
    justify-self: start;
  }

  .feature-showcase .phone-frame {
    order: 2;
  }

  .feature-showcase__copy {
    order: 1;
  }
}

@media (max-width: 680px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    padding-block: 16px;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.86rem;
  }

  .hero {
    min-height: auto;
    padding-top: 34px;
  }

  h1 {
    font-size: clamp(3.45rem, 18vw, 5.2rem);
  }

  .hero-lede {
    font-size: 1.35rem;
  }

  .download-panel {
    padding: 20px;
  }

  .download-highlights {
    grid-template-columns: 1fr;
  }

  .download-panel__top {
    flex-direction: column;
  }

  .free-badge {
    justify-self: start;
  }

  .app-store-button {
    min-height: 72px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .feature-grid article {
    min-height: auto;
  }

  .gs-hero {
    min-height: auto;
    padding-top: 38px;
  }

  .gs-hero h1 {
    font-size: clamp(3rem, 16vw, 4.8rem);
  }

  .flow-stage {
    gap: 22px;
    padding: 20px;
  }

  .flow-map {
    grid-template-columns: 1fr;
  }

  .flow-steps li {
    grid-template-columns: 48px 1fr;
    min-height: auto;
  }

  .flow-step__number {
    width: 48px;
    height: 48px;
  }

  .flow-steps::before,
  .flow-steps::after {
    left: 23px;
  }

  .flow-phone {
    width: min(66vw, 220px);
  }

  .workflow-loop {
    grid-template-columns: 1fr;
  }

  .feature-showcase__copy h2,
  .gs-cta h2 {
    font-size: clamp(2.45rem, 12vw, 3.8rem);
  }

  .phone-frame {
    width: min(100%, 290px);
  }

  .site-footer {
    flex-direction: column;
  }
}
