.ag-home { --ag-shadow: 0 14px 40px #102c401a; }
.ag-home .hero { background: radial-gradient(ellipse at 90% 10%, #24564a, transparent 65%), var(--navy); color: white; }
.ag-home .hero h1 { font-size: clamp(2.55rem, 6.1vw, 5.7rem); max-width: 14ch; }
.ag-home .hero .kicker, .ag-home .hero-copy > p:not(.kicker) { color: #d7eae1; }
.ag-home .hero .outline { color: white; border-color: #a2c2b7; background: transparent; }
.ag-home .hero .outline:hover { background: #ffffff24; }
.ag-home .hero-image { border-radius: 1.5rem; border: 1px solid #ffffff30; box-shadow: 0 22px 55px #0004; }
.ag-home .hero-image img { object-position: center 56%; }
.ag-home .section { padding-block: clamp(3rem, 8vw, 6.5rem); }
.ag-home .card, .ag-home .audit-result { border-radius: 1.25rem; overflow: hidden; }
.ag-home .card { box-shadow: 0 2px 9px #102c400c; }
.ag-home .card-copy { overflow-wrap: anywhere; }
.ag-home .diagnostic { background: #e1f0e3; color: var(--navy); }
.ag-home .diagnostic p:not(.kicker) { color: var(--muted); }
.ag-home .diagnostic .outline { color: var(--navy); border-color: #759982; }
.ag-home .mobile-navigation .primary-links { max-height: 70dvh; overflow: auto; border-radius: 1rem; box-shadow: var(--ag-shadow); }
.ag-home .mobile-navigation summary { min-height: 44px; border-radius: 2rem; }
.ag-home .mobile-navigation .primary-links a { min-height: 44px; }
.ag-bottom, .ag-carousel-controls { display: none; }
@media (hover: hover) {
  .ag-home .card:hover { box-shadow: var(--ag-shadow); }
}
@media (prefers-reduced-motion: no-preference) {
  .ag-home .card, .ag-home .button, .ag-bottom a { transition: box-shadow .22s, transform .22s, background-color .22s; }
  .ag-home .button:active, .ag-bottom a:active { transform: scale(.97); }
  .ag-home .ag-revealed { animation: ag-reveal .52s ease-out both; }
  @keyframes ag-reveal { from { opacity: .55; transform: translateY(12px); } }
}
@media (prefers-reduced-motion: reduce) {
  html:has(.ag-home) { scroll-behavior: auto; }
}
@media (max-width: 760px) {
  .ag-home { --ag-bar: calc(4rem + env(safe-area-inset-bottom, 0px)); padding-bottom: var(--ag-bar); }
  .ag-home .hero-copy { padding-block: 2rem 1.4rem; }
  .ag-home .hero-image { height: clamp(185px, 48vw, 275px); }
  .ag-home :is(.services-grid, #ecossistema-cards) {
    display: grid; grid-template-columns: none; grid-auto-flow: column;
    grid-auto-columns: min(84%, 24rem); gap: .8rem; overflow-x: auto;
    scroll-snap-type: x mandatory; padding: .35rem .2rem .9rem;
  }
  .ag-home :is(.services-grid, #ecossistema-cards) > .card { scroll-snap-align: start; min-width: 0; }
  .ag-home :is(#servicos, [aria-labelledby="materials-applications-title"]) > .section-heading {
    display: flex; justify-content: space-between; align-items: center; gap: .75rem;
  }
  .ag-carousel-controls:not([hidden]) { display: flex; gap: .25rem; }
  .ag-carousel-controls button { border: 1px solid var(--line); border-radius: 50%; width: 44px; height: 44px; color: var(--navy); background: white; font-size: 1.5rem; cursor: pointer; }
  .ag-carousel-controls button:disabled { opacity: .4; cursor: default; }
  .ag-bottom { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: center; position: fixed; z-index: 9; inset: auto 0 0; min-height: var(--ag-bar); padding: .35rem .55rem calc(.35rem + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); background: #fcfdfb; }
  .ag-bottom a { text-align: center; display: grid; align-items: center; min-height: 44px; padding-inline: .2rem; border-radius: .65rem; font-size: .875rem; }
  .ag-bottom a:active { background: var(--mint); }
  .ag-home .floating-whatsapp { bottom: calc(var(--ag-bar) + .65rem); }
  .ag-home .analytics-preference { bottom: calc(var(--ag-bar) + .65rem); }
  .ag-home:has(.analytics-preference:not([hidden])) .floating-whatsapp { visibility: hidden; }
}
@media print { .ag-bottom, .ag-carousel-controls { display: none !important; } }
