/* ============================================================
   Lexo Algorithms — Custom Stylesheet
   Bento Grid | Glassmorphism | PropTech UI
   ============================================================ */

:root {
  --accent:      #A3E635;
  --accent-dark: #84cc16;
  --bg-light:    #F8FAFC;
  --bg-dark:     #0B0F19;
  --widget-dark: #141926;
  --widget-glass:#1E2740;
  --text-light:  #F1F5F9;
  --text-muted:  #94A3B8;
  --border-glass:rgba(163,230,53,0.12);
  --shadow-sm:   0 2px 12px rgba(0,0,0,.06);
  --shadow-md:   0 8px 32px rgba(0,0,0,.12);
  --radius-lg:   1.5rem;
  --radius-xl:   2rem;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  background: var(--bg-light);
  color: #0F172A;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── Typography helpers ─────────────────────────────────── */
.text-accent  { color: var(--accent); }
.text-muted   { color: var(--text-muted); }

/* ── Pill badges ────────────────────────────────────────── */
.pill-badge {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .25rem .75rem;
  border-radius: 9999px;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  background: rgba(163,230,53,.15);
  color: var(--accent-dark);
  border: 1px solid rgba(163,230,53,.3);
}
.pill-badge.dark {
  background: rgba(163,230,53,.12);
  color: var(--accent);
  border-color: rgba(163,230,53,.2);
}

/* ── Bento grid base ────────────────────────────────────── */
.bento-grid {
  display: grid;
  gap: 1rem;
}

/* ── Widget card ────────────────────────────────────────── */
.widget {
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease;
}
.widget:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

.widget-light {
  background: #fff;
  border: 1px solid #E2E8F0;
  box-shadow: var(--shadow-sm);
  color: #0F172A;
}
.widget-dark {
  background: var(--widget-dark);
  border: 1px solid var(--border-glass);
  color: var(--text-light);
}
.widget-accent {
  background: var(--accent);
  color: #0F172A;
}
.widget-glass {
  background: rgba(30,39,64,.7);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(163,230,53,.15);
  color: var(--text-light);
}
.widget-black {
  background: #080C14;
  border: 1px solid #1E293B;
  color: var(--text-light);
}

/* ── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.6rem;
  border-radius: 9999px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: all .2s ease;
  white-space: nowrap;
}
.btn-accent {
  background: var(--accent);
  color: #0B0F19;
}
.btn-accent:hover {
  background: var(--accent-dark);
  box-shadow: 0 0 20px rgba(163,230,53,.4);
  transform: scale(1.03);
}
.btn-outline {
  background: transparent;
  border: 1.5px solid var(--accent);
  color: var(--accent);
}
.btn-outline:hover {
  background: rgba(163,230,53,.1);
}
.btn-dark {
  background: #0B0F19;
  color: var(--text-light);
  border: 1px solid #1E293B;
}
.btn-dark:hover { background: #141926; }

/* ── Progress / meter semantic overrides ───────────────── */
progress {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 99px;
  overflow: hidden;
  border: none;
  background: rgba(163,230,53,.15);
}
progress::-webkit-progress-bar   { background: rgba(163,230,53,.12); border-radius: 99px; }
progress::-webkit-progress-value { background: var(--accent); border-radius: 99px; }
progress::-moz-progress-bar      { background: var(--accent); border-radius: 99px; }

meter {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 99px;
}
meter::-webkit-meter-bar            { background: rgba(163,230,53,.12); border-radius: 99px; border: none; }
meter::-webkit-meter-optimum-value  { background: var(--accent); border-radius: 99px; }

/* ── Details / Summary (FAQ) ────────────────────────────── */
details {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid #E2E8F0;
  transition: box-shadow .2s;
}
details[open] {
  box-shadow: 0 4px 20px rgba(163,230,53,.1);
  border-color: rgba(163,230,53,.35);
}
summary {
  list-style: none;
  cursor: pointer;
  padding: 1.1rem 1.4rem;
  font-weight: 600;
  font-size: .95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  background: #fff;
  color: #0F172A;
  transition: background .15s;
}
summary::-webkit-details-marker { display: none; }
summary:hover { background: #F8FAFC; }
summary .faq-icon {
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  background: rgba(163,230,53,.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-dark);
  font-size: .8rem;
  flex-shrink: 0;
  transition: transform .3s, background .3s;
}
details[open] summary .faq-icon {
  transform: rotate(45deg);
  background: var(--accent);
  color: #0B0F19;
}
.faq-body {
  padding: 1rem 1.4rem 1.25rem;
  background: #fff;
  color: #475569;
  font-size: .9rem;
  line-height: 1.7;
  border-top: 1px solid #F1F5F9;
}

/* Dark FAQ variant */
details.dark-faq {
  border-color: var(--border-glass);
  background: var(--widget-dark);
}
details.dark-faq summary { background: var(--widget-dark); color: var(--text-light); }
details.dark-faq summary:hover { background: var(--widget-glass); }
details.dark-faq .faq-body {
  background: var(--widget-dark);
  color: var(--text-muted);
  border-top-color: rgba(255,255,255,.05);
}

/* ── Fieldset / Legend form styling ─────────────────────── */
fieldset {
  border: 1.5px solid rgba(163,230,53,.3);
  border-radius: var(--radius-xl);
  padding: 2rem;
  background: rgba(255,255,255,.04);
}
legend {
  padding: 0 .75rem;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin-bottom: 1.2rem;
}
.form-group label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: .04em;
  text-transform: uppercase;
}
.form-group input,
.form-group select {
  background: rgba(255,255,255,.06);
  border: 1.5px solid rgba(255,255,255,.1);
  border-radius: .75rem;
  padding: .75rem 1rem;
  color: var(--text-light);
  font-size: .95rem;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
}
.form-group input::placeholder { color: rgba(255,255,255,.3); }
.form-group input:focus,
.form-group select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(163,230,53,.15);
}
.form-group select option { background: #0F172A; color: #fff; }

/* Range slider */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  background: rgba(255,255,255,.12);
  border-radius: 99px;
  outline: none;
  border: none;
  cursor: pointer;
  padding: 0;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px rgba(163,230,53,.5);
  cursor: pointer;
  transition: transform .15s;
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.2); }
input[type="range"]::-moz-range-thumb {
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  cursor: pointer;
}

output {
  display: inline-block;
  font-weight: 700;
  color: var(--accent);
  font-size: 1rem;
}

/* ── Cookie banner ──────────────────────────────────────── */
#cookie-banner {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 9999;
  max-width: 340px;
  width: calc(100% - 2.5rem);
  background: rgba(14,20,36,.92);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-xl);
  padding: 1.25rem 1.4rem;
  box-shadow: 0 8px 40px rgba(0,0,0,.4);
  color: var(--text-light);
  font-size: .85rem;
  transition: opacity .35s ease, transform .35s ease;
}
#cookie-banner.hidden {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}
#cookie-banner p { color: #94A3B8; line-height: 1.5; margin-bottom: .9rem; }
#cookie-banner a { color: var(--accent); text-decoration: underline; }
.cookie-actions { display: flex; gap: .6rem; }
.cookie-actions button {
  flex: 1;
  padding: .55rem;
  border-radius: 9999px;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all .2s;
}
#cookie-accept { background: var(--accent); color: #0B0F19; }
#cookie-accept:hover { background: var(--accent-dark); }
#cookie-decline { background: rgba(255,255,255,.08); color: var(--text-muted); }
#cookie-decline:hover { background: rgba(255,255,255,.14); }

/* ── Header ─────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248,250,252,.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #E2E8F0;
  padding: .9rem 0;
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.site-logo {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -.02em;
  color: #0B0F19;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: .4rem;
}
.logo-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

.site-nav { display: flex; align-items: center; gap: 1.5rem; }
.site-nav a {
  font-size: .88rem;
  font-weight: 500;
  color: #475569;
  text-decoration: none;
  transition: color .2s;
}
.site-nav a:hover { color: #0F172A; }

.nav-cta { display: flex; align-items: center; gap: .75rem; }

/* ── Footer ─────────────────────────────────────────────── */
.site-footer {
  background: #0B0F19;
  color: var(--text-muted);
  padding: 4rem 0 2rem;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.footer-brand p { font-size: .88rem; line-height: 1.7; margin-top: .75rem; max-width: 22ch; }
.footer-col h4 {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: #64748B;
  margin-bottom: 1rem;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: .55rem; }
.footer-col ul a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: .88rem;
  transition: color .2s;
}
.footer-col ul a:hover { color: var(--accent); }
.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  font-size: .85rem;
  margin-bottom: .6rem;
  line-height: 1.5;
}
.footer-contact-icon {
  width: 1.4rem;
  height: 1.4rem;
  flex-shrink: 0;
  margin-top: .1rem;
  color: var(--accent);
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.5rem;
  font-size: .82rem;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-bottom a { color: var(--text-muted); text-decoration: none; }
.footer-bottom a:hover { color: var(--accent); }

/* ── Section wrapper ────────────────────────────────────── */
.section { padding: 5rem 0; }
.section-dark { background: var(--bg-dark); }
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.section-label {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: .75rem;
}
.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1.15;
}
.section-sub {
  color: #64748B;
  margin-top: .75rem;
  font-size: 1rem;
  max-width: 52ch;
  line-height: 1.7;
}
.section-sub.light { color: var(--text-muted); }

/* ── Stat number ─────────────────────────────────────────── */
.stat-value {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 900;
  letter-spacing: -.04em;
  line-height: 1;
}
.stat-label {
  font-size: .8rem;
  font-weight: 500;
  opacity: .65;
  margin-top: .35rem;
}

/* ── Step cards ──────────────────────────────────────────── */
.step-number {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: rgba(163,230,53,.15);
  border: 1.5px solid rgba(163,230,53,.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .78rem;
  font-weight: 800;
  color: var(--accent);
  flex-shrink: 0;
}

/* ── Metric row ──────────────────────────────────────────── */
.metric-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .6rem;
}
.metric-label { font-size: .8rem; font-weight: 500; }
.metric-val   { font-size: .8rem; font-weight: 700; color: var(--accent); }

/* ── Animate on scroll ───────────────────────────────────── */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .6s ease, transform .6s ease;
}
[data-reveal].visible {
  opacity: 1;
  transform: none;
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
@media (max-width: 768px) {
  .site-nav { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .section { padding: 3.5rem 0; }
  fieldset { padding: 1.25rem; }
}
@media (max-width: 480px) {
  .btn { padding: .6rem 1.2rem; font-size: .82rem; }
}
