/* =====================================================
   Autossocorro - assets/styles.css
   ===================================================== */

/* =========================
   Tokens de design
========================= */
:root{
  --brand: #0f79ff;
  --brand-ink:#0a57c9;
  --ink:#0b1220;
  --muted:#6b7280;
  --bg:#ffffff;
  --panel:#ffffff;
  --border:#e7eaf2;
  --radius:18px;
  --shadow:0 10px 25px rgba(10,20,40,.07);
  --shadow-strong:0 18px 40px rgba(10,20,40,.12);
  --grad: linear-gradient(180deg,#ffffff,#f7f8fb 60%,#eef2f7);
  --focus: #66a3ff;
}

/* =========================
   Reset / base
========================= */
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{
  margin:0;padding:0;
  font-family:'Inter',system-ui,-apple-system,'Segoe UI',Roboto,Arial,sans-serif;
  color:var(--ink); background:var(--grad);
  overflow-x:hidden; image-rendering:auto;
  -webkit-font-smoothing:antialiased; -moz-osx-font-smoothing:grayscale;
  height:100%;
}
body{min-height:100svh; display:flex; flex-direction:column;}
img{max-width:100%;display:block}
a{color:var(--brand);text-decoration:none}
a:hover{color:var(--brand-ink)}
:focus-visible{outline:3px solid var(--focus); outline-offset:2px}

/* =========================
   Header / identidade
========================= */
header.app-header{
  position:sticky;top:0;z-index:60;display:flex;align-items:center;gap:.6rem;
  padding:.6rem .9rem;background:linear-gradient(180deg,#fff,#f7f9ff);
  border-bottom:1px solid var(--border)
}
.logo{
  display:inline-flex;align-items:center;justify-content:center;min-width:110px;height:44px;
  padding:.25rem .6rem;background:#fff;border:1px solid var(--border);border-radius:14px
}
.logo img{height:30px;width:auto;object-fit:contain;border-radius:8px}
.btn-icon{border:0;background:#f3f5fa;padding:.6rem .7rem;border-radius:12px;cursor:pointer}
.btn-icon i{font-size:1.1rem}
.actions{margin-left:auto;display:flex;gap:.5rem;flex:0 0 auto;white-space:nowrap;align-items:center}

/* =========================
   Botões
========================= */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:.45rem;
  padding:.52rem .72rem;border-radius:12px;border:none;cursor:pointer;transition:.2s ease;
  background:var(--brand);color:#fff;font-weight:600;box-shadow:var(--shadow)
}
.btn:hover{background:var(--brand-ink)}
.btn.ghost{background:#eef2ff;color:#0f1e48}
.btn.center{display:flex;margin:.55rem auto}
.btn.sm{padding:.42rem .64rem;font-size:.92rem;border-radius:12px}

/* Evitar quebra em telas estreitas */
@media (max-width:370px){
  .btn .label{display:none}
  .btn{padding:.42rem .58rem}
}

/* =========================
   Seções / grids / cards
========================= */
.section{padding:1.1rem .9rem;scroll-margin-top:80px}
.section h2{text-align:center;margin:.3rem 0 1rem 0}
.cards{display:grid;grid-template-columns:1fr;gap:.85rem}
.card{
  background:var(--panel);border:1px solid var(--border);
  border-radius:var(--radius);padding:1rem;box-shadow:var(--shadow)
}
.grid-banners,.grid-gallery,.grid-videos,.grid-partners{display:grid;gap:.8rem}
.grid-banners{grid-template-columns:1fr}
.grid-gallery{grid-template-columns:repeat(3,1fr)}
.grid-videos{grid-template-columns:1fr}
.grid-partners{grid-template-columns:repeat(3,1fr)}

.partner{display:flex;flex-direction:column;align-items:center;gap:.4rem;padding:.7rem;background:#fff;border:1px solid var(--border);border-radius:14px}
.partner img{height:80px;object-fit:contain;border-radius:10px;background:#fff;padding:4px}

/* =========================
   Hero / slider (fade)
========================= */
.hero{background:var(--grad);padding:0}
.hero-swiper{position:relative;overflow:hidden}
.hero-swiper .slide{
  min-height:360px;background-size:cover;background-position:center;
  display:flex;align-items:flex-end;position:absolute;inset:0;opacity:0;transition:opacity .8s ease;
}
.hero-swiper .slide.active{opacity:1}
.hero-swiper .slide-content{
  background:linear-gradient(180deg,transparent,rgba(0,0,0,.65));
  color:#fff;padding:1.1rem;width:100%;text-align:center
}

/* =========================
   Pesquisa / Map
========================= */
.search{display:flex;gap:.5rem;justify-content:center}
.search input, select{
  flex:1;max-width:560px;padding:.8rem;border-radius:12px;border:1px solid var(--border);background:#fff;font-size:1rem
}
.map-wrap{border-radius:14px;overflow:hidden;border:1px solid var(--border)}
#gmap{width:100%;height:360px;border:0}

/* =========================
   Paginação genérica
========================= */
.pagination{display:flex;gap:.4rem;justify-content:center;margin-top:1rem}
.pagination a{padding:.42rem .68rem;border:1px solid var(--border);border-radius:10px;background:#fff;color:#1a2340}
.pagination a.active{background:var(--brand);color:#fff;border-color:var(--brand)}

.pager{display:flex;align-items:center;justify-content:center;gap:.45rem;margin-top:.6rem;flex-wrap:wrap}
.pager button{min-width:38px}
.pager .nums{display:flex;gap:.25rem}
.pager .nums .num{
  min-width:34px;height:34px;display:inline-flex;align-items:center;justify-content:center;
  border-radius:10px;border:1px solid var(--border);background:#fff;color:#1a2340;font-size:.9rem
}
.pager .nums .num[aria-current="page"]{background:var(--brand);color:#fff;border-color:var(--brand)}
.pager .status{font-size:.9rem;color:#555}

/* =========================
   Galerias (mesmo tamanho)
========================= */
.media-tile{
  position:relative;border:1px solid var(--border);border-radius:14px;overflow:hidden;background:#fff;
  aspect-ratio:16/9; /* força o mesmo tamanho para imagens e vídeos */
}
.media-tile img, .media-tile iframe{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;border:0}

/* =========================
   Dicas / Banners especiais
========================= */
.tips-banner{margin-top:1rem;padding:1rem;border-radius:14px;background:linear-gradient(135deg,#fffbf0,#fff5e6);border:1px solid #ffe8c2}
.glow{box-shadow:0 12px 24px rgba(15,121,255,.08), inset 0 0 0 1px rgba(15,121,255,.08)}
.neon{
  background:radial-gradient(1200px 200px at 50% -20%, rgba(15,121,255,.20), transparent 60%), #fff;
  border:1px solid rgba(15,121,255,.25);
  box-shadow:0 20px 40px rgba(15,121,255,.12), inset 0 0 0 1px rgba(15,121,255,.08);
}

/* =========================
   Sobre / Contact
========================= */
.about{display:grid;gap:.9rem}
.about .lead{font-size:1.02rem;color:#101828;text-align:center}
.about .bullets{display:grid;gap:.55rem;margin:0 auto;max-width:720px}
.about .bullets li{list-style:none;display:flex;gap:.6rem;align-items:flex-start}
.about .bullets li .mark{font-size:1.15rem}

.contact-grid{display:grid;gap:.9rem;max-width:980px;margin:0 auto}
#contactForm{max-width:680px;margin:0 auto}
input, textarea, select{width:100%;font-size:1rem}
textarea{resize:vertical}

/* =========================
   Dialog (nav modal)
========================= */
dialog{border:none;border-radius:16px;box-shadow:0 30px 60px rgba(0,0,0,.25);padding:0}
dialog>article{padding:1rem 1.2rem}
.nav-list{display:grid;gap:.5rem;margin:0;padding:0;list-style:none}
.nav-link{display:flex;align-items:center;gap:.65rem;padding:.7rem .75rem;border-radius:12px;background:#f6f8fc;color:#1a2340}
.nav-link i{width:18px;text-align:center;color:var(--brand-ink)}

/* =========================
   FABs e Tabbar
========================= */
.fab{
  position:fixed;width:56px;height:56px;border-radius:999px;display:flex;align-items:center;justify-content:center;
  text-decoration:none;box-shadow:0 12px 24px rgba(0,0,0,.18);z-index:70;color:#fff;font-size:1.25rem
}
.fab.whats{left:.9rem;bottom:1.2rem;background:#25D366}
.fab.pageup{right:.9rem;bottom:1.2rem;background:#101828}

.tabbar{
  position:sticky;bottom:0;display:grid;grid-template-columns:repeat(5,1fr);gap:.5rem;padding:.5rem;background:#fff;border-top:1px solid var(--border);z-index:50
}
.tabbar a{display:flex;flex-direction:column;align-items:center;gap:.15rem;font-size:.78rem;color:#1a2340;background:#f6f8fc;border-radius:12px;padding:.45rem 0}
.tabbar i{font-size:1rem;color:#33406b}

/* =========================
   Footer
========================= */
.footer{
  padding:.7rem .9rem;border-top:1px solid var(--border);
  background:#f0f3ff;color:#404a6b;text-align:center;font-size:.85rem
}

/* =========================
   Utilidades / Efeitos
========================= */
.fade-in{animation:fadeIn .6s ease both}
@keyframes fadeIn{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}

/* Prefere menos animação */
@media (prefers-reduced-motion:reduce){
  *{animation:none!important;transition:none!important}
}

/* =========================
   Responsivo
========================= */
@media (min-width:720px){
  .cards{grid-template-columns:repeat(2,1fr)}
  .grid-banners{grid-template-columns:repeat(3,1fr)}
  .grid-videos{grid-template-columns:repeat(3,1fr)}
}
