/* ── MANUALE GESTIONALE ATA ─────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: sans-serif;
    background: #f4f7f6;
    color: #333;
    min-height: 100vh;
}

.man-disclaimer,
.man-section {
    scroll-margin-top: 16px;
}

/* ── HEADER ── */
.man-header {
    background: linear-gradient(135deg, #1a237e, #283593);
    color: #fff;
    padding: 18px 32px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,.3);
}
.man-header h1 { font-size: 1.3em; font-weight: 800; letter-spacing: .5px; }
.man-header .ver { background: #ff6f00; color: #fff; font-size: .72em; padding: 2px 9px; border-radius: 12px; font-weight: bold; }
.man-header a.back,
.man-header button.back {
    margin-left: auto;
    background: rgba(255,255,255,.15);
    color: #fff;
    text-decoration: none;
    padding: 7px 16px;
    border-radius: 6px;
    font-size: .88em;
    font-weight: bold;
    border: 1px solid rgba(255,255,255,.3);
    cursor: pointer;
    font-family: inherit;
}
.man-header a.back:hover,
.man-header button.back:hover { background: rgba(255,255,255,.25); }

/* ── LAYOUT ── */
.man-layout {
    display: flex;
    max-width: 1100px;
    margin: 24px auto;
    gap: 24px;
    padding: 0 16px;
}

/* ── SIDEBAR ── */
.man-sidebar {
    width: 230px;
    flex-shrink: 0;
}
.man-sidebar-box {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    padding: 16px;
    position: sticky;
    top: 20px;
}
.man-sidebar-box h3 {
    font-size: .78em;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #888;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}
.man-sidebar-box a {
    display: block;
    padding: 7px 10px;
    border-radius: 6px;
    text-decoration: none;
    color: #333;
    font-size: .88em;
    margin-bottom: 2px;
    transition: background .15s;
}
.man-sidebar-box a:hover { background: #e8eaf6; color: #1a237e; }
.man-sidebar-box a.active { background: #1a237e; color: #fff; font-weight: bold; }
.man-sidebar-box a.wip { color: #aaa; }
.man-sidebar-box a.wip::after { content: ' 🚧'; font-size: .8em; }

/* ── CONTENUTO ── */
.man-content { flex: 1; min-width: 0; }

/* Disclaimer */
.man-disclaimer {
    background: #fff8e1;
    border: 1px solid #ffe082;
    border-left: 4px solid #ff6f00;
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 24px;
    font-size: .9em;
    line-height: 1.7;
}
.man-disclaimer h2 {
    font-size: 1em;
    color: #e65100;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.man-disclaimer ul { padding-left: 18px; }
.man-disclaimer li { margin-bottom: 5px; }

/* Sezioni */
.man-section {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,.07);
    margin-bottom: 20px;
    overflow: hidden;
}
.man-section-header {
    background: linear-gradient(135deg, #1a237e, #283593);
    color: #fff;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}
.man-section-header:hover { background: linear-gradient(135deg, #283593, #303f9f); }
.man-section-header.open { background: linear-gradient(135deg, #283593, #303f9f); }
.man-section-header .num {
    background: rgba(255,255,255,.2);
    width: 28px; height: 28px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: bold; font-size: .9em;
    flex-shrink: 0;
}
.man-section-header h2 { font-size: 1em; font-weight: 700; }
.man-section-header .chevron { margin-left: auto; transition: transform .25s; font-size: .9em; }
.man-section-header.open .chevron { transform: rotate(180deg); }
.man-section-header .badge-wip {
    background: #ff6f00;
    color: #fff;
    font-size: .7em;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 8px;
}

.man-section-body {
    padding: 20px 24px;
    display: none;
    line-height: 1.75;
    font-size: .93em;
}
.man-section-body.open { display: block; }

/* Elementi nel corpo */
.man-section-body p { margin-bottom: 12px; }
.man-section-body ul { padding-left: 20px; margin-bottom: 12px; }
.man-section-body li { margin-bottom: 6px; }
.man-section-body strong { color: #1a237e; }
.man-section-body .attenzione {
    background: #ffebee;
    border-left: 4px solid #e53935;
    padding: 10px 14px;
    border-radius: 0 6px 6px 0;
    margin: 14px 0;
    font-size: .9em;
}
.man-section-body .nota {
    background: #e3f2fd;
    border-left: 4px solid #1565c0;
    padding: 10px 14px;
    border-radius: 0 6px 6px 0;
    margin: 14px 0;
    font-size: .9em;
}
.man-section-body .consiglio {
    background: #e8f5e9;
    border-left: 4px solid #2e7d32;
    padding: 10px 14px;
    border-radius: 0 6px 6px 0;
    margin: 14px 0;
    font-size: .9em;
}
.man-section-body .step {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 10px;
}
.man-section-body .step-num {
    background: #1a237e;
    color: #fff;
    width: 24px; height: 24px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: .78em; font-weight: bold;
    flex-shrink: 0;
    margin-top: 2px;
}
.man-btn-fake {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 5px;
    font-size: .85em;
    font-weight: bold;
    vertical-align: middle;
}
.man-btn-green { background: #2e7d32; color: #fff; }
.man-btn-blue  { background: #1a237e; color: #fff; }
.man-btn-red   { background: #c62828; color: #fff; }
.man-btn-gray  { background: #546e7a; color: #fff; }
.man-btn-orange{ background: #e65100; color: #fff; }

/* Footer */
.man-footer {
    text-align: center;
    padding: 24px;
    font-size: .82em;
    color: #aaa;
}

/* Responsive */
@media (max-width: 700px) {
    .man-layout { flex-direction: column; }
    .man-sidebar { width: 100%; }
    .man-sidebar-box { position: static; }
}
