/* =============================================
   ORACLE NUSANTARA - DEWASA AYU CSS
   Pencarian Hari Baik Berdasarkan Wuku & Wewaran
   ============================================= */

/* ========== VARIABLES ========== */
:root {
  --gold: #D4AF37;
  --gold-light: #F3E5AB;
  --bg-dark: #0A0A0C;
  --text-muted: #A0A0B0;
  --text-dim: #606070;
  --success: #64C864;
  --danger: #FF8A8A;
  --warning: #FFB347;
  --info: #4ECDC4;
}

/* ========== RESET & BASE ========== */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: #0A0A0C;
  background-image: radial-gradient(ellipse at 30% 20%, rgba(212,175,55,0.04) 0%, transparent 50%);
  font-family: 'Inter', sans-serif;
  color: #E8E8E8;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: 960px; margin: 0 auto; padding: 0 20px; }
.hidden { display: none !important; }
.oracle-card { max-width: 900px; margin: 0 auto; }

/* ========== NAVBAR ========== */
.navbar {
  background: #0A0A0C;
  border-bottom: 2px solid var(--gold);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 9999;
}

.navbar .logo a {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links a {
  color: #E8E8E8;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--gold); }
.nav-links a.active { color: var(--gold); font-weight: 700; }

/* ========== HERO ========== */
.mystic-header {
  text-align: center;
  margin-bottom: 36px;
  padding: 20px 0;
}

.mystic-header .header-icon {
  font-size: 3.5rem;
  margin-bottom: 16px;
  animation: float 3s ease-in-out infinite;
  filter: drop-shadow(0 0 25px rgba(212,175,55,0.3));
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.mystic-header h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--gold-light);
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.mystic-header .subtitle {
  color: var(--text-muted);
  font-size: 1rem;
  font-weight: 300;
}

.header-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 16px 0;
  color: var(--gold);
  font-size: 0.7rem;
  opacity: 0.5;
}

.header-divider::before,
.header-divider::after {
  content: '';
  width: 50px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

/* ========== FORM ========== */
.form-group { display: flex; flex-direction: column; gap: 20px; }

.input-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.input-field {
  flex: 1 1 240px;
}

.input-field label {
  display: block;
  margin-bottom: 10px;
  font-weight: 500;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.75rem;
}

.input-field input,
.input-field select {
  width: 100%;
  background: rgba(10,10,12,0.8);
  border: 2px solid rgba(212,175,55,0.2);
  border-radius: 12px;
  padding: 14px 18px;
  font-size: 1rem;
  color: #E8E8E8;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s;
}

.input-field input:focus,
.input-field select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 20px rgba(212,175,55,0.1);
}

.input-field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23D4AF37' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.input-hint {
  display: block;
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 6px;
  font-style: italic;
}

/* ========== CALENDAR NAV ========== */
.calendar-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 8px;
}

.calendar-nav button {
  background: rgba(15,15,20,0.8);
  border: 1px solid rgba(212,175,55,0.3);
  color: var(--gold);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s;
  font-size: 1rem;
}

.calendar-nav button:hover {
  background: var(--gold);
  color: #0A0A0C;
}

.calendar-nav .current-date {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.2rem;
  color: var(--gold-light);
  min-width: 200px;
  text-align: center;
  font-weight: 600;
}

/* ========== BUTTONS ========== */
.btn-primary {
  background: linear-gradient(135deg, rgba(212,175,55,0.1), rgba(212,175,55,0.05));
  border: 2px solid var(--gold);
  color: var(--gold);
  padding: 18px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.4s;
  width: 100%;
  text-align: center;
  letter-spacing: 1px;
}

.btn-primary:hover {
  background: var(--gold);
  color: #0A0A0C;
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(212,175,55,0.3);
}

.btn-premium {
  background: linear-gradient(135deg, var(--gold), #C9A830);
  border: none;
  color: #0A0A0C;
  padding: 16px 32px;
  border-radius: 50px;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  max-width: 350px;
  margin: 0 auto;
  transition: all 0.3s;
  font-size: 1rem;
  letter-spacing: 0.5px;
  box-shadow: 0 8px 25px rgba(212,175,55,0.2);
}

.btn-premium:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(212,175,55,0.4);
}

.pulse-gold { animation: pulseGold 2s infinite; }

@keyframes pulseGold {
  0% { box-shadow: 0 0 0 0 rgba(212,175,55,0.6); }
  70% { box-shadow: 0 0 0 20px rgba(212,175,55,0); }
  100% { box-shadow: 0 0 0 0 rgba(212,175,55,0); }
}

/* ========== DAY SUMMARY ========== */
.day-summary {
  background: linear-gradient(145deg, rgba(15,15,20,0.9), rgba(10,10,12,0.9));
  border: 2px solid rgba(212,175,55,0.3);
  border-radius: 24px;
  padding: 40px 24px;
  text-align: center;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}

.day-summary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 4px;
  border-radius: 0 0 4px 4px;
  transition: all 0.5s;
}

.day-summary.level-sangat-baik::before { background: var(--success); width: 100%; }
.day-summary.level-baik::before { background: var(--info); width: 80%; }
.day-summary.level-cukup::before { background: var(--warning); width: 60%; }
.day-summary.level-kurang::before { background: var(--danger); width: 40%; }

.day-level {
  font-size: 3.5rem;
  font-weight: 700;
  font-family: 'Cormorant Garamond', serif;
  line-height: 1.2;
}

.level-sangat-baik .day-level { color: var(--success); }
.level-baik .day-level { color: var(--info); }
.level-cukup .day-level { color: var(--warning); }
.level-kurang .day-level { color: var(--danger); }

.day-level-icon { font-size: 3rem; margin-bottom: 8px; }
.level-sangat-baik .day-level-icon { color: var(--success); }
.level-baik .day-level-icon { color: var(--info); }
.level-cukup .day-level-icon { color: var(--warning); }
.level-kurang .day-level-icon { color: var(--danger); }

.day-desc {
  color: var(--text-muted);
  margin-top: 12px;
  font-size: 1.1rem;
  line-height: 1.6;
  font-weight: 300;
}

/* ========== DETAIL GRID ========== */
.detail-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 24px 0;
}

.detail-item {
  background: rgba(15,15,20,0.7);
  border-radius: 20px;
  padding: 24px 16px;
  text-align: center;
  border: 1px solid rgba(212,175,55,0.12);
  transition: all 0.3s;
}

.detail-item:hover {
  transform: translateY(-4px);
  border-color: rgba(212,175,55,0.35);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.detail-item .d-icon { font-size: 2rem; color: var(--gold); margin-bottom: 12px; }
.detail-item:hover .d-icon { transform: scale(1.15); }

.detail-item .d-value {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--gold-light);
  font-family: 'Cormorant Garamond', serif;
  margin-bottom: 4px;
}

.detail-item .d-label {
  font-size: 0.75rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.detail-item .d-sub { font-size: 0.8rem; color: var(--text-muted); margin-top: 2px; }

/* ========== ANALYSIS CARDS ========== */
.analysis-section-card {
  background: rgba(15,15,20,0.7);
  border-radius: 20px;
  padding: 24px;
  margin-bottom: 16px;
  border: 1px solid rgba(212,175,55,0.12);
  transition: all 0.3s;
}

.analysis-section-card:hover {
  border-color: rgba(212,175,55,0.25);
  box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.analysis-section-card h4 {
  color: var(--gold);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.1rem;
  font-family: 'Cormorant Garamond', serif;
  font-weight: 600;
}

.analysis-section-card p {
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 8px;
}

/* ========== ACTIVITY TAGS ========== */
.activity-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.activity-tag {
  padding: 8px 16px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 500;
}

.activity-tag.recommended {
  background: rgba(100,200,100,0.15);
  color: var(--success);
  border: 1px solid rgba(100,200,100,0.3);
}

.activity-tag.caution {
  background: rgba(255,179,71,0.15);
  color: var(--warning);
  border: 1px solid rgba(255,179,71,0.3);
}

.activity-tag.avoid {
  background: rgba(255,138,138,0.15);
  color: var(--danger);
  border: 1px solid rgba(255,138,138,0.3);
}

/* ========== BOXES ========== */
.info-box {
  background: rgba(212,175,55,0.06);
  border-radius: 16px;
  padding: 20px;
  margin: 16px 0;
  border-left: 4px solid var(--gold);
}

.highlight-box {
  background: rgba(100,200,100,0.06);
  border-radius: 16px;
  padding: 20px;
  margin: 16px 0;
  border-left: 4px solid var(--success);
}

.warning-box {
  background: rgba(255,138,138,0.06);
  border-radius: 16px;
  padding: 20px;
  margin: 16px 0;
  border-left: 4px solid var(--danger);
}

/* ========== TOKEN ========== */
.token-badge {
  background: rgba(212,175,55,0.15);
  border: 1.5px solid rgba(212,175,55,0.3);
  border-radius: 50px;
  padding: 12px 28px;
  display: inline-block;
  color: var(--gold-light);
  font-weight: 600;
  font-size: 0.95rem;
}

.token-badge i { color: var(--gold); margin-right: 8px; }

/* ========== WELCOME BANNER ========== */
#welcomeBanner {
  max-width: 900px;
  margin: 0 auto 20px;
}

/* ========== FOOTER ========== */
.footer {
  border-top: 1px solid rgba(212,175,55,0.15);
  padding: 32px 0;
  margin-top: 48px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.footer a {
  color: var(--gold);
  text-decoration: none;
  margin-left: 20px;
  transition: color 0.2s;
}

.footer a:hover { color: var(--gold-light); }

/* ========== LOADING ========== */
#loadingOverlay {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(10,10,12,0.95);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  flex-direction: column;
}

.spinner {
  width: 50px; height: 50px;
  border: 3px solid rgba(212,175,55,0.2);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ========== RESPONSIVE ========== */
@media (max-width: 700px) {
  .detail-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 400px) {
  .detail-grid { grid-template-columns: 1fr; }
  .day-level { font-size: 2.5rem; }
  .footer { flex-direction: column; text-align: center; }
  .footer a { margin: 0 10px; }
}