/* ==========================================================================
   REVOR — revor.com.ec
   Style: Warm Architectural Botanical & Terracotta Advisory Studio
   Palette: Parchment (#F5F2EB), Forest Emerald (#16382E), Terracotta (#C86442),
            Sage Tint (#E3EAE6), Charcoal Ink (#1D2421), Soft Sand (#E8E2D5)
   ========================================================================== */

:root {
  --bg: #F5F2EB;
  --paper: #FBF9F5;
  --sage: #E3EAE6;
  --forest: #16382E;
  --forest-2: #1F4C3E;
  --terra: #C86442;
  --terra-dark: #AA4F30;
  --ink: #1D2421;
  --muted: #58645E;
  --line: #DED7C8;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'DM Sans', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }

.wrap {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 26px;
}

/* Header */
.revor-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(245, 242, 235, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  gap: 20px;
}

.brand-revor {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-arch {
  width: 40px;
  height: 44px;
  border-radius: 20px 20px 4px 4px;
  background: var(--forest);
  color: #F5F2EB;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  display: grid;
  place-items: center;
}

.brand-title {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-title strong {
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--forest);
}

.brand-title span {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.nav-menu {
  display: flex;
  gap: 28px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--muted);
}

.nav-menu a:hover { color: var(--forest); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1.5px solid var(--forest);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.18s ease;
}

.btn-forest { background: var(--forest); color: #F5F2EB; }
.btn-forest:hover { background: var(--forest-2); }

.btn-terra { background: var(--terra); border-color: var(--terra); color: #FBF9F5; }
.btn-terra:hover { background: var(--terra-dark); border-color: var(--terra-dark); }

.btn-outline { background: transparent; color: var(--forest); }
.btn-outline:hover { background: var(--sage); }

.bag-num {
  background: var(--terra);
  color: #fff;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 0.76rem;
  display: inline-grid;
  place-items: center;
}

.mob-btn {
  display: none;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  cursor: pointer;
}

/* Hero */
.hero {
  padding: 64px 0 80px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 54px;
  align-items: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terra);
  margin-bottom: 18px;
}

.hero h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.5rem, 4.6vw, 4.2rem);
  line-height: 1.04;
  color: var(--forest);
  margin-bottom: 22px;
}

.hero h1 em {
  font-style: italic;
  color: var(--terra);
}

.hero-lead {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 520px;
  margin-bottom: 30px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 38px;
}

.hero-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.hero-metrics div strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.6rem;
  color: var(--forest);
  line-height: 1.1;
}

.hero-metrics div span {
  font-size: 0.8rem;
  color: var(--muted);
}

.hero-arch-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 220px 220px 24px 24px;
  padding: 18px;
  box-shadow: 0 24px 56px rgba(22, 56, 46, 0.08);
}

.hero-arch-card img {
  width: 100%;
  border-radius: 204px 204px 16px 16px;
}

/* Sections */
.section {
  padding: 78px 0;
}

.section-sage {
  background: var(--sage);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-forest {
  background: var(--forest);
  color: #F5F2EB;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 36px;
}

.section-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1.08;
  color: var(--forest);
}

.section-forest .section-title { color: #F5F2EB; }

/* Filters */
.filter-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin-bottom: 30px;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tab-btn {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.16s ease;
}

.tab-btn:hover { border-color: var(--forest); color: var(--forest); }
.tab-btn.active { background: var(--forest); border-color: var(--forest); color: #F5F2EB; }

.price-sel {
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  font-size: 0.86rem;
  font-weight: 600;
}

/* Service Cards */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.srv-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.srv-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(22, 56, 46, 0.08);
}

.srv-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--terra);
  margin-bottom: 10px;
}

.srv-card h3 {
  font-family: var(--serif);
  font-size: 1.32rem;
  font-weight: 500;
  line-height: 1.22;
  color: var(--forest);
  margin-bottom: 10px;
}

.srv-card p {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 18px;
}

.srv-eta {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--forest);
  background: var(--sage);
  padding: 6px 12px;
  border-radius: 999px;
  display: inline-block;
  margin-bottom: 18px;
}

.srv-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.srv-price {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 600;
  color: var(--forest);
}

/* Pillars */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.pillar-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 28px;
}

.pillar-card span {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.6rem;
  color: #E79B7D;
  display: block;
  margin-bottom: 10px;
}

.pillar-card h3 {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  margin-bottom: 8px;
}

.pillar-card p {
  font-size: 0.9rem;
  color: #D2DDD8;
}

/* Footer */
.revor-footer {
  background: #102921;
  color: #D5E0DB;
  padding: 60px 0 30px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr 1fr 1.3fr;
  gap: 32px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-grid h4 {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: #E79B7D;
  margin-bottom: 14px;
}

.footer-grid a, .footer-grid p {
  display: block;
  font-size: 0.88rem;
  color: #C7D4CE;
  margin-bottom: 8px;
}

.footer-grid a:hover { color: #FFFFFF; }

.footer-bottom {
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.8rem;
  color: #8CA198;
}

/* Drawer */
.drawer-bg {
  position: fixed;
  inset: 0;
  background: rgba(16, 41, 33, 0.45);
  z-index: 140;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}
.drawer-bg.open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(460px, 100%);
  background: var(--paper);
  border-left: 1px solid var(--line);
  z-index: 150;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.25s ease;
}
.drawer.open { transform: translateX(0); }

.drawer-head {
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drawer-head h3 { font-family: var(--serif); font-size: 1.5rem; color: var(--forest); }
.drawer-body { padding: 20px 24px; flex: 1; overflow-y: auto; }

.bag-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-bottom: 10px;
}

.bag-item h4 { font-family: var(--serif); font-size: 1.02rem; color: var(--forest); }
.bag-item small { color: var(--terra); font-weight: 700; }

.qty { display: flex; align-items: center; gap: 6px; }
.qty button { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); cursor: pointer; }

.r-form { display: grid; gap: 12px; margin-top: 18px; }
.r-form label { display: grid; gap: 5px; font-size: 0.78rem; font-weight: 700; color: var(--forest); }
.r-form input, .r-form textarea {
  padding: 10px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 0.9rem;
}

.drawer-foot {
  padding: 18px 24px;
  border-top: 1px solid var(--line);
  background: var(--sage);
  display: flex;
  justify-content: space-between;
  font-family: var(--serif);
  font-size: 1.45rem;
  color: var(--forest);
}

.done-card {
  background: var(--sage);
  border: 1px solid var(--forest);
  border-radius: 16px;
  padding: 20px;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 80px);
  background: var(--forest);
  color: #F5F2EB;
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  z-index: 200;
  transition: transform 0.2s ease;
}
.toast.show { transform: translate(-50%, 0); }

.legal-sheet {
  max-width: 840px;
  margin: 0 auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 40px;
}
.legal-sheet h1 { font-family: var(--serif); font-size: 2.3rem; color: var(--forest); margin-bottom: 14px; }
.legal-sheet h2 { font-family: var(--serif); font-size: 1.35rem; color: var(--terra); margin: 24px 0 8px; }
.legal-sheet p, .legal-sheet li { color: var(--muted); font-size: 0.95rem; margin-bottom: 10px; }
.legal-sheet ul { padding-left: 20px; }

@media (max-width: 1000px) {
  .services-grid, .pillars-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; }
  .nav-menu {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 18px 26px;
    flex-direction: column;
    gap: 14px;
  }
  .nav-menu.open { display: flex; }
  .mob-btn { display: inline-block; }
}

@media (max-width: 580px) {
  .services-grid, .pillars-grid, .footer-grid { grid-template-columns: 1fr; }
}
