
.ptop-cl {
    --v:      #6C4176;
    --v2:     #8B5499;
    --v3:     #f3eaf7;
    --v4:     #e8d5f0;
    --green:  #059669;
    --green2: #d1fae5;
    --gold:   #d97706;
    --gold2:  #fef3c7;
    --red:    #dc2626;
    --red2:   #fee2e2;
    --bg:     #F7F5F9;
    --card:   #ffffff;
    --text:   #1A1020;
    --muted:  #8A7A92;
    --border: rgba(108,65,118,0.12);
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text);
    max-width: 1100px;
    margin: 0 auto;
    padding-bottom: 80px;
}
.ptop-cl-hero {
    background: linear-gradient(135deg, #1a0a24 0%, #2d1040 60%, #1a0a24 100%);
    border-radius: 24px;
    padding: 56px 48px 48px;
    margin-bottom: 32px;
    position: relative;
    overflow: hidden;
}
.ptop-cl-hero::before {
    content: '';
    position: absolute;
    top: -120px; right: -80px;
    width: 500px; height: 500px;
    background: radial-gradient(ellipse, rgba(108,65,118,0.35) 0%, transparent 65%);
    pointer-events: none;
}
.ptop-cl-hero::after {
    content: '';
    position: absolute;
    bottom: -60px; left: 30%;
    width: 280px; height: 280px;
    background: radial-gradient(ellipse, rgba(212,160,23,0.12) 0%, transparent 65%);
    pointer-events: none;
}
.ptop-cl-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.45);
    margin-bottom: 18px;
}
.ptop-cl-eyebrow-dot {
    width: 6px; height: 6px;
    background: #4ade80;
    border-radius: 50%;
    animation: ptop-live 2s infinite;
}
@keyframes ptop-live { 0%,100%{opacity:1;} 50%{opacity:0.2;} }
.ptop-cl-hero h1 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 800;
    color: #fff;
    margin: 0 0 14px;
    letter-spacing: -0.03em;
    line-height: 1.1;
    position: relative;
}
.ptop-cl-hero h1 em { font-style: normal; color: #c084fc; }
.ptop-cl-hero p {
    color: rgba(255,255,255,0.55);
    font-size: 15px;
    margin: 0 0 28px;
    max-width: 580px;
    line-height: 1.7;
    position: relative;
}
.ptop-cl-meta { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; position: relative; }
.ptop-cl-meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    padding: 5px 13px;
    font-size: 12px;
    color: rgba(255,255,255,0.55);
}
.ptop-cl-meta-pill strong { color: rgba(255,255,255,0.9); }
.ptop-cl-tabs-wrap {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg);
    padding: 12px 0;
    margin-bottom: 32px;
}
.ptop-cl-tabs {
    display: flex;
    gap: 6px;
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 14px;
    padding: 6px;
    overflow-x: auto;
    scrollbar-width: none;
}
.ptop-cl-tabs::-webkit-scrollbar { display: none; }
.ptop-cl-tab {
    flex-shrink: 0;
    padding: 9px 18px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--muted);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.ptop-cl-tab:hover { background: var(--v3); color: var(--v); }
.ptop-cl-tab.active { background: var(--v); color: #fff; box-shadow: 0 4px 12px rgba(108,65,118,0.3); }
.ptop-cl-tab-badge { background: rgba(255,255,255,0.2); border-radius: 20px; padding: 1px 7px; font-size: 10px; font-weight: 800; }
.ptop-cl-tab:not(.active) .ptop-cl-tab-badge { background: var(--v3); color: var(--v); }
.ptop-cl-section { display: none; }
.ptop-cl-section.active { display: block; }
.ptop-cl-section-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--text);
    letter-spacing: -0.02em;
    margin: 0 0 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.ptop-cl-section-title::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.ptop-cl-kpi { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-bottom: 28px; }
.ptop-kpi { background: var(--card); border: 1.5px solid var(--border); border-radius: 16px; padding: 22px 20px; position: relative; overflow: hidden; }
.ptop-kpi::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; border-radius: 16px 16px 0 0; }
.ptop-kpi-v::before     { background: var(--v); }
.ptop-kpi-green::before { background: var(--green); }
.ptop-kpi-gold::before  { background: var(--gold); }
.ptop-kpi-red::before   { background: var(--red); }
.ptop-kpi-icon { font-size: 22px; margin-bottom: 8px; }
.ptop-kpi-lbl { font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.ptop-kpi-val { font-size: 38px; font-weight: 800; line-height: 1; letter-spacing: -0.03em; margin-bottom: 5px; }
.ptop-kpi-v .ptop-kpi-val     { color: var(--v); }
.ptop-kpi-green .ptop-kpi-val { color: var(--green); }
.ptop-kpi-gold .ptop-kpi-val  { color: var(--gold); }
.ptop-kpi-red .ptop-kpi-val   { color: var(--red); }
.ptop-kpi-sub { font-size: 12px; color: var(--muted); }
.ptop-distrib-row { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.ptop-distrib-row:last-child { margin: 0; }
.ptop-distrib-lbl { width: 120px; flex-shrink: 0; font-size: 12px; font-weight: 700; }
.ptop-distrib-track { flex: 1; background: #f0eaf5; border-radius: 8px; height: 10px; overflow: hidden; }
.ptop-distrib-fill { height: 100%; border-radius: 8px; transition: width 1.2s cubic-bezier(0.4,0,0.2,1); }
.ptop-distrib-n { width: 40px; text-align: right; font-size: 13px; font-weight: 800; flex-shrink: 0; }
.ptop-distrib-pct { width: 36px; text-align: right; font-size: 11px; color: var(--muted); flex-shrink: 0; }
.ptop-card { background: var(--card); border: 1.5px solid var(--border); border-radius: 20px; padding: 28px; margin-bottom: 20px; box-shadow: 0 2px 16px rgba(108,65,118,0.05); }
.ptop-chart-legend { display: flex; gap: 18px; margin-bottom: 18px; flex-wrap: wrap; }
.ptop-chart-legend-item { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.ptop-legend-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.ptop-rank-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 20px;
    border-bottom: 1px solid var(--border);
    transition: background 0.15s;
    text-decoration: none;
    color: var(--text);
}
.ptop-rank-row:last-child { border-bottom: none; }
.ptop-rank-row:hover { background: var(--v3); }
.ptop-rank-n { width: 32px; font-size: 18px; font-weight: 800; color: var(--border); flex-shrink: 0; text-align: center; }
.ptop-rank-row:nth-child(1) .ptop-rank-n { color: #D4A017; }
.ptop-rank-row:nth-child(2) .ptop-rank-n { color: #8A9BA8; }
.ptop-rank-row:nth-child(3) .ptop-rank-n { color: #A0622A; }
.ptop-rank-thumb { width: 42px; height: 42px; border-radius: 10px; background: var(--bg); flex-shrink: 0; overflow: hidden; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; }
.ptop-rank-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.ptop-rank-name { flex: 1; font-size: 13px; font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ptop-rank-cat { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); background: var(--v3); padding: 2px 8px; border-radius: 20px; flex-shrink: 0; }
.ptop-rank-score { flex-shrink: 0; font-size: 22px; font-weight: 800; min-width: 44px; text-align: right; }
.ptop-rank-score.high { color: var(--green); }
.ptop-rank-score.med  { color: var(--gold); }
.ptop-rank-score.low  { color: var(--red); }
.ptop-rank-bar-wrap { width: 60px; height: 6px; background: #f0eaf5; border-radius: 6px; overflow: hidden; flex-shrink: 0; }
.ptop-rank-bar { height: 100%; border-radius: 6px; }
.ptop-cat-grid {
    
    grid-template-columns: 1fr;
    gap: 20px;
    align-items: start;
}
@media (max-width: 700px) {
    .ptop-cat-grid { grid-template-columns: 1fr; }
}
.ptop-cat-card {
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    color: var(--text);
    transition: box-shadow 0.2s, border-color 0.2s;
}
.ptop-cat-card:hover {
    box-shadow: 0 8px 28px rgba(108,65,118,0.1);
    border-color: var(--v);
}
.ptop-cat-card-link {
    display: block;
    text-decoration: none;
    color: var(--text);
    margin: -4px -4px 0;
    padding: 4px 4px 12px;
    border-radius: 12px;
    transition: background 0.15s;
}
.ptop-cat-card-link:hover { background: var(--v3); }
.ptop-cat-card-header { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.ptop-cat-ring { position: relative; width: 52px; height: 52px; flex-shrink: 0; }
.ptop-cat-ring svg { transform: rotate(-90deg); }
.ptop-cat-ring-num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; color: var(--v); }
.ptop-cat-name { font-size: 15px; font-weight: 800; color: var(--text); margin-bottom: 3px; }
.ptop-cat-sub { font-size: 12px; color: var(--muted); }
.ptop-cat-bars { display: flex; flex-direction: column; gap: 6px; }
.ptop-cat-bar-row { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.ptop-cat-bar-lbl { width: 70px; color: var(--muted); font-weight: 600; }
.ptop-cat-bar-track { flex: 1; height: 6px; background: #f0eaf5; border-radius: 6px; overflow: hidden; }
.ptop-cat-bar-fill { height: 100%; border-radius: 6px; }
.ptop-cat-bar-n { width: 24px; text-align: right; font-weight: 700; }
.ptop-cat-top5 {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px dashed var(--border);
}
.ptop-cat-top5-title {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 8px;
}
.ptop-cat-top5-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 4px;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    color: var(--text);
    transition: background 0.15s;
    border-radius: 6px;
}
.ptop-cat-top5-row:last-child { border-bottom: none; }
.ptop-cat-top5-row:hover { background: var(--v3); }
.ptop-cat-top5-n {
    width: 18px;
    font-size: 11px;
    font-weight: 800;
    color: var(--muted);
    flex-shrink: 0;
    text-align: center;
}
.ptop-cat-top5-row:nth-child(1) .ptop-cat-top5-n { color: #D4A017; }
.ptop-cat-top5-row:nth-child(2) .ptop-cat-top5-n { color: #8A9BA8; }
.ptop-cat-top5-row:nth-child(3) .ptop-cat-top5-n { color: #A0622A; }
.ptop-cat-top5-thumb {
    width: 28px; height: 28px;
    border-radius: 6px;
    background: var(--bg);
    flex-shrink: 0;
    overflow: hidden;
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
}
.ptop-cat-top5-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 3px; }
.ptop-cat-top5-name {
    flex: 1;
    font-size: 11px;
    font-weight: 600;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--text);
}
.ptop-cat-top5-price {
    font-size: 11px;
    font-weight: 800;
    color: var(--v);
    flex-shrink: 0;
}
.ptop-cat-top5-score {
    font-size: 14px;
    font-weight: 800;
    flex-shrink: 0;
    min-width: 28px;
    text-align: right;
}
.ptop-cat-top5-score.high { color: var(--green); }
.ptop-cat-top5-score.med  { color: var(--gold); }
.ptop-cat-top5-score.low  { color: var(--red); }
/* FIX3: link "Vedi classifica" in fondo a ogni card categoria */
.ptop-cat-seo-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 14px;
    font-size: 11px;
    font-weight: 700;
    color: var(--v);
    text-decoration: none;
    transition: opacity .15s;
}
.ptop-cat-seo-link:hover { opacity: .75; }
.ptop-curio-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
@media (max-width: 640px) {
    .ptop-curio-grid { grid-template-columns: 1fr; }
    .ptop-curio-grid .ptop-curio-card[style*="grid-column"] { grid-column: span 1 !important; }
    .ptop-curio-icon { font-size: 26px; }
    .ptop-curio-value { font-size: 22px; }
}
.ptop-curio-card { background: var(--card); border: 1.5px solid var(--border); border-radius: 18px; padding: 24px; position: relative; overflow: hidden; }
.ptop-curio-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; border-radius: 18px 18px 0 0; }
.ptop-curio-v::before    { background: var(--v); }
.ptop-curio-green::before{ background: var(--green); }
.ptop-curio-gold::before { background: var(--gold); }
.ptop-curio-red::before  { background: var(--red); }
.ptop-curio-blue::before { background: #3b82f6; }
.ptop-curio-pink::before { background: #ec4899; }
.ptop-curio-icon { font-size: 32px; margin-bottom: 12px; }
.ptop-curio-label { font-size: 10px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.ptop-curio-value { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; color: var(--text); margin-bottom: 6px; line-height: 1.1; }
.ptop-curio-desc { font-size: 13px; color: var(--muted); line-height: 1.5; }
.ptop-histo { display: flex; align-items: flex-end; gap: 6px; height: 100px; }
.ptop-histo-bar-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; justify-content: flex-end; }
.ptop-histo-bar { width: 100%; border-radius: 4px 4px 0 0; transition: height 0.8s cubic-bezier(0.4,0,0.2,1); min-height: 4px; }
.ptop-histo-lbl { font-size: 9px; color: var(--muted); font-weight: 600; }
.ptop-seo-block { background: var(--v3); border: 1.5px solid var(--v4); border-radius: 20px; padding: 32px 36px; margin-top: 32px; }
.ptop-seo-block h2 { font-size: 20px; font-weight: 800; color: var(--v); margin: 0 0 12px; }
.ptop-seo-block p { font-size: 14px; color: var(--muted); line-height: 1.7; margin: 0 0 10px; }
.ptop-seo-block p:last-child { margin: 0; }
.ptop-fade { opacity: 0; transform: translateY(20px); transition: opacity 0.5s ease, transform 0.5s ease; }
.ptop-fade.in { opacity: 1; transform: translateY(0); }
@media (max-width: 640px) {
    .ptop-cl-hero { padding: 36px 20px 32px; }
    .ptop-cl-hero h1 { font-size: 1.9rem; }
    .ptop-rank-cat { display: none; }
    .ptop-rank-bar-wrap { display: none; }
    .ptop-card { padding: 18px; }
}
