/* Páginas FC 27 (jugador, listados, portada) — 21/09/2026. Mismo aire que la web del solver. */
:root { --bg: #050505; --surface: #0e0e0e; --surface-2: #161616; --muted: #1c1c1e; --primary: #1ed760; --accent: #ffb341; --text-1: #f5f5f7; --text-2: #a1a1a6; --text-3: #6e6e73; --border: rgba(255,255,255,0.07); --r: 14px; --r-lg: 20px; }
* { box-sizing: border-box; }
html { background: var(--bg); }
body { margin: 0; background: radial-gradient(1200px 600px at 10% -10%, rgba(30,215,96,0.10), transparent 60%), var(--bg); color: var(--text-1); font-family: "Manrope", system-ui, sans-serif; line-height: 1.45; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.page { max-width: 1180px; margin: 0 auto; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.nav-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
nav[role="site-nav"] { display: flex; gap: 6px; flex-wrap: wrap; }
.nav-button { padding: 8px 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); font-size: 0.85rem; font-weight: 600; }
.nav-button.is-active { background: var(--primary); color: #04130a; border-color: var(--primary); }
.nav-button:hover { text-decoration: none; color: var(--text-1); }
.fc27 { display: flex; flex-direction: column; gap: 14px; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 18px 20px; }
.panel h2 { margin: 0 0 6px; font-family: "Space Grotesk", "Manrope", sans-serif; font-size: 1.3rem; letter-spacing: -0.01em; }
.panel h2 small { color: var(--text-3); font-weight: 500; font-size: 0.85rem; }
.panel h3 { margin: 14px 0 6px; font-size: 0.95rem; color: var(--text-2); font-weight: 600; }
.muted { color: var(--text-2); font-size: 0.92rem; margin: 0 0 10px; }
.dos { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 800px) { .dos { grid-template-columns: 1fr; } }

/* migas */
.migas ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font-size: 0.82rem; color: var(--text-3); }
.migas li + li::before { content: "›"; margin: 0 6px; color: var(--text-3); }
.migas a { color: var(--text-2); }

/* KPIs y chips */
.kpis { list-style: none; margin: 10px 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.kpis li { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); padding: 10px 14px; min-width: 120px; }
.kpis li a { color: inherit; display: block; }
.kpis b { display: block; font-size: 1.25rem; font-family: "Space Grotesk", sans-serif; }
.kpis span { color: var(--text-3); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.chip { padding: 5px 11px; border-radius: 999px; background: var(--muted); border: 1px solid var(--border); color: var(--text-2); font-size: 0.8rem; font-weight: 600; }
.chip small { color: var(--text-3); font-weight: 500; margin-left: 4px; }
.chip.is-on { background: var(--primary); color: #04130a; border-color: var(--primary); }
.chip:hover { text-decoration: none; color: var(--text-1); border-color: rgba(255,255,255,0.2); }

/* rejilla de ligas / clubes / naciones */
.rejilla { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
.rejilla a { display: grid; grid-template-columns: 32px 1fr; grid-template-rows: auto auto; column-gap: 10px; align-items: center; padding: 8px 10px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); color: var(--text-1); }
.rejilla a:hover { text-decoration: none; border-color: rgba(30,215,96,0.5); }
.rejilla img { grid-row: 1 / span 2; width: 28px; height: auto; object-fit: contain; }
.rejilla span { font-weight: 700; font-size: 0.9rem; }
.rejilla small { color: var(--text-3); font-size: 0.75rem; }

/* tabla de cartas */
.cartas { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.cartas th { text-align: left; color: var(--text-3); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; padding: 8px 8px; border-bottom: 1px solid var(--border); }
.cartas td { padding: 8px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.cartas tr:hover td { background: rgba(255,255,255,0.025); }
.cartas .c-carta { width: 76px; }
.cartas .mini { display: inline-flex; width: 64px; height: 88px; border-radius: 8px; background-size: 100% 100%; background-position: center; align-items: center; justify-content: center; overflow: hidden; box-shadow: 0 6px 16px rgba(0,0,0,0.45); }
.cartas .mini img { width: 56px; height: 56px; object-fit: contain; margin-top: 2px; }
.cartas .c-icono { width: 48px; text-align: center; }
.cartas .c-icono img { display: inline-block; object-fit: contain; vertical-align: middle; background: rgba(255,255,255,0.06); border-radius: 8px; padding: 3px; }
.cartas .c-icono a:hover img { background: rgba(30,215,96,0.2); }
.cartas .c-pos a { color: var(--text-1); font-weight: 600; }
.cartas .c-id { text-align: right; }
.cartas .c-id a { display: inline-block; padding: 3px 8px; border-radius: 8px; border: 1px solid var(--border); color: var(--text-3); font-size: 0.78rem; font-variant-numeric: tabular-nums; }
.cartas .c-nombre a { color: var(--text-1); }
.cartas .c-nombre small { display: block; color: var(--text-3); font-size: 0.75rem; }
.cartas .c-nombre small a { color: var(--text-2); }
.cartas .c-media b { display: inline-block; min-width: 34px; text-align: center; padding: 3px 6px; border-radius: 8px; background: var(--muted); font-family: "Space Grotesk", sans-serif; color: var(--primary); font-size: 1rem; }
.cartas .c-liga a, .cartas .c-nacion a { color: var(--text-2); display: inline-flex; align-items: center; gap: 6px; }
.cartas .c-liga img, .cartas .c-nacion img { object-fit: contain; }
.cartas .c-precio { text-align: left; white-space: nowrap; font-variant-numeric: tabular-nums; }
.cartas .c-precio b { color: var(--accent); }
.cartas .c-precio small { display: block; color: var(--text-3); font-size: 0.72rem; }
.cartas .sin { color: var(--text-3); }
.cartas .c-var { text-align: right; }
@media (max-width: 760px) { .cartas .c-liga, .cartas .c-id, .cartas th.c-id { display: none; } .cartas td, .cartas th { padding: 6px 5px; } .cartas .c-carta { width: 56px; } .cartas .mini { width: 48px; height: 66px; } .cartas .mini img { width: 42px; height: 42px; } }

/* paginación */
.paginas { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 14px; font-size: 0.88rem; }
.paginas .info { color: var(--text-3); margin-right: auto; }
.paginas a, .paginas b { padding: 6px 10px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); }
.paginas b { background: var(--primary); color: #04130a; border-color: var(--primary); }
.paginas a:hover { text-decoration: none; color: var(--text-1); }
.paginas span { color: var(--text-3); }

/* ficha */
.ficha { display: grid; grid-template-columns: 300px 1fr; gap: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 20px; }
@media (max-width: 760px) { .ficha { grid-template-columns: 1fr; } .ficha__carta { margin: 0 auto; } }
.ficha__carta { position: relative; width: 260px; height: 362px; background-size: contain; background-repeat: no-repeat; background-position: center; text-align: center; font-family: "Space Grotesk", sans-serif; }
.carta__media { position: absolute; left: 44px; top: 76px; display: flex; flex-direction: column; line-height: 1; }
.carta__media b { font-size: 34px; font-weight: 700; }
.carta__media span { font-size: 15px; font-weight: 600; letter-spacing: 0.04em; }
.carta__cara { position: absolute; left: 50%; top: 42px; transform: translateX(-42%); width: 160px; height: 160px; object-fit: contain; }
.carta__nombre { position: absolute; left: 0; right: 0; top: 206px; font-size: 20px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; }
.carta__attr { position: absolute; left: 0; right: 0; top: 240px; margin: 0; padding: 0 44px; list-style: none; display: grid; grid-template-columns: repeat(6, 1fr); gap: 2px; }
.carta__attr li { display: flex; flex-direction: column; line-height: 1.1; }
.carta__attr span { font-size: 10px; font-weight: 600; opacity: 0.85; }
.carta__attr b { font-size: 16px; }
.carta__pies { position: absolute; left: 0; right: 0; top: 290px; display: flex; justify-content: center; gap: 10px; align-items: center; }
.carta__pies img { height: 20px; width: auto; object-fit: contain; }
.ficha__datos h2 { margin: 0; font-family: "Space Grotesk", sans-serif; font-size: 1.6rem; }
.ficha__datos h2 small { display: block; color: var(--text-3); font-size: 0.85rem; font-weight: 500; }
.ficha__sub { color: var(--text-2); margin: 6px 0 12px; }
.ficha__enlaces { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin: 0 0 14px; }
.ficha__enlaces div { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); padding: 8px 10px; }
.ficha__enlaces dt { color: var(--text-3); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; }
.ficha__enlaces dd { margin: 2px 0 0; font-weight: 600; }
.ficha__enlaces dd a { color: var(--text-1); display: inline-flex; align-items: center; gap: 6px; }
.ficha__enlaces img { object-fit: contain; }
.precio { display: grid; grid-template-columns: 1.4fr 0.8fr 1.4fr; gap: 10px; align-items: stretch; margin-bottom: 14px; }
@media (max-width: 760px) { .precio { grid-template-columns: 1fr 1fr; } .precio__rango { grid-column: 1 / -1; } }
.precio > div { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); padding: 10px 12px; }
.precio__etq { display: block; color: var(--text-3); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; }
.precio__actual b, .precio__pc b { display: block; font-size: 1.7rem; font-family: "Space Grotesk", sans-serif; color: var(--accent); line-height: 1.1; }
.precio__var { display: inline-block; margin-top: 4px; font-size: 0.8rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.precio__var.sube { background: rgba(30,215,96,0.15); color: var(--primary); }
.precio__var.baja { background: rgba(255,90,90,0.15); color: #ff7b7b; }
.precio__ext { display: inline-block; margin-top: 4px; font-size: 0.75rem; color: #ff7b7b; }
.precio__rango { display: flex; flex-direction: column; gap: 4px; font-size: 0.85rem; color: var(--text-2); justify-content: center; }
.precio__rango small { color: var(--text-3); }
.acciones { display: flex; flex-wrap: wrap; gap: 8px; }
.btn { padding: 9px 14px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-1); font-weight: 700; font-size: 0.88rem; }
.btn:hover { text-decoration: none; border-color: rgba(255,255,255,0.2); }
.btn--main { background: var(--primary); color: #04130a; border-color: var(--primary); }

/* gráfica */
.grafica { width: 100%; height: auto; display: block; margin: 4px 0 8px; }
.grafica .rejilla { stroke: rgba(255,255,255,0.08); stroke-width: 1; }
.grafica .eje { fill: var(--text-3); font-size: 11px; font-family: "Manrope", sans-serif; }
.grafica .linea { fill: none; stroke: var(--primary); stroke-width: 2.2; stroke-linejoin: round; }
.grafica .area { fill: rgba(30,215,96,0.12); }
.grafica .punto { fill: var(--accent); }
.hist { width: 100%; border-collapse: collapse; font-size: 0.85rem; margin-top: 8px; }
.hist th, .hist td { padding: 6px 8px; border-bottom: 1px solid var(--border); text-align: right; }
.hist th:first-child, .hist td:first-child { text-align: left; }
.hist th { color: var(--text-3); font-size: 0.72rem; text-transform: uppercase; }
details summary { cursor: pointer; color: var(--text-2); font-size: 0.88rem; }

/* atributos */
.barras { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 8px 20px; }
.barras li { display: grid; grid-template-columns: 150px 1fr 36px; align-items: center; gap: 10px; font-size: 0.9rem; }
.barras__etq small { color: var(--text-3); margin-left: 4px; }
.barras__barra { height: 8px; border-radius: 999px; background: var(--muted); overflow: hidden; }
.barras__barra i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), #8be28a); border-radius: 999px; }
.barras b { text-align: right; font-family: "Space Grotesk", sans-serif; }

.fc27-pie { color: var(--text-3); font-size: 0.8rem; padding: 10px 4px 20px; }
.fc27-pie a { color: var(--text-2); }

/* buscador y carta flotante (21/09/2026) */
.buscador { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.buscador input { flex: 1 1 320px; min-width: 200px; padding: 10px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-1); font: inherit; font-size: 0.9rem; }
.buscador input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(30,215,96,0.18); }
.buscador button { padding: 10px 16px; border-radius: 999px; border: 1px solid var(--primary); background: var(--primary); color: #04130a; font-weight: 700; cursor: pointer; }
.buscador__aviso { flex-basis: 100%; color: var(--text-3); font-size: 0.78rem; padding-left: 14px; }
.carta-flotante { position: fixed; z-index: 1000; pointer-events: none; opacity: 0; transform: scale(0.96); transition: opacity .12s ease, transform .12s ease; filter: drop-shadow(0 18px 40px rgba(0,0,0,0.7)); }
.carta-flotante.is-visible { opacity: 1; transform: none; }
.carta-flotante__carta { width: 260px; height: 362px; }
.cartas .mini { cursor: zoom-in; }
.carta-flotante__carta { background-color: rgba(10,14,12,0.92); border-radius: 18px; }

/* desplegables de la portada (21/09/2026, pedido por Mario: menú en vez de muchos botones) */
.desplegables { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; margin-top: 10px; }
.desplegable { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; }
.desplegable[open] { grid-column: 1 / -1; }
.desplegable summary { cursor: pointer; padding: 10px 14px; font-weight: 700; font-size: 0.9rem; list-style: none; display: flex; justify-content: space-between; align-items: center; color: var(--text-1); }
.desplegable summary::-webkit-details-marker { display: none; }
.desplegable summary::after { content: "▾"; color: var(--text-3); }
.desplegable[open] summary::after { content: "▴"; }
.desplegable summary small { color: var(--text-3); font-weight: 500; margin-left: auto; margin-right: 8px; }
.desplegable .chips { padding: 0 12px 12px; margin: 0; }

/* barra de filtros (21/09/2026, como la de la tabla de la web) */
.fbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 10px 0 12px; position: relative; }
.fbar-item { position: relative; }
.fbar-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); font: inherit; font-size: 0.82rem; font-weight: 600; cursor: pointer; }
.fbar-btn svg { color: var(--primary); }
.fbar-btn i { font-style: normal; color: var(--text-3); font-size: 0.7rem; }
.fbar-btn:hover, .fbar-item.is-open .fbar-btn { color: var(--text-1); border-color: rgba(30,215,96,0.6); }
.fbar-btn.is-on { background: rgba(30,215,96,0.14); color: var(--text-1); border-color: rgba(30,215,96,0.6); }
.fbar-dd { position: absolute; z-index: 60; top: calc(100% + 6px); left: 0; width: max-content; min-width: 170px; max-width: min(340px, calc(100vw - 32px)); background: #0b0b0c; border: 1px solid rgba(255,255,255,0.12); border-radius: 14px; box-shadow: 0 18px 40px rgba(0,0,0,0.6); padding: 8px; }
.fbar-dd__buscar { display: flex; align-items: center; gap: 6px; padding: 6px 10px; margin: 2px 2px 6px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-3); }
.fbar-dd__buscar input { flex: 1; border: 0; background: transparent; color: var(--text-1); font: inherit; font-size: 0.85rem; outline: none; }
.fbar-dd ul { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow: auto; }
.fbar-dd li a { display: flex; align-items: center; gap: 10px; padding: 7px 14px 7px 10px; border-radius: 8px; color: var(--text-1); font-size: 0.86rem; }
.fbar-dd li a:hover { background: rgba(255,255,255,0.06); text-decoration: none; }
.fbar-dd li.is-on a { background: rgba(30,215,96,0.14); }
.fbar-dd li img { width: 22px; height: 22px; object-fit: contain; border-radius: 4px; flex: none; }
.fbar-dd li span.fbar-dd__sin { width: 22px; flex: none; }
.fbar-dd li span { flex: 1 1 auto; min-width: 0; white-space: nowrap; }
.fbar-dd li small { color: var(--text-3); font-variant-numeric: tabular-nums; }
.fbar-dd__quitar { color: #ff9b9b !important; }
.fbar-limpiar { font-size: 0.82rem; color: var(--text-2); padding: 7px 10px; }
.copiar-id { font: inherit; font-size: 0.78rem; padding: 3px 8px; border-radius: 8px; border: 1px solid var(--border); background: transparent; color: var(--text-3); cursor: copy; font-variant-numeric: tabular-nums; }
.copiar-id:hover { color: var(--text-1); border-color: rgba(255,255,255,0.25); }
.copiar-id.is-copiado { color: var(--primary); border-color: var(--primary); }
.buscador__avanzada { padding: 10px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); font-size: 0.85rem; font-weight: 600; }
.buscador__avanzada:hover { text-decoration: none; color: var(--text-1); border-color: rgba(30,215,96,0.6); }
