:root {
  --orange: #EF6A1B;
  --orange-dark: #D6560D;
  --orange-light: #FFF1E6;
  /* Sampled from the uploaded logo artwork's background fill — the site
     header uses this (not --orange) so the reduced logomark blends into
     the bar instead of showing a seam. The artwork's PNG carries an
     embedded Display P3 profile (it's a Mac screenshot), so the raw pixel
     read (#C76927) rendered differently than the color-managed image
     actually painted on screen — #D56200 is the correct sRGB equivalent,
     confirmed against the color-managed export now used for the logo file
     itself (public/assets/img/gfc-logo-header.png).  */
  --orange-header: #D56200;
  /* The portal ("Minha GFC") uses a solid black bar instead of orange —
     an intentional visual signal that you're in the logged-in area, using
     the black logo variant (gfc-logo-header-black.png) supplied for it. */
  --header-portal: #000000;
  --navy: #14161C;
  --navy-2: #1C1F28;
  --navy-3: #24272F;
  --line-dark: #2E323C;
  --text-muted: #8B8F99;
  --green: #22C55E;
}

* { box-sizing: border-box; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.bg-brand-orange { background-color: var(--orange); }
.bg-brand-orange-dark { background-color: var(--orange-dark); }
.bg-brand-orange-light { background-color: var(--orange-light); }
.text-brand-orange { color: var(--orange); }
.border-brand-orange { border-color: var(--orange); }

.bg-navy { background-color: var(--navy); }
.bg-navy-2 { background-color: var(--navy-2); }
.bg-navy-3 { background-color: var(--navy-3); }
.border-navy-line { border-color: var(--line-dark); }
.text-muted-dark { color: var(--text-muted); }

.btn-primary {
  background-color: var(--orange);
  color: #fff;
  font-weight: 600;
  border-radius: 12px;
  padding: 14px 20px;
  text-align: center;
  transition: background-color .15s ease;
}
.btn-primary:hover { background-color: var(--orange-dark); }

.btn-outline {
  background-color: transparent;
  border: 1.5px solid #E5E7EB;
  color: #14161C;
  font-weight: 600;
  border-radius: 12px;
  padding: 14px 20px;
  text-align: center;
}

.btn-outline-dark {
  background-color: transparent;
  border: 1.5px solid var(--line-dark);
  color: #fff;
  font-weight: 600;
  border-radius: 12px;
  padding: 10px 16px;
  text-align: center;
}

.card {
  background: #fff;
  border: 1px solid #EEF0F2;
  border-radius: 16px;
}

.card-navy {
  background: var(--navy-2);
  border: 1px solid var(--line-dark);
  border-radius: 16px;
}

.progress-track {
  height: 8px;
  border-radius: 999px;
  background: #EEF0F2;
  overflow: hidden;
}
.progress-track-dark {
  height: 8px;
  border-radius: 999px;
  background: var(--navy-3);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 999px;
}

.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: #fff;
  border-top: 1px solid #EEF0F2;
  padding: 8px 4px calc(env(safe-area-inset-bottom, 0px) + 8px);
  z-index: 40;
}
.bottom-nav-dark {
  background: var(--navy-2);
  border-top: 1px solid var(--line-dark);
}
.bottom-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: #9CA3AF;
  flex: 1;
  padding: 4px 0;
}
.bottom-nav a.active { color: var(--orange); font-weight: 600; }
.bottom-nav-dark a { color: #6B7280; }
.bottom-nav-dark a.active { color: var(--orange); }

.tab-btn {
  padding: 8px 4px;
  font-weight: 600;
  font-size: 14px;
  color: #9CA3AF;
  border-bottom: 2px solid transparent;
}
.tab-btn.active {
  color: var(--orange);
  border-bottom-color: var(--orange);
}

.page-wrap {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
  padding-bottom: 96px;
}

/* The logo now fills 95% of the header bar's own height (per feedback —
   it read as too small before) instead of a fixed small pixel size. That
   needs the bar itself to have a DEFINITE height to size a percentage
   against, so mobile-header/desktop-nav get an explicit height here and
   their Tailwind vertical padding (py-4 / the 18px in the desktop-nav
   rule below) is zeroed out — horizontal padding is untouched. Every
   !important is defensive: a same-specificity rule earlier in this file
   already lost a cascade fight against the Tailwind CDN's runtime-
   injected base styles once (see the git history on this file), so
   nothing here is left to source order. */
.mobile-header {
  height: 64px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
.header-logo-link {
  display: inline-flex;
  align-items: center;
  height: 100%;
}
.header-logo {
  height: 95% !important;
  width: auto !important;
  max-width: none !important;
  display: block !important;
}

/* The header/menu itself — mobile-header and desktop-nav — painted the
   logo's own orange so the reduced mark drops in seamlessly, per feedback:
   a separate white bar read as two different things stacked. (.desktop-nav's
   own background/link-color rules are edited in place further down, since a
   second same-specificity rule here would just lose the cascade to them.) */
.mobile-header {
  background: var(--orange-header);
}
.mobile-header a,
.mobile-header button {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45) !important;
}
.desktop-nav > div a:not(.btn-primary),
.desktop-nav > div button {
  color: rgba(255, 255, 255, 0.9);
}
.desktop-nav .btn-primary {
  background: #fff;
  color: var(--orange-header);
}
.desktop-nav .btn-primary:hover { opacity: 0.9; }
.desktop-nav button[aria-label="Notificações"],
.desktop-nav button[aria-label="Menu"] {
  border-color: rgba(255, 255, 255, 0.45) !important;
}

/* "You're logged in" mode — solid black instead of orange. Always on for
   the Next.js /portal/* pages (PortalShell adds this class directly, since
   middleware guarantees a session there); toggled by app.js on the static
   pages when a session is detected, so the header stops reverting to the
   public look the moment you click through to e.g. escola-biblica.html. */
.mobile-header.header-dark,
.desktop-nav.header-dark {
  background: var(--header-portal);
}
.desktop-nav.header-dark .btn-primary {
  color: var(--header-portal);
}

/* Real-photo avatar swapped in by app.js (replaces the static "R" circle)
   once a session is confirmed. */
.header-avatar {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  object-fit: cover;
  display: block;
}
.header-signout {
  color: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  font-weight: 700;
}

/* ---- Desktop layout ---- */
@media (min-width: 768px) {
  .page-wrap {
    max-width: none;
    padding-bottom: 0;
  }
  .page-wrap.wrap-marketing { max-width: none; }
  .mobile-header { display: none !important; }
  .bottom-nav { display: none !important; }

  .shell { max-width: 1180px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }
  .shell-narrow { max-width: 720px; margin: 0 auto; padding-left: 32px; padding-right: 32px; }
  .shell-wide { max-width: 1320px; margin: 0 auto; padding-left: 40px; padding-right: 40px; }

  .desktop-nav { display: flex; }
  .desktop-hidden { display: none !important; }
}
@media (max-width: 767.98px) {
  .desktop-nav { display: none; }
  .shell, .shell-narrow, .shell-wide { max-width: none; }
}

.desktop-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  padding: 0 40px;
  background: var(--orange-header);
  border-bottom: none;
}
.desktop-nav-dark {
  background: var(--navy);
  border-bottom: 1px solid var(--line-dark);
}
.desktop-nav-links { display: flex; align-items: center; gap: 28px; }
.desktop-nav-links a {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .02em;
  color: rgba(255, 255, 255, 0.85);
}
.desktop-nav-links a:hover { color: #fff; }
.desktop-nav-dark .desktop-nav-links a { color: #C7CAD1; }
.desktop-nav-dark .desktop-nav-links a:hover { color: var(--orange); }
.desktop-nav-links a.active { color: #fff; font-weight: 700; }

.dashboard-layout { display: block; }
@media (min-width: 1024px) {
  .dashboard-layout { display: grid; grid-template-columns: 232px 1fr; align-items: start; gap: 28px; }
}
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 10px;
  font-size: 13px; font-weight: 600; color: #9CA3AF;
}
.sidebar-nav a.active { background: var(--navy-3); color: #fff; }
.sidebar-nav a:hover { color: #fff; }

.hero-photo {
  background: linear-gradient(180deg, rgba(20,22,28,.15) 0%, rgba(20,22,28,.85) 100%),
              radial-gradient(circle at 30% 20%, #3a3f4d, #14161c 70%);
}

.hero-building {
  background: linear-gradient(180deg, rgba(20,22,28,.05) 0%, rgba(20,22,28,.75) 100%), url('../img/gfc-fachada.jpg');
  background-size: cover;
  background-position: center;
}

.hero-building-top {
  background: url('../img/gfc-fachada.jpg');
  background-size: cover;
  background-position: center 22%;
}

.grid-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
}

.form-panel { }
@media (min-width: 768px) {
  .form-panel {
    background: #fff;
    border: 1px solid #EEF0F2;
    border-radius: 20px;
    padding: 40px;
  }
}

.info-panel { }
@media (min-width: 768px) {
  .info-panel {
    border: none;
    background: var(--orange-light);
  }
}

.pillar-icon {
  width: 64px; height: 64px;
  border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
}
@media (min-width: 768px) {
  .pillar-icon { width: 76px; height: 76px; font-size: 34px; border-radius: 22px; }
}

.stub-wrap {
  min-height: 60vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
}
