/* ============================================================
   IntraSGBBe • Belém — Padrão visual Intranet SGB Nacional
   Cores SGB: Azul institucional #154360 + Amarelo #d4ac0d + Branco
   Font Awesome 4.7 via cdnjs | Gov.br pattern
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@300;400;600;700&display=swap');

:root {
  --sgb-blue:       #1a5276;
  --sgb-blue-dark:  #154360;
  --sgb-blue-mid:   #2471a3;
  --sgb-blue-light: #d6eaf8;
  --sgb-yellow:     #d4ac0d;
  --sgb-yellow-bg:  #fef9e7;
  --sgb-green:      #1e8449;
  --text:           #2c3e50;
  --text-muted:     #566573;
  --bg:             #f0f3f4;
  --white:          #ffffff;
  --border:         #d5d8dc;
  --border-light:   #eaecee;
  --radius:         4px;
  --radius-md:      6px;
  --shadow-sm:      0 1px 3px rgba(0,0,0,0.10);
  --shadow:         0 2px 8px rgba(0,0,0,0.14);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; scroll-behavior: smooth; }

body {
  font-family: 'Source Sans Pro', 'Segoe UI', Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  min-height: 100vh;
}

.site { display: flex; flex-direction: column; min-height: 100vh; }

/* ── BARRA GOV.BR ── */
.govbr-bar {
  background: #071D41;
  border-bottom: 3px solid #FFCD07;
  padding: 5px 0;
}
.govbr-bar .inner {
  max-width: 1200px; margin: 0 auto; padding: 0 1rem;
  display: flex; align-items: center; justify-content: space-between;
}
.govbr-brand { display: flex; align-items: center; gap: 0.5rem; text-decoration: none; }
.govbr-brand .gov  { font-size: 0.9rem; font-weight: 700; color: #FFCD07; letter-spacing: 0.04em; }
.govbr-brand .br   { font-size: 0.9rem; font-weight: 700; color: #fff; }
.govbr-brand .pipe { color: rgba(255,255,255,0.3); margin: 0 0.25rem; }
.govbr-brand .inst { font-size: 0.72rem; color: rgba(255,255,255,0.65); }
.govbr-links { display: flex; gap: 1rem; }
.govbr-links a { font-size: 0.68rem; color: rgba(255,255,255,0.6); text-decoration: none; }
.govbr-links a:hover { color: #FFCD07; }

/* ── HEADER ── */
.header {
  background: var(--sgb-blue-dark);
  border-bottom: 4px solid var(--sgb-yellow);
  box-shadow: 0 2px 10px rgba(0,0,0,0.3);
  position: sticky; top: 0; z-index: 200;
}
.header .inner {
  max-width: 1200px; margin: 0 auto; padding: 0 1rem;
  display: flex; align-items: center; justify-content: space-between;
  min-height: 56px; gap: 1rem;
}

/* Logo */
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand-badge {
  width: 42px; height: 42px;
  background: var(--sgb-yellow);
  border-radius: var(--radius);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.brand-badge .sigla { font-size: 0.88rem; font-weight: 900; color: var(--sgb-blue-dark); line-height: 1; letter-spacing: -0.02em; }
.brand-badge .label { font-size: 0.38rem; font-weight: 800; color: var(--sgb-blue-dark); letter-spacing: 0.1em; text-transform: uppercase; }
.brand-info h1   { font-size: 0.98rem; font-weight: 700; color: #fff; line-height: 1.2; }
.brand-info .sub { font-size: 0.68rem; color: rgba(255,255,255,0.5); font-weight: 300; }

/* TopNav */
.topnav { display: flex; align-items: stretch; height: 56px; }
.topnav a {
  display: flex; align-items: center; gap: 0.4rem;
  color: rgba(255,255,255,0.72); text-decoration: none;
  font-size: 0.8rem; font-weight: 600;
  padding: 0 1rem;
  border-bottom: 3px solid transparent;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}
.topnav a i { font-size: 0.85rem; }
.topnav a:hover  { color: #fff; background: rgba(255,255,255,0.07); border-bottom-color: rgba(255,255,255,0.25); }
.topnav a.active { color: #fff; border-bottom-color: var(--sgb-yellow); background: rgba(255,255,255,0.05); }

/* ── CONTAINER ── */
.container {
  max-width: 1200px; margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
  flex: 1; width: 100%;
}

/* ── BREADCRUMB ── */
.breadcrumb { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 1.25rem; display: flex; align-items: center; gap: 0.35rem; flex-wrap: wrap; }
.breadcrumb a { color: var(--sgb-blue-mid); text-decoration: none; font-weight: 600; }
.breadcrumb a:hover { text-decoration: underline; }

/* ── SECTION HEADING ── */
.section-heading {
  display: flex; align-items: center; gap: 0.6rem;
  margin-bottom: 0.85rem; margin-top: 0.5rem;
}
.section-heading::before { content: ''; display: block; width: 4px; height: 18px; background: var(--sgb-yellow); border-radius: 2px; flex-shrink: 0; }
.section-heading h2 { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sgb-blue); white-space: nowrap; }
.section-heading::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ── CARD ── */
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--sgb-blue);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.2rem;
  margin-bottom: 1.1rem;
  box-shadow: var(--shadow-sm);
}
.card-hd {
  display: flex; align-items: flex-start; gap: 0.65rem;
  padding-bottom: 0.8rem; margin-bottom: 0.85rem;
  border-bottom: 1px solid var(--border-light);
}
.card-hd-icon {
  width: 34px; height: 34px; border-radius: var(--radius);
  background: var(--sgb-blue-light); color: var(--sgb-blue);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.card-hd-text h2 { font-size: 0.92rem; font-weight: 700; color: var(--sgb-blue-dark); }
.card-hd-text p  { font-size: 0.76rem; color: var(--text-muted); margin-top: 0.1rem; }

/* ── APP GRID ── */
.app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(185px, 1fr));
  gap: 0.7rem;
}
.app-item {
  display: flex; flex-direction: column; gap: 0.5rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.9rem;
  text-decoration: none; color: var(--text);
  position: relative; overflow: hidden;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.app-item::after {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--sgb-blue);
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.2s;
}
.app-item:hover { border-color: var(--sgb-blue-mid); box-shadow: var(--shadow); transform: translateY(-2px); }
.app-item:hover::after { transform: scaleX(1); }

.app-icon {
  width: 38px; height: 38px; border-radius: var(--radius);
  background: var(--sgb-blue-light); color: var(--sgb-blue);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
}
.app-name { font-size: 0.84rem; font-weight: 700; color: var(--sgb-blue-dark); line-height: 1.3; }
.app-desc { font-size: 0.74rem; color: var(--text-muted); line-height: 1.45; flex: 1; }
.app-badge {
  display: inline-flex; align-items: center; gap: 0.2rem;
  font-size: 0.6rem; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; padding: 0.18rem 0.5rem;
  border-radius: 99px; width: fit-content; margin-top: auto;
}
.badge-app     { background: var(--sgb-blue-light); color: var(--sgb-blue); }
.badge-sistema { background: #d5f5e3;                color: var(--sgb-green); }
.badge-externo { background: var(--sgb-yellow-bg);   color: #7d6608; }

/* ── LINKS LIST ── */
.links-list { display: flex; flex-direction: column; gap: 2px; }
.link-item {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.65rem 0.85rem;
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  text-decoration: none; color: var(--text);
  font-size: 0.84rem; font-weight: 600;
  transition: background 0.12s, border-color 0.12s;
}
.link-item:hover { background: var(--sgb-blue-light); border-color: var(--sgb-blue-mid); }
.link-item .l-icon {
  width: 28px; height: 28px; border-radius: var(--radius);
  background: var(--bg); border: 1px solid var(--border);
  color: var(--sgb-blue);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; flex-shrink: 0;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
}
.link-item:hover .l-icon { background: var(--sgb-blue); color: var(--white); border-color: var(--sgb-blue); }
.link-item .l-text { flex: 1; min-width: 0; }
.link-item .l-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.link-item .l-url  { font-size: 0.69rem; color: var(--text-muted); font-weight: 400; }
.link-item .l-arr  { color: var(--text-muted); font-size: 0.7rem; flex-shrink: 0; transition: transform 0.15s, color 0.15s; }
.link-item:hover .l-arr { color: var(--sgb-blue-mid); transform: translateX(3px); }

/* ── BUTTONS ── */
.row { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.75rem; }
.btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: var(--sgb-blue); color: var(--white);
  text-decoration: none; font-size: 0.8rem; font-weight: 700;
  padding: 0.48rem 0.95rem; border-radius: var(--radius);
  border: 1px solid var(--sgb-blue); cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.btn:hover { background: var(--sgb-blue-mid); border-color: var(--sgb-blue-mid); }
.btn.secondary { background: var(--white); color: var(--sgb-blue); }
.btn.secondary:hover { background: var(--sgb-blue-light); }

/* ── NOTICE ── */
.notice {
  background: var(--sgb-yellow-bg);
  border: 1px solid #f0c040;
  border-left: 4px solid var(--sgb-yellow);
  border-radius: var(--radius);
  padding: 0.65rem 1rem;
  font-size: 0.78rem; color: #5d4037;
  margin-bottom: 1rem;
  display: flex; align-items: flex-start; gap: 0.5rem;
}

/* ── FOOTER ── */
.footer {
  background: var(--sgb-blue-dark);
  border-top: 3px solid var(--sgb-yellow);
  padding: 0.85rem 1rem; margin-top: auto;
}
.footer .inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 0.5rem;
}
.footer p { font-size: 0.72rem; color: rgba(255,255,255,0.55); }
.footer a { color: rgba(255,255,255,0.75); text-decoration: none; }
.footer a:hover { color: var(--sgb-yellow); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .govbr-links { display: none; }
  .header .inner { flex-direction: column; align-items: flex-start; padding: 0.6rem 1rem; min-height: auto; gap: 0; }
  .topnav { height: auto; width: 100%; overflow-x: auto; }
  .topnav a { border-bottom: none; border-top: 2px solid transparent; padding: 0.5rem 0.75rem; font-size: 0.76rem; }
  .topnav a.active { border-top-color: var(--sgb-yellow); }
  .app-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 400px) {
  .app-grid { grid-template-columns: 1fr; }
}
