/* ============================================================
   Santander México — Banca en Línea
   Paleta: rojo institucional #EC0000, blancos y grises cálidos
   ============================================================ */
:root {
  --red: #EC0000;
  --red-dark: #BE0000;
  --red-deep: #8F0000;
  --ink: #1F1F1F;
  --ink-2: #444444;
  --gray: #6E6E6E;
  --gray-light: #F4F4F4;
  --line: #E5E5E5;
  --white: #FFFFFF;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .08);
  --shadow-soft: 0 4px 14px rgba(0, 0, 0, .06);
  --font: "Santander Micro Text", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input { font-family: inherit; }
img, svg { vertical-align: middle; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14.5px;
  font-weight: 600;
  transition: all .18s ease;
  white-space: nowrap;
}
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); transform: translateY(-1px); box-shadow: 0 6px 16px rgba(236,0,0,.28); }
.btn-outline { border-color: var(--red); color: var(--red); background: transparent; }
.btn-outline:hover { background: rgba(236,0,0,.06); }
.btn-ghost { border-color: var(--line); color: var(--ink-2); background: #fff; }
.btn-ghost:hover { border-color: #bbb; }
.btn-white-outline { border-color: rgba(255,255,255,.85); color: #fff; background: transparent; }
.btn-white-outline:hover { background: rgba(255,255,255,.14); }
.btn-lg { padding: 13px 30px; font-size: 15.5px; }
.btn-block { width: 100%; }
.btn-mini { padding: 6px 14px; font-size: 12.5px; }
.btn:disabled { opacity: .6; cursor: wait; }

.textlink { color: var(--red); font-weight: 600; font-size: 13.5px; }
.textlink:hover { text-decoration: underline; }
.textlink span { font-size: 15px; }

/* ---------- Top bar ---------- */
.topbar { background: var(--gray-light); border-bottom: 1px solid var(--line); font-size: 12.5px; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; height: 38px; }
.topbar-links { display: flex; gap: 22px; }
.topbar-links a { color: var(--ink-2); font-weight: 500; }
.topbar-links a:first-child { color: var(--red); font-weight: 700; }
.topbar-links a:hover { color: var(--red); }
.topbar-right { display: flex; align-items: center; gap: 18px; }
.topbar-link-icon { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); }
.topbar-link-icon:hover { color: var(--red); }
.topbar-search { display: inline-flex; align-items: center; gap: 5px; background: none; border: none; color: var(--ink-2); font-size: 12.5px; }
.topbar-search:hover { color: var(--red); }

/* ---------- Header ---------- */
.header { background: #fff; position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 0 var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand .flame { width: 40px; height: 40px; }
.brand-name { font-size: 24px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); }
.brand-name small { display: block; font-size: 11px; font-weight: 600; color: rgba(255,255,255,.8); letter-spacing: .04em; }
.brand-light .brand-name { color: #fff; }
.header-actions { display: flex; gap: 12px; }

.mainnav { border-top: 1px solid var(--line); }
.mainnav-inner { display: flex; gap: 26px; overflow-x: auto; }
.mainnav-link { display: inline-block; padding: 13px 2px; font-size: 14px; font-weight: 600; color: var(--ink-2); border-bottom: 3px solid transparent; white-space: nowrap; }
.mainnav-link:hover { color: var(--red); }
.mainnav-link.active { color: var(--red); border-bottom-color: var(--red); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; }
.hero-slide {
  display: none;
  min-height: 480px;
  color: #fff;
}
.hero-slide.active { display: block; animation: fadeIn .5s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.hero-slide-1 { background: linear-gradient(115deg, var(--red-deep) 0%, var(--red) 55%, #FF4D4D 100%); }
.hero-slide-2 { background: linear-gradient(115deg, #1A1A2E 0%, #2E2E4A 60%, #47477A 100%); }
.hero-inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; padding: 64px 24px; min-height: 480px; }
.hero-copy { max-width: 560px; }
.hero-tag { display: inline-block; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.35); border-radius: 999px; padding: 5px 14px; font-size: 12.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 18px; }
.hero-copy h1 { font-size: clamp(30px, 4.4vw, 46px); line-height: 1.12; font-weight: 800; letter-spacing: -.02em; margin-bottom: 14px; }
.hero-copy p { font-size: 16.5px; opacity: .92; margin-bottom: 26px; max-width: 46ch; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

/* Tarjeta de crédito (mock) */
.hero-art { flex-shrink: 0; }
.cc {
  width: 380px; max-width: 82vw;
  aspect-ratio: 1.586;
  border-radius: 18px;
  padding: 24px;
  color: #fff;
  display: flex; flex-direction: column; justify-content: space-between;
  box-shadow: 0 24px 50px rgba(0,0,0,.35);
  background: linear-gradient(135deg, #FF3333 0%, var(--red) 45%, var(--red-dark) 100%);
  position: relative;
}
.cc::after { content: ""; position: absolute; inset: 0; border-radius: 18px; background: radial-gradient(120% 90% at 90% 10%, rgba(255,255,255,.22), transparent 55%); pointer-events: none; }
.cc-red { background: linear-gradient(135deg, #FF3333 0%, var(--red) 45%, var(--red-dark) 100%); }
.cc-top { display: flex; justify-content: space-between; align-items: baseline; }
.cc-brand { font-weight: 800; font-size: 18px; }
.cc-type { font-size: 12px; font-weight: 700; opacity: .85; text-transform: uppercase; letter-spacing: .08em; }
.cc-chip { width: 44px; height: 32px; border-radius: 6px; background: linear-gradient(135deg, #F4D03F, #D4AC0D); position: relative; }
.cc-chip::before { content: ""; position: absolute; inset: 6px 8px; border: 1px solid rgba(0,0,0,.25); border-radius: 3px; }
.cc-num { font-size: 21px; letter-spacing: .12em; font-weight: 600; }
.cc-bottom { display: flex; justify-content: space-between; font-size: 12.5px; opacity: .9; text-transform: uppercase; letter-spacing: .05em; }
.cc-small { width: 300px; padding: 18px; }
.cc-small .cc-num { font-size: 17px; }

/* Phone mock */
.phone-mock { width: 240px; background: #111; border-radius: 32px; padding: 10px; box-shadow: 0 24px 50px rgba(0,0,0,.4); }
.phone-notch { width: 90px; height: 18px; background: #111; border-radius: 0 0 12px 12px; margin: 0 auto; }
.phone-screen { background: #fff; border-radius: 22px; padding: 18px 16px; color: var(--ink); }
.phone-row { display: flex; justify-content: space-between; align-items: center; font-weight: 700; font-size: 14px; }
.phone-dot { width: 26px; height: 26px; border-radius: 50%; background: var(--red); }
.phone-balance-label { font-size: 11px; color: var(--gray); margin-top: 14px; }
.phone-balance { font-size: 22px; font-weight: 800; margin-bottom: 14px; }
.phone-card { height: 74px; border-radius: 12px; background: linear-gradient(135deg, #FF3333, var(--red-dark)); margin-bottom: 14px; }
.phone-quick { display: flex; gap: 8px; }
.phone-quick span { flex: 1; height: 44px; border-radius: 10px; background: var(--gray-light); }

.hero-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.14); color: #fff;
  border: 1px solid rgba(255,255,255,.4); border-radius: 50%;
  width: 44px; height: 44px; font-size: 17px;
  transition: background .2s;
  z-index: 5;
}
.hero-arrow:hover { background: rgba(255,255,255,.3); }
.hero-arrow.prev { left: 22px; }
.hero-arrow.next { right: 22px; }
.hero-dots { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; gap: 9px; z-index: 5; }
.dot { width: 10px; height: 10px; border-radius: 50%; border: none; background: rgba(255,255,255,.45); transition: all .2s; }
.dot.active { background: #fff; width: 26px; border-radius: 999px; }

/* ---------- Quick links ---------- */
.quicklinks { background: #fff; padding: 34px 0 10px; }
.quicklinks-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.quicklink { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 14px; text-align: center; transition: all .18s; }
.quicklink:hover { border-color: var(--red); box-shadow: var(--shadow-soft); transform: translateY(-2px); }
.ql-icon { display: inline-flex; width: 46px; height: 46px; align-items: center; justify-content: center; border-radius: 50%; background: rgba(236,0,0,.08); color: var(--red); margin-bottom: 10px; }
.ql-icon svg { width: 24px; height: 24px; }
.ql-label { display: block; font-weight: 700; font-size: 13.5px; }
.ql-desc { display: block; font-size: 12px; color: var(--gray); margin-top: 2px; }

/* ---------- App section ---------- */
.app-section { background: var(--gray-light); margin-top: 44px; padding: 64px 0; }
.app-inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.eyebrow { color: var(--red); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: 12.5px; }
.app-copy h2 { font-size: clamp(26px, 3vw, 34px); font-weight: 800; letter-spacing: -.01em; margin: 8px 0 12px; }
.app-copy p { color: var(--ink-2); margin-bottom: 22px; max-width: 52ch; }
.store-badges { display: flex; gap: 12px; flex-wrap: wrap; }
.store-badge { display: inline-flex; align-items: center; gap: 8px; background: var(--ink); color: #fff; border-radius: 10px; padding: 10px 18px; font-weight: 600; font-size: 13.5px; transition: transform .15s; }
.store-badge:hover { transform: translateY(-2px); }
.app-highlights { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.highlight-card { background: #fff; border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-soft); border-left: 4px solid var(--red); }
.highlight-card strong { display: block; font-size: 15px; margin-bottom: 4px; }
.highlight-card span { font-size: 13px; color: var(--gray); }

/* ---------- Promos ---------- */
.promos { padding: 64px 0 72px; }
.section-title { font-size: clamp(24px, 3vw, 32px); font-weight: 800; letter-spacing: -.01em; margin-bottom: 26px; }
.promo-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.promo-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; transition: all .2s; }
.promo-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.promo-img { height: 130px; }
.promo-img-1 { background: linear-gradient(120deg, #FFE1E1, #FFB3B3 60%, #FF8080); }
.promo-img-2 { background: linear-gradient(120deg, #E3EDFF, #B9CCF6 60%, #8FA9E8); }
.promo-img-3 { background: linear-gradient(120deg, #E1F5EA, #A9DFC3 60%, #74C69D); }
.promo-img-4 { background: linear-gradient(120deg, #FFF3D6, #FFE08A 60%, #FFC94D); }
.promo-body { padding: 18px 18px 20px; }
.promo-body h3 { font-size: 17px; font-weight: 800; margin-bottom: 6px; }
.promo-body p { font-size: 13.5px; color: var(--gray); margin-bottom: 12px; }

/* ---------- Footer ---------- */
.footer { background: var(--gray-light); border-top: 1px solid var(--line); }
.footer-top { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; padding: 46px 24px 30px; }
.footer-col h4 { font-size: 13.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 14px; color: var(--ink); }
.footer-col a { display: block; font-size: 13.5px; color: var(--ink-2); padding: 4px 0; }
.footer-col a:hover { color: var(--red); }
.footer-legal { padding: 18px 24px 30px; border-top: 1px solid var(--line); font-size: 12px; color: var(--gray); }
.footer-legal p { margin-bottom: 8px; max-width: 100ch; }
.footer-legal a { color: var(--red); }
.footer-copy { font-size: 11.5px; color: #999; }
.footer-thin { background: #fff; padding: 8px 0 18px; }
.footer-dark { background: #232323; border-top: none; }
.footer-dark .footer-legal { border-top: none; color: #A8A8A8; }

/* ============================================================
   LOGIN
   ============================================================ */
.header-simple { box-shadow: 0 1px 6px rgba(0,0,0,.06); }
.header-simple .header-inner { height: 64px; }
.header-simple .brand .flame { width: 34px; height: 34px; }
.header-simple .brand-name { font-size: 21px; }

.login-wrap { background: linear-gradient(160deg, #FAFAFA 0%, #F0F0F2 100%); min-height: calc(100vh - 140px); padding: 46px 0 60px; }
.login-layout { display: grid; grid-template-columns: 1fr 460px; gap: 40px; align-items: start; max-width: 1060px; }

.login-aside { padding: 30px 6px 0 0; color: var(--ink); }
.login-aside h2 { font-size: clamp(26px, 3vw, 34px); font-weight: 800; letter-spacing: -.01em; margin-bottom: 10px; }
.login-aside > p { color: var(--ink-2); margin-bottom: 26px; max-width: 44ch; }
.aside-list { list-style: none; display: grid; gap: 18px; margin-bottom: 26px; }
.aside-list li { display: flex; gap: 12px; }
.aside-check { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--red); color: #fff; font-size: 13px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; }
.aside-list strong { display: block; font-size: 14.5px; }
.aside-list span { font-size: 13px; color: var(--gray); }
.aside-note { background: #FFF7E6; border: 1px solid #F2DCAD; border-radius: var(--radius-sm); padding: 14px 16px; font-size: 13px; color: #6B5B2E; max-width: 46ch; }

.login-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.login-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); }
.login-tab { background: none; border: none; padding: 16px; font-size: 14.5px; font-weight: 700; color: var(--gray); border-bottom: 3px solid transparent; }
.login-tab.active { color: var(--red); border-bottom-color: var(--red); }

.login-form { padding: 28px 30px 26px; }
.login-form h1 { font-size: 22px; font-weight: 800; letter-spacing: -.01em; margin-bottom: 6px; }
.login-sub { font-size: 13.5px; color: var(--gray); margin-bottom: 22px; }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--ink-2); }
.input-wrap { position: relative; display: flex; align-items: center; }
.input-icon { position: absolute; left: 13px; width: 18px; height: 18px; color: #9A9A9A; pointer-events: none; }
.input-wrap input {
  width: 100%;
  padding: 12px 14px 12px 42px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 15px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  background: #FDFDFD;
}
.input-wrap input:focus { border-color: var(--red); box-shadow: 0 0 0 3px rgba(236,0,0,.10); background: #fff; }
.input-wrap input.invalid { border-color: var(--red); }
.toggle-pass { position: absolute; right: 10px; background: none; border: none; color: var(--red); font-size: 12.5px; font-weight: 700; padding: 6px; }

.login-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 4px 0 18px; flex-wrap: wrap; }
.checkbox { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.checkbox input { width: 16px; height: 16px; accent-color: var(--red); }

.form-error {
  background: #FDECEC;
  border: 1px solid #F5B9B9;
  color: #A30000;
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 13px;
  margin-bottom: 16px;
}

.login-alt { margin-top: 20px; padding-top: 18px; border-top: 1px dashed var(--line); font-size: 13.5px; color: var(--ink-2); display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }

/* ============================================================
   DASHBOARD
   ============================================================ */
.dash-header { background: linear-gradient(100deg, var(--red-deep), var(--red)); color: #fff; position: sticky; top: 0; z-index: 50; box-shadow: 0 2px 10px rgba(0,0,0,.18); }
.dash-header-inner { display: flex; align-items: center; gap: 26px; height: 68px; }
.dash-header .brand .flame { width: 32px; height: 32px; }
.dash-header .brand-name { color: #fff; font-size: 20px; }
.dash-nav { display: flex; gap: 4px; flex: 1; overflow-x: auto; }
.dash-nav-link { padding: 24px 12px; font-size: 13.5px; font-weight: 600; color: rgba(255,255,255,.85); border-bottom: 3px solid transparent; white-space: nowrap; }
.dash-nav-link:hover { color: #fff; }
.dash-nav-link.active { color: #fff; border-bottom-color: #fff; }
.dash-user { display: flex; align-items: center; gap: 10px; }
.dash-avatar { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.2); border: 1.5px solid rgba(255,255,255,.6); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; text-transform: uppercase; }
.dash-username { font-weight: 700; font-size: 13.5px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.dash-main { padding: 30px 24px 56px; }
.dash-welcome h1 { font-size: 26px; font-weight: 800; letter-spacing: -.01em; }
.dash-welcome p { color: var(--gray); font-size: 13.5px; margin-top: 4px; }

.dash-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 20px; margin-top: 22px; }
.account-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-soft); }
.account-head { display: flex; justify-content: space-between; align-items: baseline; }
.account-kind { font-weight: 800; font-size: 16px; }
.account-num { color: var(--gray); font-size: 13px; }
.account-balance-label { margin-top: 18px; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--gray); }
.account-balance { font-size: 38px; font-weight: 800; letter-spacing: -.02em; margin: 4px 0 20px; }
.account-balance small { font-size: 15px; color: var(--gray); font-weight: 700; }
.account-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.credit-card-widget { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-soft); display: flex; gap: 22px; align-items: center; }
.cc-widget-data { flex: 1; }
.cc-widget-row { display: flex; justify-content: space-between; font-size: 13px; padding: 7px 0; border-bottom: 1px dashed var(--line); color: var(--ink-2); }
.cc-widget-row strong { color: var(--ink); }
.cc-widget-data .btn { margin-top: 14px; }

.dash-grid-2 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; margin-top: 20px; }
.tx-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-soft); }
.tx-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.tx-head h2 { font-size: 17px; font-weight: 800; }
.tx-table { width: 100%; border-collapse: collapse; }
.tx-table td { padding: 12px 6px; border-bottom: 1px solid var(--gray-light); font-size: 13.5px; vertical-align: middle; }
.tx-table tr:last-child td { border-bottom: none; }
.tx-icon { width: 40px; font-size: 19px; text-align: center; }
.tx-date { font-size: 12px; color: var(--gray); }
.tx-neg { text-align: right; font-weight: 700; color: var(--ink); white-space: nowrap; }
.tx-pos { text-align: right; font-weight: 700; color: #0E7B3D; white-space: nowrap; }

.dash-side { display: grid; gap: 16px; align-content: start; }
.side-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-soft); }
.side-card h3 { font-size: 15px; font-weight: 800; margin-bottom: 6px; }
.side-card p { font-size: 13px; color: var(--gray); margin-bottom: 14px; }
.side-card-red { background: linear-gradient(140deg, #FFF5F5, #FFE8E8); border-color: #F6C9C9; }
.progress { height: 9px; border-radius: 999px; background: #F1D8D8; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--red), #FF5C5C); }
.progress-label { display: block; margin-top: 8px; font-size: 12px; font-weight: 700; color: var(--red-dark); }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .quicklinks-grid { grid-template-columns: repeat(3, 1fr); }
  .promo-grid { grid-template-columns: repeat(2, 1fr); }
  .app-inner { grid-template-columns: 1fr; }
  .login-layout { grid-template-columns: 1fr; max-width: 560px; }
  .login-aside { display: none; }
  .dash-grid, .dash-grid-2 { grid-template-columns: 1fr; }
  .credit-card-widget { flex-direction: column; align-items: stretch; }
}
@media (max-width: 640px) {
  .topbar-links { display: none; }
  .topbar-inner { justify-content: flex-end; }
  .header-inner { height: 62px; }
  .header-actions .btn-outline { display: none; }
  .quicklinks-grid { grid-template-columns: repeat(2, 1fr); }
  .promo-grid { grid-template-columns: 1fr; }
  .hero-inner { flex-direction: column; text-align: center; padding: 44px 24px 70px; }
  .hero-cta { justify-content: center; }
  .hero-copy p { margin-left: auto; margin-right: auto; }
  .footer-top { grid-template-columns: repeat(2, 1fr); }
  .dash-nav-link { padding: 18px 10px; }
  .dash-username { display: none; }
  .account-balance { font-size: 30px; }
}
