/* Dashboard Specific Styles */

.dashboard-container {
  display: flex;
  min-height: 100vh;
  background-color: var(--bg-cream);
}

/* Sidebar Styling */
.dashboard-sidebar {
  width: 280px;
  background-color: var(--primary-navy);
  color: var(--text-light);
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border-dark);
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 50;
  transition: transform var(--transition-normal);
}

.sidebar-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-dark);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.sidebar-nav {
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  overflow-y: auto;
  flex-grow: 1;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius-md);
  font-size: 0.9rem;
  font-weight: 500;
  color: hsl(210, 20%, 80%);
  cursor: pointer;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  transition: all var(--transition-fast);
}

.sidebar-nav-item:hover, .sidebar-nav-item.active {
  background-color: rgba(255, 255, 255, 0.08);
  color: var(--bg-white);
}

.sidebar-nav-item.active {
  border-left: 3px solid var(--accent-gold);
  border-radius: 0 var(--border-radius-md) var(--border-radius-md) 0;
  padding-left: calc(1rem - 3px);
  background-color: rgba(255, 255, 255, 0.05);
}

.sidebar-nav-item svg {
  width: 18px;
  height: 18px;
  stroke: var(--accent-gold);
}

.sidebar-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border-dark);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--primary-navy-light);
}

.user-profile-summary {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.user-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: var(--accent-gold);
  color: var(--primary-navy);
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--bg-white);
}

.user-tier {
  font-size: 0.7rem;
  color: var(--accent-gold);
  font-weight: 600;
}

/* Main Dashboard Workspace */
.dashboard-main {
  flex-grow: 1;
  margin-left: 280px;
  padding: 2.5rem;
  min-width: 0; /* Prevents flex items from overflowing */
}

.dashboard-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.dashboard-title-area h1 {
  font-size: 2rem;
}

.dashboard-title-area p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.streak-counter-pill {
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-xl);
  padding: 0.5rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  color: var(--text-dark);
}

.streak-counter-pill svg {
  color: var(--warning-amber);
}

/* Responsive sidebar */
@media (max-width: 992px) {
  .dashboard-sidebar {
    transform: translateX(-100%);
  }
  .dashboard-sidebar.active {
    transform: translateX(0);
  }
  .dashboard-main {
    margin-left: 0;
    padding: 1.5rem;
  }
  .dashboard-header-bar {
    margin-top: 3rem; /* Leave space for hamburger button */
  }
}

/* Dashboard Tab Panel Display */
.dashboard-tab-panel {
  display: none;
}

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

/* Plan Dashboard Widgets */
.dashboard-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.summary-widget {
  background: var(--bg-white);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.widget-icon-box {
  width: 48px;
  height: 48px;
  border-radius: var(--border-radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.widget-icon-box.gold { background-color: hsl(38, 92%, 93%); color: var(--accent-gold); }
.widget-icon-box.sage { background-color: var(--secondary-sage-light); color: var(--secondary-sage); }
.widget-icon-box.navy { background-color: rgba(30, 41, 59, 0.08); color: var(--primary-navy); }

.widget-content-box {
  display: flex;
  flex-direction: column;
}

.widget-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-navy);
}

.widget-lbl {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Reading Planner Layout split */
.plan-split-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2rem;
  align-items: start;
}

@media (max-width: 992px) {
  .plan-split-grid {
    grid-template-columns: 1fr;
  }
}

.daily-checklist-card {
  max-height: 550px;
  overflow-y: auto;
}

.checklist-items-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.checklist-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  background-color: var(--bg-slate);
  padding: 1rem;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  transition: all var(--transition-fast);
}

.checklist-item.completed {
  opacity: 0.6;
  background-color: var(--bg-white);
  border-color: var(--border-light);
}

.checklist-item input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--secondary-sage);
  cursor: pointer;
}

.checklist-details {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.checklist-ref {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--primary-navy);
}

.checklist-item.completed .checklist-ref {
  text-decoration: line-through;
}

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

/* Journal tab styles */
.journal-editor-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2rem;
}

@media (max-width: 992px) {
  .journal-editor-grid {
    grid-template-columns: 1fr;
  }
}

.journal-history-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-height: 480px;
  overflow-y: auto;
}

.history-item {
  padding: 1rem;
  background-color: var(--bg-white);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.history-item:hover, .history-item.active {
  border-color: var(--accent-gold);
  background-color: var(--bg-cream);
}

.history-title {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 0.95rem;
}

.history-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* Prayer requests tracker styling */
.prayer-tab-layout {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

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

.prayer-column {
  background-color: var(--bg-white);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  padding: 1.5rem;
  min-height: 350px;
}

.prayer-column-title {
  font-size: 1.1rem;
  border-bottom: 2px solid var(--bg-slate);
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.prayer-count-badge {
  background-color: var(--bg-slate);
  color: var(--primary-navy);
  padding: 0.1rem 0.5rem;
  border-radius: var(--border-radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
}

.prayer-list-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.prayer-card {
  background-color: var(--bg-cream);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-light);
  padding: 1rem;
  position: relative;
}

.prayer-card-header {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--primary-navy);
  margin-bottom: 0.35rem;
}

.prayer-card-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.prayer-card-actions {
  display: flex;
  gap: 0.5rem;
}

/* AI coach chat interface */
.ai-coach-wrapper {
  background-color: var(--bg-white);
  border-radius: var(--border-radius-lg);
  border: 1px solid var(--border-light);
  height: 550px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-md);
}

.ai-coach-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-light);
  background-color: var(--primary-navy);
  color: var(--text-light);
  border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.coach-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--secondary-sage);
}

.ai-coach-chat-area {
  flex-grow: 1;
  padding: 1.5rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.chat-bubble {
  max-width: 75%;
  padding: 1rem;
  border-radius: var(--border-radius-md);
  font-size: 0.9rem;
}

.chat-bubble.coach {
  background-color: var(--bg-cream);
  color: var(--text-dark);
  align-self: flex-start;
  border-bottom-left-radius: var(--border-radius-sm);
}

.chat-bubble.user {
  background-color: var(--primary-navy);
  color: var(--bg-white);
  align-self: flex-end;
  border-bottom-right-radius: var(--border-radius-sm);
}

.ai-coach-input-area {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border-light);
  display: flex;
  gap: 0.75rem;
}

/* Scripture Memorizer Flashcard layout */
.memorizer-layout {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  max-width: 600px;
  margin: 0 auto;
}

.memorize-card {
  width: 100%;
  background-color: var(--bg-white);
  border: 2px solid var(--accent-gold);
  border-radius: var(--border-radius-lg);
  padding: 3rem;
  text-align: center;
  box-shadow: var(--shadow-lg);
  min-height: 250px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.memorize-ref {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}

.memorize-verse {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--primary-navy);
  min-height: 120px;
}

.hidden-word {
  border-bottom: 2px dashed var(--accent-gold);
  color: transparent;
  user-select: none;
  padding: 0 4px;
}

.memorizer-controls {
  display: flex;
  gap: 1rem;
  width: 100%;
  justify-content: center;
}

/* Quiz UI cards */
.quiz-widget {
  background-color: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-lg);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
  max-width: 650px;
  margin: 0 auto;
}

.quiz-progress-bar-bg {
  width: 100%;
  height: 8px;
  background-color: var(--bg-slate);
  border-radius: var(--border-radius-sm);
  margin-bottom: 1.5rem;
  overflow: hidden;
}

.quiz-progress-bar-fill {
  height: 100%;
  background-color: var(--accent-gold);
  width: 0%;
  transition: width var(--transition-normal);
}

.quiz-question-ref {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.quiz-question-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.quiz-options-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.quiz-option-btn {
  width: 100%;
  padding: 1rem;
  text-align: left;
  background-color: var(--bg-cream);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-md);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.quiz-option-btn:hover {
  background-color: var(--bg-slate);
  border-color: var(--primary-navy);
}

.quiz-option-btn.selected {
  background-color: rgba(30, 41, 59, 0.08);
  border-color: var(--primary-navy);
  font-weight: 600;
}

.quiz-option-btn.correct {
  background-color: var(--secondary-sage-light);
  border-color: var(--secondary-sage);
  color: hsl(142, 60%, 25%);
  font-weight: 600;
}

.quiz-option-btn.wrong {
  background-color: hsl(0, 75%, 95%);
  border-color: var(--danger-crimson);
  color: hsl(0, 75%, 25%);
}

/* Habit streaks circular visualization */
.habit-tracker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.habit-streak-card {
  background-color: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--border-radius-md);
  padding: 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.circle-progress-svg {
  width: 120px;
  height: 120px;
  transform: rotate(-90deg);
}

.circle-bg {
  fill: none;
  stroke: var(--bg-slate);
  stroke-width: 8px;
}

.circle-fill {
  fill: none;
  stroke: var(--accent-gold);
  stroke-width: 8px;
  stroke-linecap: round;
  stroke-dasharray: 314; /* 2 * pi * r (where r = 50) */
  stroke-dashoffset: 314;
  transition: stroke-dashoffset 1s ease-in-out;
}

.circle-fill.sage {
  stroke: var(--secondary-sage);
}

.circle-text-center {
  position: absolute;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-navy);
}

/* Hamburger overlay for mobile view */
.mobile-header-bar {
  display: none;
  background-color: var(--primary-navy);
  color: var(--text-light);
  padding: 0.75rem 1rem;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-dark);
}

@media (max-width: 992px) {
  .mobile-header-bar {
    display: flex;
  }
}
