/* ============================================================
   stile-home-questionari-limiti.css
   Home page dei questionari sui limiti (v3): questionario sulla
   definizione di limite e questionario sui limiti con forme
   indeterminate. Identico a
   stile-home-questionari-successioni-progressioni.css (stesso
   header/breadcrumb/nav/footer, stesse card di scelta modalità),
   con due sezioni, ciascuna con una coppia di card (standard/DSA),
   non avendo una versione con timer per i questionari.
   ============================================================ */

:root {
    --green: #009966;
    --green-dk: #00754d;
    --green-lt: #e6f5ee;
    --orange: #ff9800;
    --orange-dk: #e68a00;
    --border: #e0e0e0;
    --muted: #777;
    --radius: 8px;
}

* {
    box-sizing: border-box;
}

html {
    overflow-y: scroll;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 10px;
    background-color: #f8f9fa;
    color: #2c3e50;
}

.page-wrap {
    max-width: 1000px;
    margin: 0 auto;
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    padding: 20px;
}

h1, h2, h3 { text-align: center; }

/* ---------- Header v3 (dashed border, logo, breadcrumb) ---------- */
.header-box {
    border: 2px dashed var(--green);
    padding: 12px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    row-gap: 8px;
    background-color: #ffffff;
    cursor: pointer;
    margin-bottom: 15px;
    border-radius: 6px;
}
.header-box .brand-left,
.header-box .brand-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.header-box img { height: 50px; width: auto; }
.header-box .site-url { font-size: 0.85rem; color: #555; font-weight: 600; }
.header-box .logo-block { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.header-box .since { font-size: 0.72rem; color: #999; font-style: italic; }

.breadcrumb {
    font-size: 0.9rem;
    margin-bottom: 20px;
    color: #666;
}
.breadcrumb a {
    color: var(--green);
    text-decoration: none;
    font-weight: 600;
}

.main-menu {
    background-color: #f4f7f5;
    border: 1px solid #009900;
    border-radius: 8px;
    margin-bottom: 25px;
    padding: 5px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}
.main-menu a {
    display: inline-block;
    padding: 10px 20px;
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}
.main-menu a:hover, .main-menu a.current {
    background-color: var(--green);
    color: #ffffff;
}

.main-page-title {
    color: var(--green);
    font-size: 1.8rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
}

.sottotitolo {
    text-align: center;
    color: var(--muted);
    font-size: 1.05rem;
    font-style: italic;
    margin-top: 0;
    margin-bottom: 20px;
}

.page-intro {
    background-color: #eaf3fb;
    border: 1px solid var(--border);
    padding: 15px 20px;
    margin-bottom: 25px;
    border-radius: var(--radius);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ---------- Barra di collegamento rapido a pagine correlate ---------- */
.quick-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin: 0 0 30px;
    padding: 10px;
    background-color: #eaf7f1;
    border: 1px solid var(--green);
    border-radius: 8px;
}
.quick-links a {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #2c3e50;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: 999px;
    background: #f4f7f5;
    border: 1.5px solid #a8d9c4;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}
.quick-links a:hover {
    background: #eaf3fb;
    border-color: #3b82c4;
    color: #3b82c4;
}

/* ---------- Sezioni dei questionari (titolo + descrizione + card) ---------- */
.sezione-questionario {
    margin-bottom: 35px;
}
.sezione-questionario h2 {
    color: var(--green);
    font-size: 1.35rem;
    margin: 30px 0 6px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--green-lt);
}
.sezione-descrizione {
    text-align: center;
    color: var(--muted);
    font-size: 0.95rem;
    font-style: italic;
    margin: 0 0 22px;
}

/* ---------- Card di scelta modalità (standard / DSA) ---------- */
.test-cards-container {
    display: flex;
    gap: 25px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.test-card {
    background: #fff;
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 30px;
    width: 300px;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.test-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border-color: var(--green);
}

.test-card-icon {
    font-size: 3.5rem;
    margin-bottom: 12px;
}

.test-card h3 {
    margin: 8px 0;
    color: #2c3e50;
    font-size: 1.25rem;
}

.test-card p {
    font-size: 0.92rem;
    color: var(--muted);
    flex-grow: 1;
    margin-bottom: 20px;
}

/* ---------- Bottoni delle card ---------- */
.btn-test {
    display: inline-block;
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 700;
    transition: all 0.3s ease;
    width: 85%;
    text-align: center;
    border: 2px solid transparent;
}

.btn-standard {
    background-color: var(--green);
    color: #ffffff;
    border-color: var(--green);
}
.btn-standard:hover {
    background-color: #ffffff;
    color: var(--green);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* ---------- Footer v3 ---------- */
footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
    font-size: 0.88rem;
    color: #555;
}
.license-box {
    background-color: #fafafa;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
    font-size: 0.8rem;
    color: #777;
}
.footer-nav-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}
.footer-nav-btn {
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.footer-nav-btn.btn-index { background-color: #7b1f2e; }
.footer-nav-btn.btn-index:hover { background-color: #5a1722; }

p.contatore {
    margin-top: 12px;
    font-size: 0.8rem;
    color: #aaa;
    font-style: italic;
}
.validation-link {
    margin-top: 15px;
    font-size: 0.8rem;
    color: #999;
}
.validation-link a {
    color: #999;
    text-decoration: none;
}
.validation-link a:hover {
    text-decoration: underline;
}

/* ---- Bottone torna su (flottante, appare dopo 300px di scroll) ---- */
#btn-top {
    position: fixed;
    bottom: 20px;
    right: 4px;
    background: #9C27B0;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    font-size: 1.3rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    transition: background 0.2s;
}
#btn-top:hover { background: #7a00cc; }

.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
}

@media print {
    #btn-top, .main-menu, footer {
        display: none !important;
    }
}

/* MOBILE */
@media (max-width: 600px) {
    .test-card { width: 100%; }
}

@media (max-width: 420px) {
    .header-box img { height: 36px; }
    .header-box .site-url { font-size: 0.75rem; }
}

/* Bottone arancione per le card in versione DSA */
.btn-dsa {
    background-color: var(--orange);
    color: #ffffff;
    border-color: var(--orange);
}
.btn-dsa:hover {
    background-color: #ffffff;
    color: var(--orange-dk);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}
