/* ===========================================================
 * OBRIXX — Web freemium pública
 * Paleta: Amber #EF9F27 + Charcoal #1C1C1A (sistema PROJEX)
 * Tipografía: Poppins
 * =========================================================== */

:root {
  --bg:        #121210;
  --bg2:       #1C1C1A;
  --bg3:       #272724;
  --acc:       #EF9F27;
  --acc-soft:  #EF9F2722;
  --acc-glow:  #EF9F2755;
  --txt:       #e8eaf0;
  --txt2:      #8b90a7;
  --txt3:      #5a5d6c;
  --bdr:       #2A2A28;
  --card:      #1C1C1A;
  --r:         12px;
  --maxw:      1100px;

  --red:    #ff6b6b;
  --orange: #ff9f43;
  --yellow: #f7c948;
  --green:  #4ecca3;
}

:root[data-theme="light"] {
  --bg:    #F5F4F0;
  --bg2:   #FFFFFF;
  --bg3:   #EDECEA;
  --txt:   #1C1C1A;
  --txt2:  #5b5e6b;
  --txt3:  #9a9d9b;
  --bdr:   #D8D6D0;
  --card:  #FFFFFF;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { font-family: 'Poppins', system-ui, -apple-system, 'Segoe UI', sans-serif; }
body {
  background: var(--bg);
  color: var(--txt);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

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

button { font-family: inherit; cursor: pointer; border: none; }

.hidden { display: none !important; }

/* ═══ TOPBAR ═══ */
.topbar {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 32px;
  background: var(--bg2);
  border-bottom: 1px solid var(--bdr);
}
.logo { display: flex; align-items: center; gap: 14px; }
.logo-svg { width: 200px; height: 44px; display: block; background-image: url('/assets/obrixx-topbar-dark.svg'); background-size: contain; background-repeat: no-repeat; background-position: left center; }
:root[data-theme="light"] .logo-svg { background-image: url('/assets/obrixx-topbar-light.svg'); }
.logo-by { font-size: 10px; color: var(--txt2); letter-spacing: .5px; padding-left: 14px; border-left: 1px solid var(--bdr); line-height: 1.3; }
.logo-by strong { color: var(--acc); font-weight: 700; letter-spacing: 1px; }

.topnav { display: flex; align-items: center; gap: 24px; }
.topnav a { color: var(--txt2); font-size: 13px; font-weight: 500; }
.topnav a:hover { color: var(--acc); text-decoration: none; }
#btn-theme {
  background: var(--bg3); color: var(--txt2); padding: 6px 12px; border-radius: 8px;
  font-size: 14px; border: 1px solid var(--bdr); transition: all .15s;
}
#btn-theme:hover { color: var(--acc); border-color: var(--acc); }

/* ═══ HERO ═══ */
.hero {
  max-width: var(--maxw); margin: 0 auto;
  padding: 80px 32px 60px; text-align: center;
}
.hero h1 {
  font-size: 56px; font-weight: 800; line-height: 1.1; letter-spacing: -1px;
  margin-bottom: 20px;
}
.hero h1 .hl { color: var(--acc); }
.hero-sub {
  font-size: 18px; color: var(--txt2);
  max-width: 700px; margin: 0 auto 40px;
}
.hero-sub strong { color: var(--txt); font-weight: 600; }

.cta-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 18px;
  max-width: 760px; margin: 0 auto 30px;
}
.cta-card {
  background: var(--card); border: 1.5px solid var(--bdr); border-radius: var(--r);
  padding: 28px 24px; text-align: left; transition: all .2s;
  display: flex; flex-direction: column; gap: 6px; position: relative;
  color: var(--txt);
}
.cta-card:hover {
  border-color: var(--acc); transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(239,159,39,.18);
}
.cta-ico { font-size: 32px; margin-bottom: 8px; }
.cta-title { font-size: 18px; font-weight: 700; }
.cta-sub { font-size: 13px; color: var(--txt2); }
.cta-tag {
  position: absolute; top: 16px; right: 18px;
  font-size: 11px; font-weight: 600; color: var(--acc);
  background: var(--acc-soft); padding: 3px 9px; border-radius: 12px;
}

.hero-trust {
  display: flex; justify-content: center; gap: 28px; flex-wrap: wrap;
  font-size: 12px; color: var(--txt2); margin-top: 24px;
}

/* ═══ ZONA DE TRABAJO ═══ */
.work {
  max-width: 780px; margin: 0 auto;
  padding: 40px 32px;
}
.back-btn {
  background: transparent; color: var(--txt2);
  font-size: 13px; padding: 6px 12px; margin-bottom: 20px;
  border-radius: 8px; transition: all .15s;
}
.back-btn:hover { color: var(--acc); background: var(--bg3); }

.step h2 {
  font-size: 28px; font-weight: 700; margin-bottom: 24px;
  text-align: center;
}

/* DROPZONE */
.dropzone {
  display: block; cursor: pointer;
  background: var(--card); border: 2px dashed var(--bdr); border-radius: var(--r);
  padding: 60px 30px; text-align: center; transition: all .15s;
}
.dropzone:hover, .dropzone.drag {
  border-color: var(--acc); background: var(--acc-soft);
}
.dropzone-ico { font-size: 56px; margin-bottom: 12px; }
.dropzone-text { font-size: 17px; font-weight: 500; }
.dropzone-text span { color: var(--txt2); font-weight: 400; }

.dropzone-list {
  margin-top: 20px; display: flex; flex-direction: column; gap: 8px;
  text-align: left;
}
.file-pill {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg3); padding: 10px 14px; border-radius: 8px;
  font-size: 13px;
}
.file-pill .x { margin-left: auto; cursor: pointer; color: var(--red); font-weight: 700; padding: 0 6px; }

.upload-hint {
  background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r);
  padding: 18px 22px; margin-top: 22px;
  font-size: 13px; color: var(--txt2);
}
.upload-hint strong { color: var(--txt); }
.upload-hint ul { margin-top: 8px; padding-left: 18px; }
.upload-hint li { margin: 3px 0; }

.btn-primary {
  background: var(--acc); color: #1C1C1A;
  padding: 14px 28px; border-radius: 10px;
  font-size: 15px; font-weight: 700; transition: all .15s;
  margin-top: 22px; display: inline-block; text-align: center;
  width: 100%;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(239,159,39,.4);
}
.btn-primary:disabled { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }

.btn-secondary {
  background: transparent; color: var(--acc); border: 1px solid var(--acc);
  padding: 12px 22px; border-radius: 10px;
  font-size: 14px; font-weight: 600; display: inline-block;
  margin-top: 12px;
}
.btn-secondary:hover { background: var(--acc-soft); text-decoration: none; }

/* LOADER */
.loader { text-align: center; padding: 60px 20px; }
.loader-spinner {
  width: 56px; height: 56px; margin: 0 auto 24px;
  border: 4px solid var(--bdr); border-top-color: var(--acc);
  border-radius: 50%; animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loader h2 { font-size: 22px; }
.loader-time {
  font-size: 32px; font-weight: 700; color: var(--acc);
  margin-top: 14px; font-variant-numeric: tabular-nums;
}
.loader-pct {
  font-size: 16px; font-weight: 600; color: var(--txt2);
  margin-top: 4px; font-variant-numeric: tabular-nums;
}
.loader-sub { color: var(--txt2); margin-top: 14px; max-width: 480px; margin-left: auto; margin-right: auto; line-height: 1.55; }
.loader-extra {
  margin-top: 14px; padding: 12px 18px;
  background: var(--acc-soft); border-left: 3px solid var(--acc);
  border-radius: 6px; font-size: 13px; color: var(--txt);
  max-width: 480px; margin-left: auto; margin-right: auto;
  line-height: 1.5;
}
.loader-bar {
  margin-top: 22px; height: 8px;
  background: var(--bg3); border-radius: 4px; overflow: hidden;
  max-width: 360px; margin-left: auto; margin-right: auto;
}
.loader-bar-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--acc), #ffc870);
  transition: width .4s ease;
}

/* RESULTADO GRATIS */
.result-card { background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r); padding: 28px; margin-bottom: 18px; }

.verdict-row {
  display: flex; align-items: center; gap: 22px;
  margin-bottom: 20px;
}
.score-circle {
  width: 110px; height: 110px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  flex-shrink: 0; color: #fff;
  font-weight: 800;
}
.score-circle .score-num { font-size: 38px; line-height: 1; }
.score-circle .score-lbl { font-size: 10px; letter-spacing: 1.3px; opacity: .85; margin-top: 2px; }
.score-circle.s-good   { background: linear-gradient(135deg, var(--green), #2ec18a); }
.score-circle.s-mid    { background: linear-gradient(135deg, var(--yellow), #d4a808); }
.score-circle.s-warn   { background: linear-gradient(135deg, var(--orange), #d57500); }
.score-circle.s-bad    { background: linear-gradient(135deg, var(--red),    #c62929); }

.verdict-body { flex: 1; min-width: 0; }
.verdict-tag {
  display: inline-block; font-size: 11px; font-weight: 800;
  letter-spacing: 1.5px; padding: 5px 12px; border-radius: 20px;
  color: #fff; margin-bottom: 8px;
}
.verdict-tag.t-good  { background: #2ec18a; }
.verdict-tag.t-mid   { background: #d4a808; }
.verdict-tag.t-warn  { background: #e07a00; }
.verdict-tag.t-bad   { background: #c62929; }

.verdict-title { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.verdict-resumen { font-size: 13px; color: var(--txt2); line-height: 1.55; }

/* GANCHO AHORRO */
.savings-card {
  background: linear-gradient(135deg, var(--acc-soft), rgba(239,159,39,.05));
  border: 2px solid var(--acc);
  border-radius: var(--r);
  padding: 26px 28px;
  margin-bottom: 18px;
  text-align: center;
}
.savings-tag {
  display: inline-block;
  font-size: 11px; font-weight: 800; letter-spacing: 1.5px;
  background: var(--acc); color: #1C1C1A;
  padding: 4px 10px; border-radius: 12px;
  margin-bottom: 12px;
}
.savings-pct { font-size: 56px; font-weight: 800; color: var(--acc); line-height: 1; margin-bottom: 6px; }
.savings-eur { font-size: 22px; font-weight: 700; margin-bottom: 10px; }
.savings-eur strong { color: var(--acc); }
.savings-desc { font-size: 13px; color: var(--txt2); max-width: 480px; margin: 0 auto; }

/* HALLAZGOS TOP (gancho) */
.top-findings { padding: 0 28px 8px; }
.top-findings h3 {
  font-size: 13px; font-weight: 700; letter-spacing: 1px;
  color: var(--txt2); text-transform: uppercase; margin-bottom: 14px;
  display: flex; align-items: center; gap: 8px;
}
.finding-pill {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; background: var(--bg3); border-radius: 9px;
  margin-bottom: 8px; border-left: 4px solid var(--bdr);
}
.finding-pill .ico { font-size: 18px; flex-shrink: 0; }
.finding-pill .titulo { font-weight: 600; font-size: 13.5px; flex: 1; }
.finding-pill.alta   { border-left-color: var(--red); }
.finding-pill.media  { border-left-color: var(--orange); }
.finding-pill.baja   { border-left-color: var(--yellow); }
.findings-more {
  margin-top: 12px; padding: 12px 14px;
  background: var(--bg3); border-radius: 9px;
  text-align: center; font-size: 13px; color: var(--txt2);
  border: 1px dashed var(--bdr);
}
.findings-more strong { color: var(--acc); }

/* PAYWALL */
.paywall {
  background: var(--card);
  border: 2px solid var(--acc);
  border-radius: var(--r);
  padding: 28px;
  margin-top: 22px;
  position: relative;
  overflow: hidden;
}
.paywall::before {
  content: '🔓'; position: absolute; top: -12px; left: 24px;
  background: var(--bg); padding: 4px 12px; border-radius: 18px;
  border: 2px solid var(--acc); font-size: 18px;
}
.paywall h3 {
  font-size: 22px; margin-bottom: 14px; padding-top: 8px;
}
.paywall-features {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px 18px;
  margin: 18px 0;
  font-size: 13px;
}
.paywall-features li {
  list-style: none; padding-left: 22px; position: relative;
  color: var(--txt2);
}
.paywall-features li::before {
  content: '✓'; position: absolute; left: 0; color: var(--acc); font-weight: 800;
}
.paywall-cta {
  background: var(--acc); color: #1C1C1A;
  padding: 16px 24px; border-radius: 10px;
  font-size: 16px; font-weight: 800;
  width: 100%; transition: all .15s;
  display: flex; align-items: center; justify-content: center; gap: 14px;
}
.paywall-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 32px rgba(239,159,39,.5);
}
.paywall-cta .price { font-size: 22px; }
.paywall-trust {
  display: flex; justify-content: center; gap: 22px; flex-wrap: wrap;
  margin-top: 14px; font-size: 11px; color: var(--txt2);
}

/* EMAIL CARD */
.email-card { background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r); padding: 36px 32px; text-align: center; }
.email-ico { font-size: 48px; margin-bottom: 14px; }
.email-card h2 { margin-bottom: 10px; }
.email-card p { color: var(--txt2); margin-bottom: 22px; }
#email-input {
  width: 100%; max-width: 420px;
  padding: 14px 18px; font-size: 16px;
  background: var(--bg3); color: var(--txt);
  border: 1.5px solid var(--bdr); border-radius: 10px;
  font-family: inherit; outline: none;
  transition: border-color .15s;
}
#email-input:focus { border-color: var(--acc); }
.email-error { color: var(--red); font-size: 13px; margin-top: 8px; }
.email-trust { display: flex; justify-content: center; gap: 22px; flex-wrap: wrap; font-size: 11px; color: var(--txt2); margin-top: 16px; }

/* SUCCESS */
.success-card { background: var(--card); border: 2px solid var(--green); border-radius: var(--r); padding: 36px 32px; text-align: center; margin-bottom: 24px; }
.success-ico { font-size: 56px; margin-bottom: 14px; }
.success-email {
  display: inline-block; background: var(--bg3); padding: 8px 16px;
  border-radius: 8px; font-weight: 600; margin: 12px 0 22px;
}

/* CÓMO FUNCIONA */
.how { max-width: var(--maxw); margin: 0 auto; padding: 60px 32px; text-align: center; }
.how h2 { font-size: 36px; font-weight: 700; margin-bottom: 40px; }
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.how-step {
  background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r);
  padding: 28px 24px; text-align: left;
}
.how-num {
  width: 38px; height: 38px; background: var(--acc); color: #1C1C1A;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 17px; margin-bottom: 16px;
}
.how-title { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.how-text { font-size: 13px; color: var(--txt2); line-height: 1.6; }

/* PRICING */
.pricing { max-width: var(--maxw); margin: 0 auto; padding: 60px 32px; text-align: center; }
.pricing h2 { font-size: 36px; font-weight: 700; margin-bottom: 8px; }
.pricing-sub { color: var(--txt2); margin-bottom: 36px; }
.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 28px; }
.price-card {
  background: var(--card); border: 1.5px solid var(--bdr); border-radius: var(--r);
  padding: 28px 24px; text-align: left; position: relative;
  transition: all .2s;
}
.price-card:hover { transform: translateY(-2px); border-color: var(--acc); }
.price-card-best {
  border-color: var(--acc); background: linear-gradient(135deg, var(--card), rgba(239,159,39,.03));
}
.price-badge {
  position: absolute; top: -12px; left: 24px;
  background: var(--acc); color: #1C1C1A;
  padding: 5px 12px; border-radius: 14px;
  font-size: 11px; font-weight: 800; letter-spacing: 1px;
}
.price-name { font-size: 14px; color: var(--txt2); font-weight: 600; letter-spacing: .5px; text-transform: uppercase; margin-bottom: 8px; }
.price-amount { font-size: 38px; font-weight: 800; color: var(--acc); line-height: 1; margin-bottom: 6px; }
.price-amount .price-or { font-size: 17px; color: var(--txt2); font-weight: 600; margin-left: 6px; }
.price-desc { font-size: 13px; color: var(--txt2); margin-bottom: 16px; }
.price-features { list-style: none; }
.price-features li {
  font-size: 13px; padding-left: 22px; position: relative; margin: 6px 0;
  color: var(--txt2);
}
.price-features li::before {
  content: '✓'; position: absolute; left: 0; color: var(--acc); font-weight: 800;
}
.pricing-guarantee {
  background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r);
  padding: 18px 24px; max-width: 700px; margin: 24px auto 0;
  font-size: 13px; color: var(--txt2);
}
.pricing-guarantee strong { color: var(--txt); }

/* FOOTER */
.footer {
  border-top: 1px solid var(--bdr);
  margin-top: 60px;
  padding: 30px 32px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 18px;
  font-size: 12px; color: var(--txt2);
}
.footer-brand { display: flex; flex-direction: column; gap: 4px; }
.footer-logo { width: 110px; height: 28px; background: url('/assets/obrixx-topbar-dark.svg') no-repeat left center / contain; }
:root[data-theme="light"] .footer-logo { background-image: url('/assets/obrixx-topbar-light.svg'); }
.footer-tagline { font-size: 11px; color: var(--txt3); }
.footer-by strong { color: var(--acc); font-weight: 700; letter-spacing: .5px; }
.footer-links { display: flex; gap: 18px; }
.footer-links a { color: var(--txt2); }
.footer-links a:hover { color: var(--acc); }

/* INFORME COMPLETO TRAS PAGO */
.step-result-full { margin-top: 24px; }
.result-section {
  background: var(--card); border: 1px solid var(--bdr); border-radius: var(--r);
  padding: 22px; margin-bottom: 16px;
}
.result-section h3 {
  font-size: 13px; font-weight: 700; letter-spacing: 1px;
  color: var(--txt2); text-transform: uppercase; margin-bottom: 16px;
  display: flex; align-items: center; gap: 8px;
}
.result-section h3::before { content: ''; width: 3px; height: 14px; border-radius: 2px; background: var(--acc); }
.flag-detail { padding: 14px 16px; background: var(--bg3); border-radius: 9px; margin-bottom: 10px; border-left: 4px solid var(--bdr); }
.flag-detail.alta   { border-left-color: var(--red); }
.flag-detail.media  { border-left-color: var(--orange); }
.flag-detail.baja   { border-left-color: var(--yellow); }
.flag-detail.green  { border-left-color: var(--green); }
.flag-detail .head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.flag-detail .titulo { font-weight: 700; flex: 1; font-size: 14px; }
.flag-detail .grav-tag { font-size: 9px; font-weight: 800; padding: 3px 9px; border-radius: 13px; color: #fff; letter-spacing: 1px; }
.flag-detail .grav-tag.alta   { background: #c62929; }
.flag-detail .grav-tag.media  { background: #e07a00; }
.flag-detail .grav-tag.baja   { background: #d4a808; }
.flag-detail .exp { font-size: 13px; line-height: 1.6; margin-bottom: 10px; }
.flag-detail .accion {
  font-size: 12px; line-height: 1.55;
  background: var(--bg); border: 1px dashed var(--bdr); border-radius: 7px;
  padding: 9px 12px;
}
.flag-detail .accion strong { color: var(--acc); }

/* RESPONSIVE */
@media (max-width: 768px) {
  .topbar { padding: 12px 16px; }
  .topnav a { display: none; }
  .topnav #btn-theme { display: block; }
  .logo-svg { width: 150px; height: 36px; }
  .logo-by { display: none; }

  .hero { padding: 50px 18px 40px; }
  .hero h1 { font-size: 36px; }
  .hero-sub { font-size: 15px; }

  .cta-grid { grid-template-columns: 1fr; }
  .cta-card { padding: 22px 20px; }

  .work { padding: 30px 18px; }
  .step h2 { font-size: 22px; }

  .verdict-row { flex-direction: column; text-align: center; }
  .savings-pct { font-size: 44px; }
  .paywall-features { grid-template-columns: 1fr; }
  .paywall-cta { font-size: 14px; padding: 14px 18px; }
  .paywall-cta .price { font-size: 18px; }

  .how { padding: 40px 18px; }
  .how h2, .pricing h2 { font-size: 26px; }
  .how-grid, .pricing-grid { grid-template-columns: 1fr; }
  .pricing { padding: 40px 18px; }
  .footer { flex-direction: column; text-align: center; padding: 24px 18px; }
}
