/* ==========================================================================
   EasySlim - Interactive Widgets Stylesheet
   Water Intake Calculator & Multi-Step Metabolic Quiz
   ========================================================================== */

/* Calculator Layout */
.calculator-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
  padding: 40px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
}

@media (max-width: 860px) {
  .calculator-card {
    grid-template-columns: 1fr;
    padding: 24px;
    gap: 30px;
  }
}

.calc-inputs-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.calc-field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.calc-label {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--primary);
  display: flex;
  justify-content: space-between;
}

.range-slider-wrapper {
  display: flex;
  align-items: center;
  gap: 16px;
}

.calc-range-slider {
  flex-grow: 1;
  -webkit-appearance: none;
  height: 8px;
  border-radius: 4px;
  background: #D9E4DD;
  outline: none;
}

.calc-range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  transition: transform 0.15s ease;
}

.calc-range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.calc-number-input {
  width: 80px;
  padding: 8px 12px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary);
  text-align: center;
}

.calc-select {
  padding: 12px 16px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-sm);
  background-color: #FAFAFA;
  font-size: 0.95rem;
  color: var(--text-main);
  cursor: pointer;
  font-weight: 500;
}

.calc-checkbox-label {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background-color: var(--bg-mint);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--primary);
}

.calc-checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* Calculator Result Column */
.calc-results-col {
  background: linear-gradient(135deg, #1E3F20 0%, #2D5B33 100%);
  border-radius: var(--radius-md);
  color: #FFFFFF;
  padding: 34px 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  box-shadow: var(--shadow-sm);
}

.results-display-box {
  text-align: center;
}

.results-header-text {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #A8D5B8;
  margin-bottom: 8px;
  font-weight: 700;
}

.result-liters-number {
  font-size: 3.6rem;
  font-weight: 900;
  line-height: 1;
  color: #FFFFFF;
  margin-bottom: 6px;
}

.result-glasses-text {
  font-size: 1.1rem;
  color: #D3EBDC;
  font-weight: 600;
}

/* Water Visual Glass */
.water-glass-container {
  margin: 15px auto;
  width: 90px;
  height: 130px;
  border: 3px solid rgba(255, 255, 255, 0.7);
  border-top: none;
  border-radius: 0 0 16px 16px;
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
}

.water-glass-fill {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60%;
  background: linear-gradient(to top, #48cae4, #00b4d8);
  transition: height 0.4s ease;
  border-radius: 0 0 13px 13px;
}

.calc-pro-tip {
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  padding: 14px;
  font-size: 0.85rem;
  line-height: 1.5;
  color: #E2F2E9;
}

.calc-pro-tip strong {
  display: block;
  color: #FFE66D;
  margin-bottom: 4px;
}

/* Water Hourly Timeline */
.water-schedule-card {
  margin-top: 35px;
  background-color: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  padding: 30px;
}

.water-schedule-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.schedule-item {
  background-color: var(--bg-subtle);
  border-radius: var(--radius-sm);
  padding: 16px;
  border-left: 4px solid var(--primary);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.schedule-time {
  font-weight: 800;
  color: var(--accent);
  font-size: 0.95rem;
}

.schedule-amount {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--primary);
}

.schedule-content h4 {
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.schedule-content p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Interactive Metabolic Quiz Styling
   ========================================================================== */
.quiz-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
  padding: 40px;
  max-width: 780px;
  margin: 0 auto;
  transition: var(--transition);
}

@media (max-width: 600px) {
  .quiz-card {
    padding: 24px 20px;
  }
}

.quiz-header {
  margin-bottom: 24px;
}

.quiz-progress-info {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.quiz-progress-bar {
  width: 100%;
  height: 8px;
  background-color: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.quiz-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
  transition: width 0.3s ease;
}

.quiz-question-title {
  font-size: 1.4rem;
  margin-bottom: 24px;
  line-height: 1.35;
}

.quiz-options-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 30px;
}

.quiz-option-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 16px 20px;
  background-color: var(--bg-subtle);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  cursor: pointer;
  text-align: left;
  transition: var(--transition);
}

.quiz-option-btn:hover {
  background-color: var(--bg-mint);
  border-color: #B5DAC1;
  transform: translateX(4px);
}

.quiz-option-btn.selected {
  background-color: var(--bg-mint);
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(30, 63, 32, 0.08);
}

.opt-indicator {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #FFFFFF;
  border-radius: 50%;
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--primary);
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

.quiz-option-btn.selected .opt-indicator {
  background-color: var(--primary);
  color: #FFFFFF;
}

.opt-text {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-main);
}

.quiz-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border-light);
  padding-top: 20px;
}

/* Quiz Results Card */
.quiz-results-card {
  text-align: center;
}

.results-badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  background-color: var(--bg-mint);
  color: var(--primary);
  font-weight: 800;
  font-size: 0.85rem;
  margin-bottom: 12px;
}

.results-main-title {
  font-size: 1.8rem;
  margin-bottom: 8px;
}

.results-lead {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 30px;
}

.results-pillars {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
  margin-bottom: 35px;
}

.res-pillar-item {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 18px;
  background-color: var(--bg-subtle);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.res-pillar-item.res-highlight {
  background-color: #FDF4E7;
  border-color: #F5D3A2;
}

.res-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
}

.res-text h4 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.res-text p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.results-cta-box {
  background: linear-gradient(135deg, #1E3F20 0%, #152E17 100%);
  color: #FFFFFF;
  border-radius: var(--radius-md);
  padding: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.results-promo-tag {
  background-color: var(--accent);
  color: #FFFFFF;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  letter-spacing: 0.5px;
}

.results-cta-box p {
  font-size: 1rem;
  color: #E2EDE6;
  max-width: 500px;
}

.results-cta-btn {
  width: 100%;
  max-width: 360px;
}

.btn-restart-quiz {
  background: none;
  border: none;
  color: #A9BFAF;
  font-size: 0.85rem;
  cursor: pointer;
  margin-top: 6px;
  font-weight: 600;
}

.btn-restart-quiz:hover {
  color: #FFFFFF;
  text-decoration: underline;
}

/* Modal Popup Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(20, 35, 23, 0.7);
  backdrop-filter: blur(6px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background-color: #FFFFFF;
  border-radius: var(--radius-lg);
  max-width: 560px;
  width: 100%;
  padding: 40px 35px;
  box-shadow: var(--shadow-lg);
  text-align: center;
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .modal-content {
  transform: scale(1);
}

.modal-icon-success {
  width: 68px;
  height: 68px;
  background-color: var(--bg-mint);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 20px;
}

.modal-summary-card {
  background-color: var(--bg-subtle);
  border-radius: var(--radius-sm);
  padding: 18px;
  text-align: left;
  margin: 20px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.9rem;
}

.modal-summary-item {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px dashed var(--border-light);
  padding-bottom: 6px;
}

.modal-summary-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.tracking-tag {
  font-family: monospace;
  font-weight: 700;
  background-color: #E2E8E4;
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--primary);
}

.highlight-total {
  font-weight: 800;
  color: var(--accent);
  font-size: 1.1rem;
}
