/* ==========================================================================
   JobRadar Sziget - Premium Design System (v2.5 PRO)
   Fókusz: Maximális átláthatóság, gyors áttekinthetőség és produktivitás
   ========================================================================== */

:root {
  /* Color Palette - Dark Theme (Default) */
  --bg-primary: #0a0e17;
  --bg-secondary: #111827;
  --bg-surface: rgba(17, 24, 39, 0.85);
  --bg-surface-hover: rgba(31, 41, 55, 0.95);
  --bg-glass: rgba(255, 255, 255, 0.04);
  --border-glass: rgba(255, 255, 255, 0.09);
  --border-active: #3b82f6;

  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  
  --accent-primary: #3b82f6;
  --accent-primary-hover: #2563eb;
  --accent-emerald: #10b981;
  --accent-emerald-glow: rgba(16, 185, 129, 0.2);
  --accent-amber: #f59e0b;
  --accent-purple: #8b5cf6;
  --accent-pink: #ec4899;
  --accent-cyan: #06b6d4;
  --accent-red: #ef4444;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(59, 130, 246, 0.18);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;

  --font-main: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-display: 'Space Grotesk', system-ui, sans-serif;
}

[data-theme="light"] {
  --bg-primary: #f0f2f5;
  --bg-secondary: #ffffff;
  --bg-surface: rgba(255, 255, 255, 0.92);
  --bg-surface-hover: rgba(243, 244, 246, 0.98);
  --bg-glass: rgba(0, 0, 0, 0.03);
  --border-glass: rgba(0, 0, 0, 0.1);
  --border-active: #2563eb;

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 0 30px rgba(59, 130, 246, 0.1);
}

/* ==========================================================================
   Base & Reset
   ========================================================================== */

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Background Ambient Glows */
.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.12;
}

.glow-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #3b82f6, transparent);
  top: -100px;
  left: 10%;
}

.glow-2 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, #8b5cf6, transparent);
  bottom: 50px;
  right: 5%;
}

/* Glass Card Utility */
.glass-card {
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: all 0.25s ease;
}

/* ==========================================================================
   Header Section
   ========================================================================== */

.app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 14, 23, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  padding: 14px 0;
}

[data-theme="light"] .app-header {
  background: rgba(255, 255, 255, 0.9);
}

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

.brand-section {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-logo {
  position: relative;
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #1e3a8a, #3b82f6);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.4);
}

.logo-icon {
  font-size: 22px;
}

.logo-pulse {
  position: absolute;
  inset: -3px;
  border-radius: calc(var(--radius-md) + 3px);
  border: 2px solid #3b82f6;
  opacity: 0.6;
  animation: pulse-ring 2.5s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.96); opacity: 0.8; }
  50% { transform: scale(1.08); opacity: 0; }
  100% { transform: scale(0.96); opacity: 0; }
}

.brand-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-title-row h1 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand-accent {
  background: linear-gradient(135deg, #38bdf8, #818cf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.version-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: var(--radius-full);
}

.brand-subtitle {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Header Actions & Stats */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.stats-ribbon {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-glass);
  border: 1px solid var(--border-glass);
  padding: 4px 8px;
  border-radius: var(--radius-full);
}

.stat-pill {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.stat-pill:hover {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
}

.stat-pill.highlight {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.stat-num {
  font-weight: 800;
  font-size: 0.88rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 15px;
  font-size: 0.84rem;
  font-weight: 600;
  font-family: var(--font-main);
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.45);
}

.btn-emerald {
  background: linear-gradient(135deg, #059669, #10b981);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.btn-emerald:hover {
  background: linear-gradient(135deg, #047857, #059669);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-glass);
}

.btn-secondary:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
  background: var(--bg-glass);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.05rem;
  transition: all 0.2s ease;
}

.btn-icon:hover {
  background: var(--bg-surface-hover);
  transform: scale(1.05);
}

.refresh-icon.rotating {
  animation: spin 1s linear infinite;
}

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

/* ==========================================================================
   Welcome & Intelligence Banner
   ========================================================================== */

.main-content {
  position: relative;
  z-index: 1;
  padding-top: 20px;
  padding-bottom: 60px;
}

.welcome-banner {
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  border-left: 4px solid var(--accent-emerald);
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.08) 0%, var(--bg-surface) 100%);
}

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

.welcome-avatar {
  font-size: 26px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: rgba(16, 185, 129, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
}

.welcome-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 2px;
}

.welcome-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
}

.last-visit-badge {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: var(--bg-glass);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-glass);
}

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

.new-highlight {
  color: #34d399;
  font-weight: 700;
}

.visit-time-text {
  color: var(--text-primary);
  font-weight: 600;
}

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

/* ==========================================================================
   Filter Panel
   ========================================================================== */

.filter-panel {
  padding: 18px 20px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.search-row {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
}

.search-input-wrapper {
  flex: 1;
  min-width: 280px;
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
}

.search-input-wrapper input {
  width: 100%;
  padding: 10px 38px 10px 42px;
  font-size: 0.9rem;
  font-family: var(--font-main);
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  outline: none;
  transition: all 0.2s ease;
}

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

.clear-btn {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  font-size: 1.3rem;
  color: var(--text-muted);
  cursor: pointer;
}

.clear-btn:hover {
  color: var(--text-primary);
}

/* Status Tabs */
.status-tabs {
  display: flex;
  background: var(--bg-secondary);
  padding: 3px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
  gap: 2px;
  flex-wrap: wrap;
}

.status-tab {
  padding: 7px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  font-family: var(--font-main);
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
}

.status-tab:hover {
  color: var(--text-primary);
}

.status-tab.active {
  background: var(--accent-primary);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.35);
}

.status-tab.tab-new-filter.active {
  background: var(--accent-emerald);
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.35);
}

.status-tab.tab-hidden {
  color: #9ca3af;
}

.status-tab.tab-hidden.active {
  background: #4b5563;
  color: #ffffff;
}

.status-tab.tab-disqualified {
  color: #f87171;
}

.status-tab.tab-disqualified.active {
  background: #dc2626;
  color: #ffffff;
}

/* Filter Chips */
.filter-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-label {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  min-width: 90px;
  padding-top: 5px;
}

.chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  flex: 1;
}

.chip {
  padding: 5px 12px;
  font-size: 0.78rem;
  font-weight: 500;
  font-family: var(--font-main);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip:hover {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
}

.chip.active {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border-color: var(--accent-primary);
  font-weight: 600;
}

/* ==========================================================================
   Results Bar & Controls
   ========================================================================== */

.results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}

.results-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.results-info h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
}

.badge-count {
  background: var(--bg-glass);
  border: 1px solid var(--border-glass);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

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

/* View Mode Switcher Toggle */
.view-mode-toggle {
  display: flex;
  background: var(--bg-secondary);
  padding: 3px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-glass);
}

.view-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  font-size: 0.78rem;
  font-weight: 600;
  font-family: var(--font-main);
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}

.view-btn.active {
  background: var(--accent-primary);
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(59, 130, 246, 0.3);
}

.results-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.select-input {
  padding: 6px 10px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-main);
  font-size: 0.82rem;
  outline: none;
  cursor: pointer;
}

/* ==========================================================================
   2-LEVEL JOB CARD / ROW DESIGN SYSTEM (v2.7)
   Fókusz: Maximális átláthatóság, azonnali felismerés, szellős tipográfia
   ========================================================================== */

.jobs-list-view {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.job-card-two-level {
  background: var(--bg-surface);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  box-shadow: var(--shadow-sm);
}

.job-card-two-level:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(99, 102, 241, 0.4);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  transform: translateY(-1px);
}

/* Status borders on left */
.job-card-two-level.is-new {
  border-left: 4px solid var(--accent-emerald);
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.06) 0%, var(--bg-surface) 100%);
}

.job-card-two-level.status-saved {
  border-left: 4px solid var(--accent-amber);
}

.job-card-two-level.status-applied {
  border-left: 4px solid var(--accent-emerald);
}

.job-card-two-level.status-hidden {
  opacity: 0.45;
  border-left: 4px solid var(--text-muted);
}

.job-card-two-level.is-disqualified {
  opacity: 0.7;
  border-left: 4px solid var(--accent-red);
}

/* LEVEL 1: Primary Header (What to see instantly) */
.card-level-1 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: nowrap;
}

.level-1-left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.title-and-badges {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.job-main-title {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  margin: 0;
}

.job-main-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease;
}

.job-main-title a:hover {
  color: #818cf8;
  text-decoration: underline;
}

.primary-tags {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Clean, restrained tags */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.tag-new {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
  font-weight: 700;
}

.tag-disq {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.tag-neutral {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border: 1px solid var(--border-glass);
}

[data-theme="light"] .tag-neutral {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.08);
  color: #475569;
}

.tag-schedule {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  border-color: rgba(56, 189, 248, 0.2);
}

/* Subtitle: Company · Location */
.company-location-sub {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  color: var(--text-secondary);
  flex-wrap: wrap;
}

.sub-company {
  color: var(--text-primary);
  font-weight: 600;
}

.sub-dot {
  color: var(--text-muted);
  font-weight: 700;
}

.sub-location {
  color: #38bdf8;
  font-weight: 600;
}

/* LEVEL 1 RIGHT: AI Score & Primary Actions */
.level-1-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

/* AI Score Card */
.ai-score-card {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  min-width: 130px;
}

.ai-score-top {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--radius-md);
  font-weight: 700;
  transition: all 0.2s ease;
}

.ai-score-high .ai-score-top {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.2);
}

.ai-score-med .ai-score-top {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.35);
}

.ai-score-low .ai-score-top {
  background: rgba(107, 114, 128, 0.15);
  color: #9ca3af;
  border: 1px solid rgba(107, 114, 128, 0.25);
}

.ai-score-value {
  font-size: 1.05rem;
  font-weight: 800;
  font-family: var(--font-display);
}

.ai-score-text {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.9;
}

.ai-score-reason {
  font-size: 0.75rem;
  color: var(--text-muted);
  max-width: 220px;
  line-height: 1.3;
  margin-top: 4px;
}

/* Primary Level-1 Actions */
.level-1-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-primary-cta {
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #ffffff;
  padding: 9px 18px;
  font-size: 0.88rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.4);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-primary-cta:hover {
  background: linear-gradient(135deg, #4338ca, #4f46e5);
  box-shadow: 0 6px 18px rgba(79, 70, 229, 0.55);
  transform: translateY(-1px);
}

.btn-star-action {
  padding: 8px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  font-family: var(--font-main);
  border-radius: var(--radius-md);
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.08);
  color: #f59e0b;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-star-action:hover {
  background: rgba(245, 158, 11, 0.2);
  border-color: #f59e0b;
}

.btn-star-action.active {
  background: #f59e0b;
  color: #000000;
  font-weight: 700;
  border-color: #f59e0b;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.4);
}

/* LEVEL 2: Secondary Context & Secondary Actions */
.card-level-2 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--border-glass);
  font-size: 0.82rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.level-2-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.meta-sub-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.meta-source {
  color: var(--text-muted);
}

.meta-salary {
  color: #10b981;
  font-weight: 700;
}

.meta-cv {
  color: var(--text-secondary);
}

.meta-cv-link {
  color: #60a5fa;
  font-weight: 600;
  text-decoration: none;
  background: rgba(59, 130, 246, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(59, 130, 246, 0.25);
  transition: all 0.15s ease;
}

.meta-cv-link:hover {
  background: rgba(59, 130, 246, 0.2);
  text-decoration: underline;
}

/* Level 2 Sub Actions */
.level-2-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-sub {
  padding: 5px 11px;
  font-size: 0.78rem;
  font-weight: 600;
  font-family: var(--font-main);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-glass);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-sub:hover {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
}

.btn-sub-apply:hover, .btn-sub-apply.active {
  background: rgba(16, 185, 129, 0.18);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.4);
}

.btn-sub-apply.active {
  background: #10b981;
  color: #ffffff;
  font-weight: 700;
}

.btn-sub-exclude {
  color: #9ca3af;
}

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

.btn-sub-restore {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border-color: rgba(59, 130, 246, 0.3);
}

.btn-sub-expand {
  color: var(--text-muted);
}

/* Collapsible Drawer */
.card-expanded-drawer {
  padding: 12px 16px;
  background: var(--bg-glass);
  border: 1px dashed var(--border-glass);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: expand-down 0.2s ease;
}

.expanded-snippet-text {
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.expanded-notes-box {
  font-size: 0.82rem;
  background: rgba(245, 158, 11, 0.1);
  border-left: 3px solid #f59e0b;
  padding: 7px 12px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: #fbbf24;
}

/* ==========================================================================
   VIEW 2: KÁRTYA NÉZET (Grid View)
   ========================================================================== */

.jobs-grid-view {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 16px;
}

.job-card-grid-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.job-card-grid-item:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.job-card-grid-item.is-new {
  border-top: 4px solid var(--accent-emerald);
}

.job-card-grid-item.status-saved {
  border-top: 4px solid var(--accent-amber);
}

.job-card-grid-item.status-applied {
  border-top: 4px solid var(--accent-emerald);
}

.grid-card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.grid-ai-reason {
  font-size: 0.78rem;
  color: var(--text-secondary);
  background: var(--bg-glass);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border-left: 3px solid #3b82f6;
  line-height: 1.35;
}

.grid-cv-box {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
}

.grid-cv-label {
  color: var(--text-muted);
  font-weight: 600;
}

.grid-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-muted);
  padding-top: 8px;
  border-top: 1px solid var(--border-glass);
  flex-wrap: wrap;
  gap: 6px;
}

.grid-card-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

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

.grid-actions-primary .btn-primary-cta {
  flex: 1;
  text-align: center;
}

.grid-actions-secondary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS (Mobile & Tablet)
   ========================================================================== */

@media (max-width: 960px) {
  .card-level-1 {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
  }
  .level-1-right {
    justify-content: space-between;
    width: 100%;
  }
  .ai-score-card {
    align-items: flex-start;
    text-align: left;
  }
  .jobs-grid-view {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .job-card-two-level {
    padding: 14px 16px;
  }
  .job-main-title {
    font-size: 1.1rem;
  }
  .level-1-right {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .level-1-actions {
    width: 100%;
  }
  .btn-primary-cta {
    flex: 1;
    text-align: center;
    justify-content: center;
  }
  .card-level-2 {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .level-2-actions {
    justify-content: space-between;
    width: 100%;
  }
}

/* ==========================================================================
   Toast Notification (Undo & Messages)
   ========================================================================== */

.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  display: none;
  animation: toast-slide-up 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes toast-slide-up {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.toast-card {
  background: #1e293b;
  color: #f8fafc;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.85rem;
}

.btn-toast-undo {
  background: #f59e0b;
  color: #1e293b;
  border: none;
  padding: 5px 10px;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s;
}

.btn-toast-undo:hover {
  background: #fbbf24;
  transform: scale(1.05);
}

.btn-toast-close {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.2rem;
  cursor: pointer;
}

.btn-toast-close:hover {
  color: #ffffff;
}

/* ==========================================================================
   Loading & Empty States
   ========================================================================== */

.loading-state, .empty-state {
  grid-column: 1 / -1;
  padding: 60px 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: var(--text-secondary);
}

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

.empty-icon {
  font-size: 2.8rem;
}

/* ==========================================================================
   Modal Dialog
   ========================================================================== */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  width: 100%;
  max-width: 520px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: var(--shadow-lg);
  animation: modal-pop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modal-pop {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
}

.modal-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.modal-field label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.modal-highlight {
  font-weight: 700;
  color: var(--accent-primary);
}

.text-input {
  width: 100%;
  padding: 9px 12px;
  background: var(--bg-primary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-main);
  font-size: 0.88rem;
  resize: vertical;
  outline: none;
}

.text-input:focus {
  border-color: var(--accent-primary);
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

/* ==========================================================================
   Footer
   ========================================================================== */

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

.footer-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.last-sync-time {
  color: var(--text-secondary);
  font-weight: 500;
}
