/* =====================================================
   RB DISTRIBUIDORA - Folha de estilos
   Identidade: técnica, confiável, comercial.
   ===================================================== */

:root {
  /* Paleta extraída da logomarca RB:
     índigo (R / Distribuidora), vermelho (B / Nippon), azul-claro (bolhas) */
  --azul-900: #1b0e4e;
  --azul-800: #241465;
  --azul-700: #2a1872;
  --azul-600: #4636a3;
  --azul-100: #e4f1fb;
  --azul-50:  #f3f9fd;
  --bolha:    #95d2f1;
  --bolha-escura: #4ba3d8;
  --acento:   #d8281f;          /* vermelho da logo: cor principal de ação */
  --acento-escuro: #b51e16;
  --whats:    #25d366;
  --cinza-900:#1c2733;
  --cinza-700:#3d4c5c;
  --cinza-500:#64748b;
  --cinza-200:#e2e8f0;
  --cinza-100:#f1f5f9;
  --branco:   #ffffff;
  --radius:   14px;
  --shadow:   0 8px 28px rgba(13, 58, 87, .10);
  --shadow-sm:0 2px 10px rgba(13, 58, 87, .08);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--cinza-900);
  background: var(--branco);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--azul-700); text-decoration: none; }
ul { list-style: none; }

.container { width: min(1180px, 92%); margin: 0 auto; }

h1, h2, h3 { line-height: 1.2; color: var(--azul-900); font-weight: 800; }
h1 { font-size: clamp(1.9rem, 4vw, 3rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -.01em; }
h3 { font-size: 1.15rem; }

.section { padding: 72px 0; }
.section-alt { background: var(--azul-50); }
.section-head { max-width: 720px; margin-bottom: 44px; }
.section-head .kicker {
  display: inline-block; font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em; color: var(--acento);
  margin-bottom: 10px;
}
.section-head p { color: var(--cinza-500); margin-top: 12px; font-size: 1.05rem; }
.section-head.center { margin-inline: auto; text-align: center; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 28px; border-radius: 10px; font-weight: 600;
  font-size: .98rem; transition: all .2s ease; border: 2px solid transparent;
  cursor: pointer;
}
.btn-primary { background: var(--acento); color: #fff; }
.btn-primary:hover { background: var(--acento-escuro); transform: translateY(-2px); }
.btn-outline { border-color: rgba(255,255,255,.45); color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,.12); }
.btn-outline-dark { border-color: var(--azul-700); color: var(--azul-700); }
.btn-outline-dark:hover { background: var(--azul-700); color: #fff; }
.btn-light { background: #fff; color: var(--azul-800); }
.btn-light:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn-whatsapp { background: var(--whats); color: #fff; }
.btn-whatsapp:hover { background: #1ebe5a; transform: translateY(-2px); }
.btn-sm { padding: 9px 18px; font-size: .88rem; }

/* ---------- Chamada comercial (banner do painel, exibido na home) ---------- */
.promo {
  background: linear-gradient(120deg, var(--acento-escuro), var(--acento));
  color: #fff; border-radius: var(--radius); padding: 34px 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.promo h3 { color: #fff; font-size: 1.25rem; margin-bottom: 4px; }
.promo p { color: rgba(255,255,255,.88); font-size: .96rem; }
.promo .btn-light { color: var(--acento-escuro); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255,255,255,.96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--cinza-200);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 74px; gap: 24px; }
.logo { display: flex; align-items: center; }
.logo img { height: 52px; width: auto; }
.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a { color: var(--cinza-700); font-weight: 500; font-size: .94rem; padding: 6px 0; border-bottom: 2px solid transparent; }
.main-nav a:hover { color: var(--azul-700); }
.main-nav a.active { color: var(--azul-700); border-bottom-color: var(--acento); }
.nav-cta {
  background: var(--azul-800); color: #fff !important; padding: 10px 20px !important;
  border-radius: 9px; border: none !important; font-weight: 600 !important;
}
.nav-cta:hover { background: var(--azul-900); }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { display: block; width: 24px; height: 2.5px; background: var(--azul-900); margin: 5px 0; border-radius: 2px; transition: .25s; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(75,163,216,.45), transparent 60%),
    radial-gradient(700px 400px at -10% 110%, rgba(216,40,31,.28), transparent 55%),
    linear-gradient(150deg, var(--azul-900) 20%, var(--azul-800) 70%);
  color: #fff; padding: 96px 0 110px; position: relative; overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: linear-gradient(115deg, transparent 40%, #000 90%);
}
.hero-inner { position: relative; z-index: 1; max-width: 760px; }
.hero .tagline {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2);
  border-radius: 99px; padding: 6px 16px; font-size: .82rem; font-weight: 600;
  margin-bottom: 26px; letter-spacing: .02em;
}
.hero .tagline::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--acento); }
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero p { font-size: 1.13rem; color: rgba(255,255,255,.85); max-width: 620px; margin-bottom: 36px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-badges { display: flex; gap: 28px; margin-top: 52px; flex-wrap: wrap; }
.hero-badges div { font-size: .86rem; color: rgba(255,255,255,.75); display: flex; align-items: center; gap: 8px; }
.hero-badges svg { color: var(--bolha); flex-shrink: 0; }

/* ---------- Grades de cards ---------- */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--cinza-200); border-radius: var(--radius);
  padding: 30px 26px; transition: transform .2s, box-shadow .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card .card-icon {
  width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center;
  background: var(--azul-100); color: var(--azul-700); margin-bottom: 18px;
}
.card h3 { margin-bottom: 10px; }
.card p { color: var(--cinza-500); font-size: .94rem; }
.card .card-link { display: inline-block; margin-top: 16px; font-weight: 600; font-size: .9rem; color: var(--acento-escuro); }
.card .card-link:hover { text-decoration: underline; }

/* Card com imagem (segmentos/produtos) */
.card-img { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.card-img .thumb { aspect-ratio: 16/9; background: var(--azul-100); overflow: hidden; }
.card-img .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.card-img:hover .thumb img { transform: scale(1.04); }
.card-img .body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.card-img .body p { flex: 1; }
.badge {
  display: inline-block; background: var(--azul-100); color: var(--azul-700);
  font-size: .73rem; font-weight: 700; padding: 3px 12px; border-radius: 99px;
  text-transform: uppercase; letter-spacing: .06em; margin-bottom: 12px; width: fit-content;
}

/* ---------- Bloco split (texto + visual) ---------- */
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: 60px; align-items: center; }
.split .visual {
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  aspect-ratio: 4/3; background: linear-gradient(135deg, var(--azul-100), #cde9fa);
  display: grid; place-items: center; color: var(--azul-700);
}
.split .visual img { width: 100%; height: 100%; object-fit: cover; }
.checklist { margin-top: 22px; display: grid; gap: 12px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; color: var(--cinza-700); }
.checklist svg { color: var(--bolha-escura); flex-shrink: 0; margin-top: 2px; }

/* ---------- Faixa Nippon ---------- */
.nippon-band {
  background: linear-gradient(120deg, var(--azul-900), var(--azul-700));
  color: #fff; border-radius: var(--radius); padding: 52px;
  display: grid; grid-template-columns: 1fr auto; gap: 36px; align-items: center;
}
.nippon-band h2 { color: #fff; margin-bottom: 12px; }
.nippon-band p { color: rgba(255,255,255,.82); max-width: 640px; }

/* ---------- CTA final ---------- */
.cta-final { background: linear-gradient(120deg, var(--acento-escuro), var(--acento)); color: #fff; padding: 60px 0; }
.cta-final-inner { display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; }
.cta-final h2 { color: #fff; margin-bottom: 8px; max-width: 600px; }
.cta-final p { color: rgba(255,255,255,.88); }
.cta-final-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.cta-final .btn-whatsapp { background: rgba(255,255,255,.16); border: 1.5px solid rgba(255,255,255,.5); }

/* ---------- Footer ---------- */
.site-footer { background: var(--azul-900); color: rgba(255,255,255,.78); font-size: .93rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr 1fr; gap: 44px; padding: 64px 0 48px; }
.footer-logo { font-size: 1.3rem; color: #fff; margin-bottom: 14px; }
.footer-nippon { margin-top: 16px; color: rgba(255,255,255,.6); font-size: .85rem; }
.nippon-chip {
  display: inline-block; background: #fff; border-radius: 10px;
  padding: 10px 16px; margin-top: 12px;
}
.nippon-chip img { height: 34px; width: auto; }
.site-footer h3 { color: #fff; font-size: .95rem; margin-bottom: 16px; text-transform: uppercase; letter-spacing: .08em; }
.site-footer ul li { margin-bottom: 10px; }
.site-footer a { color: rgba(255,255,255,.78); }
.site-footer a:hover { color: #fff; }
.footer-contact li { display: flex; gap: 10px; align-items: flex-start; }
.footer-contact svg { flex-shrink: 0; margin-top: 3px; color: var(--bolha); }
.footer-social { display: inline-block; margin-top: 12px; border: 1px solid rgba(255,255,255,.3); padding: 6px 18px; border-radius: 99px; font-size: .85rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 20px 0; font-size: .82rem; color: rgba(255,255,255,.5); }

/* ---------- WhatsApp flutuante ---------- */
.whats-float {
  position: fixed; right: 22px; bottom: 22px; z-index: 80;
  width: 60px; height: 60px; border-radius: 50%;
  background: var(--whats); color: #fff; display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(37, 211, 102, .45);
  transition: transform .2s;
}
.whats-float:hover { transform: scale(1.08); }

/* ---------- Formulários ---------- */
.form-card {
  background: #fff; border: 1px solid var(--cinza-200); border-radius: var(--radius);
  padding: 36px; box-shadow: var(--shadow-sm);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-grid .full { grid-column: 1 / -1; }
label { font-weight: 600; font-size: .88rem; display: block; margin-bottom: 6px; color: var(--azul-900); }
input[type="text"], input[type="email"], input[type="tel"], input[type="password"],
input[type="number"], input[type="datetime-local"], select, textarea {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--cinza-200);
  border-radius: 9px; font-family: var(--font); font-size: .95rem; color: var(--cinza-900);
  background: var(--cinza-100); transition: border-color .15s, background .15s;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--azul-600); background: #fff;
}
textarea { min-height: 130px; resize: vertical; }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.alert { padding: 14px 18px; border-radius: 10px; margin-bottom: 22px; font-size: .94rem; font-weight: 500; }
.alert-ok { background: #e5f7ed; color: #116b3e; border: 1px solid #b6e7cc; }
.alert-err { background: #fdecec; color: #a02020; border: 1px solid #f5c2c2; }

/* ---------- Página interna: hero curto ---------- */
.page-hero {
  background: linear-gradient(135deg, var(--azul-900), var(--azul-700));
  color: #fff; padding: 64px 0;
}
.page-hero h1 { color: #fff; margin-bottom: 12px; }
.page-hero p { color: rgba(255,255,255,.82); max-width: 680px; font-size: 1.06rem; }
.breadcrumb { font-size: .82rem; color: rgba(255,255,255,.6); margin-bottom: 16px; }
.breadcrumb a { color: rgba(255,255,255,.8); }

/* ---------- Conteúdo de artigo ---------- */
.article-body { max-width: 760px; margin: 0 auto; font-size: 1.05rem; color: var(--cinza-700); }
.article-body h2 { margin: 36px 0 14px; }
.article-body p { margin-bottom: 18px; }
.article-body ul { margin: 0 0 18px 22px; list-style: disc; }
.article-body li { margin-bottom: 8px; }
.article-meta { color: var(--cinza-500); font-size: .88rem; margin-bottom: 28px; }
.article-cover { border-radius: var(--radius); overflow: hidden; margin-bottom: 36px; }

/* ---------- Tabela-resumo segmento ---------- */
.info-blocks { display: grid; gap: 22px; }
.info-block { background: #fff; border-left: 4px solid var(--acento); border-radius: 10px; padding: 26px 28px; box-shadow: var(--shadow-sm); }
.info-block h3 { margin-bottom: 10px; }
.info-block p { color: var(--cinza-700); }

/* ---------- Mapa / contato ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 44px; align-items: start; }
.contact-list { display: grid; gap: 18px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-list .ic { width: 44px; height: 44px; border-radius: 10px; background: var(--azul-100); color: var(--azul-700); display: grid; place-items: center; flex-shrink: 0; }
.contact-list strong { display: block; color: var(--azul-900); font-size: .92rem; }
.contact-list span, .contact-list a { color: var(--cinza-500); font-size: .94rem; }
.map-embed { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); margin-top: 36px; }
.map-embed iframe { width: 100%; height: 340px; border: 0; display: block; }

/* ---------- 404 ---------- */
.page-404 { text-align: center; padding: 110px 0; }
.page-404 .code { font-size: 6rem; font-weight: 800; color: var(--azul-100); line-height: 1; }

/* ---------- Responsivo ---------- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 36px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nippon-band { grid-template-columns: 1fr; padding: 40px 32px; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .section { padding: 52px 0; }
  .grid-3, .grid-4, .grid-2, .form-grid { grid-template-columns: 1fr; }
  .hero { padding: 64px 0 72px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }

  .nav-toggle { display: block; }
  .main-nav {
    position: fixed; inset: 74px 0 auto 0; background: #fff;
    flex-direction: column; align-items: stretch; gap: 0;
    border-bottom: 1px solid var(--cinza-200);
    box-shadow: var(--shadow); padding: 10px 0;
    transform: translateY(-130%); transition: transform .25s ease;
  }
  .main-nav.open { transform: translateY(0); }
  .main-nav a { padding: 14px 6%; border-bottom: 1px solid var(--cinza-100); }
  .main-nav .nav-cta { margin: 12px 6%; text-align: center; border-radius: 9px; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
}

/* ---------- Animação de entrada ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .5s ease, transform .5s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
