/* AC Shift — landing page. Shared tokens and chrome live in styles.css. */

/* ---------- Section scaffolding ---------- */
.home main {
  flex: 1;
}

.section-head {
  max-width: 720px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-title {
  margin: 0;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.12;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.section-lead {
  margin: 16px 0 0;
  color: var(--text-secondary);
  font-size: 18px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 88px;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -20% -10% auto;
  height: 900px;
  background:
    radial-gradient(520px 380px at 78% 30%, rgba(217, 247, 247, 0.95), transparent 70%),
    radial-gradient(560px 420px at 92% 62%, rgba(229, 238, 255, 0.95), transparent 70%),
    radial-gradient(420px 300px at 12% 12%, rgba(229, 238, 255, 0.7), transparent 70%);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(39, 90, 228, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(39, 90, 228, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 70% 40%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 70% 40%, #000 20%, transparent 75%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: center;
  gap: 56px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  padding: 6px 14px 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-sm);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
}

.pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--active-accent);
  box-shadow: 0 0 0 4px var(--active-soft);
}

.hero h1 {
  margin: 0;
  font-size: clamp(40px, 6.2vw, 72px);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.hero-accent {
  display: block;
  color: var(--accent);
  background: linear-gradient(100deg, #2047B7 0%, #275AE4 45%, #00636A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  padding-bottom: 0.06em;
}

.lead {
  max-width: 560px;
  margin: 24px 0 0;
  color: var(--text-secondary);
  font-size: 19px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.hero-actions .btn {
  min-height: 52px;
  padding: 0 26px;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 32px 0 0;
  padding: 0;
  list-style: none;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
}

.hero-points li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero-points li::before {
  content: "";
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--success-soft);
}

.hero-points li {
  position: relative;
}

.hero-points li::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 50%;
  width: 4px;
  height: 8px;
  border: solid var(--success);
  border-width: 0 2px 2px 0;
  transform: translateY(-60%) rotate(45deg);
}

.hero-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.demo-note {
  margin: 18px 0 0;
  color: var(--text-secondary);
  font-size: 13px;
}

/* Entrance */
.hero-copy > *,
.hero-visual .phones {
  animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.hero-copy > :nth-child(2) { animation-delay: 0.05s; }
.hero-copy > :nth-child(3) { animation-delay: 0.1s; }
.hero-copy > :nth-child(4) { animation-delay: 0.15s; }
.hero-copy > :nth-child(5) { animation-delay: 0.2s; }
.hero-visual .phones { animation-delay: 0.12s; }

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Phone frame for real app screenshots ----------
   Screens: /screens/<name>.png, iPhone portrait 1206x2622. */
.phones {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-height: 640px;
}

.phone {
  position: relative;
  flex-shrink: 0;
  width: 290px;
  padding: 10px;
  border-radius: 52px;
  background: linear-gradient(145deg, #2A3B55, #13233B 40%, #0C1829);
  box-shadow: var(--shadow-lg), inset 0 0 0 1.5px rgba(255, 255, 255, 0.08);
}

.phone::before {
  content: "";
  position: absolute;
  right: -3px;
  top: 22%;
  width: 3px;
  height: 64px;
  border-radius: 0 3px 3px 0;
  background: #1D2E47;
}

.phone-screen {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1206 / 2622;
  border-radius: 42px;
  /* Placeholder look while a screenshot is loading or missing */
  background: linear-gradient(160deg, var(--active-start), var(--active-end));
}

.phone-screen picture {
  display: block;
  width: 100%;
  height: 100%;
}

.phone-screen img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  color: transparent;
}

.phone-island {
  position: absolute;
  top: 2.4%;
  left: 50%;
  width: 33%;
  height: 4.2%;
  transform: translateX(-50%);
  border-radius: 999px;
  background: #0A0F18;
  pointer-events: none;
}

.phone--main {
  z-index: 2;
}

.phone--side {
  position: absolute;
  top: 50%;
  width: 232px;
  padding: 8px;
  border-radius: 42px;
  opacity: 0.97;
}

.phone--side .phone-screen {
  border-radius: 34px;
}

.phone--left {
  left: 50%;
  transform: translate(calc(-50% - 168px), -46%) rotate(-7deg);
}

.phone--right {
  left: 50%;
  transform: translate(calc(-50% + 168px), -46%) rotate(7deg);
}

/* Floating chips around the phone */
.float {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px 10px 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(227, 235, 244, 0.9);
  box-shadow: var(--shadow-lg);
  font-size: 13px;
  line-height: 1.35;
  color: var(--text-secondary);
  animation: rise 0.7s 0.35s cubic-bezier(0.2, 0.7, 0.2, 1) both, bob 7s 1.1s ease-in-out infinite;
  z-index: 2;
}

.float strong {
  color: var(--text);
  font-weight: 600;
}

.float--photo {
  left: -24px;
  bottom: 96px;
}

.float--chem {
  right: -16px;
  top: 64px;
  gap: 8px;
  padding: 10px 14px;
  color: var(--text);
  font-size: 14px;
  animation-delay: 0.45s, 2.4s;
}

.chem-k {
  color: var(--active-accent);
}

.chem-sep {
  width: 1px;
  height: 16px;
  background: var(--separator);
}

.float-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
}

.float-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.float-icon--done {
  background: var(--success-soft);
  color: var(--success);
}

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* ---------- Why ---------- */
.why {
  padding: 24px 0 96px;
}

.why-head {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.why .section-title {
  font-size: clamp(30px, 4.4vw, 48px);
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
}

.why-card {
  padding: 24px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid rgba(227, 235, 244, 0.8);
  box-shadow: var(--shadow-sm);
}

.why-role {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--accent-pressed);
  font-size: 15px;
  font-weight: 700;
}

.why-card p {
  margin: 0;
  color: var(--text-secondary);
}

/* ---------- Features ---------- */
.features {
  padding: 96px 0;
  background: var(--surface);
  border-top: 1px solid var(--separator);
  border-bottom: 1px solid var(--separator);
}

.feature-rows {
  display: grid;
  gap: 120px;
}

.feature-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 64px;
}

.feature-row--flip .feature-copy {
  order: 2;
}

.feature-copy {
  max-width: 500px;
}

.feature-label {
  margin: 0 0 10px;
  color: var(--accent-pressed);
  font-size: 15px;
  font-weight: 600;
}

.feature-copy h3 {
  margin: 0 0 14px;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.feature-copy > p:not(.feature-label) {
  margin: 0;
  color: var(--text-secondary);
  font-size: 18px;
}

.feature-points {
  display: grid;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.feature-points li {
  position: relative;
  padding-left: 30px;
  font-weight: 500;
}

.feature-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent-soft);
}

.feature-points li::after {
  content: "";
  position: absolute;
  left: 7.5px;
  top: 7.5px;
  width: 4px;
  height: 8px;
  border: solid var(--accent-pressed);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.feature-media {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 560px;
  padding: 40px 0;
}

.feature-media::before {
  content: "";
  position: absolute;
  inset: 0 4%;
  border-radius: 40px;
  background: linear-gradient(160deg, var(--accent-soft), var(--grouped));
  z-index: 0;
}

.feature-row:nth-child(3) .feature-media::before {
  background: linear-gradient(200deg, var(--active-start), var(--active-soft) 45%, var(--active-end));
}

.feature-row:nth-child(4) .feature-media::before {
  background: linear-gradient(160deg, var(--planned-soft), #EEF0FF);
}

.feature-media .phone {
  z-index: 1;
  width: 270px;
}

.feature-media .phone-screen {
  border-radius: 40px;
}

/* Two screens: front phone plus a second one behind it */
.feature-media--duo .phone--front {
  z-index: 2;
  transform: translateX(-64px);
}

.feature-media--duo .phone--back {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  width: 236px;
  padding: 8px;
  border-radius: 42px;
  transform: translate(-8px, -47%) rotate(6deg);
}

.feature-media--duo .phone--back .phone-screen {
  border-radius: 34px;
}

.feature-row--flip .feature-media--duo .phone--front {
  transform: translateX(64px);
}

.feature-row--flip .feature-media--duo .phone--back {
  transform: translate(calc(-100% + 8px), -47%) rotate(-6deg);
}

/* Close-up of a screen region */
.screen-crop {
  position: relative;
  z-index: 1;
  width: 360px;
  max-width: 100%;
  overflow: hidden;
  border-radius: 30px;
  border: 1px solid rgba(227, 235, 244, 0.9);
  background: var(--bg);
  box-shadow: var(--shadow-lg);
  transform: rotate(-2deg);
}

.screen-crop img {
  display: block;
  width: 100%;
  height: auto;
}

.feature-row:nth-child(1) .feature-media::before {
  background: linear-gradient(135deg, var(--active-start), var(--active-end));
}

/* ---------- How it works ---------- */
.how {
  padding: 104px 0 96px;
}

.how-steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.how-steps::before {
  content: "";
  position: absolute;
  top: 28px;
  left: 16%;
  right: 16%;
  height: 2px;
  background: repeating-linear-gradient(90deg, rgba(39, 90, 228, 0.35) 0 8px, transparent 8px 16px);
}

.how-step {
  position: relative;
  text-align: center;
  padding: 0 12px;
}

.how-num {
  display: inline-grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin-bottom: 20px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow);
  color: var(--accent-pressed);
  font-size: 18px;
}

.how-step:nth-child(2) .how-num {
  background: linear-gradient(135deg, var(--active-start), var(--active-end));
  color: var(--active-text);
}

.how-step:nth-child(3) .how-num {
  background: var(--success-soft);
  color: var(--success);
}

.how-step h3 {
  margin: 0 0 8px;
  font-size: 21px;
  font-weight: 700;
}

.how-step p {
  max-width: 320px;
  margin: 0 auto;
  color: var(--text-secondary);
}

/* ---------- Who ---------- */
.who {
  padding: 24px 0 104px;
}

.who-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.who-card {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.who-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.who-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 20px;
  border-radius: 14px;
}

.who-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.who-card--clean .who-icon { background: var(--accent-soft); color: var(--accent-pressed); }
.who-card--garden .who-icon { background: var(--success-soft); color: var(--success); }
.who-card--pool .who-icon { background: var(--active-soft); color: var(--active-accent); }

.who-card h3 {
  margin: 0 0 8px;
  font-size: 21px;
  font-weight: 700;
}

.who-card p {
  margin: 0;
  color: var(--text-secondary);
}

.who-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto !important;
  padding-top: 20px;
}

.who-tags span {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--separator);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
}

/* ---------- CTA ---------- */
.cta {
  padding: 0 0 96px;
}

.cta-card {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  align-items: center;
  padding: 64px;
  border-radius: 32px;
  background:
    radial-gradient(600px 300px at 0% 0%, rgba(255, 255, 255, 0.14), transparent 60%),
    linear-gradient(135deg, #275AE4, #2047B7);
  color: #fff;
  box-shadow: 0 30px 60px -30px rgba(32, 71, 183, 0.6);
}

.cta-copy {
  position: relative;
  z-index: 1;
  max-width: 560px;
}

.cta h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.cta p {
  margin: 16px 0 0;
  color: #fff;
  font-size: 18px;
  opacity: 0.95;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  margin-top: 32px;
}

.cta-actions .btn {
  min-height: 52px;
  padding: 0 28px;
}

.cta-mail {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.5);
}

.cta-mail:hover {
  color: #fff;
  text-decoration-color: #fff;
}

.cta :focus-visible {
  outline-color: #fff;
}

/* Brand mark echo: two slanted strokes from the app icon */
.cta-mark {
  position: relative;
  grid-column: 2;
  grid-row: 1;
  width: 260px;
  height: 220px;
  transform: rotate(-16deg);
}

.cta-stroke {
  position: absolute;
  left: 10px;
  width: 230px;
  height: 64px;
  border-radius: 22px 40px 22px 40px;
}

.cta-stroke--top {
  top: 46px;
  background: #F8F5EF;
}

.cta-stroke--bottom {
  top: 120px;
  left: 26px;
  background: #CFD4FF;
}

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .phone--left {
    transform: translate(calc(-50% - 140px), -46%) rotate(-7deg);
  }

  .phone--right {
    transform: translate(calc(-50% + 140px), -46%) rotate(7deg);
  }
}

@media (max-width: 1020px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero-copy {
    text-align: center;
  }

  .lead {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions,
  .hero-points {
    justify-content: center;
  }

  .phone--left {
    transform: translate(calc(-50% - 190px), -46%) rotate(-7deg);
  }

  .phone--right {
    transform: translate(calc(-50% + 190px), -46%) rotate(7deg);
  }

  .float--photo {
    left: calc(50% - 330px);
  }

  .float--chem {
    right: calc(50% - 330px);
  }

  .feature-row,
  .feature-row--flip {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }

  .feature-row--flip .feature-copy {
    order: 0;
  }

  .feature-copy {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
  }

  .feature-points {
    justify-items: center;
  }

  .feature-media {
    max-width: 640px;
    width: 100%;
    margin: 0 auto;
  }

  .feature-rows {
    gap: 88px;
  }
}

@media (max-width: 860px) {
  .why-grid,
  .who-grid {
    grid-template-columns: 1fr;
  }

  .how-steps {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .how-steps::before {
    display: none;
  }

  .cta-card {
    grid-template-columns: 1fr;
    padding: 48px 32px;
  }

  .cta-mark {
    position: absolute;
    right: -70px;
    bottom: -60px;
    opacity: 0.18;
  }
}

@media (max-width: 720px) {
  .phones {
    min-height: 0;
  }

  .phone--side,
  .float {
    display: none;
  }

  .feature-media {
    min-height: 0;
    padding: 28px 16px;
  }

  .feature-media::before {
    inset: 0;
    border-radius: 28px;
  }

  .feature-media .phone {
    width: min(260px, 72vw);
  }

  .feature-media--duo .phone--back {
    display: none;
  }

  .feature-media--duo .phone--front,
  .feature-row--flip .feature-media--duo .phone--front {
    transform: none;
  }

  .screen-crop {
    transform: none;
  }
}

@media (max-width: 600px) {
  .hero {
    padding: 40px 0 64px;
  }

  .lead {
    font-size: 17px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-points {
    gap: 8px 14px;
    font-size: 14px;
  }

  .phone--main {
    width: min(280px, 78vw);
    border-radius: 46px;
  }

  .phone--main .phone-screen {
    border-radius: 37px;
  }

  .section-head {
    margin-bottom: 32px;
  }

  .section-lead,
  .feature-copy > p:not(.feature-label) {
    font-size: 17px;
  }

  .why {
    padding-bottom: 72px;
  }

  .why-grid {
    margin-top: 32px;
  }

  .features,
  .how {
    padding: 72px 0;
  }

  .feature-rows {
    gap: 72px;
  }

  .feature-points {
    justify-items: start;
    text-align: left;
  }

  .who {
    padding-bottom: 72px;
  }

  .cta {
    padding-bottom: 64px;
  }

  .cta-card {
    padding: 40px 22px;
    border-radius: 24px;
  }

  .cta-actions .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-copy > *,
  .hero-visual .phones,
  .float {
    animation: none;
  }

  .who-card:hover {
    transform: none;
  }
}
