/* v10.1 robust loader + chat */
:root{ --shadow:0 10px 30px rgba(0,0,0,.12); --accent:#1e90ff;}
*{box-sizing:border-box} html,body{margin:0;padding:0}
body{font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,sans-serif;color:#fff;
background:linear-gradient(135deg,#000 0%,#1e90ff 30%,#6a0dad 65%,#00ff99 100%);background-attachment:fixed;line-height:1.6;}
.container{max-width:1100px;margin:auto;padding:0 20px}
.section{padding:64px 0}.section.alt{background:rgba(255,255,255,.10)}
.section-head{display:flex;justify-content:space-between;align-items:flex-end;margin-bottom:24px;gap:16px}
h1,h2,h3{font-family:Montserrat,Inter,sans-serif;margin:0 0 10px}
a{color:#fff;text-decoration:none}.btn{display:inline-block;background:var(--accent);color:#fff;padding:12px 18px;border-radius:999px;font-weight:700;box-shadow:var(--shadow)}
.site-header{position:sticky;top:0;background:rgba(0,0,0,.35);backdrop-filter:saturate(160%) blur(10px);z-index:10;border-bottom:1px solid rgba(255,255,255,.2)}
.nav{display:flex;align-items:center;justify-content:space-between;min-height:64px;gap:16px}
.brand{display:flex;align-items:center;gap:10px;font-weight:800;color:#fff}.brand img{width:40px;height:40px;border-radius:50%;object-fit:cover}
.menu{display:flex;gap:22px;font-weight:600}.menu a{color:#fff;opacity:.95}
.hero{position:relative;display:grid;place-items:center;padding:64px 0 40px}.hero-media{position:absolute;inset:0;display:grid;place-items:center;opacity:.10;pointer-events:none}
.hero-media img{width:min(800px,90vw);filter:grayscale(1)}.hero-content{text-align:center}
.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.card{background:#fff;border:1px solid #edf0f5;border-radius:14px;overflow:hidden;box-shadow:var(--shadow);display:flex;flex-direction:column;color:#000;min-height:180px}
.card-media img{width:100%;height:180px;object-fit:cover;display:block;filter:grayscale(.2)}.card-body{padding:16px 16px 10px}
.roster-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:18px}.player{background:#fff;border:1px solid #edf0f5;border-radius:14px;display:flex;gap:14px;align-items:center;padding:14px;box-shadow:var(--shadow);color:#000;min-height:88px}
.player .avatar{flex:0 0 64px;height:64px;border-radius:50%;overflow:hidden;border:2px solid #e5e7eb}.player .avatar img{width:100%;height:100%;object-fit:cover}
.sponsor-row{display:flex;gap:20px;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;padding-bottom:10px}
.sponsor-card{flex:0 0 auto;scroll-snap-align:start;background:#fff;border:1px solid #edf0f5;border-radius:18px;box-shadow:var(--shadow);display:grid;place-items:center;width:320px;height:180px;overflow:hidden}
.sponsor-card img, .sponsor-card object{max-width:95%;max-height:95%;width:95%;height:auto;object-fit:contain;display:block}
.scroll-btn{position:absolute;top:50%;transform:translateY(-50%);z-index:5;border:none;border-radius:999px;padding:10px 14px;font-size:20px;cursor:pointer;box-shadow:var(--shadow);background:#fff;color:#000;opacity:.9}
.scroll-btn:hover{opacity:1}.scroller-wrap{position:relative}.scroll-prev{left:-8px}.scroll-next{right:-8px}
#news-cards,#roster-grid{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;gap:16px;padding-bottom:10px}
#news-cards .card,#roster-grid .player{flex:0 0 auto;scroll-snap-align:start;min-width:260px;max-width:300px}
.aff-box{display:flex;align-items:center;gap:18px;background:#fff;border:1px solid #edf0f5;border-radius:14px;box-shadow:var(--shadow);padding:16px;color:#000}
.aff-badge{max-width:160px;height:auto;flex-shrink:0;border-radius:12px}
.chat-launcher{position:fixed;right:20px;bottom:20px;width:56px;height:56px;border-radius:50%;background:#1e90ff;color:#fff;display:grid;place-items:center;font-size:22px;box-shadow:var(--shadow);cursor:pointer;z-index:50}
.chat-panel{position:fixed;right:20px;bottom:88px;width:360px;max-height:70vh;background:#fff;color:#000;border-radius:16px;box-shadow:var(--shadow);display:none;flex-direction:column;overflow:hidden;z-index:50}
.chat-header{display:flex;align-items:center;justify-content:space-between;background:#1e90ff;color:#fff;padding:10px 12px}
.chat-body{padding:12px;overflow:auto;display:flex;flex-direction:column;gap:8px}
.chat-msg{padding:10px 12px;border-radius:12px;max-width:80%}
.chat-msg.bot{background:#f3f4f6;align-self:flex-start}
.chat-msg.user{background:#1e90ff;color:#fff;align-self:flex-end}
.chat-input{display:flex;gap:8px;padding:10px;border-top:1px solid #e5e7eb}
.chat-input input{flex:1;padding:10px;border:1px solid #d1d5db;border-radius:10px}
.chat-input button{padding:10px 12px;border-radius:10px;border:none;background:#1e90ff;color:#fff;cursor:pointer}
.quick-row{display:flex;gap:6px;flex-wrap:wrap;margin-top:6px}
.quick{background:#e5e7eb;border:none;border-radius:999px;padding:6px 10px;cursor:pointer}
.small{font-size:.9em;color:#6b7280}


/* v20 add-on: full-bleed roster theme */
body.roster{
  min-height:100vh;
  background:radial-gradient(at 15% 10%, #22d3ee33, transparent 40%),
             radial-gradient(at 90% 20%, #a78bfa33, transparent 42%),
             radial-gradient(at 30% 90%, #34d39933, transparent 45%),
             linear-gradient(120deg,#0ea5e9,#6d28d9);
}
.glass{background:linear-gradient(90deg,#0ea5e980,#6d28d980);border:1px solid #ffffff40;color:#fff;padding:22px 20px;border-radius:16px;backdrop-filter:blur(10px);box-shadow:0 14px 36px rgba(0,0,0,.2)}
.filters{display:flex;gap:10px;flex-wrap:wrap;margin:12px 0}
.pill{display:inline-flex;align-items:center;gap:8px;padding:8px 12px;border-radius:999px;background:#0b122066;border:1px solid #ffffff40;color:#fff;cursor:pointer;user-select:none;backdrop-filter:blur(6px)}
.pill input{accent-color:#fff}
.pill.active{background:#0b1220;border-color:#fff}
.toolbar{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.search{margin-left:auto;display:flex;align-items:center;gap:8px;background:#fff;border:1px solid #e5e7eb;border-radius:999px;padding:8px 12px;box-shadow:0 6px 20px rgba(2,6,23,.08)}
.search input{border:none;outline:none;width:220px}
.search .icon{opacity:.6}
.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:24px;margin:26px 0 80px}
@media (max-width:1024px){.grid{grid-template-columns:repeat(2,1fr)}}
@media (max-width:640px){.grid{grid-template-columns:1fr}}
.card{background:#0b1220;border-radius:16px;overflow:hidden;box-shadow:0 18px 40px rgba(0,0,0,.35);display:flex;flex-direction:column;border:1px solid #ffffff20}
.card .img{position:relative;aspect-ratio:1/1;overflow:hidden;background:#0a0f1a}
.card .img img{width:100%;height:100%;object-fit:cover;display:block;transform:scale(1.01)}
.card .body{padding:16px;background:#ffffff}
.card h3{margin:0 0 6px;color:#0b1220}
.card .role{color:#334155;margin-bottom:10px}
.badge{position:absolute;left:10px;top:10px;padding:6px 10px;border-radius:999px;color:#fff;font-size:12px;border:1px solid #ffffff55;backdrop-filter:blur(6px);z-index:2;background:#111827cc}
.badge.U14{background:#2563ebcc}
.badge.U16{background:#059669cc}
.badge._3DIVF{background:#a855f7cc}
.badge._1DIVM{background:#f59e0bcc}

/* Prova1 structure & tokens */
:root{--muted:#e5e7eb}
.p1-wrap{max-width:1200px;margin:0 auto;padding:0 16px}
.p1-nav{position:sticky;top:0;z-index:60;display:flex;align-items:center;justify-content:space-between;
  padding:10px 14px;background:linear-gradient(90deg,#0ea5e980,#6d28d980);backdrop-filter:blur(8px);border-bottom:1px solid #ffffff40}
.p1-brand{display:flex;align-items:center;gap:10px}
.p1-brand img{width:36px;height:36px;border-radius:999px;object-fit:cover;border:2px solid #ffffff90}
.p1-brand .txt{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
.p1-menu{background:#0b1220;color:#fff;border:1px solid #ffffff40;padding:8px 12px;border-radius:10px;cursor:pointer}
.p1-menu-panel{position:absolute;right:16px;top:56px;background:#0b1220;border:1px solid #ffffff30;border-radius:12px;padding:10px;display:none;min-width:210px;box-shadow:0 18px 40px rgba(0,0,0,.35)}
.p1-menu-panel a{color:#fff;text-decoration:none;display:block;padding:10px;border-radius:8px}
.p1-menu-panel a:hover{background:#ffffff14}

.p1-hero{padding:42px 0 10px;color:#fff;text-align:center}
.p1-hero h1{margin:0 0 6px;font-size:clamp(28px,5vw,54px)}
.p1-hero p{margin:0;opacity:.95}

.p1-section{margin:26px 0}
.p1-head{display:grid;grid-template-columns:1fr auto;align-items:center;gap:12px;background:linear-gradient(90deg,#0ea5e970,#6d28d970);
  border:1px solid #ffffff40;border-radius:16px;padding:14px 18px;color:#fff;backdrop-filter:blur(10px)}
.p1-head h2,.p1-head h1{margin:0;font-size:24px}
.p1-cta{display:flex;justify-content:center}
.p1-cta .btn{background:#0b1220;color:#fff;border:1px solid #ffffff40;border-radius:12px;padding:10px 14px;text-decoration:none}

.p1-grid-news{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:20px;margin-top:16px}
.p1-card{background:#fff;border:1px solid var(--muted);border-radius:16px;overflow:hidden;box-shadow:0 10px 26px rgba(2,6,23,.08)}
.p1-card img{width:100%;height:200px;object-fit:cover;display:block;background:#f1f5f9}
.p1-card .body{padding:14px;color:#111827}
.p1-card .body h3{margin:0 0 6px;font-size:18px}
.p1-card .body p{margin:0 0 10px;color:#374151}
.p1-link{color:#0b62ff;text-decoration:none;font-weight:700}

.p1-grid-roster{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:18px;margin-top:16px}
.p1-r{background:linear-gradient(90deg,#0ea5e970,#6d28d970);border:1px solid #ffffff30;border-radius:14px;overflow:hidden;color:#fff}
.p1-r img{width:100%;height:200px;object-fit:cover;display:block}
.p1-r .body{padding:12px}

/* Skeletons, search, pager already defined earlier in v23 tokens if present */
.skel{position:relative;overflow:hidden;background:linear-gradient(90deg,#e5e7eb,#f3f4f6,#e5e7eb);background-size:200% 100%;animation:sh 1.2s linear infinite}
@keyframes sh{0%{background-position:200% 0}100%{background-position:-200% 0}}
.skel.img{height:200px;border-radius:10px}
.skel.line{height:14px;border-radius:8px;margin:8px 0}
.skel.line.wide{width:90%} .skel.line.mid{width:70%} .skel.line.small{width:45%}

.search-input{min-width:280px;padding:10px 14px;border-radius:999px;background:#0b1220;border:1px solid #0f172a;color:#fff;box-shadow:0 6px 20px rgba(2,6,23,.35) inset}
.pager{display:flex;gap:8px;align-items:center;justify-content:center;margin:18px 0}
.pager button{padding:8px 12px;border-radius:10px;border:1px solid #e5e7eb;background:#fff;cursor:pointer}
.pager button.active{background:#2563eb;color:#fff;border-color:#2563eb}


/* v23.2 */
.ptv-topbar{position:sticky;top:0;z-index:60;display:flex;align-items:center;gap:12px;
  padding:10px 14px;background:linear-gradient(90deg,#0ea5e980,#6d28d980);
  border-bottom:1px solid #ffffff40; backdrop-filter: blur(8px)}
.menu-button{margin-left:auto;background:#0b1220;color:#fff;border:1px solid #ffffff40;
  padding:8px 12px;border-radius:10px;cursor:pointer}
.menu-panel{position:absolute;right:16px;top:56px;background:#0b1220;border:1px solid #ffffff30;
  border-radius:12px;box-shadow:0 18px 40px rgba(0,0,0,.35);display:none;flex-direction:column;min-width:210px}
.menu-panel a{color:#fff;text-decoration:none;padding:10px 14px;border-bottom:1px solid #ffffff14}
.menu-panel a:last-child{border-bottom:0}
.menu-panel.open{display:flex}

.brand-text,.header .brand a + a,.topbar .brand a + a,.p1-brand .txt{
  position:absolute !important; width:1px !important; height:1px !important;
  padding:0 !important; margin:-1px !important; overflow:hidden !important;
  clip:rect(0,0,0,0) !important; white-space:nowrap !important; border:0 !important;
}

main.home,.home .grid-2,.home .split,.home .home-sections{
  display:flex !important; flex-direction:column !important; gap:48px !important;
}
.home .grid-2 > *, .home .split > *, .home .home-sections > *{ width:100% !important; }

/* v23.3: News home cards più chiare */
.p1-card{background:#ffffff;border:1px solid #eef2f7;box-shadow:0 12px 32px rgba(2,6,23,.10)}
.p1-card .body{color:#0b1020}
.p1-card .body p{color:#334155}

/* v23.3: tasto Torna alla Home */
.back-home{position:sticky;top:66px;display:inline-block;margin:10px 16px;padding:8px 12px;
  background:#0b1220;color:#fff;border:1px solid rgba(255,255,255,.18);
  border-radius:12px;text-decoration:none;z-index:55}
.back-home:hover{filter:brightness(1.1)}
/* Sponsor grid */
.sponsor-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:18px;margin:18px 0 60px}
.s-card{background:#fff;border:1px solid #e5e7eb;border-radius:16px;overflow:hidden;box-shadow:0 10px 26px rgba(2,6,23,.12)}
.s-card img{width:100%;height:180px;object-fit:cover;background:#f8fafc}
.s-card .s-body{padding:14px;color:#0b1020}
.s-card .s-body h3{margin:0 0 6px}
.s-card .s-body p{margin:0;color:#334155}

/* v24 news card override */
.p1-card{background:#fff !important;border:1px solid #e5e7eb !important;border-radius:16px;
 box-shadow:0 8px 20px rgba(0,0,0,.08) !important;overflow:hidden}
.p1-card .body{color:#000 !important}
.p1-card .body h3{color:#000 !important}
.p1-card .body p{color:#111 !important}
