/* ============================================================
   img.lefix.site — mismo estilo que LeFix Panel
   Rojo a negro con detalles celestes.
   ============================================================ */
@font-face { font-family: "Inter"; src: url("/fonts/inter.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("/fonts/space-grotesk.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }
:root {
  --bg: #050407;
  --bg-2: #0b080d;
  --card: rgba(18, 13, 18, .78);
  --card-2: rgba(28, 20, 27, .9);
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(255, 255, 255, .13);
  --text: #f4f2f6;
  --muted: #8f8797;
  --red: #ff2340;
  --red-d: #a1001a;
  --rose: #ff6b81;
  --sky: #5cc8ff;
  --sky-d: #1e8fd6;
  --amber: #ffb547;
  --ok: #3ddc97;
  --grad: linear-gradient(135deg, #ff2340 0%, #a1001a 55%, #2a0008 100%);
  --radius: 18px;
  --display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SF Mono", Consolas, monospace;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { color-scheme: dark; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--text); font: 14.5px/1.5 var(--body); -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { flex: none; }
::selection { background: rgba(92, 200, 255, .35); }
:focus-visible { outline: 2px solid var(--sky); outline-offset: 2px; border-radius: 8px; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.08); border-radius: 10px; border: 2px solid transparent; background-clip: padding-box; }

.bg-glow { position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 50% at 0% 0%, rgba(255,35,64,.20), transparent 70%),
    radial-gradient(40% 40% at 100% 0%, rgba(161,0,26,.16), transparent 70%),
    radial-gradient(35% 35% at 85% 100%, rgba(92,200,255,.07), transparent 70%),
    linear-gradient(180deg, #0a0609 0%, #050407 60%); }

/* ---------- Logo ---------- */
.logo { display: flex; align-items: center; gap: 11px; font: 700 16px var(--display); letter-spacing: .08em; }
.logo b { background: linear-gradient(90deg, var(--red), var(--rose)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.logo-mark { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--grad); color: #fff; position: relative; box-shadow: 0 10px 26px -10px rgba(255,35,64,.9), inset 0 1px 0 rgba(255,255,255,.2); }
.logo-mark svg { width: 19px; height: 19px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.logo-mark::after { content: ""; position: absolute; top: 6px; right: 6px; width: 7px; height: 7px; border-radius: 50%; background: var(--sky); box-shadow: 0 0 10px var(--sky); }

/* ---------- Estructura ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; width: 250px; flex: none; display: flex; flex-direction: column; gap: 26px; padding: 24px 16px; border-right: 1px solid var(--line); background: linear-gradient(180deg, rgba(40,4,12,.55), rgba(8,5,9,.85) 40%); backdrop-filter: blur(16px); }
.sidebar .logo { padding: 0 8px; }
.nav { display: grid; gap: 4px; }
.nav a { position: relative; display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 12px; border-radius: 12px; color: #a59dab; font-weight: 600; transition: background .15s, color .15s; }
.nav a svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.nav a:hover { color: var(--text); background: rgba(255,255,255,.04); }
.nav a.active { color: #fff; background: linear-gradient(90deg, rgba(255,35,64,.22), rgba(255,35,64,.04)); box-shadow: inset 0 0 0 1px rgba(255,35,64,.25); }
.nav a.active::before { content: ""; position: absolute; left: -16px; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--red); box-shadow: 0 0 12px var(--red); }
.nav a.active svg { color: var(--sky); }
.nav-badge { margin-left: auto; min-width: 22px; height: 20px; padding: 0 7px; border-radius: 99px; display: grid; place-items: center; background: rgba(255,255,255,.08); color: #cfc8d4; font: 700 11px var(--body); }
.side-foot { margin-top: auto; display: grid; gap: 10px; }
.espacio { padding: 14px; border-radius: 14px; background: rgba(255,255,255,.03); border: 1px solid var(--line); }
.espacio .fila { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.espacio b { color: var(--text); font-size: 13.5px; }
.barra-uso { height: 6px; border-radius: 6px; background: rgba(255,255,255,.07); margin: 10px 0 8px; overflow: hidden; }
.barra-uso i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--red), var(--rose)); box-shadow: 0 0 10px rgba(255,35,64,.6); transition: width .8s ease; }

.main { flex: 1; min-width: 0; padding: 26px 34px 80px; }
.topbar { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.kicker { margin: 0; font-size: 11.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--sky); }
.topbar h1 { margin: 4px 0 0; font: 700 34px/1.1 var(--display); letter-spacing: -1px; }
.top-right { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.view { display: grid; gap: 18px; animation: rise .35s ease; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.lead { margin: 0; color: var(--muted); max-width: 720px; }
.card { position: relative; padding: 20px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); box-shadow: 0 20px 50px -30px #000; backdrop-filter: blur(10px); min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { margin: 0; font: 700 16px var(--display); letter-spacing: -.2px; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); font-size: .92em; }

/* ---------- Botones y campos ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 11px; border: 1px solid var(--line-2); background: rgba(255,255,255,.05); font-weight: 650; font-size: 13.5px; white-space: nowrap; transition: transform .12s, filter .15s, background .15s, border-color .15s; }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn:hover { background: rgba(255,255,255,.09); border-color: rgba(255,255,255,.22); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { border: 0; background: var(--grad); color: #fff; box-shadow: 0 10px 24px -12px rgba(255,35,64,.9), inset 0 1px 0 rgba(255,255,255,.18); }
.btn.primary:hover { filter: brightness(1.12); }
.btn.sky { border-color: rgba(92,200,255,.35); color: var(--sky); background: rgba(92,200,255,.08); }
.btn.sky:hover { background: rgba(92,200,255,.14); }
.btn.danger:hover { border-color: rgba(255,35,64,.5); background: rgba(255,35,64,.12); color: var(--rose); }
.btn.sm { height: 34px; padding: 0 12px; font-size: 12.5px; border-radius: 10px; }
.icon-btn { width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid transparent; background: transparent; color: var(--muted); }
.icon-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:hover { color: var(--text); background: rgba(255,255,255,.07); border-color: var(--line); }
.search { position: relative; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.search input { height: 40px; width: 280px; padding: 0 12px 0 36px; border-radius: 11px; border: 1px solid var(--line-2); background: var(--bg-2); outline: 0; }
select { height: 40px; padding: 0 12px; border-radius: 11px; border: 1px solid var(--line-2); background: var(--bg-2); outline: 0; }
select:focus, input:focus, textarea:focus { border-color: rgba(92,200,255,.55) !important; }
.field { display: grid; gap: 7px; margin-bottom: 14px; }
.field > span { font-size: 12.5px; font-weight: 600; color: #b9b1bf; }
.field input[type=text], .field input[type=number], .field input[type=password] { height: 42px; padding: 0 13px; border-radius: 11px; border: 1px solid var(--line-2); background: var(--bg-2); outline: 0; }
.field small { color: var(--muted); font-size: 12.5px; }
.field input[type=range] { accent-color: var(--red); }
.check { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-weight: 500; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--red); }

/* ---------- Zona de subida (lo llamativo) ---------- */
.subir {
  position: relative; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 22px;
  padding: 26px 28px; border-radius: 22px; cursor: pointer; overflow: hidden; isolation: isolate;
  background: linear-gradient(135deg, rgba(255,35,64,.14), rgba(18,13,18,.85) 45%, rgba(92,200,255,.06));
  border: 1px solid var(--line-2); transition: transform .2s, box-shadow .2s;
}
/* Borde de rojo a celeste que gira al arrastrar fotos encima */
.subir::before {
  content: ""; position: absolute; inset: -2px; z-index: -2; border-radius: inherit; opacity: 0; transition: opacity .25s;
  background: conic-gradient(from var(--giro, 0deg), var(--red), var(--rose), var(--sky), var(--sky-d), var(--red));
  animation: girar 2.4s linear infinite paused;
}
.subir::after { content: ""; position: absolute; inset: 1px; z-index: -1; border-radius: 21px; background: linear-gradient(135deg, #1a0c11, #0d090e 55%, #0a1218); opacity: 0; transition: opacity .25s; }
@property --giro { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes girar { to { --giro: 360deg; } }
.subir:hover { box-shadow: 0 24px 60px -30px rgba(255,35,64,.7); }
.subir.activa { transform: scale(1.01); box-shadow: 0 30px 80px -30px rgba(255,35,64,.9), 0 0 60px -20px rgba(92,200,255,.6); }
.subir.activa::before, .subir.activa::after { opacity: 1; animation-play-state: running; }
.subir .icono { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; background: var(--grad); box-shadow: 0 14px 30px -12px rgba(255,35,64,.9), inset 0 1px 0 rgba(255,255,255,.2); position: relative; }
.subir .icono svg { width: 28px; height: 28px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .25s; }
.subir.activa .icono svg { transform: translateY(-3px); }
.subir .icono::after { content: ""; position: absolute; top: 8px; right: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--sky); box-shadow: 0 0 12px var(--sky); }
.subir h2 { margin: 0; font: 700 22px var(--display); letter-spacing: -.4px; }
.subir p { margin: 4px 0 0; color: var(--muted); }
.subir kbd { font: 600 11.5px var(--mono); padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-2); background: rgba(255,255,255,.04); color: #cfc8d4; }
.subir .formatos { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.tag { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 99px; border: 1px solid var(--line-2); background: rgba(255,255,255,.03); font-size: 11.5px; font-weight: 700; color: #cfc8d4; }
.tag.sky { border-color: rgba(92,200,255,.35); color: var(--sky); background: rgba(92,200,255,.08); }
.tag.red { border-color: rgba(255,35,64,.35); color: var(--rose); background: rgba(255,35,64,.08); }

/* Cola de subidas */
.cola { display: grid; gap: 8px; }
.subida { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); animation: rise .25s ease; }
.subida img { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; background: #1a1418; }
.subida .nombre { font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subida .estado { font-size: 12px; color: var(--muted); }
.subida .progreso { height: 4px; border-radius: 4px; background: rgba(255,255,255,.07); margin-top: 6px; overflow: hidden; }
.subida .progreso i { display: block; height: 100%; width: 0; border-radius: 4px; background: linear-gradient(90deg, var(--red), var(--sky)); transition: width .2s; }
.subida.lista .estado { color: var(--ok); }
.subida.mal .estado { color: var(--rose); }
.subida.mal .progreso i { background: var(--red); }

/* ---------- Galería ---------- */
.galeria { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.foto {
  position: relative; border-radius: 16px; overflow: hidden; background: #120d12; border: 1px solid var(--line);
  aspect-ratio: 4 / 3; cursor: pointer; transition: transform .2s, border-color .2s, box-shadow .2s;
}
.foto img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.foto:hover { border-color: rgba(255,35,64,.45); box-shadow: 0 18px 40px -22px rgba(255,35,64,.7); }
.foto:hover img { transform: scale(1.04); }
.foto .velo { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5,4,7,.55), transparent 35%, transparent 55%, rgba(5,4,7,.92)); opacity: 0; transition: opacity .2s; }
.foto:hover .velo, .foto:focus-within .velo, .foto.marcada .velo { opacity: 1; }
.foto .info { position: absolute; left: 12px; right: 12px; bottom: 10px; transform: translateY(6px); opacity: 0; transition: .2s; }
.foto:hover .info, .foto:focus-within .info { transform: none; opacity: 1; }
.foto .info b { display: block; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.foto .info span { display: block; font-size: 12px; color: #c3bbc9; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.foto .acciones { position: absolute; top: 10px; right: 10px; display: flex; gap: 6px; opacity: 0; transform: translateY(-4px); transition: .2s; }
.foto:hover .acciones, .foto:focus-within .acciones { opacity: 1; transform: none; }
.foto .acciones button { width: 34px; height: 34px; border-radius: 10px; border: 1px solid rgba(255,255,255,.14); background: rgba(10,7,11,.75); backdrop-filter: blur(8px); display: grid; place-items: center; color: #fff; }
.foto .acciones button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.foto .acciones button.copiar:hover { background: var(--sky-d); border-color: var(--sky); }
.foto .acciones button.borrar:hover { background: var(--red); border-color: var(--red); }
.foto .marca { position: absolute; top: 10px; left: 10px; width: 24px; height: 24px; border-radius: 8px; border: 2px solid rgba(255,255,255,.7); background: rgba(10,7,11,.5); display: grid; place-items: center; opacity: 0; transition: .15s; }
.foto:hover .marca, .galeria.marcando .foto .marca { opacity: 1; }
.foto.marcada { border-color: var(--sky); box-shadow: 0 0 0 2px var(--sky), 0 18px 40px -22px rgba(92,200,255,.8); }
.foto.marcada .marca { opacity: 1; background: var(--sky); border-color: var(--sky); }
.foto.marcada .marca::after { content: ""; width: 10px; height: 6px; border-left: 2.5px solid #04131d; border-bottom: 2.5px solid #04131d; transform: rotate(-45deg) translate(1px, -1px); }
.foto .chips { position: absolute; left: 10px; bottom: 10px; display: flex; gap: 5px; transition: opacity .2s; }
.foto:hover .chips { opacity: 0; }
.foto .chips .tag { background: rgba(10,7,11,.7); backdrop-filter: blur(6px); height: 22px; font-size: 10.5px; }
.foto.nueva { animation: nueva 1.2s ease; }
@keyframes nueva { 0% { box-shadow: 0 0 0 3px var(--sky), 0 0 40px rgba(92,200,255,.7); } 100% { box-shadow: 0 0 0 0 transparent; } }
.vacio { padding: 60px 20px; text-align: center; color: var(--muted); border: 1px dashed var(--line-2); border-radius: 16px; }
.vacio b { display: block; color: var(--text); font: 700 18px var(--display); margin-bottom: 6px; }
.mas { display: flex; justify-content: center; padding: 20px 0 0; color: var(--muted); font-size: 13px; }

/* Barra de selección */
.barra-sel { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 30; display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 18px; border-radius: 16px; background: rgba(18,13,18,.95); border: 1px solid var(--line-2); box-shadow: 0 24px 60px -20px #000, 0 0 0 1px rgba(92,200,255,.15); backdrop-filter: blur(14px); animation: subirBarra .2s ease; }
@keyframes subirBarra { from { opacity: 0; transform: translate(-50%, 14px); } }
.barra-sel b { color: var(--sky); margin-right: 8px; font-size: 13.5px; }

/* ---------- Visor (modal) ---------- */
.visor { position: fixed; inset: 0; z-index: 50; display: grid; grid-template-columns: minmax(0, 1fr) 380px; background: rgba(3,2,4,.88); backdrop-filter: blur(10px); animation: fundir .2s ease; }
@keyframes fundir { from { opacity: 0; } }
.visor .lienzo { position: relative; display: grid; place-items: center; padding: 30px 70px; min-width: 0; }
.visor .lienzo img { max-width: 100%; max-height: calc(100vh - 60px); object-fit: contain; border-radius: 12px; box-shadow: 0 30px 80px -20px #000; background: repeating-conic-gradient(#1a151a 0 25%, #221b22 0 50%) 0 0 / 18px 18px; animation: rise .25s ease; }
.visor .flecha { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 14px; border: 1px solid var(--line-2); background: rgba(18,13,18,.8); display: grid; place-items: center; color: #fff; }
.visor .flecha svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.visor .flecha:hover { border-color: var(--sky); color: var(--sky); }
.visor .flecha.ant { left: 16px; } .visor .flecha.sig { right: 16px; }
.visor .panel { margin: 16px 16px 16px 0; padding: 22px; border-radius: 20px; background: linear-gradient(180deg, rgba(30,10,16,.95), rgba(12,8,12,.97)); border: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 16px; overflow-y: auto; min-width: 0; position: relative; }
.visor .panel::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; border-radius: 20px 20px 0 0; background: linear-gradient(90deg, var(--red), var(--sky)); }
.visor .panel > * { min-width: 0; }
.visor .cab { display: flex; align-items: center; gap: 8px; }
.visor .cab .kicker { flex: 1; }
.visor .cab .kicker span { text-transform: none; letter-spacing: .04em; font-family: var(--mono); }
.visor .nombre { width: 100%; height: 44px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--bg-2); outline: 0; font: 700 17px var(--display); }
.copiable { display: grid; gap: 6px; }
.copiable > span { font-size: 12.5px; font-weight: 600; color: #b9b1bf; }
.copiable .caja { display: flex; gap: 6px; min-width: 0; }
.copiable .caja .btn { height: 40px; }
.copiable code { flex: 1; min-width: 0; height: 40px; display: flex; align-items: center; padding: 0 12px; border-radius: 11px; background: var(--bg-2); border: 1px solid var(--line); font: 12.5px var(--mono); color: #d9d2de; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.datos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dato { padding: 12px; border-radius: 12px; background: rgba(255,255,255,.03); border: 1px solid var(--line); }
.dato span { display: block; font-size: 11.5px; color: var(--muted); }
.dato b { font-size: 14px; }
.visor .pie { display: flex; gap: 8px; margin-top: auto; }
.visor .pie .btn { flex: 1; }
.teclas { font-size: 12px; color: var(--muted); }
.teclas kbd { font: 600 11px var(--mono); padding: 1px 6px; border-radius: 5px; border: 1px solid var(--line-2); color: #cfc8d4; }

/* ---------- Estadísticas ---------- */
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat { position: relative; overflow: hidden; }
.stat .ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px; background: rgba(255,35,64,.12); color: var(--rose); }
.stat .ic.sky { background: rgba(92,200,255,.12); color: var(--sky); }
.stat .ic svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.stat .num { font: 700 30px/1 var(--display); letter-spacing: -1px; }
.stat .lbl { margin-top: 6px; color: var(--muted); font-size: 13px; }
.stat::after { content: ""; position: absolute; right: -40px; top: -40px; width: 120px; height: 120px; border-radius: 50%; background: radial-gradient(circle, rgba(255,35,64,.18), transparent 70%); }
.grafico { display: flex; align-items: flex-end; gap: 5px; height: 180px; padding-top: 10px; }
.grafico .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; height: 100%; position: relative; }
.grafico .col i { display: block; border-radius: 6px 6px 3px 3px; background: linear-gradient(180deg, var(--rose), var(--red-d)); min-height: 3px; opacity: .85; transition: opacity .15s, height .6s ease; }
.grafico .col.hoy i { background: linear-gradient(180deg, var(--sky), var(--sky-d)); box-shadow: 0 0 16px rgba(92,200,255,.5); }
.grafico .col.cero i { background: rgba(255,255,255,.06); }
.grafico .col:hover i { opacity: 1; }
.grafico .col:hover::after { content: attr(data-t); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); white-space: nowrap; padding: 4px 8px; border-radius: 8px; background: #1d151c; border: 1px solid var(--line-2); font-size: 11.5px; z-index: 2; }
.eje { display: flex; justify-content: space-between; margin-top: 8px; font-size: 11.5px; color: var(--muted); }
.anillo-caja { display: flex; align-items: center; gap: 22px; }
.anillo { width: 140px; height: 140px; flex: none; }
.anillo circle { fill: none; stroke-width: 12; }
.anillo .fondo { stroke: rgba(255,255,255,.07); }
.anillo .uso { stroke: url(#gradAnillo); stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; transition: stroke-dashoffset 1s ease; }
.anillo text { fill: var(--text); font: 700 22px var(--display); text-anchor: middle; }
.anillo text.sub { fill: var(--muted); font: 600 10.5px var(--body); }
.leyenda { display: grid; gap: 10px; font-size: 13.5px; }
.leyenda div { display: flex; justify-content: space-between; gap: 20px; }
.leyenda span { color: var(--muted); }
.grid-main { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 16px; }

/* ---------- Claves ---------- */
.clave { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 14px; background: rgba(255,255,255,.03); border: 1px solid var(--line); }
.clave .ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: rgba(92,200,255,.1); color: var(--sky); }
.clave .ic svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.clave b { display: block; }
.clave small { color: var(--muted); font-size: 12.5px; }
.lista { display: grid; gap: 10px; }
.nueva-clave { padding: 16px; border-radius: 14px; background: rgba(92,200,255,.07); border: 1px solid rgba(92,200,255,.35); }
.nueva-clave b { display: block; color: var(--sky); margin-bottom: 8px; }
.nueva-clave code { display: block; word-break: break-all; padding: 10px 12px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--line-2); font: 13px var(--mono); margin-bottom: 10px; }
.codigo { margin: 0; padding: 16px; border-radius: 14px; background: #08060a; border: 1px solid var(--line); font: 12.5px/1.65 var(--mono); color: #d9d2de; overflow-x: auto; white-space: pre; }
.codigo .k { color: var(--rose); } .codigo .s { color: var(--sky); } .codigo .c { color: #6c6472; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }

/* Aviso */
.toast { position: fixed; right: 22px; bottom: 22px; z-index: 60; display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-radius: 14px; background: rgba(18,13,18,.96); border: 1px solid var(--line-2); box-shadow: 0 20px 50px -20px #000; font-weight: 600; font-size: 13.5px; animation: rise .25s ease; }
.toast::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px var(--ok); flex: none; }
.toast.mal::before { background: var(--red); box-shadow: 0 0 10px var(--red); }

/* Arrastrar en cualquier parte de la página */
.soltar { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; pointer-events: none; background: rgba(5,4,7,.6); backdrop-filter: blur(4px); opacity: 0; transition: opacity .2s; }
.soltar div { padding: 26px 34px; border-radius: 22px; border: 2px dashed var(--sky); background: rgba(18,13,18,.9); font: 700 22px var(--display); box-shadow: 0 0 60px -10px rgba(92,200,255,.5); }
body.arrastrando .soltar { opacity: 1; }

/* ---------- Móvil ---------- */
.movil-top { display: none; }
@media (max-width: 1100px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-main, .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .sidebar { position: fixed; left: 0; right: 0; bottom: 0; top: auto; height: auto; width: auto; z-index: 35; flex-direction: row; padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); border-right: 0; border-top: 1px solid var(--line); background: rgba(8,5,9,.95); }
  .sidebar .logo, .side-foot { display: none; }
  .nav { grid-auto-flow: column; grid-auto-columns: 1fr; width: 100%; }
  .nav a { flex-direction: column; gap: 3px; height: 54px; justify-content: center; font-size: 11px; padding: 0 4px; }
  .nav a.active::before { display: none; }
  .nav-badge { display: none; }
  .main { padding: 18px 14px 110px; }
  .movil-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
  .topbar h1 { font-size: 27px; }
  .search, .search input { width: 100%; }
  .top-right { width: 100%; }
  .top-right .search { flex: 1 1 100%; }
  .top-right select, .top-right #marcar { flex: 1; }
  .foto .info .vistas { display: none; }
  .subir { grid-template-columns: auto 1fr; padding: 20px; gap: 16px; }
  .subir .formatos { display: none; }
  .subir h2 { font-size: 18px; }
  .subir .atajo { display: none; }
  .galeria { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .foto .acciones, .foto .info { opacity: 1; transform: none; }
  .foto .velo { opacity: 1; }
  .foto .chips { display: none; }
  .visor { grid-template-columns: 1fr; overflow-y: auto; }
  .visor .lienzo { padding: 16px; min-height: 50vh; }
  .visor .flecha { display: none; }
  .visor .panel { margin: 0 12px 12px; }
  .toast { left: 14px; right: 14px; bottom: 84px; }
  .barra-sel { bottom: 84px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01s !important; transition-duration: .01s !important; }
}
