/* style.css - Allkeyshop Hinnavõrdluse Stiilid */

:root {
  --bg-color: #0b0f19;
  --surface-color: #121826;
  --surface-alt: #1a2234;
  --border-color: #232d42;
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;
  
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --primary-light: rgba(59, 130, 246, 0.15);
  
  --pc-color: #10b981;
  --pc-bg: rgba(16, 185, 129, 0.12);
  --ps-color: #3b82f6;
  --ps-bg: rgba(59, 130, 246, 0.12);
  --xbox-color: #22c55e;
  --xbox-bg: rgba(34, 197, 94, 0.12);

  --accent-deluxe: #f59e0b;
  --accent-deluxe-bg: rgba(245, 158, 11, 0.15);

  --diff-positive: #ef4444; /* PS5 kallim */
  --diff-negative: #10b981; /* PS5 odavam */
  --diff-neutral: #9ca3af;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.5);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  padding: 24px 16px;
}

.app-container {
  max-width: 1320px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Header */
.app-header {
  background: linear-gradient(135deg, #161f33 0%, #111726 100%);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px 28px;
  box-shadow: var(--shadow-md);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-icon {
  font-size: 2.2rem;
  background: var(--surface-alt);
  border: 1px solid var(--border-color);
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.logo-area h1 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 14px;
}

.currency-selector-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-alt);
  padding: 6px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.currency-selector-wrap label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.styled-select {
  background: #0b0f19;
  border: 1px solid var(--border-color);
  color: #fff;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  outline: none;
  font-size: 0.9rem;
}

.styled-select:focus {
  border-color: var(--primary);
}

/* Nupud */
.btn-primary {
  background: var(--primary);
  color: #ffffff;
  border: none;
  padding: 12px 22px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 10px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--surface-alt);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: #253147;
  border-color: #3b82f6;
}

/* 3 Valuuta märgis päises */
.multi-currency-badge {
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #93c5fd;
  padding: 6px 14px;
  border-radius: var(--radius-md);
  font-size: 0.84rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
}

.multi-currency-badge strong {
  color: #fff;
}

/* Kokkupandav (Collapsible) kirjelduse aken */
.info-section {
  transition: all 0.3s ease;
}

.info-collapsible {
  background: linear-gradient(135deg, #141c2e 0%, #0f1624 100%);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  transition: all 0.3s ease;
}

.info-collapsible-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 22px;
  cursor: pointer;
  user-select: none;
  list-style: none; /* peidab vaikimisi noole */
  background: rgba(255, 255, 255, 0.02);
  transition: background 0.2s ease;
}

.info-collapsible-summary::-webkit-details-marker {
  display: none;
}

.info-collapsible-summary:hover {
  background: rgba(59, 130, 246, 0.08);
}

.summary-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.summary-text-wrap {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.summary-title {
  font-size: 0.98rem;
  font-weight: 700;
  color: #fff;
}

.summary-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.toggle-indicator {
  font-size: 0.85rem;
  color: #60a5fa;
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.3);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease;
  flex-shrink: 0;
}

.info-collapsible[open] .toggle-indicator {
  transform: rotate(180deg);
}

.info-collapsible-content {
  padding: 18px 22px 22px 22px;
  border-top: 1px solid var(--border-color);
  animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.info-item {
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.info-item:hover {
  transform: translateY(-2px);
  border-color: rgba(59, 130, 246, 0.4);
}

.info-item-icon {
  font-size: 1.35rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.info-item-text h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 4px;
}

.info-item-text p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.info-item-text strong {
  color: #fff;
}

/* 3 Valuuta kuvamise stiilid tabelis ja kaartidel */
.curr-eur {
  color: #93c5fd;
  font-weight: 700;
}

.curr-usd {
  color: #34d399;
  font-weight: 700;
}

.curr-gbp {
  color: #fcd34d;
  font-weight: 700;
}

.curr-sep {
  color: rgba(255, 255, 255, 0.25);
  font-size: 0.72rem;
  margin: 0 3px;
}

.price-triple-tag {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.86rem;
}

/* Otsinguriba kaart */
.search-card {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
}

.search-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.search-label-row label {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
}

.badge-account-info {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.search-input-wrapper {
  display: flex;
  gap: 12px;
  align-items: stretch;
}

.search-input-wrapper textarea {
  flex: 1;
  background: #0b0f19;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: #fff;
  padding: 12px 16px;
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
  outline: none;
  min-height: 50px;
  transition: border-color 0.2s;
}

.search-input-wrapper textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Kiirvalikud - Viimase 30 päeva 20 enim müüdud mängu */
.presets-section {
  margin-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-top: 1px solid var(--border-color);
  padding-top: 16px;
}

.presets-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.presets-title {
  font-size: 0.88rem;
  color: #e5e7eb;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.presets-actions {
  display: flex;
  gap: 8px;
}

.btn-xs {
  background: var(--surface-alt);
  color: #fff;
  border: 1px solid var(--border-color);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-xs:hover {
  background: #2a374f;
  border-color: var(--primary);
}

.btn-download {
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.btn-download:hover {
  background: rgba(16, 185, 129, 0.3);
  border-color: #10b981;
  color: #fff;
  transform: translateY(-1px);
}

.btn-aks-sync {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.22) 0%, rgba(139, 92, 246, 0.28) 100%);
  border: 1px solid rgba(139, 92, 246, 0.55);
  color: #c4b5fd;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.btn-aks-sync:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.38) 0%, rgba(139, 92, 246, 0.5) 100%);
  border-color: #a78bfa;
  color: #fff;
  transform: translateY(-1px);
}

.btn-aks-sync:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

.btn-aks-sync.is-syncing .sync-icon {
  display: inline-block;
  animation: spin 0.8s linear infinite;
}

.sync-status-msg {
  font-size: 0.82rem;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  margin-top: 10px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
}

.sync-status-msg.success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #34d399;
}

.sync-status-msg.loading {
  background: rgba(59, 130, 246, 0.15);
  border: 1px solid rgba(59, 130, 246, 0.35);
  color: #93c5fd;
}

.sync-status-msg.error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #fca5a5;
}

.btn-outline {
  background: transparent;
  color: var(--text-muted);
}

.btn-outline:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.3);
}

.presets-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.preset-chip {
  background: var(--surface-alt);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
  user-select: none;
}

.preset-chip .chip-rank {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-dim);
  background: rgba(0, 0, 0, 0.3);
  padding: 1px 6px;
  border-radius: 10px;
}

.preset-chip .chip-name {
  color: #f3f4f6;
}

.preset-chip:hover {
  background: #232e44;
  border-color: var(--primary);
  transform: translateY(-1px);
}

.preset-chip:hover .chip-name {
  color: #fff;
}

.preset-chip.top-rank {
  border-color: rgba(245, 158, 11, 0.4);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.1) 0%, var(--surface-alt) 100%);
}

.preset-chip.top-rank .chip-rank {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.2);
}

/* Laadimisriba */
.loading-bar-wrapper {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(59, 130, 246, 0.2);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* Kokkuvõte tabeli tipus */
.summary-section {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
  margin-bottom: 24px;
}

.summary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 12px;
}

.summary-header h2 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}

.summary-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.summary-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-highlight {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
}

.btn-highlight:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.summary-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  background: var(--surface-alt);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

.summary-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.summary-card {
  background: var(--surface-alt);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.summary-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
}

.pc-card::before { background: var(--pc-color); }
.ps-card::before { background: var(--ps-color); }
.diff-card::before { background: #f59e0b; }
.xbox-card::before { background: var(--xbox-color); }

.card-icon {
  font-size: 1.8rem;
  background: rgba(0,0,0,0.25);
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-data {
  display: flex;
  flex-direction: column;
}

.card-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.card-price {
  font-size: 1.45rem;
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
  color: #fff;
  margin: 2px 0;
}

.card-price.highlight {
  color: #f59e0b;
}

.card-sub {
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Tabeli sektsioon */
.table-section {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
}

.table-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  flex-wrap: wrap;
  gap: 12px;
}

.table-title-wrap h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}

.table-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.table-responsive {
  overflow-x: auto;
}

.comparison-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.9rem;
}

.comparison-table th {
  background: var(--surface-alt);
  color: var(--text-muted);
  font-weight: 700;
  text-align: left;
  padding: 14px 16px;
  border-top: 1px solid var(--border-color);
  border-bottom: 2px solid var(--border-color);
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.comparison-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.comparison-table tbody tr {
  transition: background 0.15s ease;
}

.comparison-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

/* Veerud ja elemendid */
.game-title-cell {
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
}

.game-title-cell .game-sub-badge {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 4px;
}

.platform-price-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  background: rgba(0,0,0,0.2);
}

.price-tag-type {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

.price-val {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.95rem;
}

.price-val.std-price {
  color: #60a5fa;
}

.price-val.deluxe-price {
  color: #fbbf24;
}

.store-name-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Hinnavahe kaardi mitmerealine vaade */
.card-diff-multiline {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 6px 0;
}

.diff-line {
  font-size: 0.86rem;
  font-family: 'JetBrains Mono', monospace;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.diff-platform-tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  text-transform: uppercase;
}

.diff-platform-tag.ps {
  background: rgba(59, 130, 246, 0.2);
  color: #60a5fa;
}

.diff-platform-tag.xbox {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
}

.diff-platform-tag.ps-xb {
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
}

/* Tabeli 3-suunaline Standard hinnavahe lahter */
.three-way-diff-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 220px;
}

.diff-mini-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(0, 0, 0, 0.25);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-family: 'JetBrains Mono', monospace;
}

.diff-mini-row .diff-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.diff-mini-row .diff-val.pos {
  color: #f87171; /* kallim */
  font-weight: 700;
}

.diff-mini-row .diff-val.neg {
  color: #34d399; /* odavam */
  font-weight: 700;
}

.diff-mini-row .diff-val.zero {
  color: #d1d5db;
}

.diff-cheapest-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  margin-top: 2px;
}

/* Hinnavahe veerg */
.diff-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.diff-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9rem;
  width: fit-content;
}

.diff-badge.expensive-ps5 {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.diff-badge.cheaper-ps5 {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
}

.diff-badge.equal-price {
  background: rgba(156, 163, 175, 0.15);
  border: 1px solid rgba(156, 163, 175, 0.3);
  color: #d1d5db;
}

.diff-subtext {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Kõigi valuutade tabel */
.all-currencies-banner {
  background: var(--surface-alt);
  border: 1px solid var(--border-color);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  margin-bottom: 14px;
  color: #e5e7eb;
}

.multi-currency-table th {
  text-align: center;
}

.multi-currency-table td {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
}

/* Tühiseis */
.empty-state {
  background: var(--surface-color);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 48px 24px;
  text-align: center;
  color: var(--text-muted);
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.empty-state h3 {
  color: #fff;
  font-size: 1.2rem;
  margin-bottom: 6px;
}

/* Modaalaken */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 16px;
}

.modal-dialog {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width: 100%;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-color);
  background: var(--surface-alt);
}

.modal-header h3 {
  font-size: 1.1rem;
  color: #fff;
}

.btn-close {
  background: transparent;
  border: none;
  font-size: 1.6rem;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
}

.btn-close:hover {
  color: #fff;
}

.modal-body {
  padding: 24px;
  max-height: 70vh;
  overflow-y: auto;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: flex-end;
  background: var(--surface-alt);
}

/* Jalus */
.app-footer {
  text-align: center;
  padding: 20px 0;
  font-size: 0.8rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border-color);
}

/* Abiklassid */
.hidden {
  display: none !important;
}

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    align-items: flex-start;
  }
  .search-input-wrapper {
    flex-direction: column;
  }
  .summary-cards-grid {
    grid-template-columns: 1fr;
  }
}
