/* ═══════════════════════════════════════════════
   GOING NORTH — educacao.css
   Estilos exclusivos da página de educação financeira.
   ═══════════════════════════════════════════════ */

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, var(--nav-bg) 0%, #003d2a 55%, #002b1e 100%);
  padding: 48px 32px 56px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -80px; right: -60px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(26,171,94,.15) 0%, transparent 65%);
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -60px; left: 10%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(13,148,136,.10) 0%, transparent 65%);
  pointer-events: none;
}
.hero-inner { max-width: 1300px; margin: 0 auto; }

/* Etiqueta animada no hero */
.hero-tag { display: inline-flex; align-items: center; gap: 7px; background: rgba(26,171,94,.15); border: 1px solid rgba(26,171,94,.3); border-radius: 20px; padding: 5px 14px; font-size: .75rem; font-weight: 600; color: #4ade80; margin-bottom: 18px; letter-spacing: .04em; }
.hero-tag-dot { width: 5px; height: 5px; border-radius: 50%; background: #4ade80; animation: blink 2s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }

.hero h1       { font-family: var(--font-d); font-size: 2.4rem; font-weight: 800; color: #fff; line-height: 1.15; margin-bottom: 14px; }
.hero h1 span  { color: #4ade80; }
.hero p        { color: rgba(255,255,255,.6); font-size: .95rem; line-height: 1.7; max-width: 560px; margin-bottom: 32px; }

/* Estatísticas no hero */
.hero-stats  { display: flex; gap: 32px; flex-wrap: wrap; }
.hstat       { display: flex; flex-direction: column; }
.hstat-num   { font-family: var(--font-d); font-size: 1.5rem; font-weight: 800; color: #4ade80; }
.hstat-label { font-size: .76rem; color: rgba(255,255,255,.45); margin-top: 2px; }

/* ── Barra de busca flutuante ── */
.search-wrap { max-width: 1300px; margin: 0 auto; padding: 0 32px; transform: translateY(-22px); }
.search-box  { background: #fff; border-radius: 14px; box-shadow: 0 8px 32px rgba(0,0,0,.12); display: flex; align-items: center; overflow: hidden; border: 1.5px solid var(--border); }
.search-box input           { flex: 1; padding: 16px 20px; font-size: .93rem; font-family: var(--font-b); color: var(--text); border: none; outline: none; }
.search-box input::placeholder { color: var(--text3); }
.search-btn  { background: var(--green); color: #fff; border: none; padding: 14px 28px; font-size: .88rem; font-weight: 600; cursor: pointer; font-family: var(--font-b); transition: background .2s; display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.search-btn:hover { background: var(--green-h); }

/* ── Layout principal ── */
.main { max-width: 1300px; margin: 0 auto; padding: 0 32px 60px; }

/* Cabeçalho de cada seção */
.sec-head      { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; flex-wrap: wrap; gap: 10px; }
.sec-title     { font-family: var(--font-d); font-size: 1.1rem; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 10px; }
.sec-title-dot { width: 8px; height: 8px; border-radius: 2px; background: var(--green); }
.sec-link      { font-size: .82rem; color: var(--green); font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 4px; }

/* ── Cards de trilhas ── */
.trilhas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-bottom: 44px; }
.trilha-card  {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 24px;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: all .25s;
  position: relative;
  overflow: hidden;
}
/* Barra colorida no topo de cada trilha (cor via CSS custom property --c) */
.trilha-card::before    { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--c, var(--green)); }
.trilha-card:hover      { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--c, var(--green)); }
.trilha-badge           { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 20px; font-size: .72rem; font-weight: 700; letter-spacing: .04em; margin-bottom: 14px; background: var(--cb, rgba(26,171,94,.1)); color: var(--c, var(--green)); }
.trilha-icon            { font-size: 2rem; margin-bottom: 10px; display: block; }
.trilha-name            { font-family: var(--font-d); font-size: 1rem; font-weight: 700; color: var(--text); margin-bottom: 6px; }
.trilha-desc            { font-size: .82rem; color: var(--text3); line-height: 1.6; margin-bottom: 16px; }
.trilha-topics          { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.trilha-topic           { display: flex; align-items: center; gap: 8px; font-size: .8rem; color: var(--text2); padding: 6px 10px; background: var(--surface2); border-radius: 8px; cursor: pointer; transition: background .15s; }
.trilha-topic:hover     { background: var(--green-light); }
.trilha-topic-dot       { width: 6px; height: 6px; border-radius: 50%; background: var(--c, var(--green)); flex-shrink: 0; }
.trilha-footer          { display: flex; align-items: center; justify-content: space-between; font-size: .76rem; color: var(--text3); }

/* ── Modal/reader de artigo ── */
.reader-overlay       { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 500; display: none; align-items: flex-start; justify-content: center; padding: 40px 20px; overflow-y: auto; backdrop-filter: blur(4px); }
.reader-overlay.open  { display: flex; }
.reader               { background: #fff; border-radius: var(--r-xl); width: 100%; max-width: 760px; min-height: 300px; position: relative; animation: slideUp .3s ease; }
@keyframes slideUp    { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
.reader-head          { padding: 28px 32px 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.reader-close         { width: 34px; height: 34px; border-radius: 50%; background: var(--surface2); border: none; cursor: pointer; font-size: 1rem; color: var(--text3); flex-shrink: 0; transition: all .2s; display: flex; align-items: center; justify-content: center; }
.reader-close:hover   { background: var(--border); color: var(--text); }
.reader-meta          { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.reader-badge         { font-size: .72rem; font-weight: 700; padding: 3px 10px; border-radius: 20px; }
.reader-time          { font-size: .75rem; color: var(--text3); }
.reader-title         { font-family: var(--font-d); font-size: 1.5rem; font-weight: 800; color: var(--text); line-height: 1.3; }

/* Corpo do artigo */
.reader-body          { padding: 20px 32px 32px; font-family: var(--font-s); font-size: .95rem; line-height: 1.85; color: var(--text2); }
.reader-body h2       { font-family: var(--font-d); font-size: 1.05rem; font-weight: 700; color: var(--text); margin: 24px 0 10px; }
.reader-body h3       { font-family: var(--font-d); font-size: .93rem; font-weight: 600; color: var(--text2); margin: 18px 0 8px; }
.reader-body p        { margin-bottom: 14px; }
.reader-body ul,
.reader-body ol       { padding-left: 20px; margin-bottom: 14px; }
.reader-body li       { margin-bottom: 6px; }
.reader-body strong   { color: var(--text); font-weight: 600; }
.reader-body .highlight { background: rgba(26,171,94,.08); border-left: 3px solid var(--green); padding: 12px 16px; border-radius: 0 8px 8px 0; margin: 16px 0; font-style: italic; }

/* Estado de carregamento do artigo */
.reader-loading            { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 32px; gap: 16px; color: var(--text3); }
.reader-loading .dots      { display: flex; gap: 6px; }
.reader-loading .dot       { width: 8px; height: 8px; border-radius: 50%; background: var(--green); animation: dotPulse 1.2s infinite; }
.reader-loading .dot:nth-child(2) { animation-delay: .2s; }
.reader-loading .dot:nth-child(3) { animation-delay: .4s; }
@keyframes dotPulse { 0%, 80%, 100% { transform: scale(.6); opacity: .3; } 40% { transform: scale(1); opacity: 1; } }

/* ── Glossário ── */
.gloss-search   { display: flex; gap: 10px; margin-bottom: 20px; }
.gloss-input    { flex: 1; padding: 11px 16px; border: 1.5px solid var(--border); border-radius: 10px; font-size: .87rem; font-family: var(--font-b); color: var(--text); outline: none; transition: border .2s; }
.gloss-input:focus { border-color: var(--green); }
.gloss-alphabet { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.gloss-letter   { width: 32px; height: 32px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); font-size: .8rem; font-weight: 600; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all .2s; color: var(--text2); }
.gloss-letter:hover,
.gloss-letter.active { background: var(--green); color: #fff; border-color: var(--green); }
.gloss-grid     { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.gloss-item     { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 16px 18px; cursor: pointer; transition: all .2s; }
.gloss-item:hover { border-color: var(--green); box-shadow: var(--shadow); }
.gloss-term     { font-family: var(--font-d); font-size: .9rem; font-weight: 700; color: var(--text); margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.gloss-preview  { font-size: .79rem; color: var(--text3); line-height: 1.5; }
.gloss-tag      { font-size: .68rem; font-weight: 600; padding: 2px 7px; border-radius: 20px; background: var(--green-light); color: var(--green); }

/* ── Card de artigo em destaque ── */
.featured-grid        { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; margin-bottom: 44px; }
.featured-main        { background: var(--surface); border-radius: var(--r-xl); overflow: hidden; box-shadow: var(--shadow); cursor: pointer; transition: all .25s; }
.featured-main:hover  { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.featured-banner      { height: 200px; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.featured-banner-icon { font-size: 4rem; position: relative; z-index: 1; }
.featured-main-body   { padding: 22px 24px; }
.featured-cat         { font-size: .72rem; font-weight: 700; letter-spacing: .06em; color: var(--green); text-transform: uppercase; margin-bottom: 8px; }
.featured-title       { font-family: var(--font-d); font-size: 1.1rem; font-weight: 700; color: var(--text); line-height: 1.35; margin-bottom: 8px; }
.featured-excerpt     { font-size: .82rem; color: var(--text3); line-height: 1.6; margin-bottom: 14px; }
.featured-footer      { display: flex; align-items: center; gap: 10px; font-size: .76rem; color: var(--text3); }
.featured-side        { display: flex; flex-direction: column; gap: 12px; }
.side-article         { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px 18px; cursor: pointer; transition: all .2s; display: flex; gap: 12px; align-items: flex-start; }
.side-article:hover   { border-color: var(--green); box-shadow: var(--shadow); }
.side-article-icon    { font-size: 1.6rem; flex-shrink: 0; }
.side-article-title   { font-family: var(--font-d); font-size: .85rem; font-weight: 700; color: var(--text); line-height: 1.3; margin-bottom: 4px; }
.side-article-cat     { font-size: .72rem; color: var(--text3); }

/* ── Toast de feedback ── */
.toast      { position: fixed; bottom: 28px; right: 28px; background: var(--nav-bg); color: #fff; padding: 13px 20px; border-radius: 12px; font-size: .86rem; font-weight: 500; box-shadow: var(--shadow-md); z-index: 9999; transform: translateY(80px); opacity: 0; transition: all .3s; display: flex; align-items: center; gap: 10px; }
.toast.show { transform: translateY(0); opacity: 1; }
.toast-icon { color: var(--green); }

/* ── Responsivo ── */
@media (max-width: 1100px) {
  .trilhas-grid  { grid-template-columns: 1fr 1fr; }
  .featured-grid { grid-template-columns: 1fr; }
  .gloss-grid    { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .trilhas-grid { grid-template-columns: 1fr; }
  .main         { padding: 0 16px 48px; }
  .hero         { padding: 32px 16px 44px; }
  .search-wrap  { padding: 0 16px; }
  .navbar       { padding: 0 16px; }
  .nav-links    { display: none; }
}
