@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@300;400;500&family=DM+Serif+Display&display=swap');

:root {
  --bg:        #0b1220;
  --text:      #eaf0ff;
  --muted:     rgba(234,240,255,.60);
  --line:      rgba(255,255,255,.10);
  --line2:     rgba(255,255,255,.18);
  --green:     #22c55e;
  --green-bg:  #052012;
  --green-fg:  #d4f5e2;
  --radius:    14px;
  --radius-sm: 8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }

body {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-weight: 400;
  color: var(--text);
  background:
    linear-gradient(rgba(11,18,32,.78), rgba(11,18,32,.78)),
    url("/static/ioniq5-bg.jpg") center / cover no-repeat fixed;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 2rem 1.25rem 5rem;
}

/* ── Top bar ── */
.dg-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.dg-wordmark {
  font-family: 'DM Serif Display', serif;
  font-size: 15px;
  letter-spacing: .02em;
  color: var(--text);
  line-height: 1;
}

.dg-wordmark span {
  font-family: 'DM Sans', sans-serif;
  font-size: 10px;
  font-weight: 300;
  color: var(--muted);
  display: block;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-top: 3px;
}

/* ── Language pills ── */
.lang-pills {
  display: flex;
  gap: 3px;
  background: rgba(255,255,255,.06);
  border-radius: 999px;
  padding: 3px;
  border: 1px solid var(--line);
}

.lang-pill {
  font-size: 11px;
  font-weight: 500;
  font-family: 'DM Sans', sans-serif;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--muted);
  border: none;
  background: transparent;
  transition: all .15s;
  letter-spacing: .04em;
}

.lang-pill.active {
  background: rgba(255,255,255,.12);
  color: var(--text);
  border: 1px solid var(--line2);
}

/* ── Profile card ── */
.dg-profile {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  background: rgba(255,255,255,.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 1rem;
}

.dg-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  object-position: top center;
  border: 2px solid rgba(34,197,94,.4);
  flex-shrink: 0;
}

.dg-profile-name {
  font-family: 'DM Serif Display', serif;
  font-size: 18px;
  font-weight: 400;
  margin-bottom: 2px;
}

.dg-profile-sub {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}

.dg-profile-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dg-pbadge {
  font-size: 10px;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 999px;
  letter-spacing: .04em;
}

.dg-pbadge.green {
  background: rgba(34,197,94,.15);
  color: #4ade80;
  border: 1px solid rgba(34,197,94,.25);
}

.dg-pbadge.blue {
  background: rgba(56,189,248,.12);
  color: #7dd3fc;
  border: 1px solid rgba(56,189,248,.2);
}

/* ── PWA banner ── */
.dg-pwa-banner {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(56,189,248,.08);
  border: 1px solid rgba(56,189,248,.2);
  border-radius: 12px;
  margin-bottom: 1.25rem;
}

.dg-pwa-banner.visible { display: flex; }

.dg-pwa-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(56,189,248,.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
}

.dg-pwa-text { flex: 1; }

.dg-pwa-title {
  font-size: 12px;
  font-weight: 500;
  color: #7dd3fc;
  margin-bottom: 2px;
}

.dg-pwa-sub {
  font-size: 11px;
  color: var(--muted);
}

.dg-pwa-btn {
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: 7px;
  background: rgba(56,189,248,.15);
  border: 1px solid rgba(56,189,248,.25);
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 500;
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  transition: background .12s;
}

.dg-pwa-btn:hover { background: rgba(56,189,248,.25); }

/* ── Hero ── */
.dg-hero { margin-bottom: 2rem; }

.dg-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 500;
  color: var(--green);
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: .9rem;
}

.dg-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(34,197,94,.5);
}

.dg-h1 {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(26px, 5vw, 38px);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -.01em;
  margin-bottom: .6rem;
  white-space: pre-line;
}

.dg-sub {
  font-size: 14px;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.75;
  max-width: 480px;
}

.dg-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 1.1rem;
}

.dg-tag {
  font-size: 11px;
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255,255,255,.03);
}

.dg-divider {
  border: none;
  border-top: 1px solid var(--line);
  margin: 0 0 1.75rem;
}

/* ── Two-panel grid ── */
.dg-grid {
  display: grid;
  grid-template-columns: 1fr;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

@media (min-width: 520px) {
  .dg-grid { grid-template-columns: 1fr 1fr; }
  .dg-separator { display: none; }
  .dg-panel:first-child { border-right: 1px solid var(--line); }
}

.dg-panel {
  background: rgba(255,255,255,.04);
  padding: 1.25rem;
  backdrop-filter: blur(12px);
}

.dg-separator {
  background: var(--line);
  height: 1px;
  grid-column: 1 / -1;
}

.dg-panel-label {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: .9rem;
}

/* ── Buttons ── */
.dg-ctarow {
  display: flex;
  gap: 8px;
  margin-bottom: .6rem;
}

.dg-btn {
  flex: 1;
  padding: 11px 10px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  border: 1px solid var(--line2);
  background: rgba(255,255,255,.06);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .12s;
}

.dg-btn:hover { background: rgba(255,255,255,.10); }

.dg-btn.primary {
  background: var(--green-bg);
  color: var(--green-fg);
  border-color: rgba(34,197,94,.25);
}

.dg-btn.primary:hover { background: #0a3a21; }

/* ── Stats ── */
.dg-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  margin-top: .75rem;
}

.dg-stat {
  background: rgba(255,255,255,.05);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 8px;
  text-align: center;
}

.dg-stat-v {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 2px;
}

.dg-stat-l {
  font-size: 10px;
  color: var(--muted);
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ── Form ── */
.dg-field { margin-bottom: .7rem; }

.dg-field-label {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--muted);
  margin-bottom: 4px;
  display: block;
}

.dg-input {
  width: 100%;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line2);
  background: rgba(255,255,255,.06);
  color: var(--text);
  font-size: 13px;
  font-family: 'DM Sans', sans-serif;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}

.dg-input::placeholder { color: var(--muted); }

.dg-input:focus {
  border-color: rgba(34,197,94,.5);
  box-shadow: 0 0 0 3px rgba(34,197,94,.10);
}

/* ── Estimate box ── */
.dg-estimate-box {
  display: none;
  margin-top: 10px;
  padding: 12px;
  background: rgba(34,197,94,.08);
  border: 1px solid rgba(34,197,94,.25);
  border-radius: 10px;
}

.dg-estimate-box.visible {
  display: block;
  animation: fadeIn .2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dg-estimate-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.dg-estimate-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: rgba(34,197,94,.8);
  margin-bottom: 4px;
}

.dg-estimate-value {
  font-family: 'DM Serif Display', serif;
  font-size: 28px;
  font-weight: 400;
  color: #4ade80;
}

.dg-estimate-sub {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
}

.dg-share-btn {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 7px;
  border: 1px solid rgba(34,197,94,.3);
  background: rgba(34,197,94,.12);
  color: #4ade80;
  font-size: 11px;
  font-weight: 500;
  font-family: 'DM Sans', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: background .12s;
}

.dg-share-btn:hover { background: rgba(34,197,94,.2); }

.dg-share-copied {
  font-size: 10px;
  color: #4ade80;
  text-align: right;
  margin-top: 4px;
  display: none;
}

.dg-share-copied.show { display: block; }

/* ── Note ── */
.dg-note {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  margin-top: .7rem;
}

/* ── Reviews ── */
.dg-reviews { margin-bottom: 1.5rem; }

.dg-reviews-label {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: .75rem;
}

.dg-review-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.dg-review {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
}

.dg-review-stars {
  font-size: 11px;
  color: #fbbf24;
  margin-bottom: 5px;
}

.dg-review-text {
  font-size: 12px;
  color: rgba(234,240,255,.75);
  line-height: 1.5;
  margin-bottom: 7px;
}

.dg-review-author {
  font-size: 10px;
  color: var(--muted);
  font-weight: 500;
  letter-spacing: .04em;
}

/* ── Quote result ── */
.dg-price-block {
  background: rgba(255,255,255,.05);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  margin-bottom: .9rem;
  backdrop-filter: blur(12px);
}

.dg-price-label {
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: 6px;
}

.dg-price-value {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(38px, 8vw, 54px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -.02em;
}

.dg-price-note {
  font-size: 11px;
  color: var(--muted);
  margin-top: 7px;
}

.dg-source {
  border-left: 2px solid var(--line2);
  padding: 7px 12px;
  margin-bottom: 1.1rem;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
}

.dg-disclaimer {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  text-align: center;
  margin-top: .9rem;
}

/* ── Footer ── */
.dg-footer {
  text-align: center;
  font-size: 11px;
  color: rgba(234,240,255,.35);
  letter-spacing: .04em;
  margin-top: 1.5rem;
}

/* ── WhatsApp floating button ── */
.wa-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #16a34a;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(22,163,74,.5);
  cursor: pointer;
  text-decoration: none;
  z-index: 99;
  transition: transform .15s, box-shadow .15s;
}

.wa-float:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 24px rgba(22,163,74,.6);
}

/* ── Resultado inline AJAX ── */
.dg-result-box {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 14px;
  padding: 1.5rem 1.25rem;
  margin-bottom: 1.5rem;
  background: rgba(255,255,255,.04);
  backdrop-filter: blur(12px);
  animation: fadeIn .3s ease;
}

.dg-result-box .dg-top { display: none !important; }
.dg-result-box .lang-pills { display: none !important; }
.dg-result-box .dg-footer { display: none !important; }
.dg-result-box .wa-float { display: none !important; }
.dg-result-box .dg-hero { margin-bottom: 1rem; }
.dg-result-box .dg-h1 { font-size: clamp(20px, 3vw, 26px); }
.dg-result-box .dg-btn[href="/m/demo"] { display: none !important; }