@font-face {
  font-family: 'Omnes';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../../comparador/static/fonts/Omnes Light.ttf') format('truetype');
}

@font-face {
  font-family: 'Omnes';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../../comparador/static/fonts/Omnes Medium.ttf') format('truetype');
}

@font-face {
  font-family: 'Omnes';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../../comparador/static/fonts/Omnes SemiBold.ttf') format('truetype');
}

@font-face {
  font-family: 'Omnes';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../../comparador/static/fonts/Omnes Bold.ttf') format('truetype');
}

:root {
  color: #061640;
  background: #fff;
  font-family: 'Omnes', sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: #fff;
  color: #061640;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

.partner-shell {
  width: 100%;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 20px;
  background: #fff;
}

.partner-panel {
  width: 86%;
  max-width: 960px;
  padding: 32px 30px 28px;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 10px 28px rgba(6, 22, 64, .08), 0 -10px 28px rgba(6, 22, 64, .08);
}

.partner-form {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 1fr);
  grid-template-areas:
    "details upload"
    "consent upload"
    "button button";
  column-gap: 30px;
  align-items: start;
  width: 100%;
  text-align: left;
}

.partner-form[hidden],
.result[hidden],
.loading[hidden] {
  display: none !important;
}

.loading {
  padding: 36px 0 24px;
  color: #061640;
  text-align: center;
}

.loading-track {
  position: relative;
  height: 132px;
  margin: 0 auto 8px;
  max-width: 320px;
  overflow: visible;
}

.loading-walker {
  position: absolute;
  left: 0;
  bottom: 10px;
  width: 96px;
  height: 100px;
  animation: gina-walk 2.4s cubic-bezier(.45, 0, .55, 1) infinite alternate;
  will-change: left;
}

.loading-gina {
  position: absolute;
  left: 0;
  bottom: 10px;
  width: 96px;
  height: auto;
  transform-origin: 50% 100%;
  animation: gina-step .55s cubic-bezier(.4, 0, .6, 1) infinite alternate;
  will-change: transform;
}

@keyframes gina-walk {
  from { left: 12px; }
  to   { left: calc(100% - 108px); }
}

@keyframes gina-step {
  from { transform: translateY(0) rotate(-5deg) scale(1.06, .94); }
  to   { transform: translateY(-12px) rotate(5deg) scale(.95, 1.06); }
}

.loading-title {
  margin: 0 0 8px;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.3;
}

.loading-text {
  margin: 0 0 22px;
  color: #7e8293;
  font-size: .95rem;
}

.loading-bar {
  position: relative;
  width: 320px;
  max-width: 100%;
  height: 10px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 999px;
  background: #e6e7ef;
}

.loading-fill {
  width: 0;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #ffb200 0%, #ff8a00 55%, #ff560c 100%);
  background-size: 200% 100%;
  transition: width .25s ease-out;
  animation: loading-shimmer 1.6s linear infinite;
}

@keyframes loading-shimmer {
  from { background-position: 0 0; }
  to   { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .loading-walker,
  .loading-gina,
  .loading-fill {
    animation: none;
  }
}

.upload-column {
  grid-area: upload;
}

.upload-title {
  margin: 0 0 8px;
  color: #061640;
  font-size: .9rem;
  font-weight: 600;
}

.details-grid {
  display: grid;
  grid-area: details;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
}

.form-group {
  min-width: 0;
  margin: 0;
}

.partner-form label:not(.upload-zone):not(.checkbox-label) {
  display: block;
  margin: 0 0 6px;
  color: #061640;
  font-size: .9rem;
  font-weight: 600;
  text-align: left;
}

.partner-form input[type="text"],
.partner-form input[type="email"],
.partner-form input[type="tel"] {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 2px solid #e6e7ef;
  border-radius: 12px;
  background: #fff;
  color: #061640;
  font: 400 1rem 'Omnes', sans-serif;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.partner-form input::placeholder {
  color: #9295a2;
}

.partner-form input:focus {
  outline: none;
  border-color: #ff560c;
  box-shadow: 0 0 0 3px rgba(255, 86, 12, .12);
}

.form-help-text {
  margin: 5px 0 0;
  color: #7e8293;
  font-size: .78rem;
  font-weight: 300;
  line-height: 1.25;
}

.field-error {
  margin: 5px 0 0;
  color: #c0392b;
  font-size: .78rem;
  line-height: 1.3;
}

.partner-form input[aria-invalid="true"] {
  border-color: #c0392b;
}

.upload-zone {
  display: flex;
  width: 94%;
  min-height: 208px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  padding: 24px;
  border: 2px dashed #ffb28f;
  border-radius: 14px;
  background: #fff4ec;
  color: #061640;
  cursor: pointer;
  text-align: center;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}

.upload-zone:hover,
.upload-zone.drag-over {
  border-color: #ff560c;
  background: #ffede3;
}

.upload-zone.drag-over {
  transform: scale(1.01);
}

.upload-zone svg {
  width: 32px;
  height: 32px;
  margin-bottom: 12px;
  padding: 7px;
  box-sizing: content-box;
  border-radius: 50%;
  background: #fff;
  color: #ff560c;
}

.upload-zone strong {
  margin-bottom: 10px;
  color: #061640;
  font-size: 1.1rem;
  font-weight: 700;
}

.upload-zone span {
  color: #7e8293;
  font-size: .9rem;
  font-weight: 300;
  line-height: 1.4;
}

.upload-zone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.file-uploaded {
  display: flex;
  min-height: 208px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  border: 2px solid #22c55e;
  border-radius: 14px;
  background: #f0faf4;
}

.file-uploaded[hidden],
.upload-zone[hidden] {
  display: none;
}

.file-uploaded-check {
  display: flex;
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #22c55e;
}

.file-uploaded-name {
  max-width: 220px;
  overflow-wrap: anywhere;
  color: #15803d;
  font-size: .95rem;
  font-weight: 600;
}

.file-change-btn {
  width: auto;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 6px 12px;
  border: 1px solid #22c55e;
  border-radius: 6px;
  background: transparent;
  box-shadow: none;
  color: #16a34a;
  font-size: .85rem;
}

.file-change-btn:hover {
  background: #22c55e;
  box-shadow: none;
  color: #fff;
  transform: none;
}

.checkbox-label {
  display: flex;
  grid-area: consent;
  align-items: flex-start;
  gap: 10px;
  margin: 10px 0 0;
  color: #7e8293;
  cursor: pointer;
  font-weight: 400;
  line-height: 1.35;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  margin: 0;
  accent-color: #ff560c;
  cursor: pointer;
}

.checkbox-label span {
  color: #7e8293;
  font-size: .82rem;
}

.checkbox-label a {
  color: #ff560c;
  text-decoration: underline;
}

.message {
  grid-column: 1 / -1;
  margin: 14px 0 0;
  padding: 10px 14px;
  border: 1px solid #f5c6cb;
  border-radius: 8px;
  background: #fdecea;
  color: #c0392b;
  font-size: .9rem;
  text-align: center;
}

button {
  display: block;
  grid-area: button;
  width: 300px;
  min-height: 52px;
  margin: 22px auto 0;
  padding: 14px 28px;
  border: 0;
  border-radius: 999px;
  background: #ff682d;
  box-shadow: 0 5px 14px rgba(255, 86, 12, .28);
  color: #fff;
  cursor: pointer;
  font: 600 1rem 'Omnes', sans-serif;
  white-space: nowrap;
  transition: background .2s ease, transform .2s ease, box-shadow .2s ease;
}

button:hover {
  background: #e64d00;
  box-shadow: 0 7px 18px rgba(255, 86, 12, .34);
  transform: translateY(-2px);
}

button:active {
  transform: translateY(0);
}

button:disabled {
  cursor: wait;
  opacity: .6;
}

.result {
  padding: 22px 0 0;
  color: #061640;
  text-align: center;
}

.result h2 {
  margin: 0 0 14px;
  color: #061640;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
}

.result-imagina-title {
  margin: 0 0 16px;
  color: #061640;
  font-size: 30px;
  font-weight: 600;
  line-height: 1.3;
}

.result-friend-card {
  border-color: #ffb28f;
}

.result-friend-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.result-friend-icon {
  display: block;
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 12px;
  object-fit: contain;
}

.result-friend-text {
  margin-top: 14px !important;
  padding-bottom: 16px;
  border-bottom: 1px solid #e6e7ef;
  color: #061640;
  font-size: .95rem;
  line-height: 1.6;
}

.result-savings-card--left {
  text-align: left;
}

.result-side-title {
  color: #061640;
  font-size: 1.25rem !important;
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
}

.result-side-text {
  margin-top: 10px !important;
  color: #4d5470;
  font-size: .95rem !important;
  line-height: 1.5;
  text-align: left;
}

.result-savings-card--left .result-retry-link {
  display: block;
}

.result p {
  margin: 12px 0;
  font-size: 20px;
}

.result-contract-button {
  display: block;
  width: 300px;
  min-height: 52px;
  margin: 22px auto 0;
  padding: 15px 24px;
  border-radius: 999px;
  background: #ff6533;
  color: #fff;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none;
}

.result-retry-button {
  grid-area: auto;
  width: 300px;
  min-height: 52px;
  margin: 22px auto 0;
}

.result-comparativa {
  text-align: left;
}

.result-comparativa p {
  margin: 0;
  font-size: 1rem;
}

.result-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e6e7ef;
}

.result-kicker {
  color: #061640;
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.result-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  background: #e6f6ee;
  color: #1d8a4f;
  font-size: .9rem;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.result-badge-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.result-badge--error {
  background: #fdecea;
  color: #d63a2f;
}

.result-badge--brand {
  background: #fff0e8;
  color: #ff560c;
}

.result-badge--info {
  background: #dff6fb;
  color: #0b6f8a;
}

.result-badge--warn {
  background: #fff4cc;
  color: #8a6d00;
}

.result-tariff-sub {
  margin-top: 8px !important;
  color: #4d5470;
  font-size: .95rem;
  line-height: 1.5;
}

.result-savings-label.result-savings-label--left,
.result-savings-amount.result-savings-amount--left {
  text-align: left;
}

.result-savings-sub {
  margin-top: 6px !important;
  color: #7e8293;
  font-size: .95rem;
  text-align: left;
}

.result-mail {
  color: #ff560c;
  font-weight: 700;
  text-decoration: none;
}

.result-tariff-card--rating {
  padding: 18px 22px;
}

.result-rating.result-rating--flush {
  display: block;
  margin-top: 0;
  line-height: 1.5;
}

.result-rating.result-rating--flush strong,
.result-rating.result-rating--flush .result-stars,
.result-rating.result-rating--flush .result-rating-text {
  display: inline;
  vertical-align: baseline;
  line-height: inherit;
}

.result-rating.result-rating--flush strong {
  margin-right: 8px;
}

.result-rating.result-rating--flush .result-stars {
  top: -1px;
  margin-right: 8px;
}

.result-rating.result-rating--flush .result-rating-text {
  font-size: .85rem;
}

.result-footnote {
  margin-top: 18px !important;
  color: #7e8293;
  font-size: .95rem !important;
}

.result-inline-link {
  display: inline;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  color: inherit;
  cursor: pointer;
  font: inherit;
  text-decoration: underline;
  white-space: normal;
}

.result-inline-link:hover {
  background: none;
  box-shadow: none;
  transform: none;
  color: #ff560c;
}

.result-mascot-card {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  padding: 24px;
}

.result-mascot {
  width: 100%;
  max-width: 260px;
  height: auto;
}

.result-tips {
  display: grid;
  gap: 14px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  color: #061640;
  font-size: .95rem;
  line-height: 1.5;
}

.result-tips li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.result-tips li span {
  flex-shrink: 0;
  font-size: 1.1rem;
  line-height: 1.3;
}

.result-savings-card .result-retry-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  margin: 22px 0 0;
  padding: 15px 24px;
  border: 0;
  box-shadow: 0 6px 16px rgba(255, 86, 12, .28);
  cursor: pointer;
  font: 700 1.1rem 'Omnes', sans-serif;
  line-height: 1.4;
  text-align: center;
  white-space: normal;
}

.result-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 1fr);
  gap: 28px;
  align-items: start;
  padding-top: 28px;
}

.result-grid--wide {
  grid-template-columns: minmax(0, 1.9fr) minmax(240px, 1fr);
}

.result-headline {
  margin: 0 0 12px;
  color: #061640;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
}

.result-highlight {
  color: #ff560c;
}

.result-lead {
  color: #061640;
  font-size: 1.05rem;
  font-weight: 300;
  line-height: 1.5;
}

.result-tariff-card {
  margin-top: 20px;
  padding: 20px 22px;
  border: 1px solid #e6e7ef;
  border-radius: 14px;
  background: #fff;
}

.result-tariff-title {
  color: #061640;
  font-size: 1.05rem;
  font-weight: 700;
}

.result-features {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px 20px;
  margin: 14px 0 0;
  padding: 0 0 16px;
  border-bottom: 1px solid #e6e7ef;
  list-style: none;
  color: #061640;
  font-size: .95rem;
}

.result-features li {
  white-space: nowrap;
}

.result-rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  margin-top: 14px;
  color: #061640;
  line-height: 1;
}

.result-rating strong {
  font-size: 1.1rem;
  line-height: 1;
}

.result-stars {
  position: relative;
  top: -2px;
  color: #00b67a;
  font-size: 1rem;
  letter-spacing: 2px;
  line-height: 1;
}

.result-rating-text {
  color: #7e8293;
  font-size: .85rem;
  line-height: 1;
}

.result-savings-card {
  padding: 28px 26px;
  border-radius: 18px;
  background: #eef3fb;
  text-align: center;
}

.result-savings-label {
  color: #4d5470;
  font-size: .95rem;
  text-align: center;
}

.result-savings-amount {
  margin-top: 6px !important;
  color: #061640;
  font-size: 3rem !important;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
}

.result-savings-amount--small {
  font-size: 1.6rem !important;
}

.result-savings-card .result-contract-button {
  width: 100%;
  margin-top: 22px;
  box-shadow: 0 6px 16px rgba(255, 86, 12, .28);
  font-size: 1.1rem;
}

.result-retry-link {
  width: auto;
  min-height: 0;
  margin: 16px auto 0;
  padding: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  color: #061640;
  font-weight: 400;
  text-decoration: underline;
}

.result-retry-link:hover {
  background: none;
  box-shadow: none;
  transform: none;
  color: #ff560c;
}

.result-disclaimer {
  margin-top: 28px !important;
  color: #8a8fa3;
  font-size: .82rem !important;
  line-height: 1.5;
}

.result-asterisk {
  margin-left: 2px;
  color: #8a8fa3;
  font-size: .45em;
  font-weight: 400;
  line-height: 0;
  vertical-align: super;
}

.result-headline .result-asterisk {
  font-size: .7em;
}

@media (max-width: 760px) {
  .result-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .result-grid--wide {
    grid-template-columns: 1fr;
  }


  .result-features {
    flex-wrap: wrap;
  }

  .result-headline {
    font-size: 1.6rem;
  }

  .result-savings-amount {
    font-size: 2.4rem !important;
  }

  .partner-shell {
    width: 100%;
    min-height: 100vh;
    padding: 16px 10px;
  }

  .partner-panel {
    width: 100%;
    max-width: none;
    padding: 24px 18px;
    border-radius: 18px;
  }

  .partner-form {
    min-width: 0;
    grid-template-columns: 1fr;
    grid-template-areas:
      "details"
      "upload"
      "consent"
      "button";
    column-gap: 0;
  }

  .upload-column,
  .details-grid,
  .checkbox-label,
  .message,
  .form-group {
    min-width: 0;
    max-width: 100%;
  }

  .details-grid {
    width: 100%;
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .upload-zone,
  .file-uploaded {
    width: 100%;
    max-width: 100%;
    min-height: 190px;
    margin-top: 12px;
    padding: 20px 14px;
  }

  .upload-zone strong {
    max-width: 260px;
    font-size: 1rem;
  }

  .upload-zone span {
    font-size: .82rem;
  }

  .checkbox-label span {
    overflow-wrap: anywhere;
  }

  button {
    width: min(300px, 100%);
  }
}

@media (max-width: 440px) {
  .details-grid {
    grid-template-columns: 1fr;
  }
}
