/* ============================================================
   Masini in Rate Fara Avans -- Stylesheet principal
   Paleta: terracotta / muștar / crem (vezi Brand Manual)
   ============================================================ */

:root {
  --terracotta: #B5442E;
  --terracotta-dark: #8C2E1D;
  --mustard: #E9A23B;
  --ink: #2B2420;
  --muted: #5A5048;
  --cream: #FBF3EA;
  --line: #EBD9C9;
  --green: #3E7A45;
  --green-bg: #EAF3EA;
  --red-bg: #FBEAE6;
  --white: #FFFFFF;
  --radius: 10px;
  --shadow: 0 2px 10px rgba(43, 36, 32, 0.06);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  font-size: 16px;
}

.wrap {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

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

h1, h2, h3, h4 {
  font-weight: 800;
  color: var(--ink);
  line-height: 1.25;
  margin: 0 0 14px 0;
}
h1 { font-size: 2.4rem; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.25rem; }
p { margin: 0 0 14px 0; }

ul { padding-left: 20px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.98rem;
  text-align: center;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.08s ease, opacity 0.15s ease;
}
.btn:hover { text-decoration: none; opacity: 0.92; }
.btn:active { transform: scale(0.98); }

.btn--primary { background: var(--terracotta); color: var(--white); }
.btn--accent  { background: var(--mustard); color: var(--ink); }
.btn--ghost   { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--outline { background: transparent; color: var(--terracotta); border-color: var(--terracotta); }
.btn--block   { display: block; width: 100%; }
.btn--lg      { padding: 16px 32px; font-size: 1.05rem; }

/* ---------- Header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--white);
  position: sticky;
  top: 0;
  z-index: 50;
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  gap: 20px;
}
.logo {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--ink);
  white-space: nowrap;
}
.logo span { color: var(--terracotta); }
.logo:hover { text-decoration: none; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
}
.main-nav > a {
  color: var(--ink);
  font-weight: 600;
  font-size: 0.95rem;
}
.main-nav > a:hover { color: var(--terracotta); text-decoration: none; }

.nav-auth { display: flex; gap: 10px; align-items: center; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--ink); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--terracotta) 0%, var(--terracotta-dark) 100%);
  color: var(--white);
  padding: 70px 0 90px 0;
}
.hero h1 { color: var(--white); font-size: 2.6rem; max-width: 720px; }
.hero p.lead { color: #F1DBC9; font-size: 1.2rem; max-width: 560px; }
.hero .cta-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 26px; }
.hero .btn--accent { color: var(--ink); }
.hero-highlights {
  list-style: none;
  padding: 0;
  margin: 30px 0 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
}
.hero-highlights li {
  color: #F8E9DA;
  font-weight: 600;
  font-size: 0.92rem;
}

/* ---------- Sections ---------- */
section { padding: 60px 0; }
section.alt { background: var(--cream); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 40px auto; }
.section-head h2 { margin-bottom: 10px; }
.section-head p { color: var(--muted); }

/* ---------- Trust bar ---------- */
.trust-bar {
  display: flex;
  justify-content: center;
  gap: 50px;
  flex-wrap: wrap;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}
.trust-bar__item { text-align: center; }
.trust-bar__item strong { display: block; font-size: 1.6rem; color: var(--terracotta); }
.trust-bar__item span { color: var(--muted); font-size: 0.9rem; }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.step { text-align: center; }
.step__num {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--mustard); color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; margin: 0 auto 14px auto; font-size: 1.1rem;
}
.step h3 { font-size: 1.05rem; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: 0.93rem; }

/* ---------- Diferentiatori ---------- */
.benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.benefit {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.benefit .check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--green-bg); color: var(--green);
  font-weight: 800; margin-bottom: 12px;
}

/* ---------- Car cards ---------- */
.car-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.car-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow);
  transition: transform 0.12s ease;
}
.car-card:hover { transform: translateY(-3px); }
.car-card__img {
  aspect-ratio: 4/3;
  background: var(--cream) url('') center/cover;
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 0.85rem;
  position: relative;
}
.car-card__badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--mustard); color: var(--ink);
  font-size: 0.75rem; font-weight: 800;
  padding: 4px 10px; border-radius: 999px;
}
.car-card__body { padding: 16px; }
.car-card__title { font-weight: 800; font-size: 1.02rem; margin-bottom: 4px; }
.car-card__meta { color: var(--muted); font-size: 0.85rem; margin-bottom: 10px; }
.car-card__price { display: flex; justify-content: space-between; align-items: baseline; }
.car-card__price strong { font-size: 1.2rem; color: var(--terracotta); }
.car-card__price small { color: var(--muted); font-size: 0.78rem; }

/* ---------- City chips ---------- */
.city-grid { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.city-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 20px;
  font-weight: 600;
  color: var(--ink);
  background: var(--white);
}
.city-chip:hover { border-color: var(--terracotta); color: var(--terracotta); text-decoration: none; }

/* ---------- FAQ ---------- */
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 18px 0;
}
.faq-item summary {
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-size: 1.4rem; color: var(--terracotta); }
.faq-item[open] summary::after { content: '−'; }
.faq-item p { margin-top: 10px; color: var(--muted); }

/* ---------- Final CTA ---------- */
.cta-final {
  background: var(--ink);
  color: var(--cream);
  text-align: center;
  border-radius: var(--radius);
  padding: 50px 30px;
}
.cta-final h2 { color: var(--white); }
.cta-final p { color: #CBB9A8; max-width: 480px; margin: 0 auto 26px auto; }

/* ---------- Forms ---------- */
.form-box {
  max-width: 480px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
}
.form-box--wide { max-width: 640px; }
label { display: block; font-weight: 700; font-size: 0.88rem; margin-bottom: 6px; margin-top: 16px; }
label:first-of-type { margin-top: 0; }
input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"],
select, textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.98rem;
  color: var(--ink);
  background: var(--white);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--terracotta);
}
.form-note { font-size: 0.82rem; color: var(--muted); margin-top: 8px; }
.form-actions { margin-top: 22px; }

.alert {
  padding: 14px 16px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 0.92rem;
}
.alert--error { background: var(--red-bg); color: #A63A2A; border: 1px solid #E3A192; }
.alert--success { background: var(--green-bg); color: var(--green); border: 1px solid #A9CBAA; }

.radio-group { display: flex; gap: 20px; margin-top: 6px; }
.radio-group label { display: flex; align-items: center; gap: 8px; font-weight: 600; margin: 0; }
.radio-group input { width: auto; }

/* ---------- Tables (dashboard) ---------- */
table.data-table { width: 100%; border-collapse: collapse; margin-top: 10px; }
table.data-table th, table.data-table td {
  text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); font-size: 0.9rem;
}
table.data-table th { background: var(--cream); font-weight: 700; }
.status-pill {
  display: inline-block; padding: 3px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 700;
}
.status-pill--nou { background: var(--red-bg); color: var(--red); }
.status-pill--contactat { background: #FFF3D6; color: #94660D; }
.status-pill--finalizat, .status-pill--activ { background: var(--green-bg); color: var(--green); }
.status-pill--in_asteptare { background: #FFF3D6; color: #94660D; }
.status-pill--suspendat, .status-pill--arhivata { background: #EEE; color: #777; }

/* ---------- Dashboard layout ---------- */
.dash-header {
  background: var(--cream);
  border-bottom: 1px solid var(--line);
  padding: 30px 0;
  margin-bottom: 30px;
}
.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 34px; }
.dash-stat { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.dash-stat strong { display: block; font-size: 1.6rem; color: var(--terracotta); }
.dash-stat span { color: var(--muted); font-size: 0.85rem; }
.dash-section { margin-bottom: 40px; }
.dash-section h2 { font-size: 1.3rem; }

/* ---------- Breadcrumbs ---------- */
.breadcrumbs { font-size: 0.85rem; color: var(--muted); margin-bottom: 20px; }
.breadcrumbs a { color: var(--muted); }

/* ---------- Car detail ---------- */
.car-detail { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: start; }
.car-detail__img { aspect-ratio: 4/3; background: var(--cream); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; color: var(--muted); }
.specs-table { width: 100%; border-collapse: collapse; margin-top: 16px; }
.specs-table td { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 0.93rem; }
.specs-table td:first-child { color: var(--muted); width: 45%; }
.price-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; position: sticky; top: 90px; }
.price-box .price { font-size: 2rem; font-weight: 800; color: var(--terracotta); }
.price-box .rate-estimate { background: var(--cream); border-radius: 8px; padding: 12px 14px; margin: 14px 0; font-size: 0.9rem; }

/* ---------- Dealer profile card ---------- */
.dealer-card {
  display: grid;
  grid-template-columns: auto 1fr 220px;
  gap: 30px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}
.dealer-card__logo {
  width: 90px; height: 90px;
  border-radius: 12px;
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.dealer-card__logo img { width: 100%; height: 100%; object-fit: contain; }
.dealer-card__logo span { font-size: 2rem; font-weight: 800; color: var(--terracotta); }
.dealer-card__info h1 { font-size: 1.4rem; margin-bottom: 6px; }
.dealer-card__actions { display: flex; flex-direction: column; gap: 10px; }
.btn--whatsapp { background: #25D366; color: #fff; }

.dealer-mini {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px 0 18px 0;
}
.dealer-mini__logo {
  width: 44px; height: 44px;
  border-radius: 8px;
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.dealer-mini__logo img { width: 100%; height: 100%; object-fit: contain; }
.dealer-mini__logo span { font-weight: 800; color: var(--terracotta); }

@media (max-width: 700px) {
  .dealer-card { grid-template-columns: 1fr; text-align: center; }
  .dealer-card__logo { margin: 0 auto; }
}

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #CBB9A8; padding: 50px 0 20px 0; margin-top: 60px; }
.footer__inner { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 30px; }
.footer__col h4 { color: var(--white); font-size: 0.95rem; margin-bottom: 14px; }
.footer__col a { display: block; color: #CBB9A8; font-size: 0.9rem; margin-bottom: 10px; }
.footer__col a:hover { color: var(--mustard); text-decoration: none; }
.logo--footer { color: var(--white); margin-bottom: 10px; }
.logo--footer span { color: var(--mustard); }
.footer__tagline { font-style: italic; font-size: 0.9rem; color: #CBB9A8; }
.footer__bottom {
  border-top: 1px solid #4A3F37;
  margin-top: 34px; padding-top: 20px;
  font-size: 0.8rem; color: #A69684;
}

/* ---------- Utility ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.muted { color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .steps, .benefits, .car-grid { grid-template-columns: 1fr 1fr; }
  .car-detail { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    gap: 16px;
  }
  .main-nav.is-open { display: flex; }
  .nav-auth { flex-direction: column; align-items: stretch; width: 100%; margin-top: 10px; }
  .hero h1 { font-size: 1.9rem; }
  .steps, .benefits, .car-grid, .dash-stats { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr; }
  h1 { font-size: 1.9rem; }
}
