/* Magnifico Store: blanco y negro, Montserrat. Tienda tipo vitrina. */
:root {
  --bg: #000;
  --card: #111;
  --card-2: #181818;
  --line: rgba(255, 255, 255, .12);
  --line-2: rgba(255, 255, 255, .24);
  --text: #fff;
  --muted: #a6a6a6;
  --dim: #6e6e6e;
  --radius: 18px;
  --font: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 500 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.1; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
button, input { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 6px; }
[hidden] { display: none !important; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 50; background: #fff; color: #000; padding: 10px 14px; border-radius: 10px; font-weight: 700; text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- logo (SVG como máscara, toma el color del texto) ---------- */
.mark-m, .wordmark { display: inline-block; background: currentColor; -webkit-mask: var(--src) center / contain no-repeat; mask: var(--src) center / contain no-repeat; }
.mark-m { --src: url("../brand/m-monogram.svg"); width: 44px; height: 31px; }
.wordmark { --src: url("../brand/magnifico-wordmark.svg"); aspect-ratio: 1152 / 399; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 20px; border-radius: 12px; border: 1px solid transparent;
  font-weight: 700; font-size: 15px; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, color .15s, border-color .15s, transform .15s;
}
.btn:active { transform: translateY(1px); }
.btn-solid { background: #fff; color: #000; }
.btn-solid:hover { background: #d9d9d9; }
.btn-line { background: transparent; border-color: var(--line-2); color: #fff; }
.btn-line:hover { border-color: #fff; background: rgba(255, 255, 255, .06); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 14px; border-radius: 10px; }
.btn[aria-disabled="true"] { background: var(--card-2); color: var(--dim); border-color: var(--line); cursor: default; }

.pill {
  display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--card);
  font-size: 14px; font-weight: 600; text-decoration: none; transition: border-color .15s, background-color .15s;
}
.pill:hover { border-color: var(--line-2); background: var(--card-2); }

.badge { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: .02em; border: 1px solid var(--line-2); color: #fff; }
.badge-solid { background: #fff; color: #000; border-color: #fff; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 20; background: rgba(0, 0, 0, .82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.top.is-stuck { border-bottom-color: var(--line); }
.top-in { display: flex; align-items: center; gap: 20px; min-height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: #fff; text-decoration: none; margin-right: auto; }
.brand-word { width: 132px; }
.top-nav { display: flex; gap: 8px; }
.top-side { display: flex; align-items: center; gap: 10px; }
.lang { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--card); }
.lang button { border: 0; background: none; padding: 0 12px; height: 32px; border-radius: 999px; font-size: 13px; font-weight: 700; color: var(--muted); cursor: pointer; }
.lang button[aria-pressed="true"] { background: #fff; color: #000; }

/* ---------- Black Friday ---------- */
.promo {
  margin-top: 24px; padding: 28px 32px; border-radius: var(--radius); border: 1px solid var(--line-2);
  background: radial-gradient(120% 140% at 100% 0%, #2a2a2a 0%, #0d0d0d 55%, #000 100%);
  display: flex; align-items: center; justify-content: space-between; gap: 24px 40px; flex-wrap: wrap;
}
.promo-copy { max-width: 620px; display: grid; gap: 10px; justify-items: start; }
.promo-title { font-size: clamp(24px, 3.2vw, 36px); font-weight: 800; letter-spacing: -.02em; }
.promo-text { color: var(--muted); }
.promo-clock { display: grid; gap: 8px; justify-items: start; }
.promo-when { font-size: 13px; font-weight: 700; color: var(--muted); }
.clock { display: flex; gap: 8px; }
.clock div { width: 66px; padding: 10px 0 8px; border: 1px solid var(--line-2); border-radius: 12px; background: #000; text-align: center; }
.clock b { display: block; font-size: 26px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }
.clock span { font-size: 11px; font-weight: 600; color: var(--muted); }

/* ---------- intro + buscador ---------- */
.intro { margin-top: 24px; padding: 40px 32px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--card); }
.kicker { font-size: 14px; font-weight: 700; color: var(--muted); }
.intro h1 { margin-top: 10px; font-size: clamp(34px, 5.4vw, 60px); font-weight: 900; letter-spacing: -.035em; max-width: 14ch; }
.lede { margin-top: 16px; max-width: 58ch; color: var(--muted); font-size: 17px; }
.tools { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.search { position: relative; flex: 0 1 360px; }
.search svg { position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.search input { width: 100%; height: 46px; padding: 0 14px 0 42px; border-radius: 12px; border: 1px solid var(--line); background: #000; font-weight: 500; }
.search input::placeholder { color: var(--dim); }
.search input:focus { outline: none; border-color: #fff; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-2); background: transparent; font-size: 14px; font-weight: 700; cursor: pointer; }
.chip:hover { border-color: #fff; }
.chip[aria-pressed="true"] { background: #fff; color: #000; border-color: #fff; }

/* ---------- grid de productos ---------- */
.store { margin-top: 24px; scroll-margin-top: 96px; }
.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); overflow: hidden; transition: border-color .2s, transform .2s; }
.card:hover { border-color: var(--line-2); transform: translateY(-2px); }
.cover { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: radial-gradient(70% 90% at 50% 0%, #3a3a3a 0%, #121212 55%, #050505 100%); border-bottom: 1px solid var(--line); cursor: pointer; }
.cover img { width: 100%; height: 100%; object-fit: cover; }
.cover::after { /* piso de escenario */
  content: ""; position: absolute; left: -20%; right: -20%; bottom: -30%; height: 60%;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,.07) 0 1px, transparent 1px 48px), repeating-linear-gradient(0deg, rgba(255,255,255,.07) 0 1px, transparent 1px 24px);
  transform: perspective(300px) rotateX(62deg); transform-origin: top; pointer-events: none;
}
.cover:has(img)::after { display: none; }
.cover-icon { position: absolute; inset: 0; display: grid; place-items: center; }
.cover-icon svg { width: 34%; height: auto; fill: none; stroke: #fff; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 24px rgba(255,255,255,.25)); }
.cover .badge { position: absolute; top: 14px; left: 14px; background: #000; }
.cover .badge-solid { background: #fff; }
.cover .off { position: absolute; top: 14px; right: 14px; left: auto; }
.card-body { display: flex; flex-direction: column; gap: 10px; padding: 18px 20px 20px; flex: 1; }
.cat { align-self: flex-start; justify-self: start; font-size: 12px; font-weight: 700; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; }
.card h2 { font-size: 21px; font-weight: 800; letter-spacing: -.01em; }
.card .tag { color: var(--muted); font-size: 14px; line-height: 1.55; }
.price { margin-top: auto; padding-top: 6px; display: flex; align-items: baseline; gap: 10px; font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums; }
.price s { font-size: 16px; font-weight: 600; color: var(--dim); }
.price .soon { font-size: 16px; font-weight: 700; color: var(--muted); }
.card-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.card-actions .btn { min-height: 44px; padding: 0 12px; }

.empty, .store-note { margin-top: 24px; text-align: center; color: var(--muted); font-size: 14px; }
.empty { padding: 40px 16px; border: 1px dashed var(--line-2); border-radius: var(--radius); font-size: 15px; }

/* ---------- detalles (dialog) ---------- */
.sheet { width: min(720px, calc(100% - 32px)); max-height: calc(100% - 48px); padding: 0; border: 1px solid var(--line-2); border-radius: 22px; background: var(--card); color: var(--text); overflow: auto; }
.sheet::backdrop { background: rgba(0, 0, 0, .72); backdrop-filter: blur(4px); }
.sheet .cover { cursor: default; aspect-ratio: 16 / 8; }
.sheet-close { position: absolute; top: 14px; right: 14px; z-index: 2; width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(0,0,0,.7); cursor: pointer; display: grid; place-items: center; }
.sheet-close svg { width: 18px; height: 18px; stroke: #fff; stroke-width: 2; stroke-linecap: round; }
.sheet-body { padding: 24px 28px 28px; display: grid; gap: 14px; }
.sheet-body h2 { font-size: 30px; font-weight: 900; letter-spacing: -.02em; }
.sheet-body h3 { font-size: 15px; font-weight: 800; margin-top: 8px; }
.sheet-body ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.sheet-body li { position: relative; padding-left: 22px; color: #e6e6e6; font-size: 15px; }
.sheet-body li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; border-radius: 2px; background: #fff; }
.sheet-buy { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 10px; padding-top: 18px; border-top: 1px solid var(--line); }
.sheet-buy .price { margin: 0; padding: 0; }

/* ---------- licencia ---------- */
.licensing, .faq { margin-top: 72px; scroll-margin-top: 96px; }
.head { display: grid; gap: 10px; margin-bottom: 24px; }
.head h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 900; letter-spacing: -.03em; }
.head p { color: var(--muted); max-width: 60ch; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; counter-reset: s; }
.steps li { counter-increment: s; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: 16px; border-radius: 10px; background: #fff; color: #000; font-weight: 900; }
.steps h3 { font-size: 18px; font-weight: 800; }
.steps p { margin-top: 8px; color: var(--muted); font-size: 14px; }

/* ---------- FAQ ---------- */
.faq-list { display: grid; gap: 10px; max-width: 820px; }
.faq details { border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 56px 18px 20px; position: relative; font-weight: 700; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); font-size: 22px; font-weight: 500; color: var(--muted); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding: 0 20px 18px; color: var(--muted); }

/* ---------- footer ---------- */
.foot { margin-top: 96px; border-top: 1px solid var(--line); }
.foot-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-top: 40px; padding-bottom: 40px; }
.foot-word { width: 150px; color: #fff; }
.foot-sign { margin-top: 6px; color: var(--muted); font-size: 14px; }
.foot-links { display: flex; gap: 20px; }
.foot-links a { font-weight: 600; text-decoration: none; color: var(--muted); }
.foot-links a:hover { color: #fff; }
.foot-legal { color: var(--dim); font-size: 13px; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .top-nav { display: none; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .top-in { min-height: 64px; gap: 10px; }
  .brand-word { display: none; }
  .mark-m { width: 40px; height: 28px; }
  .promo, .intro { padding: 24px 20px; }
  .clock div { width: 60px; }
  .grid, .steps { grid-template-columns: minmax(0, 1fr); }
  .search { flex: 1 1 100%; }
  .sheet-body { padding: 20px; }
  .sheet-body h2 { font-size: 24px; }
  .foot-in { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 380px) {
  .top-side .btn-sm { padding: 0 12px; font-size: 13px; }
  .lang button { padding: 0 9px; }
}

/* ============================================================
   Cuenta: inicio de sesión y Mis licencias (account.html)
   ============================================================ */
.page-account main { min-height: 60vh; }
.btn-lg { min-height: 56px; padding: 0 26px; font-size: 16px; border-radius: 14px; }
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn:disabled { opacity: .5; cursor: default; }

.notice { margin-top: 24px; padding: 16px 20px; border: 1px solid var(--line-2); border-left: 4px solid #fff; border-radius: 14px; background: var(--card); display: grid; gap: 4px; }
.notice-title { font-weight: 800; }
.notice-text { color: #e6e6e6; }

.acc-loading { margin-top: 80px; display: flex; align-items: center; justify-content: center; gap: 12px; color: var(--muted); font-weight: 600; }
.spinner { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line-2); border-top-color: #fff; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.signin { margin-top: 24px; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 20px; align-items: stretch; }
.signin-main { padding: 48px 40px; border: 1px solid var(--line); border-radius: var(--radius); background: radial-gradient(90% 120% at 0% 0%, #262626 0%, #111 55%); display: flex; flex-direction: column; align-items: flex-start; gap: 18px; }
.signin-mark { width: 64px; height: 45px; color: #fff; }
.signin-main h1 { font-size: clamp(32px, 4.4vw, 48px); font-weight: 900; letter-spacing: -.035em; max-width: 13ch; }
.signin-main .lede { margin-top: 0; }
.signin-main .btn-lg { margin-top: 8px; }
.fine { font-size: 13px; color: var(--dim); }
.signin-steps { padding: 32px 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
.signin-steps h2 { font-size: 20px; font-weight: 800; }
.mini-steps { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 18px; counter-reset: m; }
.mini-steps li { counter-increment: m; position: relative; padding-left: 48px; display: grid; gap: 4px; justify-items: start; }
.mini-steps li::before { content: counter(m); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: #fff; color: #000; font-weight: 900; font-size: 15px; }
.mini-steps h3 { font-size: 16px; font-weight: 800; line-height: 32px; }
.mini-steps p { color: var(--muted); font-size: 14px; }
.mini-steps .btn { margin-top: 6px; }

.account { margin-top: 24px; }
.profile { display: flex; align-items: center; gap: 20px; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: radial-gradient(90% 140% at 0% 0%, #262626 0%, #111 60%); }
.avatar { width: 88px; height: 88px; border-radius: 50%; background: #222; border: 2px solid var(--line-2); object-fit: cover; flex: none; }
.profile-id { display: grid; gap: 4px; min-width: 0; }
.profile-name { font-size: clamp(24px, 3vw, 32px); font-weight: 900; letter-spacing: -.02em; overflow-wrap: anywhere; }
.profile-sub { color: var(--muted); font-weight: 600; font-size: 14px; }
.profile-via { color: var(--dim); font-size: 13px; }
.acc-head { margin-top: 40px; }
.acc-head h2 { font-size: clamp(24px, 3vw, 32px); }
.licenses { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.lic { display: flex; align-items: center; gap: 18px; padding: 16px 20px 16px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
.lic-icon { flex: none; width: 72px; height: 72px; border-radius: 12px; display: grid; place-items: center; background: radial-gradient(80% 90% at 50% 0%, #3a3a3a 0%, #121212 70%); border: 1px solid var(--line); }
.lic-icon svg { width: 38px; height: 38px; fill: none; stroke: #fff; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.lic-body { flex: 1; min-width: 0; display: grid; gap: 2px; }
.lic-body h3 { font-size: 18px; font-weight: 800; }
.lic-tag { color: var(--muted); font-size: 14px; }
.lic-src { color: var(--dim); font-size: 13px; }
.lic .badge { flex: none; }
.acc-empty { display: grid; gap: 10px; justify-items: center; text-align: center; }
.acc-empty-title { color: #fff; font-weight: 800; font-size: 17px; }
.help-card { margin-top: 32px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 10px; justify-items: start; }
.help-card h2 { font-size: 18px; font-weight: 800; }
.help-card p { color: var(--muted); max-width: 70ch; font-size: 14px; }

@media (max-width: 860px) {
  .signin { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .signin-main { padding: 32px 22px; }
  .signin-main .btn-lg { width: 100%; }
  .signin-steps { padding: 24px 20px; }
  .profile { padding: 20px; gap: 14px; }
  .avatar { width: 64px; height: 64px; }
  .lic { display: grid; grid-template-columns: 56px minmax(0, 1fr); align-items: start; gap: 10px 14px; padding: 16px; }
  .lic-icon { width: 56px; height: 56px; grid-row: span 2; }
  .lic-icon svg { width: 30px; height: 30px; }
  .lic .badge { grid-column: 2; justify-self: start; }
}
