/* Creemos Capital V2.1 — componentes propios de la portada (se suma a evolution.css):
   terminal de mercados, aviso de directo, serie de Shorts y noticias del día. */

[hidden] { display: none !important; }
.hero .h1 { font-size: clamp(2.25rem, 1.4rem + 3.6vw, 4.25rem); max-width: 18ch; }

/* ───────── Aviso de directo: solo existe en pantalla cuando estamos en vivo ───────── */
.live-pill { display: inline-flex; align-items: center; gap: 9px; height: 46px; padding: 0 16px; border-radius: 999px; background: color-mix(in srgb, var(--down) 14%, transparent); color: var(--down); font-size: 14px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; border: 1px solid color-mix(in srgb, var(--down) 38%, transparent); animation: blink 1.6s ease-in-out infinite; }
.live-pill:hover { background: color-mix(in srgb, var(--down) 22%, transparent); }
@keyframes blink { 50% { opacity: .45; } }
.live-pill .ts { display: none; }
@media (max-width: 640px) {
  .live-pill { padding: 0 10px; }
  .live-pill .t { display: none; }
  .live-pill .ts { display: inline; }
  .live-pill { height: 40px; font-size: 13px; }
}

/* ───────── Terminal de mercados ───────── */
.terminal .win-bar { height: auto; min-height: 52px; padding: 8px 16px; flex-wrap: wrap; row-gap: 8px; }
.seg { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--surface-2); gap: 2px; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { flex: none; height: 30px; padding: 0 14px; border-radius: 999px; border: 0; background: transparent; color: var(--muted); font-size: var(--fs-xs); font-weight: 500; cursor: pointer; transition: background-color .2s, color .2s; }
.seg button:hover { color: var(--text); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.18); }
:root[data-theme="dark"] .seg button[aria-pressed="true"] { background: var(--bg); }
.mk-assets { display: flex; gap: 8px; padding: 14px 16px 0; overflow-x: auto; scrollbar-width: none; }
.mk-assets::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: transparent; font-size: 14px; font-weight: 500; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--ease); }
.chip:hover { background: var(--surface-2); transform: translateY(-1px); }
.chip[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.chip small { font: 500 11px "Geist Mono", ui-monospace, monospace; opacity: .65; }
.mk-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px 24px; padding: 18px 20px 8px; }
.mk-title b { display: block; font-size: 18px; letter-spacing: -.02em; }
.mk-title span { font-size: var(--fs-xs); color: var(--faint); }
.mk-quote { display: flex; align-items: baseline; gap: 12px; }
.mk-quote .price { font-size: clamp(1.75rem, 1.4rem + 1.6vw, 2.5rem); font-weight: 600; letter-spacing: -.03em; line-height: 1; }
.mk-quote .chg { font-size: 15px; font-weight: 500; }
.mk-quote .chg.up { color: var(--up); }
.mk-quote .chg.down { color: var(--down); }
.terminal .tf { display: flex; gap: 4px; }
.terminal .tf button { height: 30px; min-width: 40px; padding: 0 10px; border-radius: 8px; border: 0; background: transparent; color: var(--muted); font: 500 12px "Geist Mono", ui-monospace, monospace; cursor: pointer; transition: background-color .2s, color .2s; }
.terminal .tf button:hover { background: var(--surface-2); color: var(--text); }
.terminal .tf button[aria-pressed="true"] { background: var(--surface-2); color: var(--text); }
.mk-chart { position: relative; height: clamp(300px, 42vw, 440px); margin: 0 8px; }
.mk-chart canvas { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: pan-y; cursor: crosshair; }
.mk-tip { position: absolute; left: 12px; top: 8px; z-index: 2; pointer-events: none; padding: 8px 12px; border-radius: 12px; background: color-mix(in srgb, var(--surface) 88%, transparent); border: 1px solid var(--line-2); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); font: 500 12px "Geist Mono", ui-monospace, monospace; line-height: 1.55; opacity: 0; transition: opacity .15s; white-space: nowrap; }
.mk-tip.on { opacity: 1; }
.mk-tip em { font-style: normal; color: var(--faint); font-family: "Geist", sans-serif; }
.mk-tip .up { color: var(--up); }
.mk-tip .down { color: var(--down); }
.mk-state { position: absolute; inset: 0; display: grid; place-items: center; font-size: var(--fs-small); color: var(--muted); pointer-events: none; text-align: center; padding: 0 20px; }
.mk-state:empty { display: none; }
.mk-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; padding: 14px 20px 16px; border-top: 1px solid var(--line); margin-top: 8px; }
.mk-stats { display: flex; flex-wrap: wrap; gap: 8px 28px; }
.mk-stats div { display: flex; flex-direction: column; }
.mk-stats span { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .06em; }
.mk-stats b { font: 500 14px "Geist Mono", ui-monospace, monospace; }
.mk-note { font-size: 11px; color: var(--faint); max-width: 48ch; align-self: flex-end; line-height: 1.5; }
@media (max-width: 640px) {
  .mk-head { padding: 14px 14px 6px; }
  .mk-chart { margin: 0 2px; height: 300px; }
  .mk-note { max-width: none; }
  .mk-assets { padding: 12px 14px 0; }
}

/* ───────── Serie de Shorts: "Día N de 33 operando con Bitget" ───────── */
.serie-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 32px; margin-bottom: clamp(24px, 3vw, 40px); }
.serie-head .head { margin-bottom: 0; }
.progress { min-width: min(100%, 280px); display: flex; flex-direction: column; gap: 10px; }
.progress .row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.progress b { font-size: 28px; letter-spacing: -.03em; }
.progress b small { font-size: 14px; font-weight: 500; color: var(--faint); letter-spacing: 0; }
.progress .bar { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.progress .bar i { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--blue), var(--lime)); transition: width 1.2s var(--ease) .2s; }
.serie-track { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 18px; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.short { position: relative; flex: none; width: clamp(170px, 22vw, 220px); aspect-ratio: 9 / 16; border-radius: var(--r-lg); overflow: hidden; scroll-snap-align: start; background: var(--surface-2); border: 1px solid var(--line); cursor: pointer; padding: 0; text-align: left; color: #fff; transition: transform .5s var(--ease), border-color .3s; }
.short:hover { transform: translateY(-4px); border-color: var(--line-2); }
.short img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.short::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.45) 0%, transparent 32%, transparent 55%, rgba(0,0,0,.78) 100%); pointer-events: none; }
.short .day { position: absolute; z-index: 1; left: 12px; top: 12px; padding: 5px 12px; border-radius: 999px; background: var(--lime); color: var(--on-lime); font-weight: 700; font-size: 13px; letter-spacing: -.01em; }
.short .new { position: absolute; z-index: 1; right: 12px; top: 12px; padding: 4px 10px; border-radius: 999px; background: #DC2626; color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.short .play { position: absolute; z-index: 1; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: rgba(255,255,255,.92); display: grid; place-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.35); transition: transform .3s var(--ease); }
.short:hover .play { transform: scale(1.1); }
.short .play svg { width: 20px; height: 20px; margin-left: 3px; fill: #09090B; }
.short .cap { position: absolute; z-index: 1; left: 12px; right: 12px; bottom: 12px; font-size: 13px; font-weight: 500; line-height: 1.35; }
.short.playing { cursor: default; }
.short.playing:hover { transform: none; }
.short.playing::after { display: none; }
.short iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; z-index: 2; background: #000; }
.serie-nav { display: flex; gap: 8px; margin-top: 4px; justify-content: flex-end; }
.serie-empty { padding: 40px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--line-2); border-radius: var(--r-lg); }

/* ───────── Noticias del día ───────── */
.news-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-bottom: 18px; }
.news-upd { font-size: var(--fs-xs); color: var(--faint); }
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.news { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 18px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); transition: transform .5s var(--ease), border-color .3s; min-height: 132px; }
.news:hover { transform: translateY(-3px); border-color: var(--line-2); }
.news-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--faint); }
.news-src { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px; background: var(--blue-soft); color: var(--blue-text); font-weight: 600; font-size: 11px; }
.news-src.bitget { background: color-mix(in srgb, #00F0FF 16%, transparent); color: var(--text); }
.news-src.okx { background: var(--surface-2); color: var(--text); }
.news h4 { margin: 0; font-size: 15px; font-weight: 500; line-height: 1.4; letter-spacing: -.01em; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.news .go { margin-top: auto; font-size: 12px; font-weight: 500; color: var(--blue-text); }
.news-empty { grid-column: 1 / -1; padding: 40px 20px; text-align: center; color: var(--muted); font-size: var(--fs-small); border: 1px dashed var(--line-2); border-radius: var(--r-lg); }
.more-links { display: flex; flex-wrap: wrap; gap: 8px; }
.more-links a { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: 14px; transition: background-color .2s, transform .2s var(--ease); }
.more-links a:hover { background: var(--surface-2); transform: translateY(-1px); }
@media (max-width: 960px) { .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .news-grid { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .live-pill, .lf-title, .live-float { animation: none; } }

/* ───────── Hero en dos columnas: texto a la izquierda, gráfico de mercados al costado ───────── */
.hero { padding-top: clamp(24px, 3vw, 44px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, .74fr) minmax(0, 1.5fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.hero-copy { display: flex; flex-direction: column; align-items: flex-start; text-align: left; gap: 20px; }
.hero-copy .h1 { font-size: clamp(2rem, 1rem + 2.4vw, 3.2rem); max-width: none; }
.hero-copy .lead { max-width: 40ch; }
.hero-copy .hero-ctas { justify-content: flex-start; }
.hero-grid .stage { margin: 0; max-width: none; min-width: 0; }
.hero-grid .mk-chart { height: clamp(240px, calc(100vh - 470px), 360px); }   /* el gráfico completo cabe en la primera pantalla */
@media (max-width: 1020px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .hero-copy { align-items: center; text-align: center; }
  .hero-copy .h1 { max-width: 16ch; }
  .hero-copy .hero-ctas { justify-content: center; }
  .hero-grid .mk-chart { height: clamp(280px, 52vw, 400px); }
}
@media (max-width: 640px) {
  .hero-copy { gap: 14px; }
  .hero-copy .lead, .hero-copy .tag, .hero-copy .btn-ghost { display: none; }   /* en móvil el gráfico debe verse enseguida */
  .hero-grid .mk-chart { height: 300px; }
}

/* Logo de Bitget dentro del título */
.inl-brand { display: inline-flex; align-items: center; gap: .22em; }
.inl-brand img { width: .86em; height: .86em; border-radius: .2em; transform: translateY(.02em); }

/* ───────── Promoción emergente (Black Friday) ───────── */
.promo-overlay { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: 16px; background: color-mix(in srgb, var(--bg) 72%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); opacity: 0; transition: opacity .25s ease; }
.promo-overlay.on { opacity: 1; }
.promo-card { position: relative; display: grid; grid-template-columns: auto minmax(280px, 340px); max-height: min(92vh, 780px); max-width: 100%; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow); overflow: hidden; transform: translateY(16px) scale(.98); transition: transform .35s var(--ease); }
.promo-overlay.on .promo-card { transform: none; }
.promo-x { position: absolute; top: 12px; right: 12px; z-index: 3; background: color-mix(in srgb, var(--surface) 85%, transparent); backdrop-filter: blur(6px); }
.promo-img { display: block; background: #050b1f; }
.promo-img img { display: block; height: min(92vh, 780px); width: auto; max-width: 100%; aspect-ratio: 9 / 16; object-fit: cover; }
.promo-side { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 14px; padding: 36px 28px 24px; overflow-y: auto; }
.promo-title { font-size: 1.6rem; line-height: 1.1; letter-spacing: -.035em; }
.promo-sub { color: var(--muted); font-size: var(--fs-small); }
.promo-list { display: flex; flex-direction: column; gap: 6px; font-size: var(--fs-small); }
.promo-list li { position: relative; padding-left: 18px; }
.promo-list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 7px; height: 7px; border-radius: 50%; background: var(--lime); }
.promo-count { width: 100%; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 12px 14px; border-radius: 14px; background: color-mix(in srgb, var(--down) 10%, var(--surface-2)); border: 1px solid color-mix(in srgb, var(--down) 28%, transparent); }
.promo-count span { font-size: var(--fs-xs); color: var(--muted); }
.promo-count b { font-size: 1.15rem; color: var(--down); letter-spacing: -.01em; }
.promo-code { width: 100%; display: flex; flex-direction: column; gap: 6px; }
.promo-code > span { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.promo-code-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 8px 8px 16px; border-radius: 999px; border: 1px dashed var(--line-2); background: var(--surface-2); }
.promo-code-row b { font-size: 1.05rem; letter-spacing: .04em; }
.promo-no { align-self: center; background: none; border: 0; color: var(--faint); font-size: var(--fs-xs); cursor: pointer; padding: 6px 10px; }
.promo-no:hover { color: var(--text); }
@media (max-width: 760px) {
  .promo-card { grid-template-columns: minmax(0, 1fr); max-height: 94vh; overflow-y: auto; }
  .promo-img img { height: auto; width: 100%; max-height: 46vh; object-fit: contain; aspect-ratio: auto; background: #050b1f; }
  .promo-side { padding: 20px 20px 22px; justify-content: flex-start; overflow: visible; }
  .promo-title { font-size: 1.35rem; }
}
@media (prefers-reduced-motion: reduce) { .promo-overlay, .promo-card { transition: none; } }

.terminal .win-link { display: inline-flex; align-items: center; }
.news-src { gap: 5px; }
.news-src img { width: 14px; height: 14px; border-radius: 4px; }
.short .cap .bg-ico { width: 1.1em; height: 1.1em; vertical-align: -.2em; margin: 0 0 0 .2em; }

/* ───────── Ventana flotante de la sesión en vivo (solo existe mientras estamos en directo) ───────── */
.live-float { position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 340px; max-width: calc(100vw - 24px); border-radius: 18px; background: var(--surface); border: 1px solid color-mix(in srgb, var(--down) 42%, var(--line-2)); box-shadow: 0 18px 50px -12px rgba(0, 0, 0, .55), 0 0 0 4px color-mix(in srgb, var(--down) 10%, transparent); overflow: hidden; animation: lfIn .45s var(--ease); }
.live-float.big { width: min(580px, calc(100vw - 24px)); }
@keyframes lfIn { from { opacity: 0; transform: translateY(16px) scale(.97); } }
.lf-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 7px 7px 14px; cursor: grab; user-select: none; -webkit-user-select: none; touch-action: none; background: color-mix(in srgb, var(--down) 11%, var(--surface)); }
.live-float.drag .lf-bar { cursor: grabbing; }
.live-float.drag { transition: none; box-shadow: 0 26px 60px -12px rgba(0, 0, 0, .65), 0 0 0 4px color-mix(in srgb, var(--down) 16%, transparent); }
.lf-title { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--down); white-space: nowrap; animation: blink 1.6s ease-in-out infinite; }
.lf-actions { display: flex; gap: 2px; }
.lf-btn { width: 30px; height: 30px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); display: grid; place-items: center; cursor: pointer; transition: background-color .2s, color .2s; }
.lf-btn:hover { background: var(--surface-2); color: var(--text); }
.lf-btn svg { width: 16px; height: 16px; }
.lf-player { aspect-ratio: 16 / 9; background: #000; }
.lf-player iframe { width: 100%; height: 100%; border: 0; display: block; }
.lf-foot { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.lf-foot .btn { flex: 1; height: 34px; font-size: 13px; padding: 0 12px; gap: 6px; }
.lf-foot .btn svg { width: 15px; height: 15px; }
.live-float.min { width: auto; }
.live-float.min .lf-body, .live-float.min .lf-size { display: none; }
.live-float.min .lf-bar { cursor: pointer; padding-right: 7px; }
@media (max-width: 640px) {
  .live-float, .live-float.big { right: 12px; bottom: 12px; width: min(330px, calc(100vw - 24px)); }
  .live-float.min { width: auto; }
  .lf-size { display: none; }
}
