/* ============================================================
   Football Agent Tycoon — Global Stylesheet
   Dark football theme | Inter font | Mobile-first responsive
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ── Reset & base ─────────────────────────────────────────── */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg:           #0d1117;
    --bg-card:      #161b22;
    --bg-input:     #21262d;
    --border:       #30363d;
    --accent:       #00c853;
    --accent-dark:  #00a846;
    --accent-glow:  rgba(0, 200, 83, 0.25);
    --text:         #e6edf3;
    --text-muted:   #8b949e;
    --error:        #ff5252;
    --error-bg:     rgba(255, 82, 82, 0.12);
    --success:      #00c853;
    --success-bg:   rgba(0, 200, 83, 0.12);
    --warning:      #ffa726;
    --radius:       10px;
    --radius-sm:    6px;
    --shadow:       0 8px 32px rgba(0, 0, 0, 0.5);
    --transition:   0.2s ease;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--transition);
}

a:not(.btn):hover {
    color: var(--accent-dark);
}

/* Buttons as <a> must keep their own color on hover */
a.btn:hover { color: inherit; }

/* ── Scrollbar ────────────────────────────────────────────── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── Navbar ───────────────────────────────────────────────── */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    height: 64px;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
}

.navbar-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.02em;
}

.navbar-logo .logo-icon {
    font-size: 1.5rem;
}

.navbar-logo .logo-accent {
    color: var(--accent);
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.navbar-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.navbar-user strong {
    color: var(--text);
    font-weight: 600;
}

.btn-logout {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 1rem;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
}

.btn-logout:hover {
    border-color: var(--error);
    color: var(--error);
    background: var(--error-bg);
}

/* ── Auth layout ──────────────────────────────────────────── */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 2rem 1rem;
    background:
        radial-gradient(ellipse 80% 60% at 50% -20%, rgba(0,200,83,0.08) 0%, transparent 60%),
        var(--bg);
}

.auth-container {
    width: 100%;
    max-width: 420px;
}

.auth-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-logo .logo-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 0.5rem;
    filter: drop-shadow(0 0 20px var(--accent));
}

.auth-logo h1 {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text);
}

.auth-logo h1 span {
    color: var(--accent);
}

.auth-logo .tagline {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* ── Card ─────────────────────────────────────────────────── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow);
}

.card-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1.5rem;
}

/* ── Form ─────────────────────────────────────────────────── */
.form-group {
    margin-bottom: 1.2rem;
    position: relative;
}

.form-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-control {
    width: 100%;
    padding: 0.65rem 0.9rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color var(--transition), box-shadow var(--transition);
    outline: none;
    appearance: none;
}

.form-control::placeholder {
    color: var(--text-muted);
    opacity: 0.6;
}

.form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-control.is-invalid {
    border-color: var(--error);
    box-shadow: 0 0 0 3px rgba(255, 82, 82, 0.15);
}

.form-control.is-valid {
    border-color: var(--accent);
}

/* Input with inline status icon */
.input-wrapper {
    position: relative;
}

.input-wrapper .form-control {
    padding-right: 2.5rem;
}

.input-status {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    pointer-events: none;
    transition: opacity var(--transition);
}

/* ── Field feedback ───────────────────────────────────────── */
.field-error {
    font-size: 0.78rem;
    color: var(--error);
    margin-top: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.field-error::before {
    content: '⚠';
    font-size: 0.75rem;
}

.field-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.3rem;
}

/* ── Alert banners ────────────────────────────────────────── */
.alert {
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    margin-bottom: 1.2rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.alert-error {
    background: var(--error-bg);
    border: 1px solid rgba(255, 82, 82, 0.3);
    color: var(--error);
}

.alert-success {
    background: var(--success-bg);
    border: 1px solid rgba(0, 200, 83, 0.3);
    color: var(--success);
}

/* ── Password strength ────────────────────────────────────── */
.password-strength {
    margin-top: 0.4rem;
}

.strength-bar {
    height: 4px;
    border-radius: 2px;
    background: var(--border);
    overflow: hidden;
    margin-bottom: 0.3rem;
}

.strength-fill {
    height: 100%;
    border-radius: 2px;
    width: 0%;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.strength-fill.weak   { width: 33%; background: var(--error); }
.strength-fill.medium { width: 66%; background: var(--warning); }
.strength-fill.strong { width: 100%; background: var(--accent); }

.strength-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.strength-label.weak   { color: var(--error); }
.strength-label.medium { color: var(--warning); }
.strength-label.strong { color: var(--accent); }

/* ── Button ───────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition);
    letter-spacing: 0.01em;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: #000;
}

/* Full-width block button (form submit nei form di login/registrazione) */
.btn-block {
    width: 100%;
    margin-top: 0.5rem;
}

.btn-primary:hover:not(:disabled) {
    background: var(--accent-dark);
    box-shadow: 0 4px 20px rgba(0, 200, 83, 0.4);
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* ── Auth footer link ─────────────────────────────────────── */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.auth-footer a {
    font-weight: 600;
}

/* ── Dashboard layout ─────────────────────────────────────── */
.dashboard-page {
    min-height: 100vh;
    /* Sfondo "petrolio tenue": vignette radiale dall'alto (#316962 come luce) → profondità premium */
    background: radial-gradient(120% 115% at 50% -10%, #173430 0%, #0c1714 46%, #060b0a 100%) fixed;
}

.dashboard-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.dashboard-welcome {
    margin-bottom: 2rem;
}

.dashboard-welcome h2 {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text);
}

.dashboard-welcome h2 .name {
    color: var(--accent);
}

.dashboard-welcome p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

/* ── Stats grid ───────────────────────────────────────────── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.2rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
    cursor: default;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
    border-color: rgba(0, 200, 83, 0.3);
}

.stat-icon {
    font-size: 2rem;
    line-height: 1;
}

.stat-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: -0.03em;
}

.stat-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ── Section title ────────────────────────────────────────── */
.section-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

/* ── Placeholder card ─────────────────────────────────────── */
.placeholder-card {
    background: var(--bg-card);
    border: 1px dashed var(--border);
    border-radius: var(--radius);
    padding: 2.5rem;
    text-align: center;
    color: var(--text-muted);
}

.placeholder-card .placeholder-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    display: block;
    opacity: 0.5;
}

.placeholder-card p {
    font-size: 0.875rem;
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 768px) {
    .navbar {
        padding: 0 1rem;
        height: 56px;
    }

    .navbar-logo {
        font-size: 1rem;
    }

    .navbar-user span {
        display: none;
    }

    .auth-page {
        padding: 1.5rem 0.75rem;
        align-items: flex-start;
        padding-top: 3rem;
    }

    .card {
        padding: 1.5rem;
    }

    .auth-logo h1 {
        font-size: 1.3rem;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.9rem;
    }

    .stat-card {
        padding: 1.2rem;
    }

    .stat-value {
        font-size: 1.3rem;
    }

    .dashboard-main {
        padding: 1.5rem 1rem;
    }

    .dashboard-welcome h2 {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   Homepage
   ============================================================ */

/* ── Navbar additions for homepage ───────────────────────── */
.btn-ghost {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 1rem;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    transition: color var(--transition);
    text-decoration: none;
}
.btn-ghost:hover { color: var(--text); }

.btn-sm {
    padding: 0.4rem 1.1rem;
    font-size: 0.875rem;
    width: auto;
    margin-top: 0;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    transition: all var(--transition);
}
.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-glow);
}

.btn-lg {
    padding: 0.85rem 2rem;
    font-size: 1rem;
    width: auto;
    margin-top: 0;
}

/* ── Hero ─────────────────────────────────────────────────── */
.hero {
    position: relative;
    min-height: calc(100vh - 64px);
    display: flex;
    align-items: center;
    gap: 4rem;
    padding: 5rem 6vw 4rem;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.hero-glow {
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 900px;
    height: 500px;
    background: radial-gradient(ellipse, rgba(0,200,83,0.1) 0%, transparent 65%);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(48,54,61,0.35) 1px, transparent 1px),
        linear-gradient(90deg, rgba(48,54,61,0.35) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 80% 80% at 50% 0%, black 30%, transparent 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
    flex: 1;
    max-width: 580px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0,200,83,0.1);
    border: 1px solid rgba(0,200,83,0.3);
    border-radius: 100px;
    padding: 0.35rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 1.5rem;
    letter-spacing: 0.02em;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.6; transform: scale(0.85); }
}

.hero-title {
    font-size: clamp(2.4rem, 5vw, 3.6rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.04em;
    color: var(--text);
    margin-bottom: 1.25rem;
}

.hero-accent {
    color: var(--accent);
    position: relative;
}

.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 2rem;
    max-width: 480px;
}

.hero-cta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.hero-stat strong {
    display: block;
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: -0.02em;
}

.hero-stat span {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
}

.hero-stat-divider {
    width: 1px;
    height: 32px;
    background: var(--border);
}

/* ── Hero visual / agent card ─────────────────────────────── */
.hero-visual {
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}

.agent-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    width: 300px;
    box-shadow: 0 24px 64px rgba(0,0,0,0.6), 0 0 0 1px rgba(0,200,83,0.08);
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-10px); }
}

.agent-card-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.agent-card-icon {
    font-size: 2.2rem;
    line-height: 1;
    background: rgba(0,200,83,0.1);
    border-radius: 10px;
    padding: 0.5rem;
}

.agent-card-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
}

.agent-card-rank {
    font-size: 0.75rem;
    color: var(--accent);
    margin-top: 0.1rem;
}

.agent-card-stats {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    margin-bottom: 1.25rem;
}

.agent-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.82rem;
}

.agent-stat-row > span:first-child {
    color: var(--text-muted);
}

.agent-stat-val {
    font-weight: 700;
    color: var(--text);
}

.agent-stat-val.accent { color: var(--accent); }

.agent-card-deal {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(0,200,83,0.07);
    border: 1px solid rgba(0,200,83,0.2);
    border-radius: var(--radius-sm);
    padding: 0.7rem 0.85rem;
}

.deal-icon { font-size: 1.2rem; }

.deal-title {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.deal-desc {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text);
    margin-top: 0.1rem;
}

.deal-badge {
    margin-left: auto;
    background: var(--accent);
    color: #000;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.2rem 0.45rem;
    border-radius: 4px;
    letter-spacing: 0.08em;
    animation: pulse-badge 1.5s ease-in-out infinite;
}

@keyframes pulse-badge {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.6; }
}

/* ── Shared section layout ────────────────────────────────── */
.section-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 6vw;
}

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-heading {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 0.6rem;
}

.section-subheading {
    font-size: 1rem;
    color: var(--text-muted);
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ── Features ─────────────────────────────────────────────── */
.features-section {
    padding: 6rem 0;
    border-top: 1px solid var(--border);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.5);
    border-color: rgba(0,200,83,0.3);
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: block;
}

.feature-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.feature-card p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.65;
}

/* ── How it works ─────────────────────────────────────────── */
.howto-section {
    padding: 6rem 0;
    border-top: 1px solid var(--border);
    background: linear-gradient(180deg, transparent 0%, rgba(0,200,83,0.03) 50%, transparent 100%);
}

.steps-list {
    display: flex;
    align-items: flex-start;
    gap: 0;
    max-width: 900px;
    margin: 0 auto;
}

.step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

.step-number {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: 0.02em;
    box-shadow: 0 0 16px var(--accent-glow);
    flex-shrink: 0;
}

.step-body h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.4rem;
}

.step-body p {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 180px;
    margin: 0 auto;
}

.step-connector {
    flex-shrink: 0;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--border));
    margin-top: 25px;
    opacity: 0.5;
}

/* ── CTA section ──────────────────────────────────────────── */
.cta-section {
    padding: 6rem 0;
    border-top: 1px solid var(--border);
}

.cta-box {
    position: relative;
    background: var(--bg-card);
    border: 1px solid rgba(0,200,83,0.25);
    border-radius: 20px;
    padding: 4rem 2rem;
    text-align: center;
    overflow: hidden;
}

.cta-glow {
    position: absolute;
    top: -60%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(0,200,83,0.12) 0%, transparent 65%);
    pointer-events: none;
}

.cta-eyebrow {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 16px var(--accent));
}

.cta-box h2 {
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 0.75rem;
    position: relative;
}

.cta-box p {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 2rem;
    position: relative;
}

/* ── Footer ───────────────────────────────────────────────── */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 2rem 0;
    background: var(--bg-card);
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text);
}

.footer-copy {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 1.25rem;
}

.footer-links a {
    font-size: 0.82rem;
    color: var(--text-muted);
    transition: color var(--transition);
}

.footer-links a:hover { color: var(--accent); }

/* ── Homepage responsive ──────────────────────────────────── */
@media (max-width: 960px) {
    .hero {
        flex-direction: column;
        align-items: flex-start;
        padding: 3.5rem 6vw 3rem;
        gap: 2.5rem;
        min-height: unset;
    }

    .hero-visual { align-self: center; }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .steps-list {
        flex-direction: column;
        align-items: center;
        gap: 0;
    }

    .step { flex-direction: row; text-align: left; gap: 1.25rem; }
    .step-body p { max-width: none; margin: 0; }

    .step-connector {
        width: 2px;
        height: 32px;
        background: linear-gradient(180deg, var(--accent), var(--border));
        margin: 0;
        margin-left: 25px;
    }

    .footer-inner { flex-direction: column; align-items: center; text-align: center; }
    .footer-links { justify-content: center; }
}

@media (max-width: 600px) {
    .features-grid { grid-template-columns: 1fr; }

    .agent-card { width: 100%; max-width: 320px; }

    .hero-stats { gap: 1rem; }

    .cta-box { padding: 2.5rem 1.25rem; }
}

/* ============================================================
   Navbar dropdown menu
   ============================================================ */
.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 0.25rem;
    margin: 0 1.5rem;
}

.nav-item { position: relative; }

.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.85rem;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: color var(--transition), background var(--transition);
    white-space: nowrap;
    text-decoration: none;
}

.nav-link:hover,
.nav-item.open > .nav-link {
    color: var(--text);
    background: rgba(255,255,255,0.05);
}

.dropdown-arrow {
    font-size: 0.65rem;
    transition: transform 0.2s ease;
}

.nav-item.open .dropdown-arrow { transform: rotate(180deg); }

/* Dropdown panel */
.nav-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 180px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 12px 32px rgba(0,0,0,0.5);
    list-style: none;
    padding: 0.4rem 0;
    z-index: 200;
    animation: dropdown-in 0.15s ease;
}

.nav-item.open .nav-dropdown { display: block; }

@keyframes dropdown-in {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 1rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    transition: background var(--transition), color var(--transition);
    text-decoration: none;
}

.nav-dropdown-item:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text);
}

.nav-admin-link {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--warning) !important;
}

/* ── Hamburger button (hidden on desktop) ─────────────────── */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    /* iOS: garantisce che il tap funzioni */
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    -webkit-appearance: none;
    appearance: none;
}

.nav-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-muted);
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
    pointer-events: none;
}

.nav-hamburger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.is-open span:nth-child(2) { opacity: 0; }
.nav-hamburger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Barra che va a capo invece di uscire dallo schermo ───────
   Sopra la soglia dell'hamburger (860px) la navbar resta "desktop", ma
   logo + 7 voci + azioni a destra chiedono ~1600px: sotto quella misura
   (portatili 1366/1440, monitor in pivot) le voci finivano fuori dal
   viewport e si potevano raggiungere solo scrollando in orizzontale.
   Qui la barra diventa a due righe — logo e azioni sopra, menu sotto a
   tutta larghezza — e il menu stesso può spezzarsi su più righe. */
@media (min-width: 860px) {
    .navbar {
        flex-wrap: wrap;
        height: auto;
        min-height: 64px;
        row-gap: 0.15rem;
        padding-top: 0.25rem;
        padding-bottom: 0.25rem;
    }

    .nav-menu    { flex-wrap: wrap; justify-content: center; row-gap: 0.15rem; }
    .navbar-right { flex-wrap: wrap; justify-content: flex-end; row-gap: 0.15rem; }
}

/* Sotto la larghezza minima per stare su una riga sola: menu a capo.
   L'ordine esplicito evita che sia la barra azioni a scendere per prima. */
@media (min-width: 860px) and (max-width: 1780px) {
    .navbar-logo  { order: 1; }
    .navbar-right { order: 2; }
    .nav-menu     { order: 3; flex: 1 0 100%; margin: 0; }
}

/* ============================================================
   Leagues page
   ============================================================ */
.nation-section { margin-bottom: 2.5rem; }

.nation-heading {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1.1rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid var(--border);
}

.nation-flag { font-size: 1.3rem; }

.leagues-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 1.1rem;
}

.league-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.league-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.45);
    border-color: rgba(0,200,83,0.25);
}

.league-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.league-level-badge {
    background: rgba(0,200,83,0.12);
    border: 1px solid rgba(0,200,83,0.25);
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.55rem;
    border-radius: 100px;
    letter-spacing: 0.04em;
}

.league-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 6px var(--accent);
}

.league-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.9rem;
}

.league-meta { display: flex; flex-direction: column; gap: 0.45rem; margin-bottom: 0.9rem; }

.league-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
}

.league-meta-row > span:first-child { color: var(--text-muted); }
.league-meta-row strong { color: var(--text); font-weight: 600; }

.league-quality-bar {
    position: relative;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
}

.league-quality-fill {
    position: absolute;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-dark), var(--accent));
    border-radius: 2px;
}

/* ============================================================
   Admin pages
   ============================================================ */
.admin-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.admin-page-title {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
}

.admin-page-sub { color: var(--text-muted); font-size: 0.875rem; margin-top: 0.2rem; }
.admin-page-sub a { color: var(--accent); }

/* Admin menu cards */
.admin-menu-grid { display: flex; flex-direction: column; gap: 0.75rem; }

.admin-menu-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    text-decoration: none;
    transition: all var(--transition);
}

.admin-menu-card:hover {
    border-color: var(--accent);
    background: rgba(0,200,83,0.04);
    transform: translateX(4px);
}

.admin-menu-icon { font-size: 1.8rem; }

.admin-menu-card > div strong {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
}

.admin-menu-card > div p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

.admin-menu-arrow { margin-left: auto; color: var(--text-muted); font-size: 1.1rem; }

/* Admin table */
.admin-table-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.admin-table th {
    background: rgba(255,255,255,0.03);
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

.admin-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(48,54,61,0.5);
    color: var(--text);
    vertical-align: middle;
}

.admin-table tr:last-child td { border-bottom: none; }

.admin-table tr:hover td { background: rgba(255,255,255,0.02); }

.level-badge {
    background: rgba(0,200,83,0.1);
    border: 1px solid rgba(0,200,83,0.2);
    color: var(--accent);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
}

.status-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2rem 0.6rem;
    border-radius: 100px;
}

.status-active   { color: var(--accent);  background: rgba(0,200,83,0.1);  }
.status-inactive { color: var(--text-muted); background: rgba(255,255,255,0.05); }

.text-muted { color: var(--text-muted); }

.admin-actions { display: flex; align-items: center; gap: 0.35rem; }

.btn-action {
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.9rem;
    padding: 0.3rem 0.5rem;
    line-height: 1;
    transition: all var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.btn-edit:hover   { border-color: var(--accent);  background: rgba(0,200,83,0.1); }
.btn-toggle:hover { border-color: var(--warning);  background: rgba(255,167,38,0.1); }
.btn-delete:hover { border-color: var(--error);   background: rgba(255,82,82,0.1); }

/* Admin form */
.admin-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    align-items: start;
}

.admin-form-col { display: flex; flex-direction: column; gap: 0; }

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.team-input-row { margin-bottom: 0.75rem; }

@media (max-width: 860px) {
    .admin-form-grid { grid-template-columns: 1fr; }

    /* Su mobile la navbar diventa fixed (non sticky) così i figli
       con position:fixed si posizionano rispetto al viewport —
       fix per il bug iOS Safari con sticky+fixed */
    .navbar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
    }

    /* Compensa l'altezza della navbar fixed */
    .dashboard-page {
        padding-top: 64px;
    }

    /* Mostra hamburger, nascondi menu di default */
    .nav-hamburger { display: flex; }

    /* Il menu diventa un pannello fisso sotto la navbar */
    .nav-menu {
        display: none;
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        bottom: 0;
        flex-direction: column;
        background: var(--bg-card);
        border-top: 1px solid var(--border);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch; /* iOS smooth scroll */
        padding: 0.75rem 1rem 2rem;
        z-index: 200;
        gap: 0.25rem;
        margin: 0;
    }

    .nav-menu.mobile-open { display: flex; }

    /* Voci principali a larghezza piena */
    .nav-item { width: 100%; }

    .nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: 0.75rem 1rem;
        font-size: 1rem;
        border-radius: var(--radius-sm);
    }

    /* Dropdown inline (non assoluto) */
    .nav-dropdown {
        position: static;
        box-shadow: none;
        background: rgba(255,255,255,0.03);
        border: 1px solid var(--border);
        border-radius: var(--radius-sm);
        margin-top: 0.25rem;
        padding: 0.25rem 0;
        animation: none;
    }

    .nav-dropdown-item {
        padding: 0.65rem 1.25rem;
        font-size: 0.9rem;
    }

    /* Nascondi nome utente su mobile stretto */
    .navbar-username { display: none; }
}

@media (max-width: 600px) {
    .form-row-2 { grid-template-columns: 1fr; }
}

/* ============================================================
   League detail page (classifica)
   ============================================================ */
.league-page-header { margin-bottom: .5rem; }

.league-page-meta {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: .4rem;
    flex-wrap: wrap;
}

.league-page-flag  { font-size: 1.4rem; }
.league-page-nation { font-size: .85rem; color: var(--text-muted); font-weight: 500; }

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    color: var(--text-muted);
    font-size: .85rem;
    text-decoration: none;
    transition: color var(--transition);
    margin-top: .5rem;
}
.btn-back:hover { color: var(--accent); }

/* Standings table */
.standings-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.standings-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .875rem;
}

.standings-table thead th {
    background: rgba(255,255,255,.03);
    padding: .65rem 1rem;
    text-align: center;
    font-size: .72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

.standings-table thead th.col-team { text-align: left; }
.standings-table thead th.col-pos  { width: 48px; }
.standings-table thead th.col-pts  { color: var(--accent); }

.standings-table tbody td {
    padding: .75rem 1rem;
    text-align: center;
    border-bottom: 1px solid rgba(48,54,61,.5);
    color: var(--text);
    vertical-align: middle;
}

.standings-table tbody td.col-team { text-align: left; }
.standings-table tbody td.col-pos  { width: 48px; }

.standings-table tbody td.col-gd   { font-weight: 600; }
.standings-table tbody td.col-pts  { font-size: 1rem; font-weight: 800; color: var(--accent); }

.standings-table tbody tr:last-child td { border-bottom: none; }

.standings-table tbody tr:hover td { background: rgba(255,255,255,.03); }

/* Row highlights — legacy (hardcoded top-3 / bottom-3) */
.standings-table tbody tr.row-first td:first-child { border-left: 3px solid #ffd700; }
.standings-table tbody tr.row-top   td:first-child { border-left: 3px solid var(--accent); }
.standings-table tbody tr.row-rel   td:first-child { border-left: 3px solid var(--error); }

/* Row highlights — configurable (promozioni / retrocessioni) */
.standings-table tbody tr.row-promo-auto    td:first-child { border-left: 3px solid #4caf50; }
.standings-table tbody tr.row-promo-playoff td:first-child { border-left: 3px solid #40c4ff; }
.standings-table tbody tr.row-rel-playoff   td:first-child { border-left: 3px solid #f59e0b; }
.standings-table tbody tr.row-rel-auto      td:first-child { border-left: 3px solid var(--error); }

.pos-icon { font-size: 1.1rem; }
.pos-num  { font-weight: 700; color: var(--text-muted); }

.team-link {
    font-weight: 600;
    color: var(--text);
    text-decoration: none;
    transition: color var(--transition);
}
.team-link:hover { color: var(--accent); }

.standings-note {
    font-size: .78rem;
    color: var(--text-muted);
    margin-top: .75rem;
    padding-left: .25rem;
}

/* league-card hover pointer */
.league-card-link:hover { border-color: rgba(0,200,83,.4); }

/* ============================================================
   Team overview page
   ============================================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .8rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-muted); text-decoration: none; transition: color var(--transition); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span:last-child { color: var(--text); font-weight: 500; }

.team-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.team-hero-left {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.team-crest {
    font-size: 3.5rem;
    line-height: 1;
    background: rgba(0,200,83,.08);
    border: 1px solid rgba(0,200,83,.2);
    border-radius: 14px;
    padding: .75rem;
    flex-shrink: 0;
}

.team-hero-meta {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .8rem;
    color: var(--text-muted);
    margin-bottom: .3rem;
}

.team-hero-name {
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    letter-spacing: -.03em;
    color: var(--text);
    margin-bottom: .3rem;
}

.team-hero-league {
    font-size: .85rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color var(--transition);
}
.team-hero-league:hover { color: var(--accent); }

.team-hero-position {
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem 1.5rem;
    flex-shrink: 0;
}

.team-pos-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    letter-spacing: -.04em;
}

.team-pos-label {
    font-size: .75rem;
    color: var(--text-muted);
    margin-top: .2rem;
}

/* Team detail grid */
.team-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.quality-display { display: flex; flex-direction: column; gap: .75rem; }

.quality-score {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -.04em;
    line-height: 1;
}

.quality-bar-wrap { display: flex; flex-direction: column; gap: .3rem; }

.quality-bar-track {
    height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
}

.quality-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width .5s ease;
}

.quality-labels {
    display: flex;
    justify-content: space-between;
    font-size: .7rem;
    color: var(--text-muted);
}

.quality-desc {
    font-size: .85rem;
    color: var(--text-muted);
}

.team-info-rows { display: flex; flex-direction: column; gap: .6rem; }

.team-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: .875rem;
    padding-bottom: .6rem;
    border-bottom: 1px solid rgba(48,54,61,.5);
}
.team-info-row:last-child { border-bottom: none; padding-bottom: 0; }
.team-info-row > span  { color: var(--text-muted); }
.team-info-row > strong { color: var(--text); font-weight: 600; }

@media (max-width: 700px) {
    .team-detail-grid { grid-template-columns: 1fr; }
    .team-hero { flex-direction: column; align-items: flex-start; }
    .standings-table thead th,
    .standings-table tbody td { padding: .6rem .6rem; }
}

/* ============================================================
   Roster / Rosa giocatori
   ============================================================ */
.roster-group { margin-bottom: 2rem; }

.roster-group-title {
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--accent);
    margin-bottom: .6rem;
    padding-left: .25rem;
}

.roster-table-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.roster-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .8rem;
    white-space: nowrap;
}

.roster-table thead th {
    background: rgba(255,255,255,.03);
    padding: .55rem .7rem;
    text-align: center;
    font-size: .7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
}

.roster-table thead th.col-name { text-align: left; min-width: 160px; }
.roster-table thead th.col-pos  { min-width: 60px; }
.roster-table thead th.col-ovr  { color: var(--accent); }

.roster-table tbody td {
    padding: .6rem .7rem;
    text-align: center;
    border-bottom: 1px solid rgba(48,54,61,.4);
    color: var(--text);
    vertical-align: middle;
}

.roster-table tbody td.col-name { text-align: left; }
.roster-table tbody tr:last-child td { border-bottom: none; }
.roster-table tbody tr:hover td { background: rgba(255,255,255,.025); }

.player-name { font-weight: 600; color: var(--text); }

/* Ruolo tag */
.pos-tag {
    display: inline-block;
    padding: .15rem .45rem;
    border-radius: 4px;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .04em;
    background: rgba(255,255,255,.07);
    color: var(--text-muted);
}
.pos-por { background: rgba(255,167,38,.15); color: #ffa726; }
.pos-dc, .pos-ts, .pos-td { background: rgba(33,150,243,.15); color: #42a5f5; }
.pos-cdc, .pos-cc, .pos-coc { background: rgba(156,39,176,.15); color: #ce93d8; }
.pos-ala, .pos-trq, .pos-att { background: rgba(0,200,83,.15); color: var(--accent); }

/* Overall badge */
.ovr-badge {
    display: inline-block;
    min-width: 32px;
    padding: .2rem .4rem;
    border-radius: 5px;
    font-size: .8rem;
    font-weight: 800;
    text-align: center;
}
.ovr-gold   { background: rgba(255,215,0,.15);  color: #ffd700; }
.ovr-silver { background: rgba(192,192,192,.15); color: #c0c0c0; }
.ovr-bronze { background: rgba(205,127,50,.15);  color: #cd7f32; }

/* Attributi colorati */
.attr-cell { font-weight: 500; }
.attr-high { color: #00c853; }
.attr-mid  { color: var(--text); }
.attr-low  { color: #ff5252; }

/* ============================================================
   Saldo / Balance chip
   ============================================================ */
.balance-chip {
    display: flex;
    align-items: center;
    gap: .75rem;
    background: var(--bg-card);
    border: 1px solid rgba(0,200,83,.25);
    border-radius: var(--radius);
    padding: .75rem 1.25rem;
    flex-shrink: 0;
}
.balance-icon  { font-size: 1.5rem; }
.balance-label { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); }
.balance-amount { font-size: 1.2rem; font-weight: 800; color: var(--accent); letter-spacing: -.02em; }

/* ============================================================
   Staff — stato vuoto
   ============================================================ */
.empty-staff-card {
    background: var(--bg-card);
    border: 1px dashed var(--border);
    border-radius: var(--radius);
    padding: 3rem 2rem;
    text-align: center;
}
.empty-staff-icon { font-size: 3rem; display: block; margin-bottom: 1rem; opacity: .6; }
.empty-staff-card h3 { font-size: 1.2rem; font-weight: 700; color: var(--text); margin-bottom: .5rem; }
.empty-staff-card > p { color: var(--text-muted); font-size: .9rem; max-width: 500px; margin: 0 auto; }

.empty-staff-hints {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}
.hint-card {
    background: rgba(255,255,255,.03);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    text-align: center;
}
.hint-card > span   { font-size: 1.8rem; display: block; margin-bottom: .5rem; }
.hint-card > strong { display: block; font-size: .9rem; color: var(--text); margin-bottom: .35rem; }
.hint-card > p      { font-size: .78rem; color: var(--text-muted); line-height: 1.5; margin: 0; }

/* ============================================================
   Staff market — griglia cards
   ============================================================ */
.staff-market-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.staff-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: .5rem;
    transition: transform var(--transition), border-color var(--transition);
}
.staff-card:hover { transform: translateY(-3px); border-color: rgba(0,200,83,.3); }

.staff-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.staff-role-icon { font-size: 1.6rem; }

.staff-card-name   { font-size: .9rem; font-weight: 700; color: var(--text); }
.staff-card-role   { font-size: .75rem; color: var(--text-muted); font-weight: 500; }
.staff-card-salary { font-size: .85rem; font-weight: 600; color: var(--accent); margin-top: auto; padding-top: .5rem; border-top: 1px solid var(--border); }

.staff-hire-btn { width: 100%; margin-top: .25rem; }

.staff-card-block {
    font-size: .75rem;
    color: var(--text-muted);
    background: rgba(255,255,255,.04);
    border-radius: var(--radius-sm);
    padding: .35rem .6rem;
    text-align: center;
    margin-top: .25rem;
}

.staff-filters { padding: 1rem 1.25rem; }

@media (max-width: 600px) {
    .empty-staff-hints { grid-template-columns: 1fr; }
    .staff-market-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   Season badge & selector
   ============================================================ */
.season-badge {
    display: inline-block;
    background: rgba(0,200,83,.1);
    border: 1px solid rgba(0,200,83,.25);
    color: var(--accent);
    font-size: .75rem;
    font-weight: 700;
    padding: .2rem .6rem;
    border-radius: 100px;
}

.season-selector {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: 2rem;
}

.season-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: .5rem 1.1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-muted);
    font-size: .85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition);
    line-height: 1.3;
}
.season-tab:hover { border-color: var(--accent); color: var(--text); }
.season-tab.active {
    background: rgba(0,200,83,.1);
    border-color: var(--accent);
    color: var(--accent);
}
.season-tab-date { font-size: .7rem; font-weight: 400; color: var(--text-muted); }

.history-league-title {
    display: flex;
    align-items: center;
    gap: .6rem;
    font-size: .95rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: .6rem;
}

/* ── Giocatori / Assistiti ─────────────────────────────────── */

/* Badge ruolo (POR, ATT, CC …) */
.pos-badge {
    display: inline-block;
    padding: .15rem .45rem;
    border-radius: 4px;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    background: rgba(255,255,255,.06);
    color: var(--text-muted);
    border: 1px solid var(--border);
}

/* Link in tabelle */
.table-link {
    color: var(--text);
    text-decoration: none;
    transition: color var(--transition);
}
.table-link:hover { color: var(--accent); }

/* Nomi delle nazionali: il colore è inline (dipende dal prestige) e vince sul
   :hover di .table-link, quindi l'affordance di click è la sottolineatura. */
.nat-link:hover { text-decoration: underline; }

/* Link nella stat-card */
.stat-link {
    color: var(--accent);
    text-decoration: none;
    font-size: .78rem;
    transition: opacity var(--transition);
}
.stat-link:hover { opacity: .75; }

/* Riga attributi espandibile */
.attrs-row td { background: rgba(0,0,0,.2) !important; padding: .75rem 1rem !important; }
.attrs-grid {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}
.attr-chip {
    display: flex;
    align-items: center;
    gap: .3rem;
    padding: .2rem .5rem;
    border-radius: 4px;
    background: rgba(255,255,255,.04);
    border: 1px solid var(--border);
    font-size: .75rem;
}
.attr-label { color: var(--text-muted); font-weight: 600; letter-spacing: .04em; }
.attr-val   { font-weight: 700; }
.attr-high  { color: #00c853; }
.attr-mid   { color: var(--text); }
.attr-low   { color: #ef5350; }

/* Tabella clienti */
.clients-table .client-row:hover td { background: rgba(255,255,255,.025); }

/* ── Scouting ──────────────────────────────────────────────── */

/* Mappa del mondo */
.world-map-container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto 1.25rem;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border);
    cursor: crosshair;
    background: #0a1e2e;
}
#world-map { display: block; width: 100%; height: auto; }

/* Continente cliccabile */
.continent-zone {
    fill: #1b4332;
    stroke: #2d6a4f;
    stroke-width: 1;
    cursor: pointer;
    transition: fill 0.2s, stroke 0.2s;
}
.continent-zone.no-click {
    fill: #1b4332;
    stroke: #2d6a4f;
    stroke-width: .5;
    pointer-events: none;
    cursor: default;
}
.continent-zone:hover:not(.no-click) {
    fill: #2d6a4f;
    stroke: #52b788;
}
.continent-zone.selected {
    fill: #40916c !important;
    stroke: #00c853 !important;
    stroke-width: 2;
    filter: drop-shadow(0 0 6px rgba(0,200,83,0.4));
}

/* Label continente sull'SVG */
.continent-label {
    fill: rgba(255,255,255,0.45);
    font-size: 13px;
    font-family: system-ui, sans-serif;
    pointer-events: none;
    user-select: none;
}

/* Selezione osservatori */
.scout-cards-row {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    margin-top: .4rem;
}
.scout-pick-card {
    display: flex;
    align-items: center;
    cursor: pointer;
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: .6rem .9rem;
    background: var(--surface);
    transition: border-color .2s, background .2s;
    min-width: 150px;
}
.scout-pick-card:has(input:checked) {
    border-color: var(--accent);
    background: rgba(0,200,83,.07);
}
.scout-pick-card.scout-busy {
    opacity: .45;
    cursor: not-allowed;
}
.scout-pick-card input[type="radio"] { display: none; }
.scout-pick-inner {
    display: flex;
    flex-direction: column;
    gap: .3rem;
    width: 100%;
}
.scout-pick-name   { font-size: .85rem; font-weight: 600; color: var(--text); }
.scout-pick-status { font-size: .72rem; font-weight: 600; letter-spacing: .04em; }
.scout-pick-status.free { color: var(--accent); }
.scout-pick-status.busy { color: var(--text-muted); }

/* Mission cards */
.missions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.mission-card {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1rem 1.25rem;
    background: var(--surface);
}
.mission-active { border-left: 3px solid #f59e0b; }
.mission-done   { border-left: 3px solid var(--accent); }

.mission-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .5rem;
    margin-bottom: .75rem;
    flex-wrap: wrap;
}
.mission-continent {
    display: inline-block;
    font-weight: 700;
    font-size: .9rem;
    color: var(--text);
    margin-right: .4rem;
}
.mission-nation-reveal {
    font-size: .8rem;
    color: var(--accent);
    font-weight: 600;
    margin-right: .4rem;
}
.mission-role-tag {
    display: inline-block;
    padding: .1rem .45rem;
    border-radius: 4px;
    font-size: .72rem;
    font-weight: 600;
    background: rgba(255,255,255,.06);
    color: var(--text-muted);
    border: 1px solid var(--border);
}
.countdown-badge {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    padding: .2rem .6rem;
    border-radius: 20px;
    background: rgba(245,158,11,.15);
    color: #f59e0b;
    font-size: .78rem;
    font-weight: 700;
    white-space: nowrap;
}
.mission-scout-row {
    display: flex;
    align-items: center;
    gap: .6rem;
    font-size: .85rem;
    color: var(--text-muted);
}

/* Badge range OVR nei risultati */
.ovr-range-badge {
    display: inline-block;
    padding: .15rem .5rem;
    border-radius: 4px;
    font-size: .8rem;
    font-weight: 700;
    background: rgba(0,200,83,.1);
    color: var(--accent);
    border: 1px solid rgba(0,200,83,.25);
    letter-spacing: .04em;
}

@media (max-width: 640px) {
    .scout-cards-row      { flex-direction: column; }
    .scout-pick-card      { min-width: unset; width: 100%; }
    .missions-grid        { grid-template-columns: 1fr; }
    .continent-label      { font-size: 10px; }
}

/* ── Uffici / Proprietà ────────────────────────────────────── */

.offices-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    position: relative;
}

.office-card {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    background: var(--surface);
    position: relative;
    transition: border-color .2s;
}
.office-active {
    border-color: var(--accent);
    background: rgba(0,200,83,.04);
}
.office-past {
    opacity: .6;
}
.office-locked {
    opacity: .45;
}

.office-card-head {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: .75rem;
    flex-wrap: wrap;
}
.office-icon-wrap {
    font-size: 2rem;
    line-height: 1;
    flex-shrink: 0;
}
.office-icon-wrap.dimmed { filter: grayscale(1); }

.office-title-wrap { flex: 1; min-width: 0; }
.office-name  { font-size: 1rem; font-weight: 700; color: var(--text); }
.office-cost  { font-size: .82rem; font-weight: 600; color: var(--text-muted); margin-top: .15rem; }

.office-badge-wrap { flex-shrink: 0; }
.office-badge {
    display: inline-block;
    padding: .25rem .7rem;
    border-radius: 20px;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .04em;
}
.badge-active { background: rgba(0,200,83,.15);  color: var(--accent); border: 1px solid rgba(0,200,83,.3); }
.badge-past   { background: rgba(255,255,255,.06); color: var(--text-muted); border: 1px solid var(--border); }
.badge-locked { background: rgba(255,255,255,.04); color: var(--text-muted); border: 1px solid var(--border); }

.office-desc {
    font-size: .875rem;
    line-height: 1.6;
    margin: 0 0 1rem;
    color: var(--text);
}

.office-bonuses { margin-top: .5rem; }
.office-bonuses-label {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--text-muted);
    font-weight: 700;
    display: block;
    margin-bottom: .35rem;
}
.office-bonus-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}
.office-bonus-list li {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .2rem .65rem;
    border-radius: 20px;
    font-size: .8rem;
}
.bonus-active {
    background: rgba(0,200,83,.1);
    border: 1px solid rgba(0,200,83,.2);
    color: var(--text);
}
.bonus-locked {
    background: rgba(255,255,255,.04);
    border: 1px solid var(--border);
    color: var(--text-muted);
}

/* Connettore verticale tra livelli */
.office-connector {
    text-align: center;
    color: var(--border);
    font-size: 1.1rem;
    line-height: 1;
    padding: .4rem 0;
    user-select: none;
}

/* ── Calendari (world/calendars.php) ──────────────────────── */

/* Navigatore giornate */
.cal-nav-wrap {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: .75rem;
}

.cal-nav-info {
    display: flex;
    align-items: center;
    gap: .6rem;
}
.cal-nav-label {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--text-muted);
    font-weight: 700;
}
.cal-nav-current {
    font-size: 1rem;
    color: var(--accent);
}

.cal-round-scroll {
    display: flex;
    gap: .3rem;
    overflow-x: auto;
    padding-bottom: .25rem;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}
.cal-round-scroll::-webkit-scrollbar { height: 4px; }
.cal-round-scroll::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.cal-round-btn {
    position: relative;
    flex-shrink: 0;
    width: 40px;
    height: 50px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 2px;
    font-size: .82rem;
    font-weight: 700;
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text-muted);
    text-decoration: none;
    transition: border-color .15s, color .15s, background .15s, opacity .15s;
}
.cal-round-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}
/* ── Giornata attiva / selezionata ── */
.cal-round-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #0d1117;
    font-size: .88rem;
    box-shadow: 0 0 0 3px rgba(0,200,83,.2);
}
/* ── Giornata completata: sfondo verde tenue + testo accent ── */
.cal-round-btn.played {
    background: rgba(0,200,83,.1);
    border-color: rgba(0,200,83,.22);
    color: var(--accent);
}
.cal-round-btn.played:hover {
    background: rgba(0,200,83,.18);
    border-color: rgba(0,200,83,.4);
    opacity: 1;
}
/* ── Giornata futura: tratteggiata e dimmed ── */
.cal-round-btn.future {
    border-style: dashed;
    opacity: .38;
}

/* Tick ✓ sotto il numero per le giornate completate */
.crb-tick {
    display: block;
    font-size: .52rem;
    line-height: 1;
    height: .52rem; /* costante per tutti i bottoni → stessa altezza */
}
.cal-round-btn.played .crb-tick { color: var(--accent); }
.cal-round-btn.active .crb-tick { color: #0d1117; }

.cal-nav-arrows {
    display: flex;
    gap: .5rem;
}
.cal-arrow-btn {
    padding: .35rem .85rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 600;
    text-decoration: none;
    transition: border-color .15s, color .15s;
}
.cal-arrow-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* Intestazione giornata */
.cal-round-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: 1rem;
}
.cal-round-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
}
.cal-round-date {
    font-size: .85rem;
    color: var(--text-muted);
}

/* Lista partite */
.cal-matches-list {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}

.cal-match-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .75rem 1.25rem;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: .75rem;
    transition: border-color .15s;
}
.cal-match-card:hover { border-color: rgba(255,255,255,.2); }

.cal-match-card.cal-match-mine {
    border-color: rgba(0,200,83,.3);
    border-left: 4px solid var(--accent);
    background: rgba(0,200,83,.05);
}
/* Partita giocata: bordo sinistro discreto + nomi squadra attenuati */
.cal-match-card.cal-match-played {
    border-left-width: 3px;
    border-left-color: rgba(255,255,255,.1);
}
.cal-match-card.cal-match-played .cal-team-link {
    color: var(--text-muted);
}
/* Partita giocata E dei miei assistiti: mantieni il bordo verde forte */
.cal-match-card.cal-match-played.cal-match-mine {
    border-left: 4px solid rgba(0,200,83,.55);
}

.cal-match-team {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: .9rem;
    font-weight: 500;
}
.cal-match-home { justify-content: flex-end; text-align: right; }
.cal-match-away { justify-content: flex-start; text-align: left; }

.cal-team-link {
    color: var(--text);
    text-decoration: none;
    transition: color .15s;
}
.cal-team-link:hover { color: var(--accent); }

.cal-client-dot {
    color: var(--accent);
    font-size: .7rem;
    flex-shrink: 0;
}

.cal-match-score { text-align: center; min-width: 60px; }

.cal-score-badge {
    display: inline-block;
    padding: .28rem .8rem;
    background: rgba(0,200,83,.1);
    border: 1px solid rgba(0,200,83,.28);
    border-radius: 6px;
    font-size: .92rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: .06em;
    white-space: nowrap;
}
.cal-vs-badge {
    display: inline-block;
    padding: .15rem .45rem;
    font-size: .7rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: .1em;
    text-transform: uppercase;
    border: 1px solid var(--border);
    border-radius: 4px;
}

/* Vista compatta: tutte le giornate */
.cal-all-rounds-details { margin-top: 1.5rem; }
.cal-all-rounds-summary {
    cursor: pointer;
    font-size: .875rem;
    font-weight: 600;
    color: var(--text-muted);
    padding: .5rem 0;
    list-style: none;
    user-select: none;
}
.cal-all-rounds-summary::-webkit-details-marker { display: none; }
.cal-all-rounds-summary:hover { color: var(--accent); }

.cal-all-rounds {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.cal-compact-block {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}
.cal-compact-header {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .5rem .85rem;
    background: var(--bg-input);
    border-bottom: 1px solid var(--border);
}
.cal-compact-round {
    font-size: .72rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: .06em;
    text-transform: uppercase;
}
.cal-compact-date {
    font-size: .75rem;
    color: var(--text-muted);
}
.cal-compact-matches { padding: .35rem 0; }
.cal-compact-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: .4rem;
    padding: .3rem .85rem;
    font-size: .8rem;
    align-items: center;
    transition: background .1s;
}
.cal-compact-row:hover { background: rgba(255,255,255,.03); }
.cal-compact-row.mine {
    background: rgba(0,200,83,.06);
    border-left: 3px solid rgba(0,200,83,.45);
}
.cal-compact-home { text-align: right; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-compact-away { text-align: left;  color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-compact-sep  { text-align: center; color: var(--text-muted); font-weight: 700; font-size: .75rem; flex-shrink: 0; }
/* Risultato nella vista compatta — evidenziato in verde */
.cal-compact-sep.played { color: var(--accent); font-size: .78rem; }

@media (max-width: 640px) {
    .cal-match-card {
        grid-template-columns: 1fr;
        gap: .4rem;
        text-align: center;
    }
    .cal-match-home,
    .cal-match-away { justify-content: center; text-align: center; }
    .cal-match-score { order: -1; }
    .cal-all-rounds { grid-template-columns: 1fr; }
}

/* ── Scheda Giocatore (world/player.php) ───────────────────── */

.player-hero-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem 2rem;
    display: flex;
    align-items: center;
    gap: 1.75rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

/* Layout inner hero: avatar + info row */
.player-hero-main {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex: 1;
    min-width: 0;
    flex-wrap: wrap;
}

.player-hero-avatar,
.player-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-dark), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
    letter-spacing: -.02em;
}

.player-hero-info { flex: 1; min-width: 0; }

.player-hero-name {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.2;
    margin-bottom: .4rem;
}

.player-hero-meta {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
    font-size: .875rem;
    color: var(--text-muted);
    margin-bottom: .5rem;
}

.player-meta-chip {
    font-size: .82rem;
    color: var(--text-muted);
}

.player-hero-tags {
    display: flex;
    align-items: center;
    gap: .6rem;
    flex-wrap: wrap;
    font-size: .85rem;
}

.player-tag-link {
    color: var(--text-muted);
    text-decoration: none;
    padding: .2rem .55rem;
    border: 1px solid var(--border);
    border-radius: 20px;
    font-size: .8rem;
    transition: border-color .2s, color .2s;
}
.player-tag-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.player-hero-ovr {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .3rem;
    flex-shrink: 0;
}

.ovr-hero {
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
    padding: .5rem .9rem;
    border-radius: var(--radius-sm);
    letter-spacing: -.02em;
}

.ovr-hero-label {
    font-size: .7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--text-muted);
}

/* Utility */
.text-accent { color: var(--accent); font-weight: 600; }

/* Attrs bars container */
.attrs-bars { display: flex; flex-direction: column; gap: .1rem; }

/* Etichetta barra attributo: nome esteso (varia col ruolo, vedi #24) */
.attr-bar-label {
    width: 124px;
    font-size: .72rem;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
    letter-spacing: .02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Contract type badge (procuratore section) */
.contract-type-badge {
    display: inline-block;
    padding: .2rem .65rem;
    border-radius: 20px;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .03em;
}
.type-a {
    background: rgba(0,200,83,.12);
    color: var(--accent);
    border: 1px solid rgba(0,200,83,.25);
}
.type-b {
    background: rgba(255,152,0,.12);
    color: #ffa726;
    border: 1px solid rgba(255,152,0,.25);
}

/* Contract type banner */
.contract-type-banner {
    border-radius: var(--radius-sm);
    padding: .75rem 1rem;
    font-size: .875rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    border: 1px solid;
    display: flex;
    flex-direction: column;
    gap: .25rem;
}
.contract-type-banner strong { font-size: .95rem; }
.contract-type-banner span { font-weight: 400; color: var(--text-muted); font-size: .83rem; }
.type-a.contract-type-banner {
    background: rgba(0,200,83,.06);
    border-color: rgba(0,200,83,.3);
}
.type-b.contract-type-banner {
    background: rgba(255,152,0,.06);
    border-color: rgba(255,152,0,.3);
}

/* Player grid: left + right columns */
.player-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 1.25rem;
    align-items: start;
}
@media (max-width: 900px) {
    .player-grid { grid-template-columns: 1fr; }
}

.player-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.25rem;
}
.player-info-card:last-child { margin-bottom: 0; }

.player-info-card-title {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--text-muted);
    font-weight: 700;
    margin-bottom: 1rem;
    display: block;
}

.player-info-rows {}
.player-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .5rem 0;
    border-bottom: 1px solid var(--border);
    font-size: .875rem;
    gap: .5rem;
}
.player-info-row:last-child { border-bottom: none; }
.player-info-label { color: var(--text-muted); flex-shrink: 0; }
.player-info-value { font-weight: 600; text-align: right; }

/* Reputation badges */
.rep-badge {
    display: inline-block;
    padding: .2rem .6rem;
    border-radius: 20px;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .04em;
}
.rep-legend  { background: rgba(255,193,7,.18);  color: #ffd740; border: 1px solid rgba(255,193,7,.3); }
.rep-star    { background: rgba(156,39,176,.18); color: #e040fb; border: 1px solid rgba(156,39,176,.3); }
.rep-notable { background: rgba(33,150,243,.18); color: #40c4ff; border: 1px solid rgba(33,150,243,.3); }
.rep-known   { background: rgba(0,200,83,.15);   color: var(--accent); border: 1px solid rgba(0,200,83,.25); }
.rep-emerging{ background: rgba(255,152,0,.15);  color: #ffa726; border: 1px solid rgba(255,152,0,.25); }
.rep-unknown { background: rgba(255,255,255,.06); color: var(--text-muted); border: 1px solid var(--border); }

/* Attribute bars */
.attr-bar-row {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .35rem 0;
    font-size: .85rem;
}
.attr-bar-abbr {
    width: 32px;
    font-size: .72rem;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
    letter-spacing: .04em;
}
.attr-bar-track {
    flex: 1;
    height: 6px;
    background: var(--bg-input);
    border-radius: 3px;
    overflow: hidden;
}
.attr-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width .4s ease;
}
.attr-bar-val {
    width: 26px;
    text-align: right;
    font-weight: 700;
    font-size: .83rem;
    flex-shrink: 0;
}

/* Contract terms grid on player page */
.contract-type-banner {
    border-radius: var(--radius-sm);
    padding: .6rem 1rem;
    font-size: .82rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    border: 1px solid;
}
.contract-banner-a {
    background: rgba(0,200,83,.08);
    border-color: rgba(0,200,83,.3);
    color: var(--accent);
}
.contract-banner-b {
    background: rgba(255,152,0,.08);
    border-color: rgba(255,152,0,.3);
    color: #ffa726;
}

.contract-terms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: .75rem;
}
.contract-term-card {
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .85rem 1rem;
    display: flex;
    flex-direction: column;
    gap: .2rem;
}
.ct-icon  { font-size: 1.2rem; margin-bottom: .1rem; }
.ct-label { font-size: .7rem; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.ct-value { font-size: 1rem; font-weight: 700; color: var(--text); }
.ct-note  { font-size: .72rem; color: var(--text-muted); margin-top: .1rem; }

/* ── Pagina Firma (search/sign_player.php) ─────────────────── */

.sign-player-info {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
}
.sign-player-info-inner {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.sign-avatar-wrap { flex-shrink: 0; }
.sign-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-dark), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: -.02em;
}

.sign-player-details { flex: 1; min-width: 160px; }
.sign-player-name {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: .35rem;
}
.sign-player-meta {
    display: flex;
    align-items: center;
    gap: .6rem;
    flex-wrap: wrap;
    font-size: .85rem;
    color: var(--text-muted);
}

.sign-player-stats {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    align-items: center;
}
.sign-stat-item {
    display: flex;
    flex-direction: column;
    gap: .2rem;
    align-items: flex-end;
}
.sign-stat-label { font-size: .72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; }
.sign-stat-value { font-size: .9rem; font-weight: 700; color: var(--text); }

/* Options comparison grid */
.sign-options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}
@media (max-width: 768px) {
    .sign-options-grid { grid-template-columns: 1fr; }
}

.sign-option-card {
    background: var(--bg-card);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: border-color .2s;
}
.sign-option-a { border-color: rgba(0,200,83,.35); }
.sign-option-b { border-color: rgba(255,152,0,.35); }
.sign-option-a:hover { border-color: var(--accent); }
.sign-option-b:hover { border-color: #ffa726; }

.sign-option-header {
    display: flex;
    align-items: center;
    gap: .85rem;
}
.sign-option-badge {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.2rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.sign-badge-a { background: rgba(0,200,83,.2); color: var(--accent); }
.sign-badge-b { background: rgba(255,152,0,.2); color: #ffa726; }

.sign-option-title { font-size: 1rem; font-weight: 700; color: var(--text); }
.sign-option-sub   { font-size: .8rem; color: var(--text-muted); }

.sign-option-desc {
    font-size: .875rem;
    color: var(--text-muted);
    line-height: 1.55;
}

.sign-morale-pill {
    display: inline-block;
    padding: .3rem .8rem;
    border-radius: 20px;
    font-size: .8rem;
    font-weight: 700;
    align-self: flex-start;
}
.sign-morale-positive {
    background: rgba(0,200,83,.12);
    color: var(--accent);
    border: 1px solid rgba(0,200,83,.25);
}
.sign-morale-negative {
    background: rgba(239,83,80,.12);
    color: #ef5350;
    border: 1px solid rgba(239,83,80,.25);
}

.sign-terms-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: 1;
}
.sign-term-row {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .5rem 0;
    border-bottom: 1px solid var(--border);
    font-size: .85rem;
}
.sign-term-row:last-child { border-bottom: none; }
.sign-term-icon  { width: 20px; text-align: center; flex-shrink: 0; }
.sign-term-label { flex: 1; color: var(--text-muted); }
.sign-term-right { display: flex; flex-direction: column; align-items: flex-end; }
.sign-term-value { font-weight: 700; color: var(--text); font-size: .9rem; }
.sign-term-note  { font-size: .72rem; color: var(--text-muted); }

.sign-submit-form { margin-top: auto; padding-top: .5rem; }

.sign-btn-b {
    background: linear-gradient(135deg, #e65100, #ffa726);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
    transition: opacity .2s;
}
.sign-btn-b:hover { opacity: .88; }

/* ═══════════════════════════════════════════════════════════════
   CALENDAR — kickoff time, vs wrap, score link
   ═══════════════════════════════════════════════════════════════ */
.cal-kickoff-time {
    display: inline-block;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .03em;
    color: #e0a020;
    background: rgba(224,160,32,.1);
    border: 1px solid rgba(224,160,32,.25);
    padding: .1rem .4rem;
    border-radius: 4px;
}
.cal-vs-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .1rem;
}
.cal-score-link {
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--accent);
    letter-spacing: .04em;
    transition: opacity .15s;
}
.cal-score-link:hover { opacity: .75; }

/* ═══════════════════════════════════════════════════════════════
   SCORERS PAGE — two-column grid
   ═══════════════════════════════════════════════════════════════ */
.scorers-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: start;
}
@media (max-width: 900px) {
    .scorers-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════
   MATCH REPORT — tabellino
   ═══════════════════════════════════════════════════════════════ */

/* Header card */
.match-header-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem 2rem;
    margin-bottom: 1.5rem;
}
.match-meta {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .82rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}
.match-meta-sep { color: var(--border); }

/* Scoreboard */
.match-scoreboard {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1rem;
}
.match-team {
    display: flex;
    flex-direction: column;
    gap: .25rem;
}
.match-team-home { align-items: flex-end; text-align: right; }
.match-team-away { align-items: flex-start; text-align: left; }
.match-team-label {
    font-size: .7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .06em;
    font-weight: 600;
}
.match-team-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text);
    line-height: 1.1;
}
.match-score-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .2rem;
}
.match-score-main {
    display: flex;
    align-items: center;
    gap: .1rem;
}
.match-score-num {
    font-size: 2.5rem;
    font-weight: 900;
    line-height: 1;
    color: var(--text-muted);
}
.match-score-num.score-win  { color: var(--accent); }
.match-score-num.score-loss { color: #ef5350; }
.match-score-num.score-draw { color: var(--text-muted); }
.match-score-sep {
    font-size: 2rem;
    font-weight: 300;
    color: var(--border);
    margin: 0 .2rem;
    line-height: 1;
}
.match-score-label {
    font-size: .72rem;
    color: var(--text-muted);
    letter-spacing: .04em;
    font-weight: 600;
}
.match-score-vs {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-muted);
    line-height: 1;
}
.match-score-time {
    font-size: .85rem;
    color: var(--accent);
    font-weight: 700;
}

/* Events grid */
.match-events-grid {
    display: grid;
    grid-template-columns: 1fr 4px 1fr;
    gap: 0;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 1.5rem;
}
.match-events-col {
    padding: 1rem 1.25rem;
}
.match-events-divider {
    background: var(--border);
    align-self: stretch;
}
.match-events-header {
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: var(--text-muted);
    padding-bottom: .6rem;
    margin-bottom: .6rem;
    border-bottom: 1px solid var(--border);
}
.match-event-row {
    display: flex;
    align-items: flex-start;
    gap: .45rem;
    padding: .25rem 0;
    font-size: .85rem;
    line-height: 1.3;
}
.match-event-row-home { justify-content: flex-start; }
.match-event-row-away { justify-content: flex-start; }
.match-events-empty {
    color: var(--text-muted);
    font-size: .82rem;
    font-style: italic;
    padding: .5rem 0;
}
.ev-min {
    font-size: .72rem;
    color: var(--text-muted);
    min-width: 28px;
    padding-top: .1rem;
    flex-shrink: 0;
}
.ev-assist {
    font-size: .78rem;
    color: var(--text-muted);
    display: block;
    margin-top: .05rem;
}
.ev-tag {
    font-size: .68rem;
    background: rgba(255,255,255,.07);
    border-radius: 3px;
    padding: .05rem .28rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-left: .2rem;
    vertical-align: middle;
}
.ev-og  { color: #ef5350; font-weight: 700; }
.ev-red-note { color: #ef5350; font-size: .75rem; }
.ev-inj { color: #ffa726; font-size: .78rem; }

/* Ratings tables */
.match-ratings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}
@media (max-width: 800px) {
    .match-ratings-grid { grid-template-columns: 1fr; }
}
.match-ratings-team {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.match-ratings-header {
    padding: .75rem 1rem;
    font-weight: 700;
    font-size: .9rem;
    background: rgba(255,255,255,.03);
    border-bottom: 1px solid var(--border);
}
.match-ratings-table {
    width: 100%;
    border-collapse: collapse;
}
.match-ratings-table th {
    padding: .45rem .75rem;
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
.match-ratings-table td {
    padding: .45rem .75rem;
    font-size: .85rem;
    border-bottom: 1px solid rgba(255,255,255,.04);
}
.match-ratings-table tr:last-child td { border-bottom: none; }
.match-rating-icons {
    font-size: .75rem;
    display: flex;
    gap: .15rem;
    flex-wrap: wrap;
}

/* Rating badge (shared — scorers + match report) */
.rating-badge {
    display: inline-block;
    min-width: 36px;
    text-align: center;
    padding: .2rem .45rem;
    border-radius: 5px;
    font-size: .82rem;
    font-weight: 800;
    line-height: 1;
}

/* Match nav links */
.match-nav-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    gap: .5rem;
    flex-wrap: wrap;
}
.match-nav-link {
    font-size: .82rem;
    color: var(--text-muted);
    text-decoration: none;
    padding: .3rem .6rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: border-color .15s, color .15s;
}
.match-nav-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.match-nav-center {
    font-size: .8rem;
    color: var(--text-muted);
    text-align: center;
}

/* Responsive match scoreboard */
@media (max-width: 640px) {
    .match-scoreboard {
        grid-template-columns: 1fr auto 1fr;
        gap: .5rem;
    }
    .match-team-name { font-size: .95rem; }
    .match-score-num { font-size: 1.8rem; }
    .match-events-grid { grid-template-columns: 1fr; }
    .match-events-divider { display: none; }
}

/* ═══════════════════════════════════════════════════════════════
   PLAYER STATUS BADGE
   ═══════════════════════════════════════════════════════════════ */
.player-status-badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .75rem;
    font-weight: 700;
    padding: .25rem .6rem;
    border-radius: 20px;
    letter-spacing: .02em;
}
.status-available  { background: rgba(0,200,83,.12);  color: #00c853; border: 1px solid rgba(0,200,83,.25); }
.status-suspended  { background: rgba(239,83,80,.12); color: #ef5350; border: 1px solid rgba(239,83,80,.25); }
.status-injured    { background: rgba(255,167,38,.12);color: #ffa726; border: 1px solid rgba(255,167,38,.25); }

/* ═══════════════════════════════════════════════════════════════
   PLAYER SEASON HISTORY TABLE
   ═══════════════════════════════════════════════════════════════ */
.player-history-table th,
.player-history-table td {
    white-space: nowrap;
}
.player-history-current td {
    background: rgba(0,200,83,.04);
}
.player-hist-season {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    font-weight: 600;
    font-size: .88rem;
}
.hist-season-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    flex-shrink: 0;
    display: inline-block;
}

/* Scout prospect tag */
.scout-prospect-tag {
    display: inline-block;
    font-size: .65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    padding: .1rem .35rem;
    border-radius: 3px;
    background: rgba(255,167,38,.15);
    color: #ffa726;
    border: 1px solid rgba(255,167,38,.3);
    margin-left: .35rem;
    vertical-align: middle;
}

/* Scout potential badge */
.scout-pot-badge {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    padding: .18rem .5rem;
    border-radius: 4px;
    white-space: nowrap;
}
.pot-low   { background: rgba(255,255,255,.06); color: var(--text-muted); }
.pot-mid   { background: rgba(33,150,243,.15);  color: #64b5f6; }
.pot-high  { background: rgba(255,152,0,.15);   color: #ffa726; }

/* ═══════════════════════════════════════════════════════════════
   TUTORIAL
   ═══════════════════════════════════════════════════════════════ */

.tut-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 1rem 4rem;
    min-height: calc(100vh - 64px);
}

.tut-back {
    font-size: .8rem;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 1.5rem;
    align-self: flex-start;
    width: 100%;
    max-width: 680px;
    transition: color var(--transition);
}
.tut-back:hover { color: var(--text); }

/* Card contenitore */
.tut-card {
    width: 100%;
    max-width: 680px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: var(--shadow);
}

/* Barra progresso */
.tut-progress-wrap {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin-bottom: 2rem;
}
.tut-progress-bar {
    flex: 1;
    height: 4px;
    background: rgba(255,255,255,.07);
    border-radius: 2px;
    overflow: hidden;
}
.tut-progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 2px;
    transition: width .4s ease;
}
.tut-progress-label {
    font-size: .72rem;
    color: var(--text-muted);
    white-space: nowrap;
    font-weight: 600;
}

/* Dot di navigazione */
.tut-dots {
    display: flex;
    justify-content: center;
    gap: .45rem;
    margin-bottom: 2rem;
}
.tut-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,.12);
    cursor: pointer;
    transition: background .2s, transform .2s;
}
.tut-dot.active { background: var(--accent); transform: scale(1.35); }
.tut-dot.done   { background: rgba(0,200,83,.4); }

/* Step */
.tut-step        { display: none; }
.tut-step.active { display: block; }

.tut-step-icon {
    font-size: 2.8rem;
    margin-bottom: .75rem;
    display: block;
}
.tut-step-title {
    font-size: 1.45rem;
    font-weight: 800;
    margin: 0 0 1.25rem;
    line-height: 1.2;
    color: var(--text);
}

/* Body testo */
.tut-step-body p {
    color: var(--text-muted);
    font-size: .925rem;
    line-height: 1.7;
    margin: 0 0 .9rem;
}
.tut-step-body p strong { color: var(--text); }
.tut-step-body em       { color: var(--accent); font-style: normal; }

/* Tip box */
.tut-tip {
    background: rgba(0,200,83,.06);
    border: 1px solid rgba(0,200,83,.2);
    border-radius: var(--radius-sm);
    padding: .75rem 1rem;
    font-size: .85rem;
    color: var(--text-muted);
    margin-top: .9rem;
    line-height: 1.6;
}
.tut-tip strong { color: var(--accent); }

/* Grid highlight (2 colonne) */
.tut-highlight-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .75rem;
    margin: .9rem 0;
}
.tut-highlight {
    background: rgba(255,255,255,.03);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .85rem 1rem;
    display: flex;
    gap: .75rem;
    align-items: flex-start;
}
.tut-highlight > span { font-size: 1.4rem; flex-shrink: 0; }
.tut-highlight > div {
    font-size: .82rem;
    line-height: 1.55;
    color: var(--text-muted);
}
.tut-highlight > div strong {
    color: var(--text);
    display: block;
    margin-bottom: .2rem;
}

/* Lista ruoli staff */
.tut-role-list  { display: flex; flex-direction: column; gap: .75rem; margin: .5rem 0 0; }
.tut-role {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: rgba(255,255,255,.02);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .9rem 1rem;
}
.tut-role-icon {
    font-size: 1.4rem;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    background: rgba(0,200,83,.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.tut-role strong { font-size: .9rem; display: block; margin-bottom: .2rem; color: var(--text); }
.tut-role p      { font-size: .8rem; color: var(--text-muted); margin: 0; line-height: 1.55; }

/* Lista proprietà */
.tut-property-list { display: flex; flex-direction: column; gap: .65rem; margin: .75rem 0; }
.tut-property {
    display: flex;
    gap: .85rem;
    align-items: flex-start;
    background: rgba(255,255,255,.02);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .85rem 1rem;
}
.tut-property > span { font-size: 1.6rem; flex-shrink: 0; }
.tut-property > div  { font-size: .83rem; line-height: 1.55; }
.tut-property > div strong { display: block; margin-bottom: .15rem; color: var(--text); }
.tut-property > div p      { color: var(--text-muted); margin: 0; }

/* Tiers reputazione */
.tut-rep-tiers { display: flex; flex-direction: column; gap: .5rem; margin: .75rem 0; }
.tut-rep-tier {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .6rem .9rem;
    border-left: 3px solid;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    background: rgba(255,255,255,.02);
    font-size: .85rem;
}
.tut-rep-tier span   { font-size: 1rem; }
.tut-rep-tier p      { margin: 0; color: var(--text-muted); font-size: .78rem; margin-left: auto; text-align: right; }

/* Checklist finale */
.tut-checklist { display: flex; flex-direction: column; gap: .75rem; }
.tut-check-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: rgba(255,255,255,.02);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .85rem 1rem;
}
.tut-check-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent);
    color: #000;
    font-weight: 800;
    font-size: .85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.tut-check-item strong { font-size: .9rem; display: block; margin-bottom: .15rem; color: var(--text); }
.tut-check-item p      { font-size: .8rem; color: var(--text-muted); margin: 0; line-height: 1.5; }

/* Navigazione */
.tut-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 2rem;
    gap: 1rem;
}
.tut-btn-prev {
    padding: .6rem 1.4rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: .9rem;
    cursor: pointer;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-muted);
    font-family: inherit;
    transition: all var(--transition);
}
.tut-btn-prev:hover { background: rgba(255,255,255,.05); color: var(--text); }

.tut-btn-next,
.tut-btn-complete {
    padding: .6rem 1.6rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: .9rem;
    cursor: pointer;
    border: none;
    font-family: inherit;
    margin-left: auto;
    transition: all var(--transition);
}
.tut-btn-next {
    background: var(--accent);
    color: #000;
}
.tut-btn-next:hover { background: var(--accent-dark); box-shadow: 0 4px 20px var(--accent-glow); }

.tut-btn-complete {
    background: var(--accent);
    color: #000;
}
.tut-btn-complete:hover { background: var(--accent-dark); box-shadow: 0 4px 20px var(--accent-glow); }

/* Skip */
.tut-skip-wrap {
    text-align: center;
    margin-top: 1.25rem;
}
.tut-skip-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: .8rem;
    cursor: pointer;
    font-family: inherit;
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color var(--transition);
}
.tut-skip-btn:hover { color: var(--text); }

/* Mobile */
@media (max-width: 600px) {
    .tut-card          { padding: 1.75rem 1.25rem 1.5rem; }
    .tut-highlight-grid { grid-template-columns: 1fr; }
    .tut-rep-tier p     { display: none; }
    .tut-step-title     { font-size: 1.15rem; }
}

/* ═══════════════════════════════════════════════════════════════
   CLUB OFFERS — Offerte in entrata con countdown
   ═══════════════════════════════════════════════════════════════ */

/* Card offerta */
.co-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 1.25rem;
    overflow: hidden;
    transition: border-color var(--transition), box-shadow var(--transition);
}
.co-card--normal   { border-left: 4px solid var(--border); }
.co-card--warning  { border-left: 4px solid var(--warning); }
.co-card--critical { border-left: 4px solid var(--error);
                     box-shadow: 0 0 0 1px rgba(255,82,82,.15),
                                 0 4px 24px rgba(255,82,82,.12); }
.co-card--expired  { opacity: .55; pointer-events: none; }

/* Urgency banner */
.co-urgency-banner {
    padding: .45rem 1.25rem;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .04em;
    background: rgba(255,82,82,.12);
    color: var(--error);
    border-bottom: 1px solid rgba(255,82,82,.2);
}
.co-urgency-banner--warn {
    background: rgba(255,167,38,.1);
    color: var(--warning);
    border-bottom-color: rgba(255,167,38,.2);
}

/* Body principale */
.co-body {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 1.5rem;
    flex-wrap: wrap;
}

/* Club */
.co-club {
    display: flex;
    align-items: center;
    gap: .75rem;
    min-width: 160px;
    flex: 1;
}
.co-club-icon {
    font-size: 1.8rem;
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,.04);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.co-club-name { font-weight: 700; font-size: .95rem; }
.co-club-meta { font-size: .75rem; color: var(--text-muted); margin-top: .1rem; }

/* Freccia divisore */
.co-divider {
    font-size: 1.4rem;
    color: var(--text-muted);
    flex-shrink: 0;
}

/* Giocatore */
.co-player {
    display: flex;
    align-items: center;
    gap: .75rem;
    min-width: 160px;
    flex: 1;
}
.co-player-ovr {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: rgba(0,200,83,.12);
    border: 1px solid rgba(0,200,83,.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1rem;
    color: var(--accent);
    flex-shrink: 0;
}
.co-player-name { font-weight: 700; font-size: .95rem; }
.co-player-meta { font-size: .75rem; color: var(--text-muted); margin-top: .1rem; }

/* Numeri (fee + countdown) */
.co-numbers {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-shrink: 0;
}

/* Fee */
.co-fee { text-align: center; }
.co-fee-label  { font-size: .68rem; text-transform: uppercase; letter-spacing: .06em;
                 color: var(--text-muted); font-weight: 600; margin-bottom: .15rem; }
.co-fee-amount { font-size: 1.3rem; font-weight: 800; color: var(--accent); }

/* Countdown */
.co-countdown { text-align: center; }
.co-countdown-label {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: .15rem;
}
.co-countdown-timer {
    font-size: 1.3rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    letter-spacing: .04em;
    color: var(--text);
}
.co-countdown--warning  .co-countdown-timer { color: var(--warning); }
.co-countdown--critical .co-countdown-timer {
    color: var(--error);
    animation: co-pulse 1.2s ease-in-out infinite;
}
@keyframes co-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: .55; }
}

/* Azioni */
.co-actions {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .9rem 1.5rem;
    border-top: 1px solid var(--border);
    background: rgba(255,255,255,.015);
    flex-wrap: wrap;
}
.co-btn-accept { width: auto; font-size: .88rem; padding: .5rem 1.2rem; }
.co-btn-reject {
    width: auto;
    font-size: .88rem;
    padding: .5rem 1rem;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
}
.co-btn-reject:hover { border-color: var(--error); color: var(--error);
                       background: rgba(255,82,82,.08); }
.co-btn-counter {
    width: auto;
    font-size: .88rem;
    padding: .5rem 1rem;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    margin-left: auto;
}
.co-btn-counter:hover { border-color: var(--warning); color: var(--warning);
                        background: rgba(255,167,38,.08); }

/* Pannello contro-offerta */
.co-counter-panel {
    padding: 1rem 1.5rem 1.25rem;
    border-top: 1px solid var(--border);
    background: rgba(255,255,255,.02);
}

/* Widget dashboard */
.co-dashboard-widget {
    background: rgba(255,82,82,.06);
    border: 1px solid rgba(255,82,82,.25);
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 2rem;
}
.co-dashboard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .75rem 1.25rem;
    background: rgba(255,82,82,.08);
    border-bottom: 1px solid rgba(255,82,82,.2);
    font-weight: 700;
    font-size: .9rem;
    color: var(--error);
    flex-wrap: wrap;
    gap: .5rem;
}
.co-dashboard-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .75rem 1.25rem;
    border-bottom: 1px solid rgba(255,82,82,.1);
    flex-wrap: wrap;
}
.co-dashboard-item:last-child { border-bottom: none; }
.co-dash-player  { font-weight: 700; font-size: .88rem; flex: 1; min-width: 120px; }
.co-dash-team    { font-size: .82rem; color: var(--text-muted); flex: 1; min-width: 100px; }
.co-dash-fee     { font-weight: 700; font-size: .9rem; color: var(--accent); min-width: 90px; text-align: right; }
.co-dash-timer   {
    font-weight: 800;
    font-size: .9rem;
    font-variant-numeric: tabular-nums;
    min-width: 80px;
    text-align: right;
}

/* Navbar badge offerte */
.co-nav-badge {
    position: absolute;
    top: 2px; right: -2px;
    min-width: 16px; height: 16px;
    background: var(--error);
    color: #fff;
    border-radius: 50%;
    font-size: .6rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    line-height: 1;
}

@media (max-width: 640px) {
    .co-body    { flex-direction: column; align-items: flex-start; gap: 1rem; }
    .co-divider { display: none; }
    .co-numbers { width: 100%; justify-content: space-between; }
}
.pot-elite { background: rgba(255,193,7,.18);   color: #ffd54f; border: 1px solid rgba(255,193,7,.35); }

/* ============================================================
   PLAYER MOOD / DISCONTENT
   ============================================================ */

/* Flash */
.mood-flash {
    padding: .85rem 1.2rem;
    border-radius: var(--radius);
    font-weight: 500;
    font-size: .9rem;
    margin-bottom: 1.25rem;
}
.mood-flash--success { background: var(--success-bg); border: 1px solid rgba(0,200,83,.3); color: var(--accent); }
.mood-flash--error   { background: var(--error-bg);   border: 1px solid rgba(255,82,82,.3); color: var(--error); }

/* Sommario chips */
.mood-summary {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: 1.5rem;
}
.mood-summary-chip {
    padding: .35rem .85rem;
    border-radius: 20px;
    font-size: .8rem;
    font-weight: 600;
    border: 1px solid;
}
.mood-summary-chip--request { background: rgba(255,82,82,.15);  border-color: rgba(255,82,82,.4);  color: #ff5252; }
.mood-summary-chip--crisis  { background: rgba(229,57,53,.12);  border-color: rgba(229,57,53,.35); color: #ef5350; }
.mood-summary-chip--low     { background: rgba(255,167,38,.12); border-color: rgba(255,167,38,.3); color: #ffa726; }
.mood-summary-chip--ok      { background: rgba(0,200,83,.10);   border-color: rgba(0,200,83,.25);  color: var(--accent); }

/* Lista */
.mood-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Card base */
.mood-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    transition: border-color var(--transition);
}
.mood-card--low     { border-color: rgba(255,167,38,.4); }
.mood-card--crisis  { border-color: rgba(229,57,53,.5); }
.mood-card--request {
    border-color: rgba(255,82,82,.7);
    animation: mood-pulse 2s ease-in-out infinite;
}

@keyframes mood-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255,82,82,0); }
    50%       { box-shadow: 0 0 0 6px rgba(255,82,82,.15); }
}

/* Header card */
.mood-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}
.mood-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: .85rem;
    flex-shrink: 0;
    letter-spacing: -.01em;
}
.mood-card-info { flex: 1; min-width: 0; }
.mood-player-name {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.mood-player-meta {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .8rem;
    margin-top: .15rem;
    flex-wrap: wrap;
}
.mood-state-emoji {
    font-size: 1.7rem;
    flex-shrink: 0;
    line-height: 1;
}

/* Barra morale */
.mood-bar-section { margin-bottom: .85rem; }
.mood-bar {
    height: 7px;
    background: rgba(255,255,255,.07);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: .4rem;
}
.mood-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width .6s ease;
}
.mood-bar-labels {
    display: flex;
    justify-content: space-between;
    font-size: .78rem;
}

/* Alert banner interno alla card */
.mood-alert {
    display: flex;
    align-items: flex-start;
    gap: .65rem;
    padding: .7rem .9rem;
    border-radius: var(--radius-sm);
    font-size: .83rem;
    margin-bottom: .85rem;
    line-height: 1.45;
}
.mood-alert span:first-child { font-size: 1rem; flex-shrink: 0; margin-top: .05rem; }
.mood-alert--request { background: rgba(255,82,82,.12);  border: 1px solid rgba(255,82,82,.3);  color: var(--text); }
.mood-alert--promise { background: rgba(0,188,212,.1);   border: 1px solid rgba(0,188,212,.3);  color: var(--text); }
.mood-alert--crisis  { background: rgba(229,57,53,.10);  border: 1px solid rgba(229,57,53,.3);  color: var(--text); }
.mood-alert--low     { background: rgba(255,167,38,.10); border: 1px solid rgba(255,167,38,.25);color: var(--text); }

/* Azioni */
.mood-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .65rem;
    padding-top: .85rem;
    border-top: 1px solid var(--border);
}
.mood-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .15rem;
    padding: .55rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-input);
    color: var(--text);
    font-size: .87rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition);
    line-height: 1.2;
    min-width: 120px;
}
.mood-btn:hover:not([disabled]) { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.2); }
.mood-btn-sub { font-size: .72rem; font-weight: 400; color: var(--text-muted); }
.mood-btn--meeting { border-color: rgba(0,200,83,.35); }
.mood-btn--meeting:hover:not([disabled]) { border-color: var(--accent); background: rgba(0,200,83,.08); }
.mood-btn--gift    { border-color: rgba(255,167,38,.35); }
.mood-btn--gift:hover:not([disabled]) { border-color: var(--warning); background: rgba(255,167,38,.08); }
.mood-btn--promise { border-color: rgba(255,82,82,.35); }
.mood-btn--promise:hover:not([disabled]) { border-color: var(--error); background: rgba(255,82,82,.08); }
.mood-btn--disabled, .mood-btn[disabled] { opacity: .4; cursor: not-allowed; }

/* Dashboard widget scontento */
.mood-dashboard-widget {
    background: rgba(255,82,82,.07);
    border: 1px solid rgba(255,82,82,.3);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
}
.mood-dashboard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    font-size: .92rem;
    color: var(--error);
    margin-bottom: .65rem;
    gap: 1rem;
    flex-wrap: wrap;
}
.mood-dashboard-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    padding: .45rem 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
    font-size: .85rem;
    flex-wrap: wrap;
}
.mood-dashboard-row:last-child { border-bottom: none; }
.mood-nav-badge {
    position: absolute;
    top: 2px;
    right: -4px;
    background: var(--error);
    color: #fff;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    font-size: .6rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

@media (max-width: 600px) {
    .mood-actions { flex-direction: column; }
    .mood-btn { min-width: 0; width: 100%; flex-direction: row; justify-content: space-between; }
}

@keyframes nav-mood-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: .6; }
}


/* ── LAST MATCHES WIDGET (dashboard) ──────────────────────────── */
.lm-widget-body {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    max-height: 400px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}
.lm-widget-body::-webkit-scrollbar       { width: 5px; }
.lm-widget-body::-webkit-scrollbar-track { background: transparent; }
.lm-widget-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

.lm-row {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .7rem 1rem;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    color: var(--text);
    transition: background .15s;
    flex-wrap: wrap;
}
.lm-row:last-child   { border-bottom: none; }
.lm-row:hover        { background: rgba(255,255,255,.04); }

/* Colonna giocatore */
.lm-player {
    display: flex;
    align-items: center;
    gap: .45rem;
    min-width: 0;
    flex: 1 1 160px;
}
.lm-name {
    font-size: .85rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

/* Colonna partita */
.lm-match {
    display: flex;
    align-items: center;
    gap: .4rem;
    flex: 2 1 220px;
    font-size: .8rem;
    flex-wrap: nowrap;
    min-width: 0;
}
.lm-team {
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90px;
    font-size: .78rem;
}
.lm-team-mine  { color: var(--text); font-weight: 700; }
.lm-score      { font-size: .88rem; font-weight: 700; white-space: nowrap; }
.lm-round      { font-size: .7rem; color: var(--text-muted); white-space: nowrap; margin-left: .2rem; }

/* Colonna stats + voto */
.lm-stats {
    display: flex;
    align-items: center;
    gap: .3rem;
    flex-shrink: 0;
    flex-wrap: wrap;
    justify-content: flex-end;
    min-width: 80px;
}
.lm-stat {
    font-size: .82rem;
    line-height: 1;
    white-space: nowrap;
}
.lm-stat-bad { color: var(--error); font-size: .72rem; font-weight: 700; }
.lm-rating {
    font-size: .8rem;
    font-weight: 800;
    border: 1.5px solid;
    border-radius: 5px;
    padding: .1rem .3rem;
    min-width: 2rem;
    text-align: center;
    line-height: 1.4;
    white-space: nowrap;
}

@media (max-width: 600px) {
    .lm-row    { gap: .5rem; padding: .65rem .75rem; }
    .lm-team   { max-width: 60px; }
    .lm-match  { flex: 1 1 180px; }
    .lm-stats  { min-width: 60px; }
}
