/* =========================================================
   Jaguar Apps — base compartida de las mini-apps
   Mismo sistema visual que jaguarsoftware.dev
   ========================================================= */
:root {
  --azul: #0B1320; --azul-2: #0e1828; --azul-3: #121f33;
  --marfil: #F2F1E9; --turquesa: #00C2B3; --naranja: #FF7A00; --verde: #34C38F;
  --muted: #9fb0c3; --muted-2: #6f8198;
  --line: rgba(242,241,233,0.10); --card: rgba(255,255,255,0.035);
  --fd: "Space Grotesk", system-ui, sans-serif; --fb: "Inter", system-ui, sans-serif;
  --ease: cubic-bezier(0.22,1,0.36,1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--fb); background: var(--azul); color: var(--marfil);
  line-height: 1.6; -webkit-font-smoothing: antialiased; min-height: 100svh;
  display: flex; flex-direction: column;
  background-image:
    radial-gradient(1100px 700px at 12% -8%, rgba(0,194,179,.14), transparent 55%),
    radial-gradient(900px 700px at 90% 4%, rgba(255,122,0,.10), transparent 52%);
  background-attachment: fixed;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }

.wrap { width: min(100% - 2rem, 720px); margin-inline: auto; }
.wrap--ancha { width: min(100% - 2rem, 980px); margin-inline: auto; }

/* ---------- Barra superior ---------- */
.top { position: sticky; top: 0; z-index: 50; padding: .8rem 0;
  background: rgba(11,19,32,.72); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.top__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  width: min(100% - 2rem, 980px); margin-inline: auto; }
.brand { display: flex; align-items: center; gap: .6rem; }
.brand img { width: 34px; height: 34px; object-fit: contain; }
.brand b { font-family: var(--fd); font-weight: 700; font-size: 1.05rem; letter-spacing: -.02em; }
.brand b span { color: var(--turquesa); }
.top__link { font-family: var(--fd); font-weight: 600; font-size: .85rem;
  padding: .5rem 1.1rem; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--muted); transition: color .25s, border-color .25s; }
.top__link:hover { color: var(--marfil); border-color: rgba(0,194,179,.5); }

/* ---------- Encabezado de la herramienta ---------- */
.hero { text-align: center; padding: 2.5rem 0 1.6rem; }
.hero h1 { font-family: var(--fd); font-weight: 700; font-size: clamp(1.7rem, 5.5vw, 2.5rem);
  line-height: 1.1; letter-spacing: -.03em; text-wrap: balance; }
.hero h1 em { font-style: normal;
  background: linear-gradient(100deg, var(--turquesa), var(--verde) 55%, var(--naranja));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { color: var(--muted); max-width: 52ch; margin: .7rem auto 0; font-size: 1rem; }

/* ---------- Tarjeta de trabajo ---------- */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 22px;
  padding: 1.6rem; margin-bottom: 1.2rem; }
.panel h2 { font-family: var(--fd); font-weight: 600; font-size: 1.05rem; margin-bottom: 1rem; }

/* ---------- Formularios ---------- */
.campo { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1rem; }
.campo > span { font-family: var(--fd); font-weight: 500; font-size: .85rem; color: var(--muted); }
.campo input, .campo select, .campo textarea {
  background: var(--azul-2); border: 1px solid var(--line); border-radius: 12px;
  padding: .7rem .9rem; font-size: 1rem; outline: none; width: 100%;
  transition: border-color .25s; }
.campo input:focus, .campo select:focus, .campo textarea:focus { border-color: var(--turquesa); }
.campo input[type="color"] { padding: .25rem; height: 46px; cursor: pointer; }
.fila { display: grid; gap: .9rem; grid-template-columns: 1fr 1fr; }
.fila--3 { display: grid; gap: .9rem; grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 560px) { .fila, .fila--3 { grid-template-columns: 1fr; } }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font-family: var(--fd); font-weight: 600; font-size: .98rem;
  padding: .8rem 1.6rem; border-radius: 999px; transition: transform .25s var(--ease), filter .25s;
  user-select: none; }
.btn:active { transform: scale(.97); }
.btn--primary { background: linear-gradient(100deg, var(--turquesa), #2ad4c6); color: #04211e; }
.btn--naranja { background: linear-gradient(100deg, var(--naranja), #ff9d3d); color: #1c0c00; }
.btn--ghost { border: 1px solid var(--line); background: var(--card); color: var(--marfil); }
.btn:hover { filter: brightness(1.08); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.botonera { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; margin-top: 1.2rem; }

/* ---------- Resultado grande ---------- */
.resultado { text-align: center; font-family: var(--fd); }
.resultado b { font-size: clamp(2rem, 7vw, 3rem); font-weight: 700; letter-spacing: -.02em; color: var(--turquesa); }
.resultado span { display: block; color: var(--muted); font-size: .9rem; }

/* ---------- Chips / toggles ---------- */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chips button { font-family: var(--fd); font-weight: 500; font-size: .9rem;
  padding: .5rem 1.05rem; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card); color: var(--muted); transition: all .25s; }
.chips button:hover { color: var(--marfil); }
.chips button.on { color: var(--azul); background: var(--turquesa); border-color: var(--turquesa); font-weight: 600; }

/* ---------- Nota / aviso ---------- */
.nota { font-size: .85rem; color: var(--muted-2); text-align: center; margin-top: .8rem; }

/* ---------- Pie con CTA de Jaguar ---------- */
.pie { margin-top: auto; border-top: 1px solid var(--line); padding: 1.8rem 1rem 2.2rem;
  text-align: center; }
.pie p { color: var(--muted); font-size: .92rem; margin-bottom: .8rem; }
.pie .acciones { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; }
.pie a.btn { font-size: .88rem; padding: .6rem 1.3rem; }
main { flex: 1; padding-bottom: 2.5rem; }
