/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family:
    'Inter',
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  line-height: 1.6;
  background: var(--bg-primary);
  color: var(--text-primary);
  transition: all 0.3s ease;
  min-height: 100vh;
}

/* CSS Variables for theming */
:root {
  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-tertiary: #f1f5f9;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --border: #e2e8f0;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --radius: 0.75rem;
}

[data-theme='dark'] {
  --bg-primary: #0a0a0a;
  --bg-secondary: #1a1a1a;
  --bg-tertiary: #2a2a2a;
  --text-primary: #ffffff;
  --text-secondary: #e5e5e5;
  --text-muted: #a3a3a3;
  --border: #404040;
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6);
}

/* Header */
.header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.header-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

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

.logo-icon {
  width: 2.5rem;
  height: 2.5rem;
  /* Remove background and gradient */
  background: none;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.25rem;
}

.logo h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

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

.space-selector {
  min-width: 200px;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--shadow);
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1rem;
  padding-right: 2.5rem;
}

.space-selector:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.space-selector:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow:
    0 0 0 3px rgba(37, 99, 235, 0.1),
    0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

[data-theme='dark'] .space-selector {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%9ca3af' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
}

.control-btn {
  width: 4rem;
  height: 2.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-size: 1.125rem;
  box-shadow: var(--shadow);
}

.control-btn:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  .control-btn {
    width: 2.5rem;
  }
}

/* Main Content */
.main-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
}

/* Space Banner */
.space-banner {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
}

.banner-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
}

.space-info h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.space-details {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.time-range {
  color: var(--text-secondary);
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--bg-tertiary);
  border-radius: 9999px;
}

.time-range::before {
  content: '🕐';
}

.status-badge {
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-badge.active {
  background: #dcfce7;
  color: #166534;
}

.status-badge.auto-selected {
  background: #dbeafe;
  color: #1e40af;
  position: relative;
}

.status-badge.auto-selected::before {
  content: '🤖';
  margin-right: 0.25rem;
  font-size: 0.75rem;
}

.status-badge.inactive {
  background: var(--bg-tertiary);
  color: var(--text-muted);
}

[data-theme='dark'] .status-badge.active {
  background: #065f46;
  color: #34d399;
}

[data-theme='dark'] .status-badge.auto-selected {
  background: #1e3a8a;
  color: #60a5fa;
}

.current-time {
  text-align: right;
}

.current-time .time {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.current-time .date {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* Filter Chips */
.filter-chips {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  align-items: center;
}

.filter-chip {
  padding: 0.75rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: 9999px;
  background: var(--bg-secondary);
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.filter-chip:hover {
  background: var(--bg-tertiary);
  border-color: var(--primary);
  color: var(--text-primary);
}

.filter-chip.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.chip-count {
  opacity: 0.75;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.2);
  padding: 0.125rem 0.375rem;
  border-radius: 9999px;
  margin-left: 0.25rem;
}

.filter-chip:not(.active) .chip-count {
  background: var(--bg-tertiary);
  color: var(--text-muted);
}

/* Links Grid */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.link-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  display: block;
}

.link-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.link-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient, var(--primary));
  opacity: 0;
  transition: opacity 0.2s ease;
}

.link-card:hover::before {
  opacity: 1;
}

.link-content {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  position: relative;
}

.link-icon {
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius);
  /* Remove background and gradient */
  background: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  font-size: 1.25rem;
  flex-shrink: 0;
  /* Center SVGs visually */
  overflow: hidden;
}

/* Loading spinner for icons */
.link-icon .fa-spinner {
  animation: spin 1s linear infinite;
  opacity: 0.5;
}

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

.link-info {
  flex: 1;
  min-width: 0;
}

.link-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.link-url {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  word-break: break-all;
  line-height: 1.4;
}

.link-tag {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: var(--bg-tertiary);
  color: var(--text-muted);
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
}

/* Favorite Button */
.favorite-btn {
  position: absolute;
  top: 0;
  right: 0;
  width: 2rem;
  height: 2rem;
  border: none;
  background: var(--bg-tertiary);
  color: var(--text-muted);
  border-radius: 0.375rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-size: 0.875rem;
  opacity: 0.7;
}

.favorite-btn:hover {
  background: var(--warning);
  color: white;
  opacity: 1;
  transform: scale(1.1);
}

.favorite-btn.active {
  background: var(--warning);
  color: white;
  opacity: 1;
}

.favorite-btn.active:hover {
  background: #d97706;
}

/* Favorites Filter Chip */
.filter-chip.favorites-chip {
  background: linear-gradient(135deg, var(--warning), #d97706);
  color: white;
  border: none;
}

.filter-chip.favorites-chip:hover {
  background: linear-gradient(135deg, #d97706, #b45309);
  transform: translateY(-1px);
}

.filter-chip.favorites-chip.active {
  background: linear-gradient(135deg, #b45309, #92400e);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.filter-chip.favorites-chip i {
  margin-right: 0.25rem;
}

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

.empty-icon {
  width: 4rem;
  height: 4rem;
  background: var(--bg-tertiary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 1.5rem;
  color: var(--text-muted);
}

.empty-state h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.empty-state p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

/* Buttons */
.primary-btn {
  background: var(--primary);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
}

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

.secondary-btn {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.875rem;
}

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

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
}

.modal-content {
  background: var(--bg-secondary);
  border-radius: var(--radius);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

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

.modal-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.close-btn {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 0.25rem;
  transition: all 0.2s ease;
}

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

.modal-body {
  padding: 1.5rem;
  max-height: 60vh;
  overflow-y: auto;
}

.modal-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

/* Tabs */
.tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.5rem;
}

.tab-btn {
  padding: 0.75rem 1rem;
  border: none;
  background: none;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
  font-weight: 500;
}

.tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-btn:hover:not(.active) {
  color: var(--text-primary);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

/* Form Elements */
label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-primary);
}

input,
textarea,
select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: inherit;
  transition: border-color 0.2s ease;
  font-size: 0.875rem;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

textarea {
  resize: vertical;
  font-family: 'Monaco', 'Consolas', monospace;
  line-height: 1.5;
}

.help-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* File Upload Styles */
.file-upload-container {
  margin-bottom: 1rem;
}

.file-upload-label {
  display: block;
  cursor: pointer;
  transition: all 0.2s ease;
}

.file-upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  background: var(--bg-tertiary);
  transition: all 0.2s ease;
  position: relative;
}

.file-upload-area:hover {
  border-color: var(--primary);
  background: var(--bg-secondary);
}

.file-upload-area.dragover {
  border-color: var(--primary);
  background: var(--bg-secondary);
  transform: scale(1.02);
}

.file-upload-area i {
  font-size: 2rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  display: block;
}

.upload-text {
  display: block;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.upload-hint {
  display: block;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.file-info {
  margin-top: 1rem;
  padding: 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.file-details {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.file-details i {
  font-size: 1.25rem;
  color: var(--primary);
}

.file-details span {
  flex: 1;
  font-weight: 500;
  color: var(--text-primary);
  word-break: break-all;
}

.remove-file-btn {
  width: 2rem;
  height: 2rem;
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  background: var(--bg-secondary);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-size: 0.875rem;
}

.remove-file-btn:hover {
  background: var(--danger);
  color: white;
  border-color: var(--danger);
}

[data-theme='dark'] .file-upload-area {
  background: var(--bg-tertiary);
}

[data-theme='dark'] .file-upload-area:hover {
  background: var(--bg-secondary);
}

.error-message {
  background: #fef2f2;
  color: #dc2626;
  padding: 0.75rem;
  border-radius: var(--radius);
  border: 1px solid #fecaca;
  margin-top: 1rem;
  font-size: 0.875rem;
}

[data-theme='dark'] .error-message {
  background: #2d1b1b;
  color: #f87171;
  border-color: #7f1d1d;
}

/* Settings Panel */
.settings-panel {
  position: fixed;
  top: 0;
  right: -400px;
  width: 400px;
  height: 100%;
  background: var(--bg-secondary);
  border-left: 1px solid var(--border);
  z-index: 1000;
  transition: right 0.3s ease;
  box-shadow: var(--shadow-lg);
}

.settings-panel.active {
  right: 0;
}

.settings-content {
  height: 100%;
  display: flex;
  flex-direction: column;
}

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

.settings-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.settings-body {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
}

.setting-group {
  margin-bottom: 2rem;
}

.setting-group > label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.radio-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.radio-option:hover {
  background: var(--bg-tertiary);
}

.radio-option input {
  width: auto;
  margin: 0;
}

.spaces-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.space-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: var(--bg-tertiary);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.space-info {
  flex: 1;
  min-width: 0;
}

.space-name {
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

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

.delete-btn {
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 0.25rem;
  transition: background-color 0.2s ease;
}

.delete-btn:hover {
  background: rgba(239, 68, 68, 0.1);
}

.default-badge {
  background: var(--primary);
  color: white;
  padding: 0.375rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.about-info p {
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.github-attribution {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.github-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-primary);
  transition: all 0.2s ease;
}

.github-link:hover {
  color: var(--primary);
  border-color: var(--primary);
  background: var(--bg-secondary);
  transform: translateY(-1px);
}

.github-link i {
  font-size: 1rem;
}

/* Gradients for link icons */
.gradient-backend {
  --gradient: linear-gradient(135deg, #f59e0b, #ea580c);
}
.gradient-frontend {
  --gradient: linear-gradient(135deg, #8b5cf6, #ec4899);
}
.gradient-devops {
  --gradient: linear-gradient(135deg, #06b6d4, #2563eb);
}
.gradient-tools {
  --gradient: linear-gradient(135deg, #10b981, #059669);
}
.gradient-design {
  --gradient: linear-gradient(135deg, #f43f5e, #ec4899);
}
.gradient-monitoring {
  --gradient: linear-gradient(135deg, #ea580c, #dc2626);
}
.gradient-communication {
  --gradient: linear-gradient(135deg, #10b981, #14b8a6);
}
.gradient-documentation {
  --gradient: linear-gradient(135deg, #6366f1, #8b5cf6);
}
.gradient-social-media {
  --gradient: linear-gradient(135deg, #3b82f6, #1d4ed8);
}
.gradient-entertainment {
  --gradient: linear-gradient(135deg, #dc2626, #991b1b);
}
.gradient-music {
  --gradient: linear-gradient(135deg, #059669, #047857);
}
.gradient-default {
  --gradient: linear-gradient(135deg, #2563eb, #3b82f6);
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-content {
    padding: 0 1rem;
    flex-direction: column;
    gap: 1rem;
    align-items: stretch;
  }

  .controls {
    justify-content: space-between;
  }

  .space-selector {
    min-width: auto;
    flex: 1;
  }

  .main-content {
    padding: 1rem;
  }

  .banner-content {
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
  }

  .current-time {
    text-align: center;
  }

  .links-grid {
    grid-template-columns: 1fr;
  }

  .settings-panel {
    width: 100%;
    right: -100%;
  }

  .modal-content {
    width: 95%;
    margin: 1rem;
  }

  .search-container {
    display: none;
  }

  .header-content {
    gap: 0.5rem;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.3s ease-out;
}

/* Remove all previous index/NIFTY/BANKNIFTY styles, as we're embedding TradingView widget now */
.tradingview-widget-container {
  margin-top: 0.5rem;
  margin-bottom: 1rem;
  width: 100%;
  max-width: 600px;
}
.tradingview-widget-container__widget {
  min-height: 48px;
}
.tradingview-widget-copyright {
  text-align: right;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* Advice Card Styles */
.advice-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
  padding: 1.5rem 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 3.5rem;
  position: relative;
  font-size: 1.1rem;
}

.advice-quote-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--primary);
  font-size: 1.15rem;
  font-weight: 500;
  text-align: center;
  width: 100%;
  justify-content: center;
}

.advice-quote-card i {
  color: var(--primary);
  font-size: 1.5rem;
  opacity: 0.7;
}

.advice-text {
  color: var(--text-primary);
  font-style: italic;
  font-size: 1.1rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.advice-loading {
  color: var(--text-muted);
  font-size: 1rem;
  text-align: center;
  width: 100%;
}

[data-theme='dark'] .advice-card {
  background: var(--bg-tertiary);
  border-color: var(--border);
}

[data-theme='dark'] .advice-quote-card i {
  color: #60a5fa;
}

[data-theme='dark'] .advice-text {
  color: var(--text-secondary);
}

/* Search Bar */
.search-container {
  flex: 1;
  max-width: 600px;
  margin: 0 1rem;
}

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

.search-input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.2s ease;
  box-shadow: var(--shadow);
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-btn {
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  font-size: 1rem;
  box-shadow: var(--shadow);
}

.search-btn:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

@media (max-width: 768px) {
  .search-container {
    max-width: none;
    margin: 0.5rem 0;
  }
  
  .header-content {
    flex-wrap: wrap;
  }
}

/* Auto-switch notification */
.auto-switch-notification {
  position: fixed;
  top: 2rem;
  right: 2rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.5rem;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  z-index: 1000;
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s ease;
  max-width: 300px;
}

.auto-switch-notification.show {
  transform: translateX(0);
  opacity: 1;
}

.auto-switch-notification i {
  color: var(--primary);
  font-size: 1.125rem;
}

.auto-switch-notification span {
  color: var(--text-primary);
  font-size: 0.875rem;
  font-weight: 500;
}

@media (max-width: 768px) {
  .auto-switch-notification {
    top: 1rem;
    right: 1rem;
    left: 1rem;
    max-width: none;
    transform: translateY(-100%);
  }
  
  .auto-switch-notification.show {
    transform: translateY(0);
  }
}
