/* Paul's Painting - Feature Styles
   1. Cost Estimator, 2. Before/After, 4. ROI Calculator,
   5. Sticky Bar, 8. Paintability Forecast, 13. Timeline, 14. Referral */

/* ════════════════════════════════════════════
   5. STICKY MOBILE BAR
   ════════════════════════════════════════════ */
.sticky-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  background: var(--primary-dark);
  padding: 10px 16px;
  display: flex;
  gap: 10px;
  justify-content: center;
  transform: translateY(100%);
  transition: transform 0.35s ease;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.2);
}
.sticky-bar.visible {
  transform: translateY(0);
}
.sticky-bar.hidden {
  transform: translateY(100%);
}

.sticky-btn {
  flex: 1;
  max-width: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all var(--transition);
}

.sticky-btn-call {
  background: var(--accent);
  color: #fff;
}
.sticky-btn-call:hover { background: var(--accent-dark); }

.sticky-btn-text {
  background: rgba(255,255,255,0.15);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
}
.sticky-btn-text:hover { background: rgba(255,255,255,0.25); }

.sticky-btn-icon { font-size: 1.2rem; }

/* Pad bottom of page so sticky bar doesn't cover content */
body { padding-bottom: 0; transition: padding-bottom 0.35s; }
.sticky-bar.visible ~ footer { margin-bottom: 70px; }

@media (min-width: 769px) {
  .sticky-bar { padding: 8px 24px; }
  .sticky-btn { max-width: 240px; padding: 12px 24px; }
}

/* ════════════════════════════════════════════
   8. PAINTABILITY FORECAST
   ════════════════════════════════════════════ */
.forecast-section {
  background: linear-gradient(135deg, #1B4D7A 0%, #2A6BA5 100%);
  color: #fff;
  padding: 48px 0;
}

.forecast-section .section-header h2 { color: #fff; }
.forecast-section .section-header p { color: rgba(255,255,255,0.8); }

.forecast-urgency {
  text-align: center;
  margin-bottom: 32px;
  font-size: 1.1rem;
}
.forecast-urgency strong {
  font-size: 2.2rem;
  color: var(--accent);
  display: inline-block;
  margin: 0 4px;
}

.forecast-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
}

.forecast-card {
  background: rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  padding: 16px 10px;
  text-align: center;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.15);
  transition: all var(--transition);
}
.forecast-card:hover {
  background: rgba(255,255,255,0.18);
  transform: translateY(-3px);
}

.forecast-day {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 2px;
}
.forecast-date {
  font-size: 0.72rem;
  opacity: 0.7;
  margin-bottom: 8px;
}
.forecast-icon {
  font-size: 2rem;
  margin-bottom: 6px;
}
.forecast-temp {
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 4px;
}
.forecast-detail {
  font-size: 0.7rem;
  opacity: 0.7;
  line-height: 1.4;
}
.forecast-status {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  font-family: var(--font-body);
  margin-top: 8px;
}
.forecast-status.ideal { background: #28a745; color: #fff; }
.forecast-status.possible { background: #ffc107; color: #333; }
.forecast-status.poor { background: #dc3545; color: #fff; }

.forecast-score-bar {
  height: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 2px;
  margin-top: 8px;
  overflow: hidden;
}
.forecast-score-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 1s ease;
}
.forecast-score-fill.ideal { background: #28a745; }
.forecast-score-fill.possible { background: #ffc107; }
.forecast-score-fill.poor { background: #dc3545; }

.forecast-cta {
  text-align: center;
  margin-top: 28px;
}

@media (max-width: 768px) {
  .forecast-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .forecast-card:nth-child(n+5) {
    grid-column: span 1;
  }
}
@media (max-width: 480px) {
  .forecast-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .forecast-urgency strong { font-size: 1.8rem; }
}

/* ════════════════════════════════════════════
   1. COST ESTIMATOR
   ════════════════════════════════════════════ */
.estimator-section {
  background: var(--bg-warm);
}

.estimator-wrapper {
  max-width: 700px;
  margin: 0 auto;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 24px var(--shadow);
  overflow: hidden;
  border: 1px solid var(--border);
}

.estimator-header {
  background: var(--primary);
  color: #fff;
  padding: 24px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.estimator-header h3 {
  font-size: 1.1rem;
  margin: 0;
}
.step-indicators {
  display: flex;
  gap: 8px;
}
.step-indicator {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  font-family: var(--font-body);
  transition: all var(--transition);
}
.step-indicator.active {
  background: var(--accent);
  color: #fff;
  transform: scale(1.15);
}
.step-indicator.done {
  background: rgba(255,255,255,0.5);
  color: var(--primary);
}

.estimator-body {
  padding: 32px;
}

.est-step {
  display: none;
}
.est-step.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

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

.est-step h4 {
  font-size: 1.1rem;
  margin-bottom: 16px;
  color: var(--primary);
}
.est-step p {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.est-options {
  display: grid;
  gap: 10px;
}
.est-options.cols-3 {
  grid-template-columns: repeat(3, 1fr);
}
.est-options.cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

.est-option {
  position: relative;
}
.est-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.est-option label {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 12px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
}
.est-option label:hover {
  border-color: var(--primary-light);
  background: rgba(27,77,122,0.03);
}
.est-option input:checked + label {
  border-color: var(--primary);
  background: rgba(27,77,122,0.06);
  box-shadow: 0 0 0 3px rgba(27,77,122,0.15);
}
.est-option-icon {
  font-size: 1.8rem;
  margin-bottom: 6px;
}
.est-option-title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
}
.est-option-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.est-select {
  width: 100%;
  padding: 12px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: var(--font-body);
  margin-bottom: 16px;
}
.est-select:focus {
  border-color: var(--primary);
  outline: none;
}

.est-checkboxes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.est-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}
.est-checkbox:hover { background: var(--bg-light); }
.est-checkbox input { accent-color: var(--primary); width: 18px; height: 18px; }
.est-checkbox span {
  font-size: 0.9rem;
  font-weight: 500;
}

.estimator-nav {
  display: flex;
  justify-content: space-between;
  padding: 0 32px 24px;
}

/* Estimate Result */
.est-result {
  display: none;
  padding: 40px 32px;
  text-align: center;
}
.est-result-amount {
  font-family: var(--font-body);
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--primary);
  margin: 16px 0;
}
.est-result-amount .est-sep {
  color: var(--text-muted);
  font-weight: 400;
  margin: 0 8px;
  font-size: 1.5rem;
}
.est-result h3 {
  color: var(--text);
  font-size: 1.3rem;
  margin-bottom: 8px;
}
.est-result > p {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 24px;
}
.est-result-details {
  text-align: left;
  background: var(--bg-light);
  padding: 16px 20px;
  border-radius: var(--radius);
  margin-bottom: 24px;
}
.est-result-details h4 {
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--primary);
}
.est-result-details ul {
  list-style: none;
}
.est-result-details li {
  padding: 3px 0;
  font-size: 0.85rem;
  color: var(--text-light);
}
.est-result-details li::before {
  content: "- ";
  color: var(--accent);
  font-weight: 700;
}
.est-result-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .est-options.cols-3 { grid-template-columns: 1fr; }
  .est-options.cols-2 { grid-template-columns: 1fr; }
  .est-checkboxes { grid-template-columns: 1fr; }
  .estimator-body { padding: 24px 16px; }
  .estimator-nav { padding: 0 16px 16px; }
  .est-result { padding: 24px 16px; }
  .est-result-amount { font-size: 1.8rem; }
}

/* ════════════════════════════════════════════
   2. BEFORE/AFTER SLIDER
   ════════════════════════════════════════════ */
.gallery-section {
  background: var(--bg);
}

.ba-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.ba-project {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 2px 12px var(--shadow);
}

.ba-slider {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/10;
  cursor: ew-resize;
  user-select: none;
}

.ba-before, .ba-after {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: cover;
  background-position: center;
}

/* Demo before/after using CSS gradients (replace with real photos) */
.ba-before { z-index: 1; }
.ba-after { z-index: 2; }

.ba-label {
  position: absolute;
  padding: 6px 14px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.75rem;
  border-radius: var(--radius);
  z-index: 5;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.ba-label-before { top: 12px; left: 12px; }
.ba-label-after { top: 12px; right: 12px; }

.ba-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background: #fff;
  z-index: 10;
  cursor: ew-resize;
  box-shadow: 0 0 8px rgba(0,0,0,0.3);
}
.ba-handle::after {
  content: "< >";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--primary);
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  letter-spacing: 2px;
}

.ba-info {
  padding: 16px 20px;
  background: #fff;
}
.ba-info h4 {
  font-size: 0.95rem;
  margin-bottom: 4px;
  color: var(--text);
}
.ba-info p {
  font-size: 0.82rem;
  color: var(--text-light);
}
.ba-colors {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.ba-color-tag {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 600;
  font-family: var(--font-body);
  color: var(--text-light);
}
.ba-color-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid var(--border);
}

/* Guess the Color Game */
.guess-game-wrapper {
  background: var(--bg-light);
  border-radius: var(--radius-lg);
  padding: 32px;
  border: 1px solid var(--border);
  text-align: center;
}
.guess-game-wrapper h3 {
  font-size: 1.2rem;
  color: var(--primary);
  margin-bottom: 8px;
}
.guess-game-wrapper > p {
  color: var(--text-light);
  margin-bottom: 24px;
}

.guess-prompt {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 20px;
}

.guess-options {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.guess-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 24px;
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  cursor: pointer;
  background: #fff;
  transition: all var(--transition);
  min-width: 120px;
}
.guess-option:hover:not(:disabled) {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.guess-option:disabled { cursor: default; opacity: 0.7; }
.guess-option.correct { border-color: #28a745; background: rgba(40,167,69,0.08); }
.guess-option.wrong { border-color: #dc3545; background: rgba(220,53,69,0.08); }

.guess-swatch {
  width: 50px;
  height: 50px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.guess-label {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--text);
}

.guess-feedback {
  margin-top: 16px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
}
.guess-correct { color: #28a745; }
.guess-wrong { color: #dc3545; }

.guess-result h3 {
  font-size: 1.3rem;
  color: var(--primary);
  margin-bottom: 8px;
}
.guess-result p {
  color: var(--text-light);
  margin-bottom: 20px;
}

/* ════════════════════════════════════════════
   4. ROI CALCULATOR
   ════════════════════════════════════════════ */
.roi-section {
  background: var(--bg-warm);
}

.roi-wrapper {
  max-width: 800px;
  margin: 0 auto;
}

.roi-form {
  background: #fff;
  padding: 32px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: 0 2px 12px var(--shadow);
}

.roi-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.roi-input-group label {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 6px;
  color: var(--text);
}
.roi-input-group input,
.roi-input-group select {
  width: 100%;
  padding: 12px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: var(--font-body);
}
.roi-input-group input:focus,
.roi-input-group select:focus {
  border-color: var(--primary);
  outline: none;
}

.roi-condition-options {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.roi-condition-opt {
  position: relative;
}
.roi-condition-opt input { position: absolute; opacity: 0; }
.roi-condition-opt label {
  display: block;
  padding: 8px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 600;
  transition: all var(--transition);
}
.roi-condition-opt input:checked + label {
  border-color: var(--primary);
  background: rgba(27,77,122,0.06);
}

.roi-calc-btn {
  text-align: center;
}

/* ROI Result */
.roi-result {
  display: none;
  margin-top: 24px;
  padding: 32px;
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: 0 4px 24px var(--shadow);
}

.roi-result-header {
  text-align: center;
  margin-bottom: 28px;
}
.roi-result-header h3 {
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 8px;
}
.roi-big-number {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 2.5rem;
  color: #28a745;
}
.roi-big-number .roi-sep {
  color: var(--text-muted);
  font-weight: 400;
  margin: 0 8px;
  font-size: 1.5rem;
}
.roi-subtitle {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-top: 8px;
}

.roi-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}
.roi-stat {
  text-align: center;
  padding: 16px;
  background: var(--bg-light);
  border-radius: var(--radius);
}
.roi-stat-value {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--primary);
}
.roi-stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.roi-comparison h4 {
  font-size: 1rem;
  margin-bottom: 16px;
  color: var(--text);
}

.roi-bar-group {
  margin-bottom: 12px;
}
.roi-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text);
}
.roi-bar-track {
  height: 24px;
  background: var(--bg-light);
  border-radius: var(--radius);
  overflow: hidden;
}
.roi-bar-fill {
  height: 100%;
  border-radius: var(--radius);
  transition: width 1.2s ease;
  min-width: 20px;
}
.roi-bar-fill.paint { background: linear-gradient(90deg, var(--primary), var(--primary-light)); }
.roi-bar-fill.kitchen { background: #aaa; }
.roi-bar-fill.landscape { background: #8BC34A; }
.roi-bar-fill.windows { background: #9E9E9E; }

.roi-cta {
  text-align: center;
  margin-top: 28px;
}

@media (max-width: 600px) {
  .roi-inputs { grid-template-columns: 1fr; }
  .roi-stats { grid-template-columns: 1fr; }
  .roi-form { padding: 24px 16px; }
  .roi-result { padding: 24px 16px; }
  .roi-big-number { font-size: 1.8rem; }
}

/* ════════════════════════════════════════════
   13. INTERACTIVE TIMELINE
   ════════════════════════════════════════════ */
.timeline-section {
  background: var(--bg);
}

.timeline-wrapper {
  max-width: 700px;
  margin: 0 auto;
}

.tl-step {
  position: relative;
  padding-left: 60px;
  padding-bottom: 28px;
  cursor: pointer;
  border-left: 3px solid var(--border);
  margin-left: 20px;
  transition: border-color var(--transition);
}
.tl-step:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}

.tl-step:hover { border-left-color: var(--primary-light); }
.tl-step.open { border-left-color: var(--primary); }

.tl-number {
  position: absolute;
  left: -22px;
  top: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-light);
  border: 3px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: all var(--transition);
}
.tl-step:hover .tl-number,
.tl-step.open .tl-number {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.tl-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.tl-header h4 {
  font-size: 1rem;
  color: var(--text);
  transition: color var(--transition);
}
.tl-step:hover .tl-header h4 { color: var(--primary); }

.tl-toggle {
  font-size: 1.2rem;
  color: var(--text-muted);
  transition: transform var(--transition);
}
.tl-step.open .tl-toggle { transform: rotate(180deg); }

.tl-time {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
  font-weight: 500;
}

.tl-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding-top: 0;
}
.tl-step.open .tl-content {
  max-height: 300px;
  padding-top: 12px;
}

.tl-content p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.7;
}
.tl-content ul {
  list-style: none;
  margin-top: 8px;
}
.tl-content li {
  padding: 3px 0;
  font-size: 0.85rem;
  color: var(--text-light);
}
.tl-content li::before {
  content: "- ";
  color: var(--accent);
  font-weight: 700;
}

@media (max-width: 480px) {
  .tl-step { padding-left: 44px; margin-left: 14px; }
  .tl-number { width: 32px; height: 32px; font-size: 0.75rem; left: -18px; }
}

/* ════════════════════════════════════════════
   14. REFERRAL PROGRAM
   ════════════════════════════════════════════ */
.referral-section {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: #fff;
}
.referral-section .section-header h2 { color: #fff; }
.referral-section .section-header p { color: rgba(255,255,255,0.8); }

.referral-wrapper {
  max-width: 800px;
  margin: 0 auto;
}

.referral-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 32px;
  align-items: start;
}

.referral-tiers {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ref-tier {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-lg);
  padding: 20px;
  backdrop-filter: blur(4px);
  transition: all var(--transition);
}
.ref-tier:hover {
  background: rgba(255,255,255,0.15);
  transform: translateX(4px);
}

.ref-tier-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.ref-tier-badge {
  font-size: 1.3rem;
}
.ref-tier-name {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
}
.ref-tier-desc {
  font-size: 0.82rem;
  opacity: 0.8;
}
.ref-tier-reward {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--accent);
  margin-top: 6px;
}

.referral-form-card {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-lg);
  padding: 28px;
  backdrop-filter: blur(4px);
}
.referral-form-card h3 {
  font-size: 1.1rem;
  margin-bottom: 16px;
}

.ref-form-group {
  margin-bottom: 12px;
}
.ref-form-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 4px;
  opacity: 0.8;
}
.ref-form-group input {
  width: 100%;
  padding: 12px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-size: 0.95rem;
  font-family: var(--font-body);
}
.ref-form-group input::placeholder { color: rgba(255,255,255,0.4); }
.ref-form-group input:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(255,255,255,0.15);
}

.ref-result {
  display: none;
  text-align: center;
}
.ref-result-icon { font-size: 2.5rem; margin-bottom: 12px; }
.ref-result h3 {
  font-size: 1.2rem;
  margin-bottom: 16px;
}
.ref-code-display {
  background: rgba(255,255,255,0.15);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 16px;
}
.ref-code-value {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 2rem;
  color: var(--accent);
  letter-spacing: 2px;
}
.ref-code-link {
  font-size: 0.8rem;
  opacity: 0.7;
  margin-top: 4px;
  word-break: break-all;
}
.ref-result-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}
.ref-btn {
  padding: 10px 20px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: none;
}
.ref-btn-primary {
  background: var(--accent);
  color: #fff;
}
.ref-btn-primary:hover { background: var(--accent-dark); }
.ref-btn-outline {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
}
.ref-btn-outline:hover { background: rgba(255,255,255,0.1); }

@media (max-width: 700px) {
  .referral-layout { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════
   SPECIALTY SERVICES
   ════════════════════════════════════════════ */
.specialty-section {
  background: var(--bg);
}

.specialty-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.spec-card {
  position: relative;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 12px var(--shadow);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.spec-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  border-color: var(--primary-light);
}

.spec-icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.spec-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.7rem;
  padding: 4px 10px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.spec-card h3 {
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 8px;
}

.spec-card > p {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 16px;
}

.spec-pricing {
  background: var(--bg-light);
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
}
.spec-price {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--primary);
}
.spec-note {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.spec-features {
  list-style: none;
  margin-bottom: 20px;
  flex: 1;
}
.spec-features li {
  padding: 4px 0;
  font-size: 0.85rem;
  color: var(--text-light);
}
.spec-features li::before {
  content: "- ";
  color: var(--accent);
  font-weight: 700;
}

.spec-card .btn { align-self: flex-start; }

@media (max-width: 480px) {
  .specialty-grid { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════
   SERVICE BUILDER
   ════════════════════════════════════════════ */
.builder-section {
  background: var(--bg-warm);
}

.builder-wrapper {
  max-width: 960px;
  margin: 0 auto;
}

.builder-layout {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 28px;
  align-items: start;
}

.builder-options h3,
.builder-summary h3 {
  font-size: 1.1rem;
  margin-bottom: 16px;
  color: var(--text);
}

.builder-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  margin-bottom: 8px;
  transition: all var(--transition);
}
.builder-item:hover {
  border-color: var(--primary-light);
  background: rgba(27,77,122,0.02);
}
.builder-item:has(input:checked) {
  border-color: var(--primary);
  background: rgba(27,77,122,0.05);
  box-shadow: 0 0 0 3px rgba(27,77,122,0.1);
}

.builder-item input[type="checkbox"] {
  accent-color: var(--primary);
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.builder-item-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.builder-item-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.builder-item-info {
  flex: 1;
  min-width: 0;
}
.builder-item-info strong {
  display: block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
}
.builder-item-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.builder-item-price {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--primary);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Summary panel */
.builder-summary {
  position: sticky;
  top: 100px;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: 0 4px 24px var(--shadow);
}

.builder-empty p {
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
  padding: 20px 0;
}

.builder-items-list {
  margin-bottom: 16px;
}

.builder-line-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.85rem;
}
.builder-line-item:last-child { border-bottom: none; }
.builder-line-name {
  font-weight: 600;
  color: var(--text);
}
.builder-line-price {
  font-family: var(--font-body);
  font-weight: 700;
  color: var(--primary);
  font-size: 0.82rem;
}

.builder-totals {
  border-top: 2px solid var(--border);
  padding-top: 16px;
}

.builder-subtotal,
.builder-discount,
.builder-total {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 0.9rem;
}
.builder-subtotal span:first-child,
.builder-discount span:first-child {
  color: var(--text-light);
}
.builder-subtotal span:last-child {
  font-weight: 600;
  color: var(--text);
}
.builder-discount span:last-child {
  color: #28a745;
  font-weight: 700;
}

.builder-total {
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--primary);
  padding: 12px 0;
  border-top: 2px solid var(--primary);
  margin-top: 8px;
}

.builder-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  margin: 12px 0 16px;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .builder-layout { grid-template-columns: 1fr; }
  .builder-summary { position: static; }
  .builder-item-content { flex-wrap: wrap; }
  .builder-item-price { width: 100%; text-align: right; margin-top: 4px; }
}

/* ════════════════════════════════════════════
   SCHEDULING CALENDAR
   ════════════════════════════════════════════ */
.cal-section {
  background: var(--bg);
}

.cal-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  align-items: start;
}

/* Calendar Panel */
.cal-panel {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 16px var(--shadow);
}

.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.cal-month-label {
  font-size: 1.3rem;
  color: var(--text);
  margin: 0;
}

.cal-nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: #fff;
  color: var(--text);
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
.cal-nav-btn:hover:not(:disabled) {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}
.cal-nav-btn:disabled {
  cursor: default;
}

/* Weekday headers */
.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 6px;
}
.cal-weekdays span {
  text-align: center;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 6px 0;
}

/* Calendar Grid */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day {
  aspect-ratio: 1;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4px;
  position: relative;
  font-size: 0.82rem;
  transition: all 0.2s ease;
  border: 2px solid transparent;
  min-height: 56px;
}

.cal-day-empty {
  background: transparent;
}

.cal-day[data-date] {
  cursor: pointer;
  background: var(--bg-light);
}
.cal-day[data-date]:hover {
  border-color: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.cal-day-num {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
  line-height: 1;
}

.cal-day-icon {
  font-size: 0.9rem;
  line-height: 1;
  margin-top: 2px;
}

.cal-day-temp {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-muted);
  line-height: 1;
}

.cal-day-tag {
  font-size: 0.55rem;
  font-weight: 700;
  font-family: var(--font-body);
  padding: 1px 5px;
  border-radius: 3px;
  margin-top: 2px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  line-height: 1.3;
}

/* Day states */
.cal-day-past {
  opacity: 0.35;
  pointer-events: none;
}
.cal-day-past .cal-day-num {
  color: var(--text-muted);
}

.cal-day-today {
  border-color: var(--accent) !important;
}
.cal-day-today .cal-day-num {
  color: var(--accent);
}

.cal-day-booked {
  background: rgba(220, 53, 69, 0.08);
  pointer-events: none;
}
.cal-day-booked .cal-day-tag {
  background: #dc3545;
  color: #fff;
}

.cal-day-off {
  background: rgba(0,0,0,0.03);
}
.cal-tag-off {
  background: var(--text-muted);
  color: #fff;
}

.cal-day-selected {
  border-color: var(--primary) !important;
  background: rgba(46, 52, 65, 0.06);
  box-shadow: 0 0 0 3px rgba(46, 52, 65, 0.12);
}

/* Weather quality colors */
.cal-day-ideal {
  background: rgba(40, 167, 69, 0.08);
}
.cal-day-ideal .cal-day-num { color: #1a7a35; }

.cal-day-possible {
  background: rgba(255, 193, 7, 0.10);
}
.cal-day-possible .cal-day-num { color: #8a6d00; }

.cal-day-poor {
  background: rgba(220, 53, 69, 0.06);
}
.cal-day-poor .cal-day-num { color: #b02a37; }

/* Legend */
.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  justify-content: center;
}
.cal-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
}
.cal-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}
.cal-dot-ideal { background: rgba(40, 167, 69, 0.5); }
.cal-dot-possible { background: rgba(255, 193, 7, 0.6); }
.cal-dot-poor { background: rgba(220, 53, 69, 0.4); }
.cal-dot-booked { background: #dc3545; }
.cal-dot-off { background: var(--text-muted); }

/* Sidebar */
.cal-sidebar {
  position: sticky;
  top: 100px;
}

.cal-sidebar-empty {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 16px var(--shadow);
  text-align: center;
}
.cal-sidebar-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}
.cal-sidebar-empty h3 {
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 8px;
}
.cal-sidebar-empty p {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 20px;
}

.cal-sidebar-tips {
  text-align: left;
  background: var(--bg-light);
  padding: 16px 20px;
  border-radius: var(--radius);
}
.cal-sidebar-tips h4 {
  font-size: 0.85rem;
  color: var(--primary);
  margin-bottom: 10px;
}
.cal-tip {
  font-size: 0.82rem;
  color: var(--text-light);
  line-height: 1.5;
  margin-bottom: 8px;
}
.cal-tip:last-child { margin-bottom: 0; }
.cal-tip strong { color: var(--text); }

/* Form Wrap */
.cal-form-wrap {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 16px var(--shadow);
}
.cal-form-wrap h3 {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 16px;
}

/* Weather row */
.cal-wx-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-light);
  border-radius: var(--radius);
  margin-bottom: 20px;
}
.cal-wx-icon {
  font-size: 2rem;
  flex-shrink: 0;
}
.cal-wx-info {
  flex: 1;
  min-width: 0;
}
.cal-wx-info strong {
  display: block;
  font-size: 0.88rem;
  color: var(--text);
}
.cal-wx-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.cal-wx-badge {
  padding: 6px 12px;
  border-radius: 50px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.72rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.cal-badge-ideal { background: #28a745; color: #fff; }
.cal-badge-possible { background: #ffc107; color: #333; }
.cal-badge-poor { background: #dc3545; color: #fff; }

.cal-no-wx {
  font-size: 0.85rem;
  color: var(--text-muted);
  padding: 12px 16px;
  background: var(--bg-light);
  border-radius: var(--radius);
  margin-bottom: 20px;
}

/* Form fields */
.cal-form-group {
  margin-bottom: 14px;
}
.cal-form-group label {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--text);
  margin-bottom: 5px;
}
.cal-form-group input,
.cal-form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-family: var(--font-body);
  transition: border-color var(--transition);
}
.cal-form-group input:focus,
.cal-form-group textarea:focus {
  border-color: var(--primary);
  outline: none;
}
.cal-form-group textarea {
  resize: vertical;
}

/* Radio group */
.cal-radio-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cal-radio {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}
.cal-radio:hover {
  border-color: var(--primary-light);
  background: rgba(46, 52, 65, 0.02);
}
.cal-radio:has(input:checked) {
  border-color: var(--primary);
  background: rgba(46, 52, 65, 0.04);
}
.cal-radio input {
  accent-color: var(--primary);
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.cal-radio-text {
  display: flex;
  flex-direction: column;
}
.cal-radio-text strong {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
}
.cal-radio-text small {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Deposit info */
.cal-deposit-info {
  background: rgba(196, 146, 58, 0.08);
  border: 1px solid rgba(196, 146, 58, 0.25);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 14px;
}
.cal-deposit-info p {
  font-size: 0.82rem;
  color: var(--text);
  line-height: 1.5;
  margin: 0;
}

/* Success state */
.cal-success {
  text-align: center;
  padding: 12px 0;
}
.cal-success-icon {
  font-size: 3rem;
  color: #28a745;
  margin-bottom: 12px;
}
.cal-success h3 {
  font-size: 1.3rem;
  color: var(--text);
  margin-bottom: 12px;
}
.cal-success p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 16px;
}

.cal-deposit-confirm {
  background: rgba(196, 146, 58, 0.08);
  border: 1px solid rgba(196, 146, 58, 0.25);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 8px;
}
.cal-deposit-confirm p {
  font-size: 0.85rem;
  margin-bottom: 0;
}

.cal-date-weather {
  margin-bottom: 16px;
}

/* Responsive */
@media (max-width: 900px) {
  .cal-layout {
    grid-template-columns: 1fr;
  }
  .cal-sidebar {
    position: static;
  }
}

@media (max-width: 480px) {
  .cal-panel {
    padding: 16px;
  }
  .cal-day {
    min-height: 44px;
    padding: 2px;
  }
  .cal-day-num { font-size: 0.75rem; }
  .cal-day-icon { font-size: 0.7rem; }
  .cal-day-temp { font-size: 0.55rem; }
  .cal-day-tag { font-size: 0.5rem; }
  .cal-legend {
    gap: 8px;
  }
  .cal-legend-item { font-size: 0.65rem; }
  .cal-form-wrap { padding: 20px; }
  .cal-wx-row { flex-wrap: wrap; }
  .cal-wx-badge { width: 100%; text-align: center; }
}
