/* Camada visual compartilhada — IEP Boituva */
:root {
  --iep-navy: #062d63;
  --iep-blue: #1461ae;
  --iep-sky: #eaf4ff;
  --iep-ink: #14233a;
  --iep-muted: #5d6c80;
  --iep-line: #d7e2ee;
  --iep-surface: #ffffff;
  --iep-page: #f5f8fc;
  --iep-radius: 16px;
  --iep-shadow: 0 10px 30px rgba(6, 45, 99, .10);
}

html { scroll-behavior: smooth; }
body { background: var(--iep-page); color: var(--iep-ink); -webkit-font-smoothing: antialiased; }
body::selection { background: #b9ddfb; color: var(--iep-navy); }
a { text-underline-offset: .18em; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid #76b9ed;
  outline-offset: 3px;
}

header { box-shadow: 0 2px 12px rgba(6, 45, 99, .12); }
header .bar, header nav { min-height: 76px; }
header .brand img { box-shadow: 0 4px 13px rgba(0, 0, 0, .18); }

button, .button, .primary, .reset, .store, .access .button {
  min-height: 44px;
  border-radius: 12px !important;
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, border-color .18s ease;
}
button:hover:not(:disabled), .button:hover, .primary:hover, .reset:hover, .store:hover, .access .button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(6, 45, 99, .18);
}
button:active:not(:disabled), .button:active, .primary:active, .reset:active, .store:active { transform: translateY(0); }
button:disabled { cursor: not-allowed; opacity: .65; }

input, select, textarea {
  min-height: 44px;
  border-radius: 10px !important;
  border-color: #afc4db !important;
  transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}
textarea { min-height: 112px; }
input:hover, select:hover, textarea:hover { border-color: #699dd0 !important; }
input:focus, select:focus, textarea:focus { border-color: var(--iep-blue) !important; box-shadow: 0 0 0 3px rgba(20, 97, 174, .14); }

.card, article.card, .item, .security, .notice, .access, main > section, .consent {
  border-radius: var(--iep-radius) !important;
}
.card, article.card, .item {
  border-color: var(--iep-line) !important;
  box-shadow: 0 1px 0 rgba(6, 45, 99, .03);
}
.card:hover, article.card:hover, .item:hover { box-shadow: var(--iep-shadow); }

.eyebrow { letter-spacing: .12em !important; }
.lead, p { text-wrap: pretty; }

/* Abertura institucional breve e discreta. */
.iep-opening {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 50% 35%, #1b6bb2 0%, #0a3d78 38%, #041d40 100%);
  color: #fff;
  transition: opacity .55s ease, visibility .55s ease;
}
.iep-opening.is-leaving { opacity: 0; visibility: hidden; }
.iep-opening__content { display: grid; justify-items: center; gap: 17px; padding: 32px; text-align: center; animation: iep-rise .72s cubic-bezier(.2,.8,.2,1) both; }
.iep-opening__logo { width: 96px; height: 96px; padding: 8px; object-fit: contain; background: #fff; border-radius: 24px; box-shadow: 0 18px 44px rgba(0, 0, 0, .28); }
.iep-opening__name { font: 700 clamp(1.2rem, 4vw, 1.65rem)/1.1 Arial, sans-serif; letter-spacing: .08em; }
.iep-opening__line { width: 66px; height: 3px; border-radius: 99px; background: #91cef5; animation: iep-pulse 1s ease-in-out infinite alternate; }
@keyframes iep-rise { from { opacity: 0; transform: translateY(14px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes iep-pulse { to { transform: scaleX(1.45); opacity: .55; } }

.devotional-popup { position:fixed; inset:0; z-index:9998; display:grid; place-items:center; padding:20px; background:rgba(4,29,64,.68); backdrop-filter:blur(4px); }
.devotional-popup__card { position:relative; width:min(540px,100%); padding:34px; border:1px solid #c49c5f; border-radius:12px; color:#392619; background:#f7e7bd url('pergaminho-devocional.png') center/cover; box-shadow:0 28px 70px rgba(0,0,0,.35); font-family:Georgia,serif; }
.devotional-popup__eyebrow { color:#7b3127; font:700 12px Arial,sans-serif; letter-spacing:.13em; text-transform:uppercase; }
.devotional-popup__card h2 { margin:13px 42px 10px 0; color:#5b3a1f; font:32px/1.08 Georgia,serif; }
.devotional-popup__reference { margin:0 0 15px; color:#7b3127; font:700 15px Arial,sans-serif; }
.devotional-popup__text { margin:0 0 22px; font-size:17px; line-height:1.58; }
.devotional-popup__link { display:inline-flex; min-height:44px; align-items:center; padding:11px 15px; border-radius:10px; background:#5b3a1f; color:#fff; font:700 14px Arial,sans-serif; text-decoration:none; }
.devotional-popup__close { position:absolute; top:14px; right:14px; min-height:36px; padding:7px 9px; border:1px solid #9c7442; border-radius:8px; background:#fff5d9aa; color:#5b3a1f; font-size:12px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
  .iep-opening { display: none; }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  header .bar, header nav { min-height: 68px; }
  header nav.wrap { flex-wrap: wrap; gap: 10px; padding-block: 11px; }
  header nav .links { display: flex !important; order: 3; width: 100%; flex-wrap: wrap; gap: 7px !important; }
  header nav .links a { padding: 7px 9px; border-radius: 8px; background: rgba(255,255,255,.10); }
  .wrap { width: min(94%, 1120px) !important; }
  .grid, .next-grid, .download-grid { grid-template-columns: 1fr !important; }
  .card, article.card { padding: 20px !important; }
  .devotional-popup__card { padding:28px 22px; }
  h1 { letter-spacing: -.03em; }
  button, .button, .primary, .reset { min-height: 46px; }
}

/* Motion editorial: presença suave, sem comprometer leitura ou acessibilidade. */
.motion-hero { position: relative; overflow: hidden; isolation: isolate; }
.motion-hero::before, .motion-hero::after { content: ""; position: absolute; z-index: 0; border-radius: 50%; pointer-events: none; }
.motion-hero > .wrap { position: relative; z-index: 1; }
.motion-hero::before { width: 38rem; height: 38rem; right: -12rem; top: -20rem; background: radial-gradient(circle, rgba(166, 219, 255, .46), transparent 67%); filter: blur(2px); animation: iep-orbit 6s ease-in-out infinite alternate; }
.motion-hero::after { width: 20rem; height: 20rem; right: 21%; bottom: -13rem; border: 1px solid rgba(220, 244, 255, .42); box-shadow: 0 0 0 28px rgba(220, 244, 255, .09), 0 0 0 56px rgba(220, 244, 255, .06); animation: iep-orbit 4.5s ease-in-out infinite alternate-reverse; }
.motion-chips, .app-benefits { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 28px; }
.motion-chips span, .app-benefits span { display: inline-flex; align-items: center; min-height: 32px; padding: 6px 12px; border-radius: 999px; font-weight: 700; font-size: 13px; letter-spacing: .01em; }
.motion-chips span { border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.10); color: #fff; backdrop-filter: blur(6px); animation: iep-chip 3.6s ease-in-out infinite; }
.motion-chips span:nth-child(2) { animation-delay: .35s; }
.motion-chips span:nth-child(3) { animation-delay: .7s; }
.app-benefits span { color: var(--iep-blue); background: #fff; border: 1px solid #c8def2; box-shadow: 0 5px 14px rgba(6,45,99,.07); }
.download .store { text-decoration: none; position: relative; overflow: hidden; }
.download .store::after { content: ""; position: absolute; inset: 0 auto 0 -130%; width: 54%; background: linear-gradient(90deg, transparent, rgba(255,255,255,.22), transparent); transform: skewX(-20deg); transition: left .6s ease; }
.download .store:hover::after { left: 145%; }
.motion-ready [data-motion] { opacity: 0; transform: translateY(22px); transition: opacity .62s ease, transform .62s cubic-bezier(.2,.9,.25,1); }
.motion-ready [data-motion].is-visible { opacity: 1; transform: none; }
.motion-ready [data-motion-item] { opacity: 0; transform: translateY(14px) scale(.985); transition: opacity .5s ease, transform .5s cubic-bezier(.2,.9,.25,1), box-shadow .2s ease; }
.motion-ready [data-motion-item].is-visible { opacity: 1; transform: none; }
@keyframes iep-orbit { to { transform: translate3d(-32px, 22px, 0) scale(1.12); } }
@keyframes iep-chip { 50% { transform: translateY(-5px); background: rgba(255,255,255,.24); } }
/* Movimento de abertura mais evidente para a página institucional. */
.motion-hero { background-size: 180% 180% !important; animation: iep-hero-shift 8s ease-in-out infinite; }
.motion-hero .eyebrow, .motion-hero h1, .motion-hero p, .motion-hero .actions, .motion-hero .motion-chips { animation: iep-hero-enter .75s cubic-bezier(.18,.88,.26,1) both; }
.motion-hero h1 { animation-delay: .10s; }
.motion-hero p { animation-delay: .20s; }
.motion-hero .actions { animation-delay: .30s; }
.motion-hero .motion-chips { animation-delay: .42s; }
.motion-hero .button:first-child { animation: iep-cta-pulse 2.4s ease-in-out 1.1s infinite; }
@keyframes iep-hero-shift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes iep-hero-enter { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes iep-cta-pulse { 50% { box-shadow: 0 0 0 10px rgba(255,255,255,.14), 0 8px 20px rgba(0,0,0,.18); } }