:root {
  --bg-color: #0f172a;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --primary: #5865F2; /* Discord Color */
  --primary-hover: #4752C4;
  --danger: #ef4444;
  --danger-hover: #dc2626;
  --glass-bg: rgba(30, 41, 59, 0.7);
  --glass-border: rgba(255, 255, 255, 0.1);
}

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

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  color-scheme: dark;
}

.background-blobs {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.5;
}

.blob-1 {
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(88,101,242,0.8) 0%, rgba(15,23,42,0) 70%);
}

.blob-2 {
  bottom: -10%;
  right: -10%;
  width: 40vw;
  height: 40vw;
  background: radial-gradient(circle, rgba(239,68,68,0.5) 0%, rgba(15,23,42,0) 70%);
}

.app-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

header {
  text-align: center;
  margin-bottom: 3rem;
}

header h1 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

header {
  position: relative;
}

.header-buttons {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  gap: 1rem;
}

.btn-icon {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.3s ease;
}

.btn-icon:hover {
  color: var(--text-main);
}

header p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

.dashboard {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 768px) {
  .dashboard {
    grid-template-columns: 400px 1fr;
  }
}

.form-section {
  position: sticky;
  top: 2rem;
  height: fit-content;
  max-height: calc(100vh - 4rem);
  overflow-y: auto;
}

/* Custom Scrollbar for form section to make it look clean */
.form-section::-webkit-scrollbar {
  width: 6px;
}
.form-section::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 10px;
}

.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

h2 {
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

input, select, textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  color: var(--text-main);
  font-family: inherit;
  font-size: 1rem;
  transition: all 0.3s ease;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(88, 101, 242, 0.3);
}

/* Make calendar/clock icons white in dark theme */
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s;
}

input[type="date"]::-webkit-calendar-picker-indicator:hover,
input[type="time"]::-webkit-calendar-picker-indicator:hover {
  opacity: 1;
}

.btn-primary {
  width: 100%;
  padding: 1rem;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

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

.reminder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.reminder-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 1.5rem;
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.reminder-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.4);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
}

.badge.daily { background: rgba(52, 211, 153, 0.2); color: #34d399; }
.badge.weekly { background: rgba(96, 165, 250, 0.2); color: #60a5fa; }
.badge.specific { background: rgba(244, 114, 182, 0.2); color: #f472b6; }

.btn-delete {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.2rem;
  transition: color 0.2s ease;
}

.btn-delete:hover {
  color: var(--danger);
}

.card-time {
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.card-date {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.card-channel {
  font-size: 0.85rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.card-message {
  font-size: 0.95rem;
  line-height: 1.5;
  background: rgba(0,0,0,0.2);
  padding: 0.75rem;
  border-radius: 8px;
  word-break: break-word;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-content {
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
}

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

.modal-header .btn-icon {
  position: static;
}

.mb-2 {
  margin-bottom: 2rem;
}

.mt-2 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

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

.channel-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0,0,0,0.2);
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--glass-border);
}

.channel-item-name {
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Logs Styles */
.logs-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.log-item {
  background: rgba(0,0,0,0.2);
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.log-status {
  padding: 0.2rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.log-status.success {
  background: rgba(52, 211, 153, 0.2);
  color: #34d399;
}

.log-status.error {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.log-channel {
  font-weight: 600;
  color: var(--text-main);
}

.log-snippet {
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--text-muted);
}

.log-error {
  font-size: 0.85rem;
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
  padding: 0.5rem;
  border-radius: 4px;
  margin-top: 0.25rem;
}

/* List Sections */
.recurring-list-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.recurring-card {
  background: rgba(0,0,0,0.2);
  border: 1px solid var(--glass-border);
  padding: 1rem;
  border-radius: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.recurring-info {
  flex: 1;
}

.recurring-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  gap: 1rem;
  margin-top: 0.25rem;
}

/* Timeline Styles */
.timeline-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.timeline-month {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--primary);
  border-bottom: 2px solid rgba(139, 92, 246, 0.3);
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

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

.timeline-date {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-main);
  background: rgba(139, 92, 246, 0.1);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  display: inline-block;
  align-self: flex-start;
}

.timeline-items {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding-left: 1rem;
  border-left: 2px solid rgba(255,255,255,0.1);
  margin-left: 0.5rem;
}

.timeline-item {
  background: rgba(0,0,0,0.2);
  border: 1px solid var(--glass-border);
  padding: 0.75rem;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.timeline-item-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.timeline-item-time {
  font-weight: 600;
  color: #fff;
  background: rgba(139, 92, 246, 0.5);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
}

.timeline-item-message {
  font-size: 0.95rem;
  color: var(--text-main);
}

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

.tab-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border-bottom: 3px solid transparent;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px 8px 0 0;
}

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

.hidden-tab-content {
  display: none !important;
}

.active-tab-content {
  display: flex;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}
