/* css/astro.css — Golden Dawn Natal Chart + Trânsitos
   Carregado APÓS base/layout/components — nunca antes */

/* ── Layout wrapper ── */
.astro-wrap {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  max-width: 680px;
  margin: 0 auto;
  padding: var(--space-md);
}

/* ── Tabs ── */
.astro-tabs {
  display: flex;
  gap: var(--space-xs);
}

.astro-tab {
  flex: 1;
  padding: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  font-family: 'Cinzel', serif;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  transition: all 0.2s;
}

.astro-tab.active {
  background: var(--gold);
  color: var(--bg);
  border-color: var(--gold);
  font-weight: 600;
}

/* ── Panel ── */
.astro-panel { display: flex; flex-direction: column; gap: var(--space-md); }

/* ── Form fields ── */
.astro-source {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin: -4px 0 var(--space-sm);
  letter-spacing: 0.04em;
}

.astro-form-fields {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.astro-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.astro-field input[type="date"],
.astro-field input[type="time"],
.astro-field input[type="text"] {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 8px 10px;
  font-size: 0.92rem;
  width: 100%;
  box-sizing: border-box;
  font-family: 'EB Garamond', serif;
}

/* ── City autocomplete ── */
.astro-city-wrap {
  position: relative;
  isolation: isolate; /* new stacking context — dropdown won't leak */
}

.astro-city-drop {
  position: absolute;
  top: calc(100% + 2px);
  left: 0; right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  z-index: 200;
  max-height: 220px;
  overflow-y: auto;
  box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

.astro-city-item {
  padding: 8px 12px;
  font-size: 0.82rem;
  font-family: 'EB Garamond', serif;
  cursor: pointer;
  line-height: 1.4;
  border-bottom: 1px solid var(--border);
}

.astro-city-item:last-child { border-bottom: none; }
.astro-city-item:hover { background: var(--bg-input); }
.astro-city-item small { color: var(--text-muted); font-size: 0.75rem; }
.astro-city-item strong { font-weight: 600; }

.astro-city-status {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 3px;
  min-height: 16px;
}

/* ── Disclaimer ── */
.astro-disclaimer {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.5;
  margin-top: var(--space-sm);
}

.astro-disclaimer--result {
  border-top: 1px solid var(--border);
  padding-top: var(--space-sm);
  margin-top: var(--space-xs);
}

/* ── Wheel ── */
.astro-wheel-wrap {
  display: flex;
  justify-content: center;
  padding: var(--space-sm) 0;
}

.astro-wheel {
  width: 100%;
  max-width: 280px;
  height: auto;
  filter: drop-shadow(0 0 12px rgba(212,175,55,0.15));
}

/* ── Planet cards ── */
.astro-planets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space-sm);
}

.astro-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-sm);
}

.astro-card-header {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-xs);
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--space-xs);
}

.astro-symbol {
  font-size: 1.3rem;
  color: var(--gold);
  line-height: 1;
}

.astro-planet-name {
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: 0.88rem;
  flex: 1;
}

.astro-dignity {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.astro-sign {
  font-size: 0.92rem;
  font-weight: 500;
  margin-bottom: 2px;
  font-family: 'EB Garamond', serif;
}

.astro-detail {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.5;
  font-family: 'EB Garamond', serif;
}

/* ── Synthesis ── */
.astro-synthesis { margin-top: var(--space-sm); }

.astro-ai-loading {
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.88rem;
  padding: var(--space-sm) 0;
  font-family: 'EB Garamond', serif;
}

.astro-synthesis p {
  font-family: 'EB Garamond', serif;
  font-size: 0.96rem;
  line-height: 1.75;
  margin-bottom: var(--space-sm);
  color: var(--text);
}

.astro-gate {
  text-align: center;
  padding: var(--space-md);
}

.astro-gate p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
  font-family: 'EB Garamond', serif;
}

/* ── Transits ── */
.astro-transit-now {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
  font-family: 'EB Garamond', serif;
}

.astro-transit-header {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.astro-transit-moment,
.astro-transit-elem {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.astro-transit-label {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: 'Cinzel', serif;
}

.astro-transit-time {
  font-size: 0.88rem;
  font-weight: 500;
  font-family: 'EB Garamond', serif;
}

.astro-transit-elem-val {
  font-size: 1rem;
  font-weight: 700;
  color: var(--gold);
  font-family: 'Cinzel', serif;
}

/* ── Meta ── */
.astro-meta {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-align: center;
  letter-spacing: 0.04em;
}

/* ── Mobile ── */
@media (max-width: 480px) {
  .astro-planets { grid-template-columns: 1fr 1fr; }
  .astro-wheel { max-width: 240px; }
}
