/* ============================================
   RESOLVE CASA — DESIGN SYSTEM PREMIUM v2.0
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=DM+Sans:wght@300;400;500;600;700&display=swap');

:root {
  /* Core Palette */
  --ink:        #0D0F14;
  --ink-80:     #1C2030;
  --ink-60:     #2E3348;
  --surface:    #F7F5F0;
  --surface-2:  #EDEBE5;
  --white:      #FFFFFF;

  /* Accent */
  --gold:       #C9A84C;
  --gold-light: #E8C96A;
  --gold-dim:   rgba(201,168,76,0.15);
  --teal:       #2AB5A0;
  --danger:     #D64045;

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'DM Sans', system-ui, sans-serif;

  /* Spacing */
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;

  /* Shadows */
  --shadow-sm:  0 2px 8px rgba(13,15,20,0.08);
  --shadow-md:  0 8px 28px rgba(13,15,20,0.12);
  --shadow-lg:  0 20px 60px rgba(13,15,20,0.18);
  --shadow-gold:0 8px 32px rgba(201,168,76,0.22);

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- Reset & Base ---- */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--surface);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* ---- TOPBAR ---- */
.rc-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(13,15,20,0.96);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(201,168,76,0.2);
  padding: 0 6%;
  height: 68px;
  display: flex; align-items: center; justify-content: space-between;
}
.rc-logo {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--white);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.rc-logo span { color: var(--gold); }
.rc-nav-link {
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.2s var(--ease);
}
.rc-nav-link:hover { color: var(--gold); }

/* ---- HERO DARK ---- */
.rc-hero {
  background: var(--ink);
  position: relative;
  overflow: hidden;
  padding: 80px 6% 140px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  flex-wrap: wrap;
}
.rc-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 65% 40%, rgba(201,168,76,0.08) 0%, transparent 70%),
              radial-gradient(ellipse 40% 40% at 10% 80%, rgba(42,181,160,0.06) 0%, transparent 60%);
  pointer-events: none;
}
.rc-hero::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0; right: 0; height: 80px;
  background: linear-gradient(to top, var(--surface), transparent);
}

.rc-hero-text { flex: 1; min-width: 300px; position: relative; z-index: 2; }
.rc-hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 20px;
}
.rc-hero-eyebrow::before {
  content: ''; width: 28px; height: 1px; background: var(--gold);
}
.rc-hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 20px;
  letter-spacing: -0.03em;
}
.rc-hero-title em { font-style: italic; color: var(--gold-light); }
.rc-hero-subtitle {
  font-size: 1.05rem; font-weight: 300; line-height: 1.7;
  color: rgba(255,255,255,0.6);
  max-width: 480px;
  margin-bottom: 36px;
}

/* Benefits pills */
.rc-benefits { display: flex; flex-wrap: wrap; gap: 10px; }
.rc-benefit-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 100px;
  padding: 8px 16px;
  font-size: 0.82rem; font-weight: 500; color: rgba(255,255,255,0.75);
}
.rc-benefit-pill svg { color: var(--gold); flex-shrink: 0; }

/* Hero image placeholder */
.rc-hero-visual {
  flex: 0 1 420px;
  position: relative; z-index: 2;
}
.rc-hero-img-frame {
  width: 100%; aspect-ratio: 3/4;
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, rgba(255,255,255,0.04) 0%, rgba(255,255,255,0.01) 100%);
  border: 1px solid rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.rc-hero-img-frame::after {
  content: attr(data-label);
  color: rgba(255,255,255,0.2);
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase; text-align: center; padding: 20px;
}

/* ---- CALCULATOR CARD ---- */
.rc-calc-wrap {
  padding: 0 6% 80px;
  margin-top: -90px;
  position: relative; z-index: 10;
  display: flex; justify-content: center;
}
.rc-calc-card {
  background: var(--white);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  padding: 44px;
  width: 100%; max-width: 580px;
  border: 1px solid rgba(13,15,20,0.06);
}
.rc-calc-title {
  font-family: var(--font-display);
  font-size: 1.5rem; font-weight: 700;
  color: var(--ink);
  text-align: center;
  margin-bottom: 8px;
}
.rc-calc-subtitle {
  text-align: center;
  font-size: 0.85rem; color: rgba(13,15,20,0.45);
  margin-bottom: 32px;
}

/* Form elements */
.rc-field { margin-bottom: 20px; }
.rc-label {
  display: block;
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
  color: rgba(13,15,20,0.45);
  margin-bottom: 8px;
}
.rc-select, .rc-input {
  width: 100%; padding: 13px 16px;
  border: 1.5px solid var(--surface-2);
  border-radius: var(--r-md);
  font-family: var(--font-body); font-size: 0.95rem; color: var(--ink);
  background: var(--surface);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  appearance: none; outline: none;
}
.rc-select:focus, .rc-input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-dim);
  background: var(--white);
}

/* Number stepper */
.rc-stepper {
  display: flex; align-items: center;
  border: 1.5px solid var(--surface-2);
  border-radius: var(--r-md);
  overflow: hidden; background: var(--surface);
  transition: border-color 0.2s;
}
.rc-stepper:focus-within { border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim); }
.rc-stepper-btn {
  width: 52px; padding: 13px;
  background: var(--white);
  border: none; cursor: pointer;
  font-size: 1.1rem; font-weight: 600;
  color: var(--ink); transition: background 0.15s, color 0.15s;
}
.rc-stepper-btn:hover { background: var(--gold); color: var(--white); }
.rc-stepper-input {
  flex: 1; border: none; background: transparent;
  text-align: center; font-size: 1rem; font-weight: 600; color: var(--ink);
  padding: 13px 0;
  -moz-appearance: textfield;
}
.rc-stepper-input::-webkit-outer-spin-button,
.rc-stepper-input::-webkit-inner-spin-button { -webkit-appearance: none; }

/* Urgency toggle */
.rc-urgency-box {
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(135deg, rgba(214,64,69,0.04) 0%, rgba(214,64,69,0.08) 100%);
  border: 1.5px solid rgba(214,64,69,0.2);
  border-radius: var(--r-md);
  padding: 16px;
  margin-bottom: 24px;
  cursor: pointer;
}
.rc-urgency-box input[type="checkbox"] {
  width: 18px; height: 18px; accent-color: var(--danger); cursor: pointer; flex-shrink: 0;
}
.rc-urgency-label {
  font-size: 0.9rem; font-weight: 600;
  color: var(--danger);
}

/* Extras grid */
.rc-extras-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
  padding: 18px;
  background: var(--surface);
  border: 1.5px solid var(--surface-2);
  border-radius: var(--r-md);
  margin-bottom: 20px;
}
.rc-extra-item {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.88rem; font-weight: 500; color: var(--ink-60);
  cursor: pointer;
}
.rc-extra-item input { accent-color: var(--gold); width: 16px; height: 16px; cursor: pointer; }

/* Items grid (sofá, etc) */
.rc-items-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
  margin-bottom: 24px;
}
.rc-item-box {
  background: var(--surface); border: 1.5px solid var(--surface-2);
  border-radius: var(--r-md); padding: 14px 10px;
  text-align: center; transition: border-color 0.2s, box-shadow 0.2s;
}
.rc-item-box:focus-within {
  border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-dim);
}
.rc-item-label {
  font-size: 0.75rem; font-weight: 600; color: rgba(13,15,20,0.5);
  letter-spacing: 0.04em; text-transform: uppercase;
  margin-bottom: 8px; display: block;
}
.rc-item-input {
  width: 100%; border: none; background: transparent;
  text-align: center; font-size: 1.1rem; font-weight: 700; color: var(--ink);
  outline: none; font-family: var(--font-body);
}

/* Primary button */
.rc-btn-primary {
  width: 100%; padding: 16px;
  background: var(--ink);
  color: var(--white);
  border: none; border-radius: var(--r-md);
  font-family: var(--font-body); font-size: 1rem; font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.2s var(--ease), transform 0.15s var(--ease), box-shadow 0.2s;
  position: relative; overflow: hidden;
}
.rc-btn-primary::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(255,255,255,0.06) 100%);
}
.rc-btn-primary:hover { background: var(--ink-60); box-shadow: var(--shadow-md); transform: translateY(-1px); }
.rc-btn-primary:active { transform: translateY(0); }
.rc-btn-primary:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

/* Result area */
.rc-result {
  display: none;
  margin-top: 28px; padding-top: 28px;
  border-top: 1.5px solid var(--surface-2);
  text-align: center;
  animation: fadeSlideUp 0.35s var(--ease) both;
}
.rc-result-label {
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: rgba(13,15,20,0.4); margin-bottom: 6px;
}
.rc-price {
  font-family: var(--font-display);
  font-size: 3rem; font-weight: 700;
  color: var(--teal);
  letter-spacing: -0.04em;
  margin-bottom: 20px;
}
.rc-btn-cta {
  width: 100%; padding: 17px;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--ink);
  border: none; border-radius: var(--r-md);
  font-family: var(--font-body); font-size: 1rem; font-weight: 700;
  letter-spacing: 0.02em; cursor: pointer;
  box-shadow: var(--shadow-gold);
  transition: transform 0.15s, box-shadow 0.2s;
}
.rc-btn-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 40px rgba(201,168,76,0.35); }

/* Form row */
.rc-row { display: flex; gap: 16px; }
.rc-row .rc-field { flex: 1; }

/* Divider */
.rc-divider {
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: rgba(13,15,20,0.35); margin-bottom: 12px;
  display: flex; align-items: center; gap: 12px;
}
.rc-divider::before, .rc-divider::after { content: ''; flex: 1; height: 1px; background: var(--surface-2); }

/* Animations */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { box-shadow: var(--shadow-gold); }
  50%       { box-shadow: 0 12px 40px rgba(201,168,76,0.5); }
}
.rc-btn-cta { animation: pulse 2.5s ease-in-out infinite; }

/* ---- BADGE ---- */
.rc-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}
.badge-pendente, .badge-aguardando_pagamento { background: #FEF3CD; color: #996B00; }
.badge-aprovado, .badge-concluida { background: #D0F5EC; color: #0A6B4E; }
.badge-aceita, .badge-a_caminho, .badge-iniciado { background: #DCEEFF; color: #1A4F99; }
.badge-cancelada { background: #FFE0E0; color: #991B1B; }
.badge-suspenso   { background: #F5F5F5; color: #666; }

/* ---- ALERT ---- */
.rc-alert {
  display: none; padding: 14px 18px;
  border-radius: var(--r-md); font-size: 0.9rem; font-weight: 500;
  margin-bottom: 20px;
}
.rc-alert-error   { background: #FEE2E2; color: #991B1B; border: 1px solid #FECACA; }
.rc-alert-success { background: #D0F5EC; color: #0A6B4E; border: 1px solid #A7F3D0; }

/* Responsive */
@media (max-width: 900px) {
  .rc-hero { padding: 60px 5% 120px; }
  .rc-hero-visual { display: none; }
  .rc-calc-wrap { padding: 0 5% 60px; }
  .rc-calc-card { padding: 28px 22px; }
  .rc-row { flex-direction: column; gap: 0; }
}
@media (max-width: 600px) {
  .rc-items-grid { grid-template-columns: repeat(2, 1fr); }
}
