/* =========================================================================
   Tema "poncesiles" para TMail — oscuro con acentos violeta
   ========================================================================= */
:root {
  --psx-bg: #05060a;
  --psx-surface: #0f1320;
  --psx-surface-2: #161b2b;
  --psx-field: #1a2032;
  --psx-border: #262d42;
  --psx-border-2: #333b55;
  --psx-text: #eef0f7;
  --psx-muted: #8f97b0;
  --psx-faint: #5d6580;
  --psx-accent: #6d6af5;
  --psx-accent-2: #9a98ff;
  --psx-accent-soft: rgba(109, 106, 245, .16);
  --psx-danger: #f0606e;
  --psx-radius: 22px;
  --psx-radius-sm: 12px;
  --psx-font: "Montserrat", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

html, body.psx { background: var(--psx-bg); }
body.psx {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  color: var(--psx-text);
  font-family: var(--psx-font);
  -webkit-font-smoothing: antialiased;
}
.psx * { box-sizing: border-box; }
.psx a { color: inherit; }

/* Fondo: malla de puntos + resplandores */
.psx-bg {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(520px 420px at 14% 26%, rgba(88, 80, 236, .22), transparent 70%),
    radial-gradient(560px 460px at 86% 78%, rgba(88, 80, 236, .18), transparent 70%),
    radial-gradient(circle, rgba(255, 255, 255, .07) 1px, transparent 1.2px) 0 0 / 26px 26px,
    var(--psx-bg);
}
.psx-top, .psx-main, .psx-foot { position: relative; z-index: 1; }

/* ---------- Barra superior ---------- */
.psx-top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 24px;
  background: rgba(10, 11, 16, .82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.psx-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.psx-brand-name { font-weight: 800; font-size: 18px; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.psx-badge {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(135deg, var(--psx-accent), var(--psx-accent-2));
  color: #fff; font-weight: 800; font-size: 15px; letter-spacing: .02em;
  box-shadow: 0 6px 20px rgba(109, 106, 245, .35);
}
.psx-badge-sm { width: 38px; height: 38px; font-size: 13px; border-radius: 11px; }

.psx-nav { display: flex; align-items: center; gap: 10px; }
.psx-nav-links { display: flex; align-items: center; gap: 4px; }
.psx-nav-link {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: 10px; border: 0; background: none; cursor: pointer;
  color: var(--psx-muted); font: 600 13px var(--psx-font); text-decoration: none;
}
.psx-nav-link:hover, .psx-nav-link.is-on { color: var(--psx-text); background: rgba(255, 255, 255, .06); }
.psx-nav-link i { font-size: 10px; }
.psx-nav-admin { color: #ffb4bb; border: 1px dashed rgba(240, 96, 110, .6); }
.psx-nav-icon { padding: 8px; color: var(--psx-muted); }
.psx-nav-icon:hover { color: var(--psx-text); }
.psx-nav-drop { position: relative; }
.psx-nav-menu {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 180px; z-index: 30;
  background: var(--psx-surface-2); border: 1px solid var(--psx-border); border-radius: 12px; padding: 6px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .5);
}
.psx-nav-menu a { display: block; padding: 8px 10px; border-radius: 8px; font-size: 13px; text-decoration: none; color: var(--psx-muted); }
.psx-nav-menu a:hover { background: rgba(255, 255, 255, .06); color: var(--psx-text); }
.psx-locale select {
  appearance: none; -webkit-appearance: none; cursor: pointer;
  background: var(--psx-field); color: var(--psx-text); border: 1px solid var(--psx-border);
  border-radius: 10px; padding: 7px 12px; font: 600 12px var(--psx-font); text-transform: uppercase;
}
.psx-locale select:focus { outline: none; border-color: var(--psx-accent); }

.psx-avatar-btn {
  display: none; width: 42px; height: 42px; border-radius: 50%; border: 0; cursor: pointer;
  background: linear-gradient(135deg, var(--psx-accent), var(--psx-accent-2)); color: #fff; font-size: 16px;
  box-shadow: 0 6px 20px rgba(109, 106, 245, .35);
}
.psx-drawer {
  position: fixed; top: 0; right: 0; z-index: 60; width: min(300px, 86vw); height: 100vh; height: 100dvh;
  display: flex; flex-direction: column; gap: 4px; padding: 64px 18px 18px;
  background: var(--psx-surface); border-left: 1px solid var(--psx-border);
  box-shadow: -20px 0 60px rgba(0, 0, 0, .6);
}
.psx-drawer a { padding: 12px 14px; border-radius: 12px; text-decoration: none; font-weight: 600; font-size: 14px; color: var(--psx-muted); }
.psx-drawer a:hover { background: rgba(255, 255, 255, .06); color: var(--psx-text); }
.psx-drawer .psx-locale { margin-top: 12px; padding: 0 14px; }
.psx-drawer-close { position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; border-radius: 10px; border: 0; cursor: pointer; background: rgba(255, 255, 255, .06); color: var(--psx-text); }

/* ---------- Contenido ---------- */
.psx-main {
  flex: 1; width: 100%; max-width: 760px; margin: 0 auto;
  display: flex; flex-direction: column; align-items: center; gap: 20px;
  padding: 56px 16px 64px;
}
.psx-actions { width: 100%; display: flex; flex-direction: column; align-items: center; gap: 20px; }

.psx-card {
  position: relative; width: 100%; max-width: 440px;
  background: linear-gradient(180deg, rgba(22, 27, 43, .96), rgba(13, 16, 27, .96));
  border: 1px solid var(--psx-border); border-radius: var(--psx-radius);
  padding: 22px 26px 24px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .04);
}
.psx-card::before {
  content: ""; position: absolute; left: 18px; right: 18px; top: -1px; height: 3px; border-radius: 0 0 4px 4px;
  background: linear-gradient(90deg, var(--psx-accent), var(--psx-accent-2));
}
.psx-card-wide { max-width: 760px; }
.psx-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.psx-card-title { font-weight: 700; font-size: 14px; }
.psx-card-kicker { font-weight: 700; font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--psx-muted); margin-top: 2px; }

.psx-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin-bottom: 22px; border-radius: 14px; background: rgba(5, 6, 10, .55); border: 1px solid var(--psx-border); }
.psx-tab {
  border: 0; cursor: pointer; padding: 10px 8px; border-radius: 10px; background: none;
  color: var(--psx-accent-2); font: 700 13px var(--psx-font); letter-spacing: .02em;
  transition: background .2s, color .2s;
}
.psx-tab:hover { background: rgba(255, 255, 255, .04); }
.psx-tab.is-on { color: #fff; background: linear-gradient(135deg, var(--psx-accent), #807df8); box-shadow: 0 6px 18px rgba(109, 106, 245, .35); }

.psx-title {
  margin: 0; text-align: center; font-size: 24px; font-weight: 800; letter-spacing: -.01em;
  background: linear-gradient(90deg, var(--psx-accent-2), var(--psx-accent)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.psx-sub { margin: 6px 0 0; text-align: center; color: var(--psx-muted); font-size: 13px; line-height: 1.5; }

.psx-form { margin-top: 20px; display: flex; flex-direction: column; }
.psx-label { display: block; font-weight: 700; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--psx-muted); margin: 14px 0 8px 2px; }
.psx-label-tight { display: inline; margin: 0; }
.psx-req { color: var(--psx-danger); }
.psx-field {
  position: relative; display: flex; align-items: center;
  background: var(--psx-field); border: 1px solid var(--psx-border-2); border-radius: var(--psx-radius-sm);
  transition: border-color .2s, box-shadow .2s;
}
.psx-field:focus-within { border-color: var(--psx-accent); box-shadow: 0 0 0 4px var(--psx-accent-soft); }
.psx-field > i:first-child { position: absolute; left: 16px; color: var(--psx-muted); font-size: 14px; pointer-events: none; }
.psx-field input, .psx-field select {
  width: 100%; height: 50px; padding: 0 44px 0 44px; border: 0; background: transparent;
  color: var(--psx-text); font: 500 15px var(--psx-font);
}
.psx-field input::placeholder { color: var(--psx-faint); }
.psx-field input:focus, .psx-field select:focus { outline: none; }
.psx-field select { appearance: none; -webkit-appearance: none; cursor: pointer; font-weight: 600; }
.psx-field select option { background: var(--psx-surface-2); color: var(--psx-text); }
.psx-caret { position: absolute; right: 16px; color: var(--psx-muted); font-size: 11px; pointer-events: none; }
.psx-captcha { display: flex; justify-content: center; margin-bottom: 6px; }

/* ---------- Validacion en vivo del correo ---------- */
.psx-field-mail input { padding-right: 46px; }
.psx-field-mail.is-ok  { border-color: #2fbf71; box-shadow: 0 0 0 4px rgba(47, 191, 113, .16); }
.psx-field-mail.is-bad { border-color: var(--psx-danger); box-shadow: 0 0 0 4px rgba(240, 96, 110, .14); }
.psx-mail-ok, .psx-mail-bad {
  position: absolute; right: 15px; top: 50%; transform: translateY(-50%) scale(.4);
  opacity: 0; pointer-events: none; display: flex; transition: opacity .2s, transform .25s;
}
.psx-mail-bad { color: var(--psx-danger); font-size: 18px; }
.psx-field-mail.is-ok  .psx-mail-ok  { opacity: 1; transform: translateY(-50%) scale(1); }
.psx-field-mail.is-bad .psx-mail-bad { opacity: 1; transform: translateY(-50%) scale(1); }
.psx-mail-ok svg { width: 24px; height: 24px; }
.psx-mail-ok svg circle { fill: #2fbf71; }
.psx-mail-ok svg path {
  fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 20; stroke-dashoffset: 20;
}
.psx-field-mail.is-ok .psx-mail-ok svg { animation: psx-ok-pop .32s ease-out; }
.psx-field-mail.is-ok .psx-mail-ok svg path { animation: psx-ok-draw .4s .08s ease-out forwards; }
@keyframes psx-ok-draw { to { stroke-dashoffset: 0; } }
@keyframes psx-ok-pop { 0% { transform: scale(.4); } 60% { transform: scale(1.18); } 100% { transform: scale(1); } }
.psx-mail-msg { display: flex; align-items: center; gap: 7px; margin: 8px 2px -2px; font-size: 13px; font-weight: 600; }
.psx-mail-msg.is-ok  { color: #37c97e; }
.psx-mail-msg.is-bad { color: var(--psx-danger); }
.psx-mail-msg.is-ok i { animation: psx-ok-pop .32s ease-out; }

.psx-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border: 0; cursor: pointer; border-radius: var(--psx-radius-sm);
  background: linear-gradient(90deg, var(--psx-accent), var(--psx-accent-2));
  color: #fff; font: 700 15px var(--psx-font);
  box-shadow: 0 12px 30px rgba(109, 106, 245, .35);
  transition: transform .15s, box-shadow .15s, filter .15s;
}
.psx-btn:hover { filter: brightness(1.07); box-shadow: 0 14px 36px rgba(109, 106, 245, .45); }
.psx-btn:active { transform: translateY(1px); }
.psx-btn-block { width: 100%; height: 54px; margin-top: 22px; }
.psx-btn-sm { padding: 8px 16px; font-size: 13px; }
.psx-btn i { margin-right: 6px; }

.psx-secure { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 18px; color: var(--psx-faint); font-size: 11.5px; font-weight: 500; }
.psx-secure i { font-size: 10px; margin-right: 3px; }
.psx-dot { color: var(--psx-muted); }

.psx-list { display: flex; flex-direction: column; gap: 8px; margin-top: 20px; }
.psx-list-item {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px; text-decoration: none;
  background: var(--psx-field); border: 1px solid var(--psx-border-2); border-radius: var(--psx-radius-sm);
  font-weight: 600; font-size: 14px; word-break: break-all;
}
.psx-list-item:hover { border-color: var(--psx-accent); }
.psx-list-item > i:first-child { color: var(--psx-accent-2); }
.psx-list-item span { flex: 1; }
.psx-list-go { color: var(--psx-faint); font-size: 11px; }
.psx-empty-sm { text-align: center; color: var(--psx-faint); font-size: 13px; padding: 18px 0; }

/* ---------- Barra del correo activo ---------- */
.psx-bar { max-width: 760px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 22px; }
.psx-bar-info { min-width: 0; flex: 1 1 260px; }
.psx-current { display: flex; align-items: center; gap: 10px; margin-top: 6px; font-size: 18px; font-weight: 700; word-break: break-all; }
.psx-current i { color: var(--psx-accent-2); }
.psx-bar-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.psx-tool {
  display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; cursor: pointer; text-decoration: none;
  border-radius: 11px; border: 1px solid var(--psx-border-2); background: var(--psx-field);
  color: var(--psx-text); font: 600 12.5px var(--psx-font);
}
.psx-tool:hover { border-color: var(--psx-accent); color: #fff; }
.psx-tool i { color: var(--psx-accent-2); }
.psx-tool-danger i { color: var(--psx-danger); }
.psx-tool-danger:hover { border-color: var(--psx-danger); }
.pause-spinner { animation-play-state: paused !important; }

.psx-counter {
  --psx-p: 0%;
  position: relative; width: 40px; height: 40px; border-radius: 50%; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: conic-gradient(var(--psx-accent) var(--psx-p), var(--psx-field) 0);
}
.psx-counter::after { content: ""; position: absolute; inset: 4px; border-radius: 50%; background: var(--psx-surface); }
.psx-counter .text { position: relative; z-index: 1; font-size: 12px; font-weight: 700; color: var(--psx-accent-2); }
.psx-counter .filler { display: none; }

/* ---------- Bandeja ---------- */
.psx-inbox-wrap { width: 100%; display: flex; justify-content: center; }
.psx-inbox { max-width: 760px; padding: 0; overflow: hidden; }
.psx-inbox-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 18px 22px; border-bottom: 1px solid var(--psx-border); font-weight: 700; font-size: 14px;
}
.psx-inbox-head > div > i { color: var(--psx-accent-2); margin-right: 8px; }
.psx-pill { min-width: 28px; padding: 3px 10px; border-radius: 999px; text-align: center; font-size: 12px; background: var(--psx-accent-soft); color: var(--psx-accent-2); }
.psx-messages { min-height: 120px; }
.psx-msg {
  display: flex; align-items: center; gap: 14px; padding: 16px 22px; cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, .05); transition: background .15s;
}
.psx-msg:hover { background: rgba(109, 106, 245, .08); }
.psx-avatar {
  flex: none; width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: var(--psx-accent-soft); color: var(--psx-accent-2); font-weight: 800; font-size: 16px;
}
.psx-msg-body { flex: 1; min-width: 0; }
.psx-msg-top { display: flex; justify-content: space-between; gap: 10px; }
.psx-msg-from { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.psx-msg-time { flex: none; font-size: 11.5px; color: var(--psx-muted); }
.psx-msg-subject { font-size: 13.5px; color: var(--psx-text); opacity: .9; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.psx-msg-email { font-size: 11.5px; color: var(--psx-faint); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.psx-back { border: 0; background: none; cursor: pointer; color: var(--psx-text); font: 700 13px var(--psx-font); display: inline-flex; align-items: center; gap: 8px; }
.psx-back i { color: var(--psx-accent-2); }
.psx-head-actions { display: flex; gap: 8px; }
.psx-open { padding: 20px 22px 24px; }
.psx-open-subject { font-size: 18px; font-weight: 800; line-height: 1.35; }
.psx-open-meta { display: flex; flex-direction: column; gap: 6px; margin: 12px 0 18px; font-size: 13px; color: var(--psx-text); }
.psx-open-meta .psx-label { margin-right: 6px; }
.psx-muted { color: var(--psx-muted); }
.psx-frame { background: #fff; border-radius: 14px; overflow: hidden; }
.psx-iframe { display: block; width: 100%; min-height: 520px; border: 0; }
.psx-attach { display: flex; flex-wrap: wrap; gap: 8px; }
.psx-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; text-decoration: none; font-size: 13px; background: var(--psx-field); border: 1px solid var(--psx-border-2); }
.psx-chip:hover { border-color: var(--psx-accent); }

.psx-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 48px 22px; text-align: center; }
.psx-empty > i { font-size: 34px; color: var(--psx-accent-2); opacity: .8; margin-bottom: 6px; }
.psx-empty-title { font-weight: 800; font-size: 17px; }

.psx-imap-error { position: fixed; inset: 0; z-index: 70; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(40, 6, 12, .85); }
.psx-imap-box { max-width: 460px; text-align: center; padding: 28px; border-radius: var(--psx-radius); background: var(--psx-surface); border: 1px solid var(--psx-danger); }
.psx-imap-box > i { font-size: 40px; color: var(--psx-danger); margin-bottom: 12px; }

/* Estados: formulario de ingreso vs. bandeja */
body.psx:not(.psx-in) .psx-bar,
body.psx:not(.psx-in) .psx-inbox-wrap { display: none; }
body.psx.psx-in .psx-login { display: none; }

/* ---------- Avisos / anuncios / páginas ---------- */
.psx-notice {
  width: 100%; max-width: 760px; padding: 12px 18px; border-radius: 14px; text-align: center;
  background: var(--psx-accent-soft); border: 1px solid rgba(109, 106, 245, .35); color: var(--psx-text);
  font-weight: 600; font-size: 14px; overflow-wrap: anywhere;
}
.psx-ad { width: 100%; max-width: 760px; display: flex; justify-content: center; align-items: center; color: var(--psx-muted); font-size: 12px; overflow-wrap: anywhere; word-break: break-word; }
.psx-page { color: var(--psx-text); padding: 0 !important; }
.psx-page a { color: var(--psx-accent-2); }

/* ---------- Pie ---------- */
.psx-foot {
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 16px 24px; font-size: 12px; color: var(--psx-muted);
  background: rgba(10, 11, 16, .82); border-top: 1px solid rgba(255, 255, 255, .06);
}
.psx-foot b { color: var(--psx-text); }
.psx-foot i { font-size: 10px; margin-right: 4px; }

.psx-cookie {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 80;
  justify-content: space-between; align-items: center; gap: 16px; padding: 14px 18px;
  background: var(--psx-surface-2); border: 1px solid var(--psx-border); border-radius: 16px;
  color: var(--psx-text); font-size: 13px; box-shadow: 0 20px 50px rgba(0, 0, 0, .6);
  max-width: 560px; margin: 0 auto;
}
.psx-cookie:not(.hidden) { display: flex !important; flex-wrap: nowrap; }
.psx-cookie > div:first-child { flex: 1; }
.psx-cookie #cookie_close { flex: none; }

/* ---------- Fuente: ignorar la fuente de títulos global de TMail ---------- */
.psx, .psx h1, .psx h2, .psx h3, .psx h4, .psx h5, .psx h6,
.psx button, .psx input, .psx select, .psx textarea { font-family: var(--psx-font) !important; }

/* ---------- Selector de plataforma ---------- */
:root {
  --nf: #e50914;
  --nf-2: #ff3b45;
  --dp: #0063e5;
  --dp-2: #19c3ff;
  --hbo: #8b3bff;
  --hbo-2: #6d8cff;
}
.psx-plats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.psx-plat {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; min-height: 86px; padding: 12px 6px;
  border-radius: 14px; border: 1px solid var(--psx-border-2); background: var(--psx-field);
  color: var(--psx-text); cursor: pointer; text-align: center;
  transition: border-color .2s, box-shadow .2s, transform .15s, background .2s;
}
.psx-plat:hover { transform: translateY(-2px); }
.psx-plat-name { font-weight: 700; font-size: 13px; }
.psx-plat-img { flex: none; width: 42px; height: 32px; object-fit: contain; }
.psx-plat-img-wide { width: 58px; height: 30px; }
.psx-plat-netflix .psx-plat-img { filter: drop-shadow(0 4px 10px rgba(229, 9, 20, .35)); }
.psx-plat-disney .psx-plat-img { filter: drop-shadow(0 0 8px rgba(25, 160, 255, .55)); }
.psx-plat-hbo .psx-plat-img { filter: drop-shadow(0 0 9px rgba(139, 59, 255, .6)); }
.psx-plat-check { position: absolute; top: 7px; right: 8px; opacity: 0; transform: scale(.6); transition: opacity .2s, transform .2s; font-size: 15px; }
.psx-plat.is-on .psx-plat-check { opacity: 1; transform: scale(1); }
.psx-plat-netflix.is-on { border-color: var(--nf); background: linear-gradient(135deg, rgba(229, 9, 20, .16), rgba(229, 9, 20, .04)); box-shadow: 0 0 0 4px rgba(229, 9, 20, .14); }
.psx-plat-netflix.is-on .psx-plat-check { color: var(--nf-2); }
.psx-plat-disney.is-on { border-color: var(--dp-2); background: linear-gradient(135deg, rgba(0, 99, 229, .2), rgba(25, 195, 255, .05)); box-shadow: 0 0 0 4px rgba(25, 195, 255, .14); }
.psx-plat-disney.is-on .psx-plat-check { color: var(--dp-2); }
.psx-plat-hbo.is-on { border-color: var(--hbo); background: linear-gradient(135deg, rgba(139, 59, 255, .2), rgba(109, 140, 255, .05)); box-shadow: 0 0 0 4px rgba(139, 59, 255, .16); }
.psx-plat-hbo.is-on .psx-plat-check { color: var(--hbo-2); }

.psx-error {
  margin-top: 14px; padding: 10px 14px; border-radius: 10px; font-size: 13px; font-weight: 600;
  color: #ffd0d4; background: rgba(240, 96, 110, .12); border: 1px solid rgba(240, 96, 110, .4);
}

.psx-plat-tag {
  display: inline-flex; align-items: center; height: 22px; padding: 0 10px; margin-left: 8px; border-radius: 999px;
  font-size: 11px; font-weight: 800; color: #fff; vertical-align: middle; letter-spacing: .02em;
}
.psx-plat-tag.is-netflix { background: linear-gradient(135deg, var(--nf), #a30610); }
.psx-plat-tag.is-disney { background: linear-gradient(135deg, var(--dp), #0aa5e6); }
.psx-plat-tag.is-hbo { background: linear-gradient(135deg, var(--hbo), #4b32d8); }

/* ---------- Filtro de la bandeja ---------- */
.psx-inbox-head > div:first-child { display: flex; align-items: center; gap: 4px; }
.psx-inbox-head .psx-pill { margin-left: 8px; }
.psx-filter { display: flex; gap: 6px; }
.psx-fchip {
  height: 32px; padding: 0 12px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--psx-border-2); background: var(--psx-field); color: var(--psx-muted);
  font: 700 12px var(--psx-font);
}
.psx-fchip:hover { color: var(--psx-text); }
.psx-fchip.is-on { color: #fff; border-color: transparent; background: linear-gradient(135deg, var(--psx-accent), var(--psx-accent-2)); }
.psx-fchip-netflix.is-on { background: linear-gradient(135deg, var(--nf), #a30610); }
.psx-fchip-disney.is-on { background: linear-gradient(135deg, var(--dp), #0aa5e6); }
.psx-fchip-hbo.is-on { background: linear-gradient(135deg, var(--hbo), #4b32d8); }
body[data-plat="netflix"] .psx-avatar { background: rgba(229, 9, 20, .16); color: var(--nf-2); }
body[data-plat="disney"] .psx-avatar { background: rgba(25, 195, 255, .14); color: var(--dp-2); }
body[data-plat="hbo"] .psx-avatar { background: rgba(139, 59, 255, .16); color: var(--hbo-2); }

/* =========================================================================
   Fondo animado: Netflix + Disney+ + HBO Max (órbitas)
   ========================================================================= */
.psx-bg { overflow: hidden; }

.psx-aurora { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; will-change: transform; }
.psx-aurora-red { width: 46vw; height: 46vw; left: -12vw; top: 8vh; background: radial-gradient(circle, rgba(229, 9, 20, .55), transparent 65%); animation: psx-drift-a 22s ease-in-out infinite alternate; }
.psx-aurora-blue { width: 50vw; height: 50vw; right: -14vw; bottom: -10vh; background: radial-gradient(circle, rgba(0, 99, 229, .6), transparent 65%); animation: psx-drift-b 26s ease-in-out infinite alternate; }
.psx-aurora-violet { width: 36vw; height: 36vw; left: 32vw; top: 30vh; background: radial-gradient(circle, rgba(109, 106, 245, .45), transparent 65%); opacity: .35; animation: psx-drift-c 30s ease-in-out infinite alternate; }
@keyframes psx-drift-a { to { transform: translate(14vw, 18vh) scale(1.15); } }
@keyframes psx-drift-b { to { transform: translate(-16vw, -14vh) scale(1.1); } }
@keyframes psx-drift-c { 0% { transform: translate(-8vw, -6vh) scale(.9); } 100% { transform: translate(10vw, 8vh) scale(1.2); } }

/* Sistema orbital: cada plataforma gira en su elipse como un planeta con estela de cometa.
   Cadena de transformaciones: órbita (inclinar + aplastar) > brazo (gira) > planeta (gira al revés)
   > fix (des-aplasta y des-inclina) — así el logo siempre queda derecho y sin deformarse. */
.psx-orbits { position: absolute; inset: 0; --sq: .34; --isq: 2.94; }
.psx-core {
  position: absolute; left: 50%; top: 46%; width: 34vmin; height: 34vmin; transform: translate(-50%, -50%);
  border-radius: 50%; background: radial-gradient(circle, rgba(154, 152, 255, .28), rgba(109, 106, 245, .08) 45%, transparent 70%);
  animation: psx-core 7s ease-in-out infinite;
}
@keyframes psx-core { 0%, 100% { transform: translate(-50%, -50%) scale(.9); opacity: .6; } 50% { transform: translate(-50%, -50%) scale(1.12); opacity: 1; } }

/* Rayos de luz que giran muy lento detras del sistema orbital */
.psx-rays {
  position: absolute; left: 50%; top: 46%; width: 130vmax; height: 130vmax; margin: -65vmax 0 0 -65vmax; border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, rgba(154, 152, 255, .10) 0deg 4deg, transparent 4deg 18deg, rgba(229, 9, 20, .06) 18deg 21deg, transparent 21deg 33deg, rgba(25, 195, 255, .07) 33deg 37deg, transparent 37deg 45deg);
  -webkit-mask: radial-gradient(circle, #000 0, rgba(0, 0, 0, .6) 25%, transparent 62%);
          mask: radial-gradient(circle, #000 0, rgba(0, 0, 0, .6) 25%, transparent 62%);
  animation: psx-spin 120s linear infinite;
}
@keyframes psx-spin { to { transform: rotate(360deg); } }

/* Ondas de energia que se expanden desde el centro */
.psx-wave {
  position: absolute; left: 50%; top: 46%; width: 24vmax; height: 24vmax; margin: -12vmax 0 0 -12vmax; border-radius: 50%;
  border: 1.5px solid rgba(154, 152, 255, .4); opacity: 0;
  animation: psx-wave-out 7.8s ease-out var(--dl) infinite;
}
@keyframes psx-wave-out {
  0%   { transform: scale(.2); opacity: 0; }
  12%  { opacity: .5; }
  100% { transform: scale(3.4); opacity: 0; border-color: rgba(109, 106, 245, 0); }
}

/* Estrellas fugaces */
.psx-star {
  position: absolute; width: 2px; height: 2px; border-radius: 50%; background: #fff; opacity: 0;
  animation: psx-shoot var(--d) ease-in var(--dl) infinite;
}
.psx-star::after {
  content: ""; position: absolute; right: 1px; top: 50%; width: 120px; height: 1.5px; transform: translateY(-50%);
  background: linear-gradient(270deg, currentColor, transparent);
}
.psx-star.is-nf  { color: rgba(255, 90, 100, .9); box-shadow: 0 0 8px 2px rgba(229, 9, 20, .7); }
.psx-star.is-dp  { color: rgba(90, 200, 255, .9); box-shadow: 0 0 8px 2px rgba(25, 195, 255, .7); }
.psx-star.is-hbo { color: rgba(180, 130, 255, .9); box-shadow: 0 0 8px 2px rgba(139, 59, 255, .7); }
@keyframes psx-shoot {
  0%        { transform: translate3d(0, 0, 0); opacity: 0; }
  3%        { opacity: 1; }
  11%       { transform: translate3d(-42vw, 26vh, 0); opacity: 0; }
  100%      { transform: translate3d(-42vw, 26vh, 0); opacity: 0; }
}

.psx-orbit {
  /* min(): en pantallas altas (celular en "modo computadora") vmax = alto y las órbitas salían gigantes */
  --oc: 154, 152, 255; --rr: calc(var(--rn) * min(1vmax, 1.25vw));
  position: absolute; left: 50%; top: 46%; width: 0; height: 0;
  transform: rotate(var(--tilt)) scaleY(var(--sq));
}
.psx-orbit.is-nf  { --oc: 229, 9, 20; }
.psx-orbit.is-dp  { --oc: 25, 195, 255; }
.psx-orbit.is-hbo { --oc: 139, 59, 255; }
.psx-orbit-ring, .psx-orbit-trail {
  position: absolute; left: calc(var(--rr) * -1); top: calc(var(--rr) * -1);
  width: calc(var(--rr) * 2); height: calc(var(--rr) * 2); border-radius: 50%;
}
.psx-orbit-ring { border: 2px dashed rgba(var(--oc), .22); box-shadow: 0 0 40px rgba(var(--oc), .08), inset 0 0 40px rgba(var(--oc), .06); }
.psx-orbit-arm { position: absolute; left: 0; top: 0; width: 0; height: 0; animation: psx-orbit var(--d) linear var(--dl) infinite; }
.psx-orbit-trail {
  background: conic-gradient(from -20deg, transparent 0deg, rgba(var(--oc), .05) 40deg, rgba(var(--oc), .85) 110deg, transparent 110.5deg);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
  filter: blur(1px);
}
.psx-planet { position: absolute; left: var(--rr); top: 0; width: 0; height: 0; animation: psx-orbit-back var(--d) linear var(--dl) infinite; }
.psx-planet-fix { position: absolute; width: 0; height: 0; transform: scaleY(var(--isq)) rotate(calc(var(--tilt) * -1)); }
.psx-planet-body {
  position: absolute; left: -38px; top: -38px; width: 76px; height: 76px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .22), rgba(var(--oc), .22) 45%, rgba(10, 12, 22, .85) 75%);
  border: 1px solid rgba(var(--oc), .55);
  box-shadow: 0 0 26px rgba(var(--oc), .55), inset 0 0 18px rgba(var(--oc), .35);
  animation: psx-depth var(--d) linear var(--dl) infinite;
}
.psx-planet-body img { width: 64%; height: auto; max-height: 56%; object-fit: contain; user-select: none; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .6)); }
.psx-orbit.is-nf .psx-planet-body img { width: 40%; max-height: 62%; }
/* Lunita al lado opuesto del planeta */
.psx-moon {
  position: absolute; left: calc(var(--rr) * -1); top: 0; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%;
  background: rgb(var(--oc)); box-shadow: 0 0 12px 3px rgba(var(--oc), .8); transform: scaleY(var(--isq)); opacity: .7;
}
@keyframes psx-orbit { to { transform: rotate(360deg); } }
@keyframes psx-orbit-back { to { transform: rotate(-360deg); } }
/* Profundidad: el planeta crece al pasar por delante (abajo) y se achica por detrás (arriba) */
@keyframes psx-depth {
  0%   { transform: scale(.9);  opacity: .5; }
  25%  { transform: scale(1.2); opacity: .85; }
  50%  { transform: scale(.9);  opacity: .5; }
  75%  { transform: scale(.6);  opacity: .22; }
  100% { transform: scale(.9);  opacity: .5; }
}

/* Códigos que suben como burbujas */
.psx-code {
  position: absolute; bottom: -8vh; font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-weight: 700; font-size: calc(17px * var(--s)); letter-spacing: .28em; padding: 4px 6px 4px 9px; border-radius: 8px;
  color: rgba(var(--cc), .9); background: rgba(var(--cc), .07); border: 1px solid rgba(var(--cc), .25);
  text-shadow: 0 0 12px rgba(var(--cc), .9); opacity: 0; will-change: transform, opacity;
  animation: psx-code-rise var(--d) linear var(--dl) infinite;
}
.psx-code.is-nf  { --cc: 255, 70, 80; }
.psx-code.is-dp  { --cc: 60, 200, 255; }
.psx-code.is-hbo { --cc: 170, 120, 255; }
/* Solo transform y opacity: la tarjeta gráfica los mueve sin redibujar (antes animaba blur y trababa) */
@keyframes psx-code-rise {
  0%   { transform: translate3d(0, 0, 0) scale(.8); opacity: 0; }
  12%  { opacity: .45; }
  50%  { transform: translate3d(18px, -60vh, 0) scale(1); }
  80%  { opacity: .3; }
  100% { transform: translate3d(-12px, -118vh, 0) scale(.9); opacity: 0; }
}

/* Destellos */
.psx-spark {
  position: absolute; width: 3px; height: 3px; border-radius: 50%; background: #fff;
  box-shadow: 0 0 8px 2px rgba(160, 200, 255, .8); opacity: 0;
  animation: psx-twinkle var(--d) ease-in-out var(--dl) infinite;
}
@keyframes psx-twinkle { 0%, 100% { opacity: 0; transform: scale(.4); } 50% { opacity: .8; transform: scale(1); } }

/* Viñeta para que el contenido siga siendo legible */
.psx-vignette { position: absolute; inset: 0; background: radial-gradient(ellipse 60% 70% at 50% 45%, rgba(5, 6, 10, .78), rgba(5, 6, 10, .25) 70%, rgba(5, 6, 10, .55)); }

@media (prefers-reduced-motion: reduce) {
  .psx-aurora, .psx-orbit-arm, .psx-planet, .psx-planet-body, .psx-core, .psx-code, .psx-spark, .psx-rays, .psx-wave, .psx-star, .psx-btn-fx, .psx-btn-shine { animation: none !important; }
  .psx-code, .psx-orbit-trail, .psx-wave, .psx-star { display: none; }
}

/* ---------- Menú de la personita (arriba a la derecha) ---------- */
.psx-top { z-index: 40; }
.psx .psx-avatar-btn { display: inline-flex; align-items: center; justify-content: center; transition: transform .15s, box-shadow .15s; }
.psx .psx-avatar-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 26px rgba(109, 106, 245, .5); }
.psx-menu-wrap { position: relative; }
.psx-menu {
  position: absolute; right: 0; top: calc(100% + 12px); width: 300px; max-width: calc(100vw - 32px); z-index: 50;
  padding: 10px; border-radius: 18px;
  background: linear-gradient(180deg, rgba(24, 29, 46, .98), rgba(14, 17, 28, .98));
  border: 1px solid var(--psx-border); box-shadow: 0 24px 60px rgba(0, 0, 0, .6);
  transform-origin: top right;
}
.psx-menu::before { content: ""; position: absolute; right: 16px; top: -6px; width: 12px; height: 12px; transform: rotate(45deg); background: #181d2e; border-left: 1px solid var(--psx-border); border-top: 1px solid var(--psx-border); }
.psx-menu-enter { transition: opacity .16s ease-out, transform .16s ease-out; }
.psx-menu-from { opacity: 0; transform: translateY(-6px) scale(.97); }
.psx-menu-to { opacity: 1; transform: translateY(0) scale(1); }
.psx-menu-hello { display: flex; align-items: center; gap: 12px; padding: 10px 10px 14px; margin-bottom: 6px; border-bottom: 1px solid var(--psx-border); }
.psx-menu-wave { font-size: 26px; display: inline-block; transform-origin: 70% 70%; animation: psx-wave 2.4s ease-in-out infinite; }
@keyframes psx-wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(16deg); } 20%, 40% { transform: rotate(-8deg); } }
.psx-menu-title { font-weight: 800; font-size: 16px; }
.psx-menu-sub { font-size: 12.5px; color: var(--psx-muted); margin-top: 2px; }
.psx-menu-item {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 10px; border: 0; border-radius: 12px;
  background: none; color: var(--psx-text); text-align: left; text-decoration: none; cursor: pointer;
}
.psx-menu-item:hover { background: rgba(255, 255, 255, .05); }
.psx-menu-ico { flex: none; width: 38px; height: 38px; border-radius: 11px; display: flex; align-items: center; justify-content: center; font-size: 16px; color: #fff; }
.psx-menu-ico.is-violet { background: linear-gradient(135deg, var(--psx-accent), var(--psx-accent-2)); }
.psx-menu-ico.is-green { background: linear-gradient(135deg, #25d366, #128c4a); font-size: 19px; }
.psx-menu-ico.is-red { background: linear-gradient(135deg, var(--nf), #8f050c); }
.psx-menu-text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.psx-menu-text b { font-size: 14px; font-weight: 700; }
.psx-menu-text small { font-size: 11.5px; color: var(--psx-muted); margin-top: 1px; }

/* ---------- Franja animada de logos (Netflix · Disney+ · HBO Max) ---------- */
.psx-hero {
  position: relative; width: 100%; max-width: 440px; height: 96px;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
  border-radius: 18px; background: rgba(15, 19, 32, .72);
  border: 1px solid var(--psx-border); backdrop-filter: blur(6px);
}
.psx-hero-glow {
  position: absolute; inset: -45% -12%; pointer-events: none; z-index: 0;
  background:
    radial-gradient(42% 60% at 20% 50%, rgba(229, 9, 20, .30), transparent 70%),
    radial-gradient(42% 60% at 50% 50%, rgba(25, 160, 255, .28), transparent 70%),
    radial-gradient(42% 60% at 80% 50%, rgba(139, 59, 255, .34), transparent 70%);
  filter: blur(16px); animation: psx-hero-glow 9s ease-in-out infinite;
}
@keyframes psx-hero-glow {
  0%, 100% { transform: translateX(-12%) scale(1.05); opacity: .85; }
  50%      { transform: translateX(12%) scale(1.12); opacity: 1; }
}
.psx-hero-stage { position: relative; z-index: 1; width: 160px; height: 52px; }
.psx-hero-logo {
  position: absolute; inset: 0; margin: auto; display: block;
  max-width: 100%; max-height: 100%; object-fit: contain;
  opacity: 0; transform: translateY(16px) scale(.9);
  filter: drop-shadow(0 0 18px rgba(255, 255, 255, .2));
  animation: psx-hero-cycle 9s ease-in-out infinite;
}
.psx-hero-logo.is-nf  { width: 126px; animation-delay: 0s; }
.psx-hero-logo.is-dp  { width: 96px;  animation-delay: 3s; }
.psx-hero-logo.is-hbo { width: 120px; animation-delay: 6s; }
@keyframes psx-hero-cycle {
  0%   { opacity: 0; transform: translateY(16px) scale(.9); }
  6%   { opacity: 1; transform: translateY(0) scale(1); }
  28%  { opacity: 1; transform: translateY(0) scale(1); }
  34%  { opacity: 0; transform: translateY(-16px) scale(.92); }
  100% { opacity: 0; transform: translateY(-16px) scale(.92); }
}
.psx-hero-dots { position: absolute; z-index: 1; bottom: 11px; left: 0; right: 0; display: flex; justify-content: center; gap: 7px; }
.psx-hero-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .25); animation: psx-hero-dot 9s ease-in-out infinite; }
.psx-hero-dot.d1 { animation-delay: 3s; }
.psx-hero-dot.d2 { animation-delay: 6s; }
@keyframes psx-hero-dot {
  0%, 34%, 100% { background: rgba(255, 255, 255, .25); transform: scale(1); }
  5%, 29%       { background: #fff; transform: scale(1.4); }
}
@media (prefers-reduced-motion: reduce) {
  .psx-hero-glow, .psx-hero-logo, .psx-hero-dot { animation: none; }
  .psx-hero-logo { opacity: 1; transform: none; }
  .psx-hero-logo.is-dp, .psx-hero-logo.is-hbo { opacity: 0; }
}
body.psx.psx-in .psx-hero { max-width: 760px; }
.psx-brand-name { font-size: 16px; }

/* ---------- Efecto del botón Buscar ---------- */
.psx-btn-fx {
  position: relative; overflow: hidden; isolation: isolate;
  background: linear-gradient(90deg, #5b57f0, #8f8cff, #5b57f0); background-size: 200% 100%;
  animation: psx-btn-flow 6s linear infinite, psx-btn-glow 2.8s ease-in-out infinite;
  transition: transform .18s cubic-bezier(.2, .8, .2, 1), filter .18s;
}
.psx-btn-fx:hover { transform: translateY(-2px); filter: brightness(1.1); }
.psx-btn-fx:active { transform: translateY(1px) scale(.985); }
.psx-btn-fx:disabled { cursor: wait; filter: saturate(.7); }
@keyframes psx-btn-flow { to { background-position: -200% 0; } }
@keyframes psx-btn-glow {
  0%, 100% { box-shadow: 0 10px 28px rgba(109, 106, 245, .35), 0 0 0 0 rgba(154, 152, 255, .0); }
  50% { box-shadow: 0 14px 40px rgba(109, 106, 245, .55), 0 0 0 6px rgba(154, 152, 255, .12); }
}
.psx-btn-shine {
  position: absolute; top: 0; bottom: 0; left: -60%; width: 45%; z-index: -1; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent);
  transform: skewX(-20deg); animation: psx-shine 3.2s ease-in-out infinite;
}
@keyframes psx-shine { 0%, 55% { left: -60%; } 85%, 100% { left: 130%; } }
.psx-btn-label { display: inline-flex; align-items: center; gap: 10px; }
.psx-btn-label i { margin-right: 0; }
.psx-btn-arrow { font-size: 12px; opacity: 0; transform: translateX(-8px); transition: opacity .2s, transform .2s; }
.psx-btn-fx:hover .psx-btn-arrow { opacity: 1; transform: translateX(0); }
.psx-btn-fx:hover .fa-search { animation: psx-search-wiggle .6s ease; }
@keyframes psx-search-wiggle { 0%, 100% { transform: rotate(0); } 30% { transform: rotate(-14deg) scale(1.1); } 60% { transform: rotate(10deg) scale(1.1); } }
.psx-ripple { position: absolute; border-radius: 50%; background: rgba(255, 255, 255, .35); transform: scale(0); animation: psx-ripple .65s ease-out forwards; pointer-events: none; }
@keyframes psx-ripple { to { transform: scale(1); opacity: 0; } }

.psx-locked > i { color: var(--psx-accent-2); }

/* ---------- Tarjeta "Código encontrado" ---------- */
.psx-found-list { padding: 18px; display: flex; flex-direction: column; gap: 16px; }
.psx-found {
  border: 1px solid var(--psx-border-2); border-radius: 18px; padding: 20px;
  background: linear-gradient(180deg, rgba(26, 32, 50, .9), rgba(16, 20, 32, .9));
  animation: psx-pop .35s cubic-bezier(.2, .8, .2, 1);
}
@keyframes psx-pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
.psx-found-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.psx-found-check {
  flex: none; width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff; font-size: 19px;
  box-shadow: 0 0 0 6px rgba(34, 197, 94, .14), 0 10px 24px rgba(34, 197, 94, .3);
}
.psx-found-title { font-size: 20px; font-weight: 800; letter-spacing: -.01em; }
.psx-found-plat { display: inline-block; margin-top: 4px; padding: 3px 12px; border-radius: 999px; font-size: 12px; font-weight: 800; color: #fff; background: var(--psx-accent); }
.psx-found-plat.is-netflix { background: linear-gradient(135deg, var(--nf), #a30610); }
.psx-found-plat.is-disney { background: linear-gradient(135deg, var(--dp), #0aa5e6); }
.psx-found-plat.is-hbo { background: linear-gradient(135deg, var(--hbo), #4b32d8); }
.psx-found-meta { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; margin-bottom: 14px; border-radius: 14px; background: rgba(5, 6, 10, .45); border: 1px solid var(--psx-border); }
.psx-found-row { display: grid; grid-template-columns: 92px 1fr; gap: 10px; font-size: 14px; }
.psx-found-k { color: var(--psx-muted); font-weight: 700; }
.psx-found-v { font-weight: 600; word-break: break-word; }
/* Vista del correo en formato horizontal (más ancha que alta) */
body.psx.psx-in .psx-main { max-width: 940px; }
body.psx.psx-in .psx-bar, body.psx.psx-in .psx-inbox, body.psx.psx-in .psx-hero { max-width: 940px; }
.psx-found .psx-frame { border-radius: 14px; }
.psx-found .psx-iframe { min-height: 0; height: 400px; display: block; }
.psx-found .psx-found-timer { margin: 0 0 14px; }
.psx-found-timer {
  display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 14px; padding: 12px 14px;
  border-radius: 14px; font-size: 14px; color: #ffe2a8; text-align: center;
  background: rgba(245, 158, 11, .1); border: 1px solid rgba(245, 158, 11, .35);
}
.psx-found-timer b { color: #ffc861; }
.psx-found-timer-ico { font-size: 18px; }
.psx-found-close { height: 52px; margin-top: 4px; }
.psx-found-close i { margin-right: 4px; }

/* ---------- Celular ---------- */
@media (max-width: 860px) {
  .psx-nav-links { display: none; }
  .psx-avatar-btn { display: inline-flex; align-items: center; justify-content: center; }
}
@media (max-width: 560px) {
  .psx-top { padding: 12px 16px; }
  .psx-brand-name { font-size: 16px; }
  .psx-main { padding: 28px 16px 48px; gap: 16px; }
  .psx-card { padding: 20px 18px 22px; border-radius: 20px; }
  .psx-inbox { padding: 0; }
  .psx-title { font-size: 22px; }
  .psx-bar { padding: 16px; }
  .psx-bar-tools { width: 100%; }
  .psx-tool span { display: none; }
  .psx-tool { flex: 1; justify-content: center; }
  .psx-inbox-head, .psx-msg, .psx-open { padding-left: 16px; padding-right: 16px; }
  .psx-iframe { min-height: 420px; }
  .psx-found .psx-iframe { min-height: 0; height: 340px; }
  .psx-found-list { padding: 12px; }
  .psx-found { padding: 16px; }
  .psx-found-row { grid-template-columns: 78px 1fr; font-size: 13px; }
  .psx-plats { gap: 7px; }
  .psx-plat { min-height: 78px; padding: 10px 4px; gap: 6px; }
  .psx-plat-img { width: 38px; height: 28px; }
  .psx-plat-img-wide { width: 52px; height: 26px; }
  .psx-plat-name { font-size: 11.5px; }
  .psx-plat-check { top: 5px; right: 5px; font-size: 13px; }
  .psx-hero { height: 84px; }
  .psx-filter { width: 100%; }
  .psx-fchip { flex: 1; }
  .psx-orbits { --sq: .5; --isq: 2; }
  .psx-orbit { --rr: calc(var(--rn) * 1.05vw); }
  .psx-planet-body { left: -29px; top: -29px; width: 58px; height: 58px; }
  .psx-code { font-size: calc(13px * var(--s)); }
  .psx-foot { justify-content: center; text-align: center; padding: 14px 16px; }
}

/* ---------- Pantallas táctiles (celular / tablet), también en "modo computadora" ----------
   Estas reglas dependen del tipo de pantalla, no del ancho, así que siguen activas
   cuando el navegador del celular finge ser una computadora (980px de ancho). */
@media (hover: none) and (pointer: coarse) {
  /* El fondo no cambia de tamaño cuando aparece/desaparece la barra del navegador (evita saltos) */
  .psx-bg { bottom: auto; height: 100vh; height: 100lvh; }
  /* Efectos muy pesados para el celular: se apagan o se aligeran */
  .psx-rays { animation: none; }
  .psx-wave { display: none; }
  .psx-aurora { filter: blur(40px); will-change: auto; }
  .psx-spark:nth-child(2n) { display: none; }
  .psx-code:nth-of-type(2n) { display: none; }
  .psx-top, .psx-hero { backdrop-filter: none; }
  /* En táctil el :hover se queda "pegado" después de tocar: se anula el movimiento */
  .psx-plat:hover, .psx-btn-fx:hover, .psx .psx-avatar-btn:hover { transform: none; }
  .psx-btn-fx:hover .psx-btn-arrow { opacity: 0; transform: translateX(-8px); }
  .psx-btn-fx:hover .fa-search { animation: none; }
}

/* Celular en "modo computadora": pantalla táctil, ancha (>860px) pero mucho más alta que ancha.
   El navegador encoge toda la página para que entre y el formulario quedaba diminuto:
   se agranda el contenido para que se vea igual que en la vista de celular. */
@media (hover: none) and (pointer: coarse) and (min-width: 861px) and (max-aspect-ratio: 2/3) {
  .psx-top, .psx-main, .psx-foot { zoom: 1.9; }
  .psx-nav-links { display: none; }
  .psx-avatar-btn { display: inline-flex; align-items: center; justify-content: center; }
  .psx-main { padding: 24px 12px 32px; gap: 16px; }
  .psx-orbit, .psx-core, .psx-rays, .psx-wave { top: 30%; }
}
/* Lo mismo, detectado por JavaScript (algunos navegadores en modo computadora dicen tener mouse) */
html.psx-deskm .psx-top, html.psx-deskm .psx-main, html.psx-deskm .psx-foot { zoom: 1.9; }
html.psx-deskm .psx-nav-links { display: none; }
html.psx-deskm .psx-main { padding: 24px 12px 32px; gap: 16px; }
html.psx-deskm .psx-orbit, html.psx-deskm .psx-core { top: 30%; }
html.psx-deskm .psx-bg { bottom: auto; height: 100vh; height: 100lvh; }
html.psx-deskm .psx-plat:hover, html.psx-deskm .psx-btn-fx:hover { transform: none; }

/* ---------- Modo liviano (celular en modo computadora o equipo lento) ----------
   Se quita lo que obliga a redibujar en cada cuadro: desenfoques, sombras animadas,
   fondos que se desplazan y decenas de partículas. Las órbitas con los logos se mantienen. */
html.psx-lite .psx-aurora { filter: none; animation: none; will-change: auto; opacity: .3; }
html.psx-lite .psx-rays, html.psx-lite .psx-wave, html.psx-lite .psx-orbit-trail,
html.psx-lite .psx-star, html.psx-lite .psx-code, html.psx-lite .psx-moon, html.psx-lite .psx-btn-shine { display: none; }
html.psx-lite .psx-spark { display: none; box-shadow: none; animation: none; }
html.psx-lite .psx-spark:nth-child(4n) { display: block; opacity: .45; }
html.psx-lite .psx-core { animation: none; opacity: .8; }
html.psx-lite .psx-orbit-ring { box-shadow: none; }
html.psx-lite .psx-planet-body { box-shadow: 0 0 14px rgba(var(--oc), .45); }
html.psx-lite .psx-planet-body img, html.psx-lite .psx-hero-logo { filter: none; }
html.psx-lite .psx-hero-glow { filter: none; animation: none; opacity: .7; }
html.psx-lite .psx-top, html.psx-lite .psx-hero { backdrop-filter: none; -webkit-backdrop-filter: none; }
html.psx-lite .psx-btn-fx { animation: none; background-position: 0 0; box-shadow: 0 10px 28px rgba(109, 106, 245, .35); }
html.psx-lite .psx-menu-wave { animation: none; }

/* ---------- IAs: Claude, ChatGPT y Qwen ---------- */
:root {
  --cl: #d97757;
  --cl-2: #f0a080;
  --gpt: #10a37f;
  --gpt-2: #3fd6a8;
  --qw: #6f69f7;
  --qw-2: #a5a1ff;
}
.psx-cats { margin: 0 0 4px; }
.psx-cats .psx-tab i { margin-right: 6px; font-size: 12px; }
.psx-hint { display: flex; align-items: center; gap: 7px; margin: 8px 2px 0; font-size: 12.5px; color: var(--psx-muted); }
.psx-hint i { color: var(--psx-accent-2); }
.psx-plat-claude .psx-plat-img { filter: drop-shadow(0 0 8px rgba(217, 119, 87, .5)); }
.psx-plat-chatgpt .psx-plat-img { filter: drop-shadow(0 0 8px rgba(16, 163, 127, .55)); }
.psx-plat-qwen .psx-plat-img { filter: drop-shadow(0 0 8px rgba(111, 105, 247, .6)); }
.psx-plat-claude.is-on { border-color: var(--cl); background: linear-gradient(135deg, rgba(217, 119, 87, .2), rgba(217, 119, 87, .04)); box-shadow: 0 0 0 4px rgba(217, 119, 87, .14); }
.psx-plat-claude.is-on .psx-plat-check { color: var(--cl-2); }
.psx-plat-chatgpt.is-on { border-color: var(--gpt); background: linear-gradient(135deg, rgba(16, 163, 127, .2), rgba(16, 163, 127, .04)); box-shadow: 0 0 0 4px rgba(16, 163, 127, .14); }
.psx-plat-chatgpt.is-on .psx-plat-check { color: var(--gpt-2); }
.psx-plat-qwen.is-on { border-color: var(--qw); background: linear-gradient(135deg, rgba(111, 105, 247, .22), rgba(165, 161, 255, .05)); box-shadow: 0 0 0 4px rgba(111, 105, 247, .16); }
.psx-plat-qwen.is-on .psx-plat-check { color: var(--qw-2); }
.psx-plat-tag.is-claude, .psx-found-plat.is-claude { background: linear-gradient(135deg, var(--cl), #a9502f); }
.psx-plat-tag.is-chatgpt, .psx-found-plat.is-chatgpt { background: linear-gradient(135deg, var(--gpt), #0b7358); }
.psx-plat-tag.is-qwen, .psx-found-plat.is-qwen { background: linear-gradient(135deg, var(--qw), #4b32d8); }
body[data-plat="claude"] .psx-avatar { background: rgba(217, 119, 87, .16); color: var(--cl-2); }
body[data-plat="chatgpt"] .psx-avatar { background: rgba(16, 163, 127, .16); color: var(--gpt-2); }
body[data-plat="qwen"] .psx-avatar { background: rgba(111, 105, 247, .16); color: var(--qw-2); }
/* Clave vencida o consulta cerrada: solo se ve el aviso */
body.psx-ai-off .psx-inbox > :not(.psx-ai-locked) { display: none !important; }
body.psx-ai-off .psx-inbox > .psx-ai-locked { display: flex !important; }
.psx-ai-locked > i { color: var(--psx-accent-2); }
/* Aviso en la tarjeta: la clave ya mostró su único código */
.psx-found-once {
  display: flex; align-items: center; gap: 10px; margin: -4px 0 14px; padding: 11px 14px; border-radius: 14px;
  font-size: 13px; line-height: 1.45; color: var(--psx-text);
  background: var(--psx-accent-soft); border: 1px solid rgba(109, 106, 245, .4);
}
.psx-found-once i { color: var(--psx-accent-2); flex: none; }
.psx-found-once b { color: #fff; }
