/* ufoNoticias.com — portal de notícias de ufologia (PT-BR) — v3 */

@font-face {
  font-family: "Space Grotesk";
  src: url("/assets/fonts/space-grotesk.woff2") format("woff2");
  font-weight: 300 700;
  font-display: swap;
}

:root {
  --bg: #0b1020;
  --bg-2: #0e1530;
  --panel: #131c3a;
  --panel-2: #182349;
  --line: #26325e;
  --text: #e9edf9;
  --muted: #a3b0d1;
  --faint: #7c89ad;
  --green: #59e6a4;
  --blue: #7fa8ff;
  --purple: #b3a6ff;
  --pink: #e0a6ff;
  --amber: #ffcf7a;
  --red: #ff8f8f;
  --maxw: 1120px;
  --radius: 14px;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(89, 110, 255, .18), transparent 60%),
    radial-gradient(900px 500px at 10% -5%, rgba(89, 230, 164, .10), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  min-height: 100vh;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { max-width: 100%; display: block; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- Topbar / header ---------- */

.topbar {
  border-bottom: 1px solid var(--line);
  background: rgba(11, 16, 32, .85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar .wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.logo {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -.02em;
  color: var(--text);
  white-space: nowrap;
}
.logo:hover { text-decoration: none; }
.logo .u { color: var(--green); }
.logo .dot { color: var(--faint); font-weight: 400; }

.nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}

.nav a {
  color: var(--muted);
  font-size: .95rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  transition: color .15s ease, background .15s ease;
}
.nav a:hover { color: var(--text); background: var(--panel); text-decoration: none; }
.nav a.active { color: var(--bg); background: var(--green); }

.tagline-bar {
  border-bottom: 1px solid var(--line);
  background: var(--bg-2);
  color: var(--faint);
  font-size: .85rem;
}
.tagline-bar .wrap {
  padding-top: 7px;
  padding-bottom: 7px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: space-between;
}
.tagline-bar strong { color: var(--muted); font-weight: 600; }
.tagline-bar .hoje { text-transform: capitalize; }

/* ---------- Ticker de últimas ---------- */

.ticker {
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(89,230,164,.07), rgba(127,168,255,.05) 40%, transparent);
  overflow: hidden;
  position: relative;
}
.ticker .label {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  display: flex;
  align-items: center;
  padding: 0 14px 0 20px;
  background: var(--bg-2);
  border-right: 1px solid var(--line);
  color: var(--green);
  font-family: var(--display);
  font-weight: 700;
  font-size: .78rem;
  letter-spacing: .14em;
  z-index: 2;
}
.ticker-viewport { margin-left: 118px; overflow: hidden; }
.ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 44px;
  padding: 8px 0;
  white-space: nowrap;
  animation: ticker-roll 55s linear infinite;
  will-change: transform;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-track a {
  color: var(--muted);
  font-size: .86rem;
}
.ticker-track a:hover { color: var(--text); }
.ticker-track a::before {
  content: "◆";
  color: var(--green);
  font-size: .6rem;
  margin-right: 10px;
  vertical-align: 1px;
}
@keyframes ticker-roll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
}

/* ---------- Section headings ---------- */

.section-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 46px 0 20px;
}
.section-head h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: -.01em;
  display: flex;
  align-items: center;
  gap: 12px;
}
.section-head h2::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--green);
  transform: rotate(45deg);
  flex-shrink: 0;
}
.section-head.acc-gov h2::before { background: var(--blue); }
.section-head.acc-brasil h2::before { background: var(--green); }
.section-head.acc-mundo h2::before { background: var(--purple); }
.section-head.acc-ciencia h2::before { background: var(--pink); }
.section-head .rule { flex: 1; height: 1px; background: var(--line); }
.section-head .more { font-size: .9rem; color: var(--faint); white-space: nowrap; }

/* ---------- Hero (destaque + últimas) ---------- */

.hero {
  display: grid;
  grid-template-columns: 1.6fr .9fr;
  gap: 24px;
  margin-top: 30px;
  position: relative;
}

.hero-main {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.hero-main:hover {
  border-color: #35468c;
  box-shadow: 0 18px 44px rgba(4, 8, 20, .5);
}

.hero-main .cover { aspect-ratio: 16 / 7.5; }

.hero-main .body { padding: 22px 26px 26px; }

.hero-main h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.8rem;
  line-height: 1.22;
  letter-spacing: -.015em;
  margin: 10px 0 12px;
}
.hero-main h1 a { color: var(--text); }
.hero-main p.lead { color: var(--muted); font-size: 1.02rem; }

/* coluna de últimas */
.latest {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
}
.latest-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--green);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 8px;
}
.latest-title::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 10px var(--green);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .35; }
}
@media (prefers-reduced-motion: reduce) {
  .latest-title::before { animation: none; }
}
.latest-list {
  list-style: none;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.latest-list li {
  padding: 12px 0;
  border-bottom: 1px solid rgba(38, 50, 94, .55);
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.latest-list li:last-child { border-bottom: none; }
.latest-list a {
  color: var(--text);
  font-size: .93rem;
  font-weight: 600;
  line-height: 1.42;
}
.latest-list a:hover { color: var(--green); text-decoration: none; }
.latest-list time { font-size: .76rem; color: var(--faint); }
.latest-rss {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: .84rem;
  color: var(--faint);
}
.latest-rss:hover { color: var(--green); text-decoration: none; }

/* ---------- Cards grid ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: #35468c;
  box-shadow: 0 16px 36px rgba(4, 8, 20, .45);
}

.card .cover { aspect-ratio: 16 / 8; }

.card .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }

.card h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.38;
  letter-spacing: -.01em;
}
.card h3 a { color: var(--text); }
.card p.excerpt { color: var(--muted); font-size: .93rem; flex: 1; }

/* card destaque de seção (largura dupla, layout horizontal) */
@media (min-width: 760px) {
  .card--wide { grid-column: span 2; flex-direction: row; }
  .card--wide > a {
    width: 46%;
    flex-shrink: 0;
    position: relative;
    min-height: 280px;
    display: block;
  }
  .card--wide > a .cover {
    position: absolute;
    inset: 0;
    aspect-ratio: auto;
    height: 100%;
  }
  .card--wide .body { padding: 22px 24px; justify-content: center; }
  .card--wide h3 { font-size: 1.3rem; line-height: 1.3; }
  .card--wide p.excerpt { flex: 0 0 auto; margin-top: 4px; }
}

/* ---------- Covers ---------- */

.cover {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.cover svg.art { width: 34%; height: auto; opacity: .95; }
.cover.gov   { background: linear-gradient(135deg, #16204a 0%, #232f6b 55%, #16204a 100%); }
.cover.brasil{ background: linear-gradient(135deg, #0d3b2e 0%, #14584a 55%, #0d3b2e 100%); }
.cover.mundo { background: linear-gradient(135deg, #263056 0%, #3b3f7d 55%, #263056 100%); }
.cover.ciencia{ background: linear-gradient(135deg, #331f4f 0%, #4b2e73 55%, #331f4f 100%); }
.cover.analise{ background: linear-gradient(135deg, #3a2a14 0%, #5a4420 55%, #3a2a14 100%); }
.cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 25%, rgba(255,255,255,.14) 0 1.5px, transparent 2px),
    radial-gradient(circle at 70% 15%, rgba(255,255,255,.12) 0 1px, transparent 1.6px),
    radial-gradient(circle at 85% 60%, rgba(255,255,255,.10) 0 1.4px, transparent 2px),
    radial-gradient(circle at 40% 75%, rgba(255,255,255,.10) 0 1px, transparent 1.6px),
    radial-gradient(circle at 55% 40%, rgba(255,255,255,.08) 0 1px, transparent 1.5px);
  pointer-events: none;
}

/* capas com fotografia */
figure.cover { margin: 0; }
.cover img.photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cover.has-img::after {
  background: linear-gradient(180deg, rgba(11,16,32,0) 55%, rgba(11,16,32,.45) 100%);
}
.card .cover.has-img img.photo,
.hero-main .cover.has-img img.photo { transition: transform .3s ease; }
.card:hover .cover.has-img img.photo,
.hero-main:hover .cover.has-img img.photo { transform: scale(1.045); }
.img-credit {
  position: absolute;
  right: 10px;
  bottom: 8px;
  z-index: 2;
  font-size: .68rem;
  line-height: 1.3;
  color: rgba(255,255,255,.88);
  background: rgba(8,12,24,.6);
  padding: 2px 10px;
  border-radius: 999px;
  max-width: 92%;
}
.img-credit a { color: inherit; }

/* ---------- Meta / badges ---------- */

.meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .8rem;
  color: var(--faint);
  flex-wrap: wrap;
}

.badge {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid;
}
.badge.gov     { color: var(--blue);  border-color: rgba(127,168,255,.45); background: rgba(127,168,255,.09); }
.badge.brasil  { color: var(--green); border-color: rgba(89,230,164,.45);  background: rgba(89,230,164,.09); }
.badge.mundo   { color: var(--purple); border-color: rgba(179,166,255,.45); background: rgba(179,166,255,.09); }
.badge.ciencia { color: var(--pink);  border-color: rgba(224,166,255,.45); background: rgba(224,166,255,.09); }
.badge.analise { color: var(--amber); border-color: rgba(255,207,122,.45); background: rgba(255,207,122,.09); }

/* ---------- Article page ---------- */

.article {
  max-width: 760px;
  margin: 36px auto 60px;
  padding: 0 20px;
}

.article .cover {
  aspect-ratio: 16 / 6.5;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin: 22px 0 8px;
}

.article header h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 2.05rem;
  line-height: 1.22;
  letter-spacing: -.02em;
  margin: 14px 0 10px;
}

.article header .subtitle {
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.55;
}

.article .byline {
  display: flex;
  gap: 10px;
  align-items: center;
  color: var(--faint);
  font-size: .88rem;
  margin: 16px 0 8px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}

.article .content { font-family: var(--serif); font-size: 1.1rem; line-height: 1.85; }
.article .content p { margin: 18px 0; }
.article .content h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: -.01em;
  margin: 34px 0 6px;
}
.article .content ul, .article .content ol { margin: 18px 0 18px 26px; }
.article .content li { margin: 8px 0; }
.article .content blockquote {
  border-left: 3px solid var(--green);
  padding: 6px 0 6px 18px;
  margin: 22px 0;
  color: var(--muted);
  font-style: italic;
}
.article .content strong { color: var(--text); }

.sources {
  margin-top: 36px;
  padding: 18px 22px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: .92rem;
}
.sources h2 { font-size: 1rem; margin-bottom: 8px; font-family: var(--display); }
.sources ul { list-style: none; margin: 0; }
.sources li { margin: 6px 0; padding-left: 18px; position: relative; }
.sources li::before { content: "↗"; position: absolute; left: 0; color: var(--green); }

.article-nav {
  max-width: 760px;
  margin: 0 auto 70px;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.article-nav a {
  color: var(--muted);
  font-size: .92rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 16px;
  transition: color .15s ease, border-color .15s ease;
}
.article-nav a:hover { color: var(--text); border-color: #35468c; text-decoration: none; }

/* ---------- Info boxes / about ---------- */

.notice {
  margin: 34px 0;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--amber);
  border-radius: 10px;
  background: var(--panel);
  color: var(--muted);
  font-size: .93rem;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  margin: 24px 0 10px;
}
.about-grid .item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.about-grid .item h3 { font-size: 1.02rem; margin-bottom: 6px; font-family: var(--display); }
.about-grid .item p { color: var(--muted); font-size: .93rem; }

/* ---------- Footer ---------- */

footer {
  margin-top: 70px;
  border-top: 1px solid var(--line);
  background: var(--bg-2);
}
footer .wrap {
  padding: 30px 20px 40px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  color: var(--faint);
  font-size: .88rem;
}
footer .cols { display: flex; gap: 60px; flex-wrap: wrap; }
footer h4 { color: var(--muted); font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 10px; font-family: var(--display); }
footer ul { list-style: none; }
footer li { margin: 6px 0; }
footer a { color: var(--faint); }
footer a:hover { color: var(--text); }

/* ---------- Responsivo ---------- */

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .topbar .wrap { flex-wrap: wrap; gap: 10px; }
  .nav { margin-left: 0; width: 100%; justify-content: flex-start; }
  .hero-main h1 { font-size: 1.42rem; }
  .article header h1 { font-size: 1.55rem; }
  .ticker .label { position: static; padding: 8px 0 0 20px; border: none; background: none; }
  .ticker-viewport { margin-left: 0; }
}
