/* ==========================================================================
   BRUSCO ASSICURAZIONI — PAGINE INTERNE
   Si carica dopo site.css: componenti delle pagine Assicurazioni, Pratiche
   Auto, Prestiti, Strumenti, Privacy, Cookie e 404.
   ========================================================================== */

/* ─── Testata di pagina ────────────────────────────────────────────────── */
.hero--page { padding: calc(var(--header-h) + 2.2rem) 0 3.6rem; }
.hero--page .hero-title { font-size: clamp(2.1rem, 4.8vw, 3.5rem); margin-bottom: 1.1rem; }
.hero--page .hero-lead { margin-bottom: 1.6rem; }
.hero--page .hero-actions { margin-bottom: 0; }
.hero--page .copy { max-width: 46rem; }
.hero--page.center .copy { margin: 0 auto; text-align: center; }
.hero--page.center .hero-actions { justify-content: center; }
.hero--page.center .crumbs ol { justify-content: center; }

.hero--slim { padding-bottom: 2.4rem; }
.hero--slim .hero-title { font-size: clamp(1.9rem, 4vw, 2.7rem); margin-bottom: 0; }

.crumbs { margin-bottom: 1.1rem; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; font-size: .88rem; color: #9fb0d9; }
.crumbs li + li::before { content: "/"; margin-right: .4rem; opacity: .55; }
.crumbs a { color: #cfd9f5; }
.crumbs [aria-current] { color: #fff; }

/* Variante ambra (pagina prestiti) */
.hero--amber .aurora i:nth-child(1) { background: radial-gradient(closest-side, rgba(217, 119, 6, .75), transparent); }
.hero--amber .aurora i:nth-child(2) { background: radial-gradient(closest-side, rgba(251, 191, 36, .4), transparent); }
.hero--amber .aurora i:nth-child(3) { background: radial-gradient(closest-side, rgba(244, 63, 94, .35), transparent); }
.hero--amber .grad { background-image: linear-gradient(100deg, #fde68a, #fbbf24 50%, #fdba74); }
.hero-legal {
  max-width: 44rem; margin: 0 0 1.5rem; padding: .7rem .95rem; border-radius: 12px; font-size: .88rem; line-height: 1.5; color: #fde9b8;
  background: rgba(245, 158, 11, .14); border: 1px solid rgba(245, 158, 11, .4);
}
.btn-amber { background: var(--amber); color: #1a1200; box-shadow: 0 10px 24px -10px rgba(245, 158, 11, .8); }
.btn-amber:hover { background: #d98a06; color: #1a1200; }

/* ─── Schede a griglia ─────────────────────────────────────────────────── */
.svc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; }
.svc-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.svc-grid .svc h3 { font-size: 1.35rem; }
.why .svc { align-items: flex-start; }
.why.center .svc { text-align: center; align-items: center; }
@media (max-width: 980px) { .svc-grid.three { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .svc-grid { grid-template-columns: 1fr; } }
.sec-note { max-width: 46rem; margin: 2rem auto 0; text-align: center; color: var(--muted); }

/* ─── Blocco finale di invito ──────────────────────────────────────────── */
.cta {
  position: relative; isolation: isolate; overflow: hidden; text-align: center; color: #fff; background: #070d24;
  border-radius: 28px; padding: clamp(2.5rem, 6vw, 4rem) 1.5rem;
}
.cta .aurora i:nth-child(1) { left: -14vmax; top: -30vmax; }
.cta h2 { color: #fff; font-size: clamp(1.7rem, 3.6vw, 2.5rem); margin-bottom: .8rem; }
.cta p { color: #c9d5f2; max-width: 40rem; margin: 0 auto 1.6rem; font-size: 1.08rem; }
.cta-actions { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; }

/* ─── Modulo e calcolatore ─────────────────────────────────────────────── */
.split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 1.6rem; align-items: start; }
@media (max-width: 960px) { .split { grid-template-columns: 1fr; } }
.panel-card { padding: clamp(1.4rem, 3vw, 2.2rem); border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.panel-card h2 { font-size: clamp(1.4rem, 2.6vw, 1.8rem); margin-bottom: .5rem; }
.panel-card > p.lead { color: var(--muted); font-size: 1.05rem; margin-bottom: 1.3rem; }
.panel-card .svc-ico { width: 48px; height: 48px; margin-bottom: 1rem; }

.form-group { margin-bottom: 1rem; }
.form-label { display: block; font-size: .86rem; font-weight: 600; color: var(--head); margin-bottom: .4rem; }
.form-input, .form-select {
  width: 100%; padding: .78rem 1rem; font-size: 1rem; color: var(--head); background: #fff;
  border: 1px solid var(--line); border-radius: 12px; outline: none; transition: border-color .2s, box-shadow .2s;
}
.form-input::placeholder { color: #8a94ad; }
.form-input:focus, .form-select:focus { border-color: var(--brand-600); box-shadow: 0 0 0 3px rgba(52, 70, 196, .2); }
.form-row { display: flex; gap: 1rem; }
.form-row > * { flex: 1; }
.form-row.end { align-items: flex-end; }
@media (max-width: 640px) { .form-row { flex-direction: column; gap: 0; } }

.result-box {
  display: none; margin-top: 1.2rem; padding: 1.1rem 1.2rem; border-radius: 14px; text-align: center; font-size: 1.15rem;
  color: var(--head); background: var(--brand-50); border: 1px solid #cfd6ff;
}
.result-box strong { color: var(--brand); }

.note {
  margin-top: 1.2rem; padding: 1rem 1.1rem; border-radius: 14px; font-size: .9rem; line-height: 1.55;
  background: #fffbeb; border: 1px solid #fde68a; color: #7a4a06;
}
.note a { color: #7a4a06; text-decoration: underline; }
.mini { margin-top: 1.2rem; padding: 1.1rem 1.2rem; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.mini h3 { font-size: 1rem; margin-bottom: .4rem; }
.mini ul { list-style: none; color: var(--muted); font-size: .95rem; }

/* Scheda scura con elenco */
.card-dark {
  position: relative; isolation: isolate; overflow: hidden; padding: clamp(1.4rem, 3vw, 2rem); border-radius: var(--radius); color: #dbe4fb; background: #0a1230;
}
.card-dark::before { content: ""; position: absolute; z-index: -1; width: 30rem; height: 30rem; right: -12rem; top: -14rem; background: radial-gradient(closest-side, rgba(52, 70, 196, .65), transparent); }
.card-dark h3 { color: #fff; font-size: 1.3rem; margin-bottom: 1.1rem; }
.check-list { list-style: none; display: grid; gap: .7rem; margin-bottom: 1.5rem; }
.check-list li { display: flex; align-items: center; gap: .7rem; color: #e6ecff; }
.check-list .ck { flex: 0 0 auto; width: 1.55rem; height: 1.55rem; border-radius: 50%; display: grid; place-items: center; background: rgba(125, 211, 252, .18); color: #7dd3fc; }

/* ─── Pagina Strumenti ─────────────────────────────────────────────────── */
.tools-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 1.6rem; align-items: start; }
.tools-side { display: grid; gap: 1.2rem; }
@media (max-width: 960px) { .tools-layout { grid-template-columns: 1fr; } }
.tcard { padding: 1.5rem; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.tcard h2, .tcard h3 { font-size: 1.15rem; margin-bottom: 1rem; }
.tcard.big h2 { font-size: clamp(1.5rem, 2.6vw, 1.9rem); margin-bottom: .4rem; }
.tcard.big .sub { color: var(--muted); margin-bottom: 1rem; }
.tcard .svc-ico { width: 48px; height: 48px; margin-bottom: 1rem; }
.tcard.soft { background: var(--brand-50); border-color: #cfd6ff; }
.tcard.soft h3 { color: var(--brand); }
.tcard .btn-row { display: flex; gap: .5rem; margin-top: .3rem; }
.tcard .btn-row .btn { flex: 1; }
.tcard .inline { display: flex; gap: .5rem; }
.tcard .inline .form-input { flex: 2; }
.tcard .inline .btn { flex: 1; }
.tcard small { display: block; margin-top: .8rem; font-size: .8rem; color: var(--muted); }
.ext-links { display: grid; gap: .6rem; }
.ext-links .btn { justify-content: flex-start; background: #fff; }

.tabs { display: flex; gap: .4rem; padding: .3rem; margin-bottom: 1.2rem; background: #eef0f7; border-radius: 14px; }
.tab-btn {
  flex: 1; padding: .6rem .5rem; text-align: center; font-size: .92rem; font-weight: 600; color: var(--muted);
  border: 0; background: transparent; border-radius: 11px; cursor: pointer; transition: background .2s, color .2s;
}
.tab-btn:hover { color: var(--head); }
.tab-btn.active { background: #fff; color: var(--head); box-shadow: 0 1px 3px rgba(10, 18, 48, .12); }

.ac-wrap { position: relative; }
.ac-list {
  position: absolute; top: calc(100% + 4px); left: 0; right: 0; z-index: 30; display: none; max-height: 250px; overflow-y: auto;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-md);
}
.ac-list.show { display: block; }
.ac-item { padding: .7rem 1rem; font-size: .96rem; cursor: pointer; border-bottom: 1px solid #f0f2f8; }
.ac-item:last-child { border-bottom: 0; }
.ac-item:hover { background: var(--brand-50); color: var(--brand); }

.big-result { margin-top: 1.2rem; padding: 1.3rem; border-radius: 14px; background: var(--brand-50); border: 2px dashed #9ea9f0; text-align: center; }
.omo { margin-top: 1rem; padding: 1rem; border-radius: 12px; background: var(--bg); }
.omo h3 { font-size: .95rem; margin-bottom: .4rem; }
.omo div { font-family: ui-monospace, Consolas, monospace; font-size: .88rem; }

/* ─── Testi lunghi: guide, informative ─────────────────────────────────── */
.prose { max-width: 50rem; margin: 0 auto; }
.prose h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin: 2.4rem 0 .9rem; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.2rem; margin: 1.9rem 0 .5rem; }
.prose h4 { font-size: 1.02rem; margin: 1.4rem 0 .4rem; color: var(--head); }
.prose p, .prose li { color: #475069; font-size: 1.02rem; line-height: 1.75; }
.prose p { margin-bottom: .9rem; }
.prose ul, .prose ol { padding-left: 1.4rem; margin-bottom: 1rem; }
.prose li { margin-bottom: .45rem; }
.prose li > ul { margin: .5rem 0 0; }
.prose strong { color: var(--head); font-weight: 600; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose .last-update { display: inline-block; font-size: .85rem; color: var(--muted); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: .2rem .8rem; margin: 0 0 1.4rem; }
.table-wrap { overflow-x: auto; margin: 1.2rem 0; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.prose table { width: 100%; border-collapse: collapse; min-width: 640px; }
.prose th { background: var(--ink); color: #fff; padding: .7rem .8rem; text-align: left; font-size: .82rem; font-weight: 600; letter-spacing: .02em; }
.prose td { padding: .7rem .8rem; border-bottom: 1px solid var(--line); font-size: .9rem; color: #475069; vertical-align: top; line-height: 1.5; }
.prose tr:last-child td { border-bottom: 0; }
.prose tr:nth-child(even) td { background: #fafbfe; }
.guide h3 { margin-top: 1.9rem; }
.guide .faq { margin-top: 2.2rem; }
.guide .faq-title { font-size: clamp(1.5rem, 3vw, 2rem); margin: 2.6rem 0 1.2rem; text-align: center; }

/* ─── Prestiti: informazioni legali ────────────────────────────────────── */
.notices { max-width: 56rem; margin: 0 auto; display: grid; gap: 1.2rem; }
.notice { padding: 1.5rem 1.6rem; border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg); }
.notice h3 { font-size: 1.05rem; margin-bottom: .7rem; display: flex; align-items: center; gap: .6rem; }
.notice p, .notice li { font-size: .95rem; line-height: 1.7; color: #475069; }
.notice ul { padding-left: 1.2rem; }
.notice li { margin-bottom: .5rem; }
.notice li:last-child { margin-bottom: 0; }
.notice strong { color: var(--head); }
.notice a { text-decoration: underline; text-underline-offset: 3px; }
.notice.warn { background: #fffbeb; border-color: #fde68a; }
.notice.warn h3, .notice.warn strong { color: #7a4a06; }
.notice.warn p, .notice.warn li { color: #6b4405; }
.notice.ok { background: #f0fdf4; border-color: #bbf7d0; }
.notice.ok h3 { color: #166534; }
.legal-strip { background: #0a1230; color: #b9c7ea; padding: 1.2rem 1.5rem; text-align: center; font-size: .85rem; line-height: 1.6; }
.legal-strip strong { color: #fff; letter-spacing: .02em; }
.legal-strip a { color: #8ec5ff; text-decoration: underline; }

/* ─── 404 ──────────────────────────────────────────────────────────────── */
.hero--404 { min-height: 78vh; display: flex; align-items: center; }
.hero--404 .big { font-size: clamp(4.5rem, 16vw, 9rem); font-weight: 700; letter-spacing: -.05em; line-height: .95; margin-bottom: .6rem; }
.hero--404 h2 { color: #fff; font-size: 1.1rem; font-weight: 600; margin: 1.6rem 0 1rem; opacity: .85; }
.hero--404 .hero-actions { justify-content: center; }
