/* =====================================================================
   Building Tasks — public home page
   ===================================================================== */

:root {
  --bg: #f7f7fc;
  --surface: #ffffff;
  --text: #0e0f1a;
  --muted: #5d6175;
  --border: rgba(14, 15, 26, .08);
  --brand: #5b54f5;
  --brand-2: #3d35d8;
  --brand-soft: #edecff;
  --mint: #2fe6b0;
  --sky: #14b8ff;
  --glass: rgba(255, 255, 255, .62);
  --glass-border: rgba(255, 255, 255, .8);
  --shadow: 0 30px 80px -30px rgba(61, 53, 216, .45);
  --radius: 28px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a0a12;
    --surface: #15151f;
    --text: #f3f3fa;
    --muted: #a3a6b8;
    --border: rgba(255, 255, 255, .09);
    --brand: #8d88ff;
    --brand-soft: #232048;
    --glass: rgba(30, 30, 46, .55);
    --glass-border: rgba(255, 255, 255, .12);
    --shadow: 0 30px 80px -30px rgba(0, 0, 0, .8);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.55 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 {
  font-family: -apple-system-ui-rounded, ui-rounded, "SF Pro Rounded", -apple-system, sans-serif;
  letter-spacing: -.02em;
  line-height: 1.08;
  margin: 0 0 .4em;
}
h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 4vw, 3rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }

.center { text-align: center; }
.narrow { max-width: 620px; margin-left: auto; margin-right: auto; }
.small { font-size: .95rem; color: var(--muted); }

.eyebrow {
  margin: 0 0 12px;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brand);
}

.lead { font-size: 1.2rem; color: var(--muted); max-width: 560px; }

.grad {
  background: linear-gradient(100deg, var(--brand) 10%, var(--sky) 55%, var(--mint) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- Buttons ------------------------------------------------------ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 650;
  font-size: 1rem;
  white-space: nowrap;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: scale(.98); }
.btn-lg { min-height: 56px; padding: 0 28px; font-size: 1.05rem; }

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, #7c78ff, #5b54f5 50%, #3d35d8);
  box-shadow: 0 10px 30px -10px rgba(91, 84, 245, .8), inset 0 1px 0 rgba(255, 255, 255, .35);
}

.btn-glass {
  color: var(--text);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 8px 24px -14px rgba(14, 15, 26, .35), inset 0 1px 0 rgba(255, 255, 255, .5);
}

.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 22px 0 18px;
  border-radius: 14px;
  background: #000;
  color: #fff;
  font-weight: 650;
  font-size: 1.2rem;
  line-height: 1.05;
  border: 1px solid rgba(255, 255, 255, .18);
  transition: transform .15s ease;
}
.store-btn:hover { text-decoration: none; transform: translateY(-1px); }
.store-btn svg { width: 22px; height: 26px; }
.store-btn small { display: block; font-size: .68rem; font-weight: 500; opacity: .85; }
.store-btn.is-soon { opacity: .8; cursor: default; }
.store-btn-lg { min-height: 60px; font-size: 1.35rem; }

/* ---- Navigation --------------------------------------------------- */

.nav {
  position: sticky;
  top: 12px;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 20px;
  max-width: 1120px;
  margin: 12px auto 0;
  padding: 8px 8px 8px 16px;
  border-radius: 999px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 10px 40px -20px rgba(14, 15, 26, .35);
}
.nav-brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 750; }
.nav-brand:hover { text-decoration: none; }
.nav-brand img { border-radius: 9px; }
.nav-links { display: flex; gap: 22px; margin-left: auto; }
.nav-links a { color: var(--muted); font-weight: 550; font-size: .95rem; }
.nav-links a:hover { color: var(--text); text-decoration: none; }

/* ---- Hero --------------------------------------------------------- */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 40px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 90px 24px 60px;
}

.hero-bg {
  position: absolute;
  inset: -140px -30vw 0;
  z-index: -1;
  background:
    radial-gradient(40% 50% at 75% 35%, rgba(20, 184, 255, .32), transparent 70%),
    radial-gradient(35% 45% at 90% 70%, rgba(47, 230, 176, .25), transparent 70%),
    radial-gradient(45% 55% at 60% 20%, rgba(91, 84, 245, .35), transparent 70%);
  filter: blur(10px);
}

.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 30px 0 14px; }

.hero-phones { position: relative; height: 620px; }
.hero-phones .phone { position: absolute; width: 270px; }
.phone-front { right: 40px; top: 10px; transform: rotate(3deg); z-index: 2; }
.phone-back { right: 230px; top: 70px; transform: rotate(-7deg) scale(.92); opacity: .95; }

.phone {
  padding: 9px;
  border-radius: 46px;
  background: linear-gradient(160deg, #2b2b38, #0b0b12);
  box-shadow: var(--shadow), inset 0 0 0 1px rgba(255, 255, 255, .12);
}
.phone img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 37px;
}

/* ---- Sections ----------------------------------------------------- */

.section { max-width: 1120px; margin: 0 auto; padding: 90px 24px; }

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 46px;
}
.feature {
  padding: 26px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform .2s ease, box-shadow .2s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: 0 20px 50px -30px rgba(61, 53, 216, .5); }
.feature p { margin: 0; color: var(--muted); }
.feature-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 18px;
  border-radius: 15px;
  color: #fff;
  background: linear-gradient(135deg, #7c78ff, #5b54f5);
  box-shadow: 0 10px 24px -10px rgba(91, 84, 245, .8);
}
.feature:nth-child(3n+2) .feature-icon { background: linear-gradient(135deg, #38c9ff, #0e8fe0); box-shadow: 0 10px 24px -10px rgba(20, 184, 255, .8); }
.feature:nth-child(3n) .feature-icon { background: linear-gradient(135deg, #43efbd, #12b98a); box-shadow: 0 10px 24px -10px rgba(47, 230, 176, .8); }
.feature-icon svg { width: 24px; height: 24px; }

.screens-section { max-width: none; padding-left: 0; padding-right: 0; }
.screens-section h2, .screens-section .eyebrow, .screens-section .lead { padding: 0 24px; }
.screens {
  display: flex;
  gap: 28px;
  margin-top: 40px;
  padding: 20px max(24px, calc((100vw - 1120px) / 2)) 40px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.screens::-webkit-scrollbar { display: none; }
.screen { flex: 0 0 250px; margin: 0; scroll-snap-align: center; text-align: center; }
.screen figcaption { margin-top: 18px; }
.screen figcaption strong { display: block; font-size: 1.05rem; }
.screen figcaption span { color: var(--muted); font-size: .95rem; }

.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.duo-card {
  padding: 34px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
}
.duo-card:first-child { background: linear-gradient(160deg, var(--brand-soft), var(--surface) 70%); }
.duo-card ul { margin: 14px 0 0; padding: 0; list-style: none; }
.duo-card li { position: relative; padding: 8px 0 8px 32px; color: var(--muted); }
.duo-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--mint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 13px no-repeat;
}

.web-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 50px;
  border-radius: 36px;
  color: #fff;
  background:
    radial-gradient(60% 90% at 90% 10%, rgba(20, 184, 255, .55), transparent 60%),
    radial-gradient(50% 80% at 10% 100%, rgba(47, 230, 176, .35), transparent 60%),
    linear-gradient(135deg, #6a65ff, #4a42e6 50%, #2e269f);
  box-shadow: var(--shadow);
}
.web-band .eyebrow { color: rgba(255, 255, 255, .8); }
.web-band .lead { color: rgba(255, 255, 255, .85); }
.web-band .btn-primary { background: #fff; color: #3d35d8; box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .5); }
.web-band .btn-glass { color: #fff; background: rgba(255, 255, 255, .14); border-color: rgba(255, 255, 255, .3); }
.web-actions { display: flex; flex-direction: column; gap: 12px; flex-shrink: 0; }

.final {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 40px 24px 110px;
  text-align: center;
}
.final img { border-radius: 22px; filter: drop-shadow(0 18px 30px rgba(91, 84, 245, .45)); margin-bottom: 10px; }

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 24px 40px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: .92rem;
}
.footer nav { display: flex; gap: 20px; }
.footer a { color: var(--muted); }

/* ---- Small screens ------------------------------------------------ */

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 60px; text-align: center; }
  .hero .lead { margin-left: auto; margin-right: auto; }
  .cta-row { justify-content: center; }
  .hero-phones { height: 470px; max-width: 420px; width: 100%; margin: 0 auto; }
  .hero-phones .phone { width: 210px; }
  .phone-front { right: 30px; }
  .phone-back { right: auto; left: 20px; }
  .features { grid-template-columns: 1fr 1fr; }
  .duo { grid-template-columns: 1fr; }
  .web-band { flex-direction: column; align-items: flex-start; padding: 34px 26px; }
  .web-actions { width: 100%; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .nav { margin: 10px 12px 0; padding-left: 12px; }
  .nav-links { display: none; }
  .nav .btn { margin-left: auto; min-height: 42px; padding: 0 16px; }
  .nav-brand span { font-size: .95rem; }
  .hero { padding: 44px 16px 30px; }
  .hero-phones { height: 400px; }
  .hero-phones .phone { width: 180px; border-radius: 34px; padding: 7px; }
  .hero-phones .phone img { border-radius: 28px; }
  .phone-front { right: 8%; }
  .phone-back { left: 8%; }
  .section { padding: 60px 16px; }
  .features { grid-template-columns: 1fr; }
  .screen { flex-basis: 220px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
