/* CarXiss - Social App für Autofahrer 2026 */

:root {
  /* Light Theme - Default (Tag) */
  --bg-primary: #F2F2F7;
  --bg-secondary: #FFFFFF;
  --bg-tertiary: #FAFAFA;
  --bg-elevated: #FFFFFF;
  
  --text-primary: #000000;
  --text-secondary: #3C3C43;
  --text-tertiary: #8E8E93;
  
  --accent-primary: #EC4899;
  --accent-blue: #EC4899;
  --accent-green: #34C759;
  --accent-red: #EF4444;
  --accent-orange: #FF9500;
  --accent-purple: #AF52DE;
  --accent-pink: #EC4899;
  --accent-teal: #5AC8FA;
  --accent-yellow: #FFCC00;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
  --shadow-xl: 0 12px 32px rgba(0, 0, 0, 0.15);
  
  --border-color: rgba(0, 0, 0, 0.08);
  --separator-color: rgba(60, 60, 67, 0.12);
  
  --blur-bg: rgba(255, 255, 255, 0.72);
  --blur-border: rgba(255, 255, 255, 0.18);
}

[data-theme="dark"] {
  /* Dark Theme (Nacht) */
  --bg-primary: #000000;
  --bg-secondary: #1C1C1E;
  --bg-tertiary: #2C2C2E;
  --bg-elevated: #1C1C1E;
  
  --text-primary: #FFFFFF;
  --text-secondary: #EBEBF5;
  --text-tertiary: #8E8E93;
  
  --accent-primary: #EC4899;
  --accent-blue: #EC4899;
  --accent-green: #30D158;
  --accent-red: #FF453A;
  --accent-orange: #FF9F0A;
  --accent-purple: #BF5AF2;
  --accent-pink: #FF375F;
  --accent-teal: #64D2FF;
  --accent-yellow: #FFD60A;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 12px 32px rgba(0, 0, 0, 0.6);
  
  --border-color: rgba(255, 255, 255, 0.1);
  --separator-color: rgba(84, 84, 88, 0.65);
  
  --blur-bg: rgba(28, 28, 30, 0.72);
  --blur-border: rgba(255, 255, 255, 0.08);
}

/* Color Styles - User Preference */
/* Neutral (Default - Gray) */
[data-color-style="neutral"] {
  --accent-primary: #6B7280;
  --accent-blue: #6B7280;
}

[data-theme="dark"][data-color-style="neutral"] {
  --accent-primary: #9CA3AF;
  --accent-blue: #9CA3AF;
}

/* Pink (Female) - Logo Colors */
[data-color-style="pink"] {
  --accent-primary: #EC4899;
  --accent-blue: #EC4899;
}

[data-theme="dark"][data-color-style="pink"] {
  --accent-primary: #EC4899;
  --accent-blue: #EC4899;
}

/* Blue (Male) */
[data-color-style="blue"] {
  --accent-primary: #3B82F6;
  --accent-blue: #3B82F6;
}

[data-theme="dark"][data-color-style="blue"] {
  --accent-primary: #60A5FA;
  --accent-blue: #60A5FA;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', 'Arial', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: var(--text-primary);
  background: var(--bg-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Theme Toggle Button */
/* Backgrounds */
.welcome-bg {
  background: var(--bg-primary);
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.app-bg {
  background: var(--bg-primary);
  min-height: 100vh;
  padding-bottom: 6rem;
}

/* Glass Cards - CarPlay Style */
.glass-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
}

.glass-card:hover {
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

/* Modern Header - Flexbox Layout */
.modern-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.modern-card {
  background: var(--bg-elevated);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--border-color);
  transition: all 0.2s ease;
}

.section-container {
  background: var(--bg-elevated);
  border-radius: 12px;
  padding: 1.25rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--border-color);
  transition: all 0.2s ease;
}

/* Typography - SF Pro Style */
.app-title {
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.section-title {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  letter-spacing: -0.3px;
}

.section-subtitle {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: -0.2px;
}

.subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Buttons - CarPlay Style */
.btn-primary {
  background: var(--accent-blue);
  color: white;
  font-weight: 600;
  padding: 0.875rem 1.75rem;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  font-size: 0.9375rem;
  transition: all 0.15s ease;
}

.btn-primary:hover {
  opacity: 0.85;
}

.btn-primary:active {
  opacity: 0.7;
  transform: scale(0.98);
}

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-weight: 600;
  padding: 0.875rem 1.75rem;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  font-size: 0.9375rem;
  transition: all 0.15s ease;
}

.btn-secondary:hover {
  background: var(--bg-secondary);
}

.btn-add {
  background: var(--accent-blue);
  color: white;
  font-weight: 600;
  padding: 0.625rem 1.25rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-size: 0.875rem;
  transition: all 0.15s ease;
}

.btn-add:hover {
  opacity: 0.85;
}

.back-btn {
  color: var(--accent-blue);
  font-weight: 600;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: none;
  background: var(--bg-tertiary);
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.back-btn:hover {
  background: var(--bg-secondary);
  transform: translateX(-2px);
}

/* Icon Buttons - Floating Style */
.icon-btn {
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.icon-btn:hover {
  background: var(--bg-secondary);
  transform: scale(1.1);
  box-shadow: var(--shadow-md);
}

.icon-btn:active {
  transform: scale(0.95);
}

/* Small Notification Badge for Header */
.notification-badge-small {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: linear-gradient(135deg, #FF3B30 0%, #FF2D55 100%);
  border-radius: 9px;
  font-size: 0.65rem;
  font-weight: 700;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(255, 59, 48, 0.5);
  border: 2px solid var(--bg-primary);
  animation: badge-pop 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Inputs - iOS Style */
.input-group {
  margin-bottom: 1.25rem;
}

.input-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.modern-input {
  width: 100%;
  padding: 1rem 1.25rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.2s ease;
}

.modern-input:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.15);
}

.modern-input::placeholder {
  color: var(--text-tertiary);
}

/* CarPlay Icon Grid */
.carplay-icon {
  width: 80px;
  height: 80px;
  background: var(--bg-elevated);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.carplay-icon:hover {
  transform: scale(1.08);
  box-shadow: var(--shadow-lg);
}

.carplay-icon:active {
  transform: scale(0.95);
}

.carplay-icon-emoji {
  font-size: 2.5rem;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.15));
}

.carplay-icon-label {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-align: center;
  letter-spacing: -0.1px;
}

/* Stats - Minimalistic */
.stat-card {
  background: var(--bg-elevated);
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.stat-icon {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.1));
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-blue);
  margin-bottom: 0.25rem;
  letter-spacing: -1px;
}

.stat-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Vehicle Cards - CarPlay Grid Style */
.vehicle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.vehicle-card-modern {
  background: var(--bg-elevated);
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.vehicle-card-modern:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-xl);
}

.vehicle-card-header {
  background: var(--bg-tertiary);
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.license-plate {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.plate-country {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.plate-number {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 2px;
  font-family: 'SF Mono', 'Monaco', 'Courier New', monospace;
}

.vehicle-icon-large {
  font-size: 3rem;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.15));
}

.vehicle-card-body {
  padding: 1.5rem;
}

.vehicle-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
  letter-spacing: -0.3px;
}

.vehicle-year {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.vehicle-description {
  font-size: 0.875rem;
  color: var(--text-tertiary);
  line-height: 1.5;
}

.vehicle-reactions {
  display: flex;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--separator-color);
  background: var(--bg-secondary);
}

.reaction-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* Search - iOS Style */
.search-container {
  background: var(--bg-elevated);
  border-radius: 16px;
  padding: 1rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.search-form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.search-input {
  flex: 1;
  padding: 1rem 1.25rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.2s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-blue);
  background: var(--bg-elevated);
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
}

.search-btn {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: none;
  background: var(--accent-blue);
  color: white;
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.search-btn:hover:not(:disabled) {
  opacity: 0.9;
  transform: scale(1.05);
}

.search-btn:active {
  transform: scale(0.95);
}

.search-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Detail Card */
.detail-card {
  background: var(--bg-elevated);
  border-radius: 24px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
}

.detail-header {
  background: var(--bg-tertiary);
  padding: 2rem;
  text-align: center;
}

.detail-icon {
  font-size: 5rem;
  margin-bottom: 1rem;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.15));
}

.license-plate-large {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-elevated);
  padding: 1.5rem 2.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  border: 2px solid var(--border-color);
}

.license-plate-large .plate-number {
  font-size: 2.5rem;
}

.detail-body {
  padding: 2rem;
}

.detail-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.detail-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.detail-description {
  background: var(--bg-tertiary);
  padding: 1.25rem;
  border-radius: 12px;
  border-left: 4px solid var(--accent-blue);
  margin-bottom: 1.5rem;
}

.detail-description p {
  color: var(--text-secondary);
  line-height: 1.6;
}

.detail-owner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1rem;
  color: var(--text-secondary);
  padding: 1rem;
  background: var(--bg-tertiary);
  border-radius: 12px;
  font-weight: 500;
}

/* Reactions - CarPlay Grid */
.reactions-container {
  background: var(--bg-elevated);
  border-radius: 20px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.reactions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.reaction-btn-modern {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem 0.75rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.reaction-btn-modern:hover {
  transform: scale(1.05);
  background: var(--bg-elevated);
  box-shadow: var(--shadow-md);
}

.reaction-btn-modern:active {
  transform: scale(0.95);
}

.reaction-btn-modern.active {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
}

.reaction-emoji {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  display: block;
}

.reaction-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.25rem;
}

.reaction-btn-modern.active .reaction-label {
  color: white;
}

.reaction-count {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-blue);
}

.reaction-btn-modern.active .reaction-count {
  color: white;
}

/* Stats Grid */
.stats-container {
  background: var(--bg-elevated);
  border-radius: 20px;
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.stat-box {
  text-align: center;
  padding: 1.5rem 0.75rem;
  background: var(--bg-tertiary);
  border-radius: 16px;
  transition: all 0.2s ease;
}

.stat-box:hover {
  transform: scale(1.05);
  background: var(--bg-elevated);
  box-shadow: var(--shadow-md);
}

.stat-emoji {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  display: block;
}

.stat-value-large {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
  letter-spacing: -1px;
}

.stat-label-small {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

/* Modal - iOS Style */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 1000;
  animation: fade-in 0.2s ease-out;
}

.modal-content {
  background: var(--bg-elevated);
  border-radius: 24px;
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-color);
  animation: scale-in 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem;
  border-bottom: 1px solid var(--separator-color);
}

.modal-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.modal-close {
  background: var(--bg-tertiary);
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: var(--bg-secondary);
  transform: scale(1.1);
}

.modal-body {
  padding: 1.5rem;
}

/* Bottom Navigation - CarPlay Style */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--blur-bg);
  backdrop-filter: blur(40px) saturate(180%);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  border-top: 1px solid var(--separator-color);
  padding: 0.5rem 0 env(safe-area-inset-bottom, 0.5rem);
  z-index: 100;
  box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.08);
}

.bottom-nav-container {
  max-width: 600px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.25rem;
  padding: 0 0.5rem;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  padding: 0.4rem 0.25rem;
  background: transparent;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 56px;
}

.nav-item:active {
  transform: scale(0.92);
}

.nav-item.active {
  background: var(--bg-tertiary);
}

.nav-icon {
  transition: transform 0.2s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.nav-item.active .nav-icon {
  transform: scale(1.1);
}

.nav-label {
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.nav-item.active .nav-label {
  color: var(--accent-blue);
  font-weight: 700;
}

/* Responsive: 2 Rows on very small screens */
@media (max-width: 380px) {
  .bottom-nav-container {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.25rem;
  }
  
  .nav-icon {
    font-size: 1.35rem;
  }
  
  .nav-label {
    font-size: 0.55rem;
  }
}

/* Empty States */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
}

.empty-icon {
  font-size: 5rem;
  opacity: 0.2;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

/* Monochrome Icons - Professional Look */
.nav-icon i,
.fab-icon i,
.icon-btn i {
  color: var(--text-secondary);
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-item.active .nav-icon i {
  color: var(--accent-blue);
  transform: scale(1.1);
}

.icon-btn:hover i {
  color: var(--text-primary);
  transform: scale(1.1);
}

.fab-icon i {
  color: white;
}

.empty-text {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  letter-spacing: -0.3px;
}

.empty-subtext {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Messages */
.error-message {
  background: rgba(255, 59, 48, 0.1);
  border: 1px solid rgba(255, 59, 48, 0.3);
  border-radius: 12px;
  padding: 1rem;
  color: var(--accent-red);
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.demo-box {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
}

/* Animations */
@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

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

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

.animate-fade-in {
  animation: fade-in 0.4s ease-out forwards;
}

.animate-fade-in-up {
  animation: fade-in-up 0.4s ease-out forwards;
}

.animate-slide-down {
  animation: slide-down 0.4s ease-out forwards;
}

.animate-scale-in {
  animation: scale-in 0.3s ease-out forwards;
}

/* Responsive */
@media (max-width: 640px) {
  .app-title {
    font-size: 2.5rem;
  }
  
  .vehicle-grid {
    grid-template-columns: 1fr;
  }
  
  .reactions-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Scrollbar - iOS Style */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--text-tertiary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-secondary);
}

/* Safe Area Support */
@supports (padding: env(safe-area-inset-bottom)) {
  .bottom-nav {
    padding-bottom: env(safe-area-inset-bottom);
  }
}

/* ========== FLOATING ACTION BUTTONS (FAB) ========== */
.fab-container {
  position: fixed;
  right: 1rem;
  bottom: 72px; /* Über Bottom Nav */
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 90;
  pointer-events: none; /* Container ist durchklickbar */
}

.fab-container > * {
  pointer-events: auto; /* Nur Buttons sind klickbar */
}

.fab {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.fab::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  padding: 2px;
  background: linear-gradient(135deg, rgba(255,255,255,0.4), rgba(255,255,255,0.1));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

.fab:hover {
  transform: scale(1.1) rotate(8deg);
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.25);
}

.fab:active {
  transform: scale(0.95) rotate(0deg);
}

/* Reaction FAB - Solid Color */
.fab-reaction {
  background: #EC4899;
  box-shadow: 0 2px 8px rgba(236, 72, 153, 0.25);
}

.fab-reaction:hover {
  opacity: 0.9;
}

/* Warning FAB - Solid Color */
.fab-warning {
  background: #F59E0B;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.25);
}

.fab-warning:hover {
  opacity: 0.9;
}

/* Notification FAB - Solid Color */
.fab-notification {
  background: var(--accent-blue);
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25);
  position: relative;
}

.fab-notification:hover {
  opacity: 0.9;
}

.fab-notification .fab-icon {
  display: block;
}

/* Notification Badge */
.fab-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  background: #EF4444;
  border-radius: 11px;
  font-size: 0.7rem;
  font-weight: 700;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-primary);
  z-index: 10;
  line-height: 1;
  pointer-events: none;
}

@keyframes badge-pop {
  0% {
    transform: scale(0);
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
  }
}

.fab-warning:hover {
  box-shadow: 0 6px 30px rgba(255, 149, 0, 0.6);
}

/* Pulse Animation für Attention */
@keyframes fab-pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.25);
  }
}

.fab.pulse {
  animation: fab-pulse 2s ease-in-out infinite;
}

/* Ripple Effect */
.fab::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  opacity: 0;
  transform: scale(0);
  transition: transform 0.5s, opacity 0.5s;
}

.fab:active::after {
  transform: scale(1.5);
  opacity: 0;
}

/* Hide FAB on certain screens */
.fab-container.hide {
  display: none;
}

/* Mobile Optimierung */
@media (max-width: 480px) {
  .fab-container {
    right: 0.75rem;
    bottom: 68px;
    gap: 0.65rem;
  }
  
  .fab {
    width: 52px;
    height: 52px;
    font-size: 1.6rem;
  }
}

/* Dark Theme Support */
[data-theme="dark"] .fab {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .fab:hover {
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.6);
}
