/**
 * CALKULATEME - Premium Dark Theme with Golden Touch
 * CSS Custom Properties for uniform theming
 */

:root {
  --bg-primary: #0d0d0d;
  --bg-secondary: #121212;
  --bg-surface: #1a1a1a;
  --bg-surface-hover: #1e1e1e;
  --bg-elevated: #242424;

  --gold-primary: #d4af37;
  --gold-secondary: #c5a059;
  --gold-muted: #a68b2e;
  --gold-glow: rgba(212, 175, 55, 0.15);
  --gold-border: rgba(212, 175, 55, 0.35);

  --text-primary: #ffffff;
  --text-secondary: #a6a6a6;
  --text-muted: #6b6b6b;
  --text-gold: #d4af37;

  --success: #22c55e;
  --warning: #f59e0b;
  --danger: #ef4444;
  --info: #3b82f6;

  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-gold: rgba(212, 175, 55, 0.4);

  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;

  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-gold: 0 0 20px rgba(212, 175, 55, 0.12);

  --font-sans: 'Inter', 'Segoe UI', system-ui, sans-serif;
  --transition: 0.2s ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
}

html[data-lang="hi"] body,
html[lang="hi"] body {
  font-family: 'Noto Sans Devanagari', var(--font-sans);
}

html[data-lang="bn"] body,
html[lang="bn"] body {
  font-family: 'Noto Sans Bengali', var(--font-sans);
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}
::-webkit-scrollbar-thumb {
  background: var(--gold-muted);
  border-radius: 4px;
}

/* Cards */
.calc-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.calc-card:hover {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-gold);
}

/* Output panel */
.output-panel {
  background: linear-gradient(135deg, var(--bg-elevated) 0%, var(--bg-surface) 100%);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  box-shadow: var(--shadow-gold);
}

.output-panel .output-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--gold-primary);
  letter-spacing: -0.02em;
}

/* Form elements */
.calc-input {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.625rem 0.875rem;
  color: var(--text-primary);
  font-size: 0.9375rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.calc-input:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: 0 0 0 3px var(--gold-glow);
}
.calc-input::placeholder {
  color: var(--text-muted);
}

.calc-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23d4af37' viewBox='0 0 20 20'%3E%3Cpath d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1.25rem;
  padding-right: 2.5rem;
}

.calc-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Buttons */
.btn-gold {
  background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-secondary) 100%);
  color: var(--bg-primary);
  font-weight: 600;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
}
.btn-gold:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.35);
}
.btn-gold:active {
  transform: translateY(0);
}

.btn-outline {
  background: transparent;
  color: var(--gold-primary);
  border: 1px solid var(--gold-border);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
}
.btn-outline:hover {
  background: var(--gold-glow);
  border-color: var(--gold-primary);
}

/* Badge */
.badge-recommend {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.badge-recommend.winner {
  background: rgba(34, 197, 94, 0.15);
  color: var(--success);
  border: 1px solid rgba(34, 197, 94, 0.3);
}
.badge-recommend.neutral {
  background: var(--gold-glow);
  color: var(--gold-primary);
  border: 1px solid var(--gold-border);
}

/* Tables */
.calc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.calc-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  color: var(--text-gold);
  font-weight: 600;
  border-bottom: 1px solid var(--gold-border);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.calc-table td {
  padding: 0.625rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}
.calc-table tr:hover td {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
}
.calc-table .amount {
  color: var(--text-primary);
  font-weight: 500;
  text-align: right;
}

/* Nav active state */
.nav-link {
  color: var(--text-secondary);
  transition: color var(--transition);
  border-bottom: 2px solid transparent;
  padding-bottom: 0.25rem;
}
.nav-link:hover,
.nav-link.active {
  color: var(--gold-primary);
  border-bottom-color: var(--gold-primary);
}

/* Calculator grid */
.input-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* Comparison columns */
.compare-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.compare-col {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  border: 1px solid var(--border-subtle);
}
.compare-col.highlight {
  border-color: var(--gold-border);
  box-shadow: var(--shadow-gold);
}

/* Breakdown row */
.breakdown-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-subtle);
}
.breakdown-row:last-child {
  border-bottom: none;
  font-weight: 600;
  color: var(--gold-primary);
  padding-top: 0.75rem;
  margin-top: 0.25rem;
  border-top: 1px solid var(--gold-border);
}

/* Language selector */
.lang-btn {
  padding: 0.35rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  min-width: 2rem;
  line-height: 1;
}
.lang-btn:hover,
.lang-btn.active {
  color: var(--gold-primary);
  border-color: var(--gold-border);
  background: var(--gold-glow);
}

/* Numerology number display */
.numero-circle {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--gold-glow) 0%, var(--bg-elevated) 100%);
  border: 2px solid var(--gold-primary);
  color: var(--gold-primary);
}

.numero-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.numero-list li {
  position: relative;
  padding-left: 1.25rem;
  font-size: 0.875rem;
  color: var(--text-muted, #9ca3af);
  line-height: 1.5;
}

.numero-list li::before {
  content: '◆';
  position: absolute;
  left: 0;
  color: var(--gold-primary);
  font-size: 0.6rem;
  top: 0.35rem;
}

/* Chart container */
.chart-container {
  position: relative;
  height: 280px;
  margin-top: 1rem;
}

/* Mobile nav */
@media (max-width: 768px) {
  .calc-card {
    padding: 1rem;
  }
  .output-panel .output-value {
    font-size: 1.375rem;
  }
  .input-grid {
    grid-template-columns: 1fr;
  }
}

/* Fade in animation for route changes */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.route-enter {
  animation: fadeIn 0.3s ease forwards;
}

/* Income tax form tabs */
.form-tab {
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: all var(--transition);
}
.form-tab:hover {
  color: var(--gold-primary);
  border-color: var(--gold-border);
}
.form-tab.active {
  background: var(--gold-glow);
  color: var(--gold-primary);
  border-color: var(--gold-primary);
}
