/* ============================================================
   TeLoArreglo · landing styles
   Plain CSS, no framework. Mobile-first.
   Palette mirrors the iOS app (Assets.xcassets/Colors/).
   ============================================================ */

:root {
  /* Brand — from iOS brandPrimary (#2D5F4E) + brandAccent (#C9762B) */
  --brand:          #2D5F4E;
  --brand-dark:     #1E4537;
  --brand-tint:     #E8F0EC;
  --accent:         #C9762B;
  --accent-dark:    #A85F1F;

  /* Neutrals — from iOS surface / card / ink scale */
  --ink:            #15201C;
  --ink-soft:       #4A554F;
  --ink-muted:      #828A86;
  --line:           rgba(21, 32, 28, 0.10);
  --line-soft:      rgba(21, 32, 28, 0.06);
  --surface:        #F5F4F0;
  --surface-card:   #FFFFFF;

  /* Status — mirror JobStatus colors in the app */
  --status-open:     #DC2A2A;
  --status-assigned: #8C4DD6;
  --status-started:  #2B6FE3;
  --status-done:     #1F8A3F;

  --radius: 14px;
  --shadow: 0 8px 28px rgba(20, 30, 26, 0.08);
}

@media (prefers-color-scheme: dark) {
  :root {
    --brand:        #4A8E78;
    --brand-dark:   #6BAA94;
    --brand-tint:   #234034;
    --accent:       #E59548;
    --accent-dark:  #C9762B;

    --ink:          #F2F2F2;
    --ink-soft:     #B5BAB7;
    --ink-muted:    #767B78;
    --line:         rgba(255, 255, 255, 0.12);
    --line-soft:    rgba(255, 255, 255, 0.08);
    --surface:      #1A1F1C;
    --surface-card: #232826;

    --shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--surface);
}

h1, h2, h3 {
  margin: 0 0 12px;
  color: var(--ink);
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(34px, 6vw, 56px); line-height: 1.05; font-weight: 800; }
h2 { font-size: clamp(26px, 4vw, 36px); font-weight: 700; margin-bottom: 24px; }
h3 { font-size: 18px; font-weight: 700; }

p { margin: 0 0 14px; color: var(--ink-soft); }

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

/* ---- Nav ---- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: block;
  object-fit: cover;
}

.brand-name { font-size: 18px; }

.nav nav { display: flex; gap: 22px; }
.nav nav a { color: var(--ink-soft); font-weight: 500; }
.nav nav a:hover { color: var(--ink); }

@media (max-width: 600px) {
  .nav nav { display: none; }
}

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

.hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
  padding: 32px 24px 60px;
  max-width: 1100px;
  margin: 0 auto;
}

@media (min-width: 860px) {
  .hero { grid-template-columns: 1.1fr 0.9fr; padding-top: 60px; padding-bottom: 100px; }
}

.eyebrow {
  display: inline-block;
  background: var(--brand-tint);
  color: var(--brand);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 18px;
}

.lead {
  font-size: 18px;
  color: var(--ink-soft);
  margin-bottom: 28px;
  max-width: 56ch;
}

/* ---- Form ---- */

.lead-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--surface-card);
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.toggle {
  display: flex;
  gap: 6px;
  padding: 4px;
  margin: 0;
  border: none;
  background: var(--surface);
  border-radius: 999px;
}

.toggle label {
  flex: 1;
  position: relative;
  cursor: pointer;
}

.toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.toggle span {
  display: block;
  text-align: center;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  transition: background .15s ease, color .15s ease;
}

.toggle input:checked + span {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.10);
}

.toggle input:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

@media (min-width: 520px) {
  .field-row { grid-template-columns: 1fr auto; }
}

.lead-form.is-pro #pro-type { grid-column: 1 / -1; }

.lead-form input[type="email"],
.lead-form select {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  font-size: 16px;
  color: var(--ink);
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}

.lead-form select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  padding-right: 40px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%234A554F' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='5 8 10 13 15 8'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px 18px;
}

.lead-form input[type="email"]:focus,
.lead-form select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-tint);
}

.lead-form select[hidden] { display: none; }

#submit-btn {
  height: 48px;
  padding: 0 22px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  background: var(--brand);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background .15s ease, transform .05s ease;
}

#submit-btn:hover { background: var(--brand-dark); }
#submit-btn:active { transform: scale(0.98); }
#submit-btn:disabled { background: var(--ink-muted); cursor: not-allowed; }

.status {
  min-height: 1.2em;
  margin: 0;
  font-size: 14px;
  color: var(--ink-soft);
}
.status.ok  { color: var(--status-done); }
.status.err { color: var(--status-open); }

.legal {
  margin: 0;
  font-size: 12px;
  color: var(--ink-muted);
}

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

.hero-art {
  display: none;
}

@media (min-width: 860px) {
  .hero-art { display: block; }
}

.cat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  transform: rotate(-4deg);
  max-width: 360px;
  margin-left: auto;
}

.cat {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  font-size: 38px;
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  animation: float 5s ease-in-out infinite;
  animation-delay: var(--delay);
}

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

/* ---- How ---- */

.how {
  padding: 60px 24px;
  background: var(--surface-card);
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.how h2 { max-width: 1100px; margin: 0 auto 28px; }

.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  max-width: 1100px;
  margin: 0 auto;
}

@media (min-width: 720px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
}

.step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.step-num {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: var(--brand);
  color: #fff;
  border-radius: 50%;
  font-weight: 700;
  margin-bottom: 12px;
}

.step h3 { margin-bottom: 6px; }
.step p { margin: 0; font-size: 15px; }

.ai-pill {
  display: inline-block;
  margin-top: 8px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--brand-tint);
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.ai-pill::before {
  content: "✨ ";
}

/* ---- Lifecycle (job status) ---- */

.lifecycle {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1100px;
  margin: 28px auto 0;
  padding: 0;
  list-style: none;
}

.lifecycle li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}

.lifecycle .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.lifecycle .dot.open      { background: var(--status-open); }
.lifecycle .dot.assigned  { background: var(--status-assigned); }
.lifecycle .dot.started   { background: var(--status-started); }
.lifecycle .dot.done      { background: var(--status-done); }

/* ---- Pros ---- */

.pros {
  padding: 60px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

.trades {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}

.trades li {
  background: var(--surface-card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 14px;
  color: var(--ink);
}

/* ---- FAQ ---- */

.faq {
  padding: 60px 24px 80px;
  max-width: 760px;
  margin: 0 auto;
}

details {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
}

details summary {
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--ink);
}

details summary::after {
  content: "+";
  font-size: 22px;
  color: var(--ink-muted);
  margin-left: 12px;
}

details[open] summary::after { content: "−"; }

details p {
  margin-top: 10px;
  font-size: 15px;
}

/* ---- Footer ---- */

.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 24px;
  border-top: 1px solid var(--line);
  color: var(--ink-muted);
  font-size: 13px;
  max-width: 1100px;
  margin: 0 auto;
}

.footer .links { display: flex; gap: 18px; }
.footer .links a { color: var(--ink-muted); }
.footer .links a:hover { color: var(--ink); }
