/* ASTRA Styles — Unified with EAHub Design System */

/* ============================================
   Base — Reuse EAHub Variables
   ============================================ */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@300;400;500;600&family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@300;400;500&display=swap');

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

:root {
  --bg: #fafbfc;
  --bg-card: #ffffff;
  --bg-soft: #f8f9fc;
  --text-primary: #1a1a1a;
  --text-secondary: #6b7280;
  --text-tertiary: #9ca3af;
  --border: #f0f1f3;
  --border-hover: #e5e7eb;
  --accent: #3b3f6b;
  --accent-soft: #e8eaf0;
  --highlight: #c9a04f;
  --highlight-soft: #f5ecd8;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.02);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.04);
  --shadow-lg: 0 4px 20px rgba(0,0,0,0.06);
}

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  font-weight: 300;
  min-height: 100vh;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 500px;
  background:
    radial-gradient(ellipse 700px 350px at 15% 10%, rgba(59, 63, 107, 0.06), transparent),
    radial-gradient(ellipse 600px 300px at 80% 15%, rgba(59, 63, 107, 0.04), transparent),
    radial-gradient(ellipse 500px 250px at 50% 0%, rgba(201, 160, 79, 0.04), transparent);
  pointer-events: none;
  z-index: 0;
}

/* ============================================
   Layout — Reuse EAHub Structure
   ============================================ */
.dashboard {
  position: relative;
  z-index: 1;
  padding: 24px 28px 32px;
  max-width: 680px;
  margin: 0 auto;
}

.dash-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.dash-title {
  display: flex;
  align-items: center;
  gap: 18px;
}

.dash-title .symbol {
  font-size: 30px;
  letter-spacing: 3px;
  opacity: 0.7;
  color: var(--accent);
  font-weight: 300;
}

.dash-title h1 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: 28px;
  letter-spacing: 0.5px;
  color: var(--text-primary);
}

.dash-title .subtitle {
  font-size: 11px;
  color: var(--text-tertiary);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 2px;
  font-weight: 300;
}

.dash-meta {
  display: flex;
  align-items: center;
  gap: 28px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-secondary);
}

.back-link {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}
.back-link:hover { opacity: 0.7; }

/* ============================================
   Pages
   ============================================ */
.page { display: none; }
.page.active { display: block; animation: fadeIn 0.4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ============================================
   Hero
   ============================================ */
.hero { text-align: center; padding: 32px 0 24px; }
.hero h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 32px;
  font-weight: 400;
  margin-bottom: 8px;
  letter-spacing: -0.3px;
}
.hero p {
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 300;
  max-width: 420px;
  margin: 0 auto 20px;
}
.badge {
  display: inline-block;
  border: 1px solid var(--border-hover);
  border-radius: 100px;
  padding: 5px 14px;
  font-size: 11px;
  color: var(--text-tertiary);
  letter-spacing: 1px;
  margin-bottom: 20px;
}

/* ============================================
   Entry Cards — ASTRA Specific
   ============================================ */
.entry-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.entry-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.entry-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.entry-card .icon {
  font-size: 32px;
  margin-bottom: 12px;
  display: block;
}

.entry-card h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.entry-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  font-weight: 300;
}

/* ============================================
   Blueprint Entry
   ============================================ */
.blueprint-entry {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 28px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.blueprint-entry::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  background: var(--highlight);
}

.blueprint-entry .symbol {
  font-size: 28px;
  color: var(--accent);
  opacity: 0.7;
  margin-bottom: 8px;
}

.blueprint-entry h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 6px;
}

.blueprint-entry p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  font-weight: 300;
}

/* ============================================
   Panels — Reuse EAHub
   ============================================ */
.panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 16px;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.panel-title {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.panel-title .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.panel-body { padding: 16px 18px; }

/* ============================================
   Forms
   ============================================ */
.form-row { display: flex; gap: 12px; margin-bottom: 14px; }
.form-row > div { flex: 1; }
.form-group { margin-bottom: 14px; }

label {
  display: block;
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 6px;
  font-weight: 500;
}

input, select {
  width: 100%;
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  color: var(--text-primary);
  background: var(--bg-soft);
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  outline: none;
}

input:focus, select:focus { border-color: var(--accent); }

/* ============================================
   Buttons
   ============================================ */
.btn {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s;
  letter-spacing: 0.5px;
  font-family: 'Inter', sans-serif;
}
.btn:hover { opacity: 0.9; }

.btn-secondary {
  background: var(--bg-card);
  color: var(--accent);
  border: 1px solid var(--accent);
}

/* ============================================
   Loading
   ============================================ */
.loading { text-align: center; padding: 80px 20px; }
.spinner {
  width: 40px;
  height: 40px;
  border: 2px solid var(--border);
  border-top: 2px solid var(--highlight);
  border-radius: 50%;
  margin: 0 auto 20px;
  animation: spin 1s linear infinite;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* ============================================
   Results
   ============================================ */
.result-header { text-align: center; padding: 24px 0; }
.result-tag {
  display: inline-block;
  border: 1px solid var(--accent);
  border-radius: 100px;
  padding: 4px 12px;
  font-size: 11px;
  color: var(--accent);
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}
.result-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 32px;
  font-weight: 400;
  margin-bottom: 4px;
}
.result-sub {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 300;
}

/* Stats */
.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  background: var(--accent);
}
.stat-card.gold::before { background: var(--highlight); }
.stat-value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 28px;
  font-weight: 500;
  line-height: 1;
  margin-bottom: 4px;
}
.stat-label {
  font-size: 11px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Insights */
.insight-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.insight-item:last-child { border-bottom: none; }
.insight-label {
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  margin-bottom: 4px;
}
.insight-value {
  font-size: 15px;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.5;
}

/* Unlock Box */
.unlock-box {
  background: var(--accent);
  color: #fff;
  border-radius: 10px;
  padding: 22px;
  text-align: center;
  margin: 20px 0;
  position: relative;
  overflow: hidden;
}
.unlock-box::before {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 150px; height: 150px;
  background: radial-gradient(circle, rgba(201,160,79,0.15), transparent 70%);
  pointer-events: none;
}
.unlock-box h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 400;
  margin-bottom: 6px;
  position: relative;
}
.unlock-box p {
  font-size: 12px;
  opacity: 0.75;
  margin-bottom: 16px;
  font-weight: 300;
  position: relative;
}
.unlock-btn {
  background: var(--highlight);
  color: #1a1a1a;
  border: none;
  padding: 10px 24px;
  border-radius: 8px;
  font-weight: 500;
  cursor: pointer;
  font-size: 13px;
  position: relative;
  transition: opacity 0.2s;
}
.unlock-btn:hover { opacity: 0.9; }

/* Footer */
.footer {
  padding: 24px 0;
  text-align: center;
  font-size: 11px;
  color: var(--text-tertiary);
  border-top: 1px solid var(--border);
  margin-top: 32px;
  letter-spacing: 0.5px;
}

/* Responsive */
@media (max-width: 600px) {
  .entry-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr; }
  .form-row { flex-direction: column; }
}
