/* ===================================================================
   radar.css — Identidade Visual Radar Eleitoral IA
   Seção de acompanhamento eleitoral com IA
   =================================================================== */

/* ---- Radar Gradient Variables ---- */
:root {
  --radar-gradient-1: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
  --radar-gradient-2: linear-gradient(135deg, #1a1a3e, #0d0d1a);
  --radar-accent: #4fc3f7;
  --radar-accent-2: #7c4dff;
  --radar-accent-glow: rgba(79, 195, 247, 0.15);
  --radar-green: #00e676;
  --radar-orange: #ffab00;
  --radar-red: #ff5252;
  --radar-surface: rgba(15, 12, 41, 0.6);
  --radar-border: rgba(79, 195, 247, 0.15);
}

[data-theme='light'] {
  --radar-gradient-1: linear-gradient(135deg, #e8eaf6, #c5cae9, #e8eaf6);
  --radar-gradient-2: linear-gradient(135deg, #f5f5ff, #e8eaf6);
  --radar-accent: #1565c0;
  --radar-accent-2: #5c6bc0;
  --radar-accent-glow: rgba(21, 101, 192, 0.1);
  --radar-surface: rgba(255, 255, 255, 0.8);
  --radar-border: rgba(21, 101, 192, 0.15);
}

/* ---- Radar Header ---- */
.radar-header {
  text-align: center;
  padding: 60px 0 40px;
  position: relative;
  overflow: hidden;
}
.radar-header::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 50% 50%, var(--radar-accent-glow) 0%, transparent 70%);
  animation: radarPulse 4s ease-in-out infinite;
  pointer-events: none;
}
@keyframes radarPulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.05); }
}

.radar-logo {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}
.radar-logo-icon {
  width: 48px;
  height: 48px;
  background: var(--radar-gradient-1);
  border: 2px solid var(--radar-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  box-shadow: 0 0 30px var(--radar-accent-glow);
  position: relative;
}
.radar-logo-icon::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--radar-accent);
  animation: radarRing 2s ease-out infinite;
}
@keyframes radarRing {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 0; }
}
.radar-logo-text {
  text-align: left;
}
.radar-logo-text h1 {
  font-size: 1.8rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--radar-accent), var(--radar-accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
  margin: 0;
}
.radar-logo-text .subtitle {
  font-size: 0.8rem;
  color: var(--text-2);
  letter-spacing: 1px;
  font-weight: 500;
  text-transform: uppercase;
}

.radar-tagline {
  font-size: 1.05rem;
  color: var(--text-2);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ---- Radar Badge ---- */
.radar-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--radar-accent-glow);
  border: 1px solid var(--radar-border);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 0.78rem;
  color: var(--radar-accent);
  font-weight: 500;
  margin-bottom: 24px;
}
.radar-badge .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--radar-green);
  display: inline-block;
  animation: radarDotPulse 1.5s ease-in-out infinite;
}
@keyframes radarDotPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* ---- Info Section ---- */
.radar-section {
  padding: 48px 0;
}
.radar-section-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--radar-accent);
  font-weight: 600;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.radar-section-title {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text);
}
.radar-section-text {
  color: var(--text-2);
  font-size: 0.95rem;
  line-height: 1.7;
  max-width: 720px;
}

/* ---- How It Works Timeline ---- */
.radar-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  padding-left: 40px;
  max-width: 700px;
}
.radar-timeline::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--radar-accent), var(--radar-accent-2), transparent);
}
.radar-timeline-item {
  position: relative;
  padding: 20px 0 20px 24px;
  opacity: 0;
  transform: translateX(-20px);
  animation: radarFadeIn 0.5s ease forwards;
}
.radar-timeline-item:nth-child(1) { animation-delay: 0.1s; }
.radar-timeline-item:nth-child(2) { animation-delay: 0.2s; }
.radar-timeline-item:nth-child(3) { animation-delay: 0.3s; }
.radar-timeline-item:nth-child(4) { animation-delay: 0.4s; }
.radar-timeline-item:nth-child(5) { animation-delay: 0.5s; }
@keyframes radarFadeIn {
  to { opacity: 1; transform: translateX(0); }
}
.radar-timeline-item::before {
  content: '';
  position: absolute;
  left: -32px;
  top: 24px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--radar-accent);
  border: 3px solid var(--bg);
  box-shadow: 0 0 12px var(--radar-accent-glow);
}
.radar-timeline-step {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--radar-accent);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}
.radar-timeline-item h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 4px;
}
.radar-timeline-item p {
  font-size: 0.85rem;
  color: var(--text-2);
  line-height: 1.5;
}

/* ---- Radar Cards Grid ---- */
.radar-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.radar-card {
  background: var(--radar-surface);
  border: 1px solid var(--radar-border);
  border-radius: var(--radius);
  padding: 28px;
  backdrop-filter: blur(12px);
  transition: all 0.3s ease;
}
.radar-card:hover {
  transform: translateY(-4px);
  border-color: var(--radar-accent);
  box-shadow: 0 12px 40px var(--radar-accent-glow);
}
.radar-card .icon {
  font-size: 2rem;
  margin-bottom: 12px;
}
.radar-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.radar-card p {
  font-size: 0.85rem;
  color: var(--text-2);
  line-height: 1.6;
  margin-bottom: 12px;
}
.radar-card .radar-card-link {
  color: var(--radar-accent);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s;
}
.radar-card .radar-card-link:hover { gap: 10px; }

/* ---- FAQ Accordion ---- */
.radar-faq {
  max-width: 720px;
}
.radar-faq-item {
  border: 1px solid var(--radar-border);
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.radar-faq-item:hover {
  border-color: var(--radar-accent);
}
.radar-faq-question {
  width: 100%;
  background: var(--radar-surface);
  border: none;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 16px 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  font-family: var(--font);
  transition: background 0.2s;
}
.radar-faq-question:hover {
  background: var(--surface-2);
}
.radar-faq-question .faq-icon {
  font-size: 1.2rem;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}
.radar-faq-item.open .radar-faq-question .faq-icon {
  transform: rotate(45deg);
}
.radar-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 20px;
  font-size: 0.87rem;
  color: var(--text-2);
  line-height: 1.6;
}
.radar-faq-item.open .radar-faq-answer {
  max-height: 300px;
  padding: 0 20px 16px;
}

/* ---- Email Capture ---- */
.radar-newsletter {
  background: var(--radar-gradient-2);
  border: 1px solid var(--radar-border);
  border-radius: var(--radius);
  padding: 40px 32px;
  text-align: center;
}
.radar-newsletter h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.radar-newsletter p {
  color: var(--text-2);
  font-size: 0.9rem;
  margin-bottom: 20px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}
.radar-newsletter-form {
  display: flex;
  gap: 10px;
  max-width: 480px;
  margin: 0 auto;
}
.radar-newsletter-form input[type="email"] {
  flex: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 0.9rem;
  color: var(--text);
  font-family: var(--font);
  outline: none;
  min-width: 0;
  transition: border-color 0.2s;
}
.radar-newsletter-form input[type="email"]:focus {
  border-color: var(--radar-accent);
}
.radar-newsletter-form button {
  background: var(--radar-accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 12px 24px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font);
  white-space: nowrap;
  transition: all 0.2s;
  min-height: 44px;
}
.radar-newsletter-form button:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.radar-newsletter-success {
  display: none;
  color: var(--radar-green);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 12px;
}
.radar-newsletter-success.show { display: block; }

/* ---- Support Section ---- */
.radar-support {
  background: var(--radar-surface);
  border: 1px solid var(--radar-border);
  border-radius: var(--radius);
  padding: 40px 32px;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}
.radar-support h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
}
.radar-support p {
  font-size: 0.88rem;
  color: var(--text-2);
  line-height: 1.6;
  margin-bottom: 20px;
}
.radar-support .pix-area {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  margin-top: 12px;
}
.radar-support .pix-area .pix-key {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-2);
  cursor: pointer;
}

/* ---- Methodology disclaimer ---- */
.radar-disclaimer {
  background: rgba(255, 171, 0, 0.08);
  border: 1px solid rgba(255, 171, 0, 0.2);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  font-size: 0.82rem;
  color: var(--radar-orange);
  line-height: 1.5;
  margin-bottom: 24px;
}

/* ---- Method page specific ---- */
.radar-method-section {
  margin-bottom: 32px;
}
.radar-method-section h2 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--radar-accent);
}
.radar-method-section p, .radar-method-section li {
  font-size: 0.9rem;
  color: var(--text-2);
  line-height: 1.7;
}
.radar-method-section ul {
  padding-left: 20px;
  list-style: none;
}
.radar-method-section ul li::before {
  content: '▸ ';
  color: var(--radar-accent);
  font-weight: bold;
}

/* ---- Responsive ---- */
@media (max-width: 640px) {
  .radar-header { padding: 40px 0 24px; }
  .radar-logo { flex-direction: column; text-align: center; }
  .radar-logo-text { text-align: center; }
  .radar-logo-text h1 { font-size: 1.4rem; }
  .radar-section-title { font-size: 1.3rem; }
  .radar-timeline { padding-left: 32px; }
  .radar-newsletter-form { flex-direction: column; }
  .radar-newsletter-form button { width: 100%; }
  .radar-cards-grid { grid-template-columns: 1fr; }
}
