/* ========================================
   HOLOMOVEMENT DEVELOPMENT PLAN STYLES
   Consolidated styles for investment summary,
   timeline, and Gantt chart components
   ======================================== */

/* ----------------------------------------
   INVESTMENT SUMMARY STYLES
   ---------------------------------------- */
.investment-summary {
  margin-top: 2rem;
  margin-bottom: 0;
}

.investment-table-wrapper {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  overflow: hidden;
}

.investment-table {
  width: 100%;
  border-collapse: collapse;
}

.investment-table thead {
  background: linear-gradient(135deg, rgba(21, 182, 158, 0.15), rgba(139, 92, 246, 0.15));
}

.investment-table th {
  padding: 1rem 1.5rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #a0a0a0;
  border-bottom: 1px solid #2a2a2a;
}

.investment-table th:not(:first-child) {
  text-align: center;
}

.investment-table td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #2a2a2a;
  font-size: 0.9375rem;
  color: #ffffff;
}

.investment-table td:not(:first-child) {
  text-align: center;
}

.investment-table tbody tr:last-child td {
  border-bottom: none;
}

.investment-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.investment-table .phase-name {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.phase-indicator {
  width: 4px;
  height: 24px;
}

/* Phase indicator colors - scoped to avoid affecting other elements */
.phase-indicator.phase-1 { background: #3b82f6; }
.phase-indicator.phase-2 { background: #ec4899; }
.phase-indicator.phase-3 { background: #f59e0b; }
.phase-indicator.phase-4 { background: #15b69e; }

.investment-table .total-row {
  background: linear-gradient(135deg, rgba(21, 182, 158, 0.1), rgba(139, 92, 246, 0.1));
}

.investment-table .total-row td {
  font-weight: 600;
  padding: 1.25rem 1.5rem;
}

.investment-table .total-row .amount {
  color: #15b69e;
  font-size: 1.125rem;
}

.investment-note {
  margin-top: 1rem;
  padding: 1rem 1.5rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.2);
  font-size: 0.875rem;
  color: #a0a0a0;
}

.investment-note strong {
  color: #ffffff;
}

/* Monthly Costs Table */
.monthly-costs {
  margin-top: 2rem;
  margin-bottom: 0;
}

.monthly-costs h3 {
  margin-bottom: 1rem;
  color: #ffffff;
}

.monthly-table-wrapper {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  overflow: hidden;
}

.monthly-table {
  width: 100%;
  border-collapse: collapse;
}

.monthly-table th {
  padding: 0.875rem 1.25rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #666666;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid #2a2a2a;
}

.monthly-table th:last-child {
  text-align: right;
}

.monthly-table td {
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem;
  color: #a0a0a0;
  border-bottom: 1px solid #2a2a2a;
}

.monthly-table td:last-child {
  text-align: right;
  color: #ffffff;
}

.monthly-table tbody tr:last-child td {
  border-bottom: none;
}

.monthly-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.monthly-table .total-row {
  background: linear-gradient(135deg, rgba(21, 182, 158, 0.1), rgba(21, 182, 158, 0.05));
}

.monthly-table .total-row td {
  font-weight: 600;
  color: #ffffff;
  padding: 1rem 1.25rem;
}

.monthly-table .total-row td:last-child {
  color: #15b69e;
}

/* ----------------------------------------
   PAYMENT SCHEDULE STYLES (Compact/Timeline)
   ---------------------------------------- */
#payment-schedule-container {
  margin-top: 2em;
}

.payment-schedule {
  padding: 1em 1.25em;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(59, 130, 246, 0.03));
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-left: 3px solid #3b82f6;
}

.payment-schedule-header {
  display: flex;
  align-items: center;
  gap: 0.5em;
  margin-bottom: 0.75em;
}

.payment-schedule-header h4 {
  margin: 0;
  font-size: 0.85em;
  font-weight: 600;
  color: #a0a0a0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.payment-schedule-header .phase-tag {
  font-size: 0.75em;
  padding: 0.15em 0.5em;
  background: rgba(59, 130, 246, 0.25);
  color: #3b82f6;
  border-radius: 2px;
  font-weight: 600;
}

.payment-items {
  display: flex;
  gap: 0.5em;
  margin-bottom: 1em;
}

.payment-item {
  display: flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.5em 0.75em;
  background: rgba(0, 0, 0, 0.25);
  border-left: 2px solid #666;
  flex: 1;
}

.payment-item.deposit { border-left-color: #3b82f6; }
.payment-item.milestone { border-left-color: #8b5cf6; }
.payment-item.final { border-left-color: #15b69e; }

.payment-item-percent {
  font-size: 1.1em;
  font-weight: 700;
  line-height: 1;
}

.payment-item.deposit .payment-item-percent { color: #3b82f6; }
.payment-item.milestone .payment-item-percent { color: #8b5cf6; }
.payment-item.final .payment-item-percent { color: #15b69e; }

.payment-item-details {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.payment-item-label {
  font-size: 0.85em;
  font-weight: 600;
  color: #ffffff;
  line-height: 1.3;
}

.payment-item-timing {
  font-size: 0.85em;
  color: #a0a0a0;
  line-height: 1.3;
  font-weight: 500;
}

.payment-item-amount {
  font-size: 1em;
  font-weight: 600;
  color: #ffffff;
  margin-left: auto;
}

/* Investment Slider Styles */
.investment-slider-container {
  margin-bottom: 1em;
  padding: 1em 0;
  border-bottom: 1px solid rgba(59, 130, 246, 0.15);
  position: relative;
}

.slider-header {
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 0.25em;
  margin-bottom: 0.75em;
  position: relative;
}

.slider-label {
  display: block;
  font-size: 0.85em;
  font-weight: 600;
  color: #666666;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  position: relative;
  order: 1;
}

.slider-value {
  display: block;
  font-size: 1.75em;
  font-weight: 700;
  color: #3b82f6;
  line-height: 1;
  position: relative;
  order: 2;
}

.investment-slider {
  width: 100%;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(59, 130, 246, 0.2);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

.investment-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  background: #3b82f6;
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.investment-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.5);
}

.investment-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  background: #3b82f6;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.investment-slider::-moz-range-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.5);
}

.slider-range {
  display: flex;
  justify-content: space-between;
  margin-top: 0.5em;
  font-size: 0.85em;
  color: #666666;
}

/* Scope Features (dynamic bullet points) */
.scope-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5em;
  margin: 1.5em 0;
  padding-top: 1em;
}

.scope-category {
  min-width: 0;
}

.scope-category-title {
  font-size: 0.85em;
  font-weight: 700;
  color: #3b82f6;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 0.625em 0;
  padding-bottom: 0.375em;
  border-bottom: 1px solid rgba(59, 130, 246, 0.2);
}

.scope-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.scope-item {
  position: relative;
  padding: 0.1em 1em 0.1em 0.4em;
  font-size: 1em;
  color: var(--snow, #e0e0e0);
  line-height: 1;
  transition: opacity 0.2s ease;
}

.scope-item::before {
  content: '•';
  position: absolute;
  left: 0;
  color: currentColor;
  opacity: 0.6;
}

/* Responsive: stack on mobile */
@media (max-width: 640px) {
  .scope-features {
    grid-template-columns: 1fr;
    gap: 1.25em;
  }
}

/* ----------------------------------------
   TIMELINE / GANTT CHART STYLES
   ---------------------------------------- */
#hm-timeline-container {
  display: block;
}

.hm-timeline-section {
  margin: 3rem 0;
  display: flex !important;
  flex-direction: column !important;
  grid-template-columns: none !important;
  grid-template-rows: none !important;
}

.hm-timeline-section h2 {
  margin-bottom: 2rem;
  color: #ffffff;
}

/* Gantt Chart Container */
.gantt-container {
  position: relative;
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  padding: 2rem 2rem 1.5rem 2rem;
  overflow-x: auto;
}

.gantt-inner {
  position: relative;
  min-width: 800px;
}

/* Month Headers */
.gantt-months {
  display: flex;
  border-bottom: 1px solid #2a2a2a;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
}

.gantt-month {
  flex: 1;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #666666;
}

.gantt-month.current {
  color: #15b69e;
}

/* Grid Lines */
.gantt-grid {
  position: absolute;
  top: 3rem;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  pointer-events: none;
}

.gantt-grid-line {
  flex: 1;
  border-left: 1px solid #222222;
}

.gantt-grid-line:first-child {
  border-left: none;
}

/* Phase Bars Container */
.gantt-phases {
  position: relative;
  padding: 0.5rem 0;
}

/* Phase Row */
.gantt-phase-row {
  display: flex;
  align-items: center;
  height: 52px;
  margin-bottom: 0.5rem;
}

.gantt-phase-row:last-child {
  margin-bottom: 0;
}

/* Phase Bar */
.gantt-bar {
  position: absolute;
  height: 44px;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 1rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  transition: opacity 0.2s ease;
}

.gantt-bar:hover {
  opacity: 0.9;
}

.gantt-bar.phase-1 { background: linear-gradient(135deg, #3b82f6, #2563eb); }
.gantt-bar.phase-2 { background: linear-gradient(135deg, #ec4899, #db2777); }
.gantt-bar.phase-3 { background: linear-gradient(135deg, #f59e0b, #d97706); }
.gantt-bar.phase-4 { background: linear-gradient(135deg, #15b69e, #0d9488); }

.gantt-bar-label {
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.gantt-bar-cost {
  font-size: 0.6875rem;
  font-weight: 500;
  opacity: 0.85;
  margin-top: 0.125rem;
}

/* Milestone Markers */
.gantt-milestones {
  position: relative;
  height: 50px;
  margin-top: 1rem;
  border-top: 1px solid #2a2a2a;
  padding-top: 0.75rem;
}

.milestone-marker {
  position: absolute;
  top: 0.75rem;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
}

.milestone-diamond {
  width: 12px;
  height: 12px;
  border: 2px solid #666666;
  background: #0a0a0a;
  transform: rotate(45deg);
  transition: all 0.2s ease;
}

.milestone-marker:hover .milestone-diamond {
  transform: rotate(45deg) scale(1.2);
}

.milestone-marker.m1 .milestone-diamond { border-color: #3b82f6; }
.milestone-marker.m2 .milestone-diamond { border-color: #ec4899; }
.milestone-marker.m3 .milestone-diamond { border-color: #f59e0b; }
.milestone-marker.m4 .milestone-diamond { border-color: #15b69e; }
.milestone-marker.wave .milestone-diamond {
  border-color: #f59e0b;
  background: #f59e0b;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.6);
}

.milestone-date {
  margin-top: 0.5rem;
  font-size: 0.6875rem;
  font-weight: 600;
  color: #666666;
  white-space: nowrap;
}

.milestone-marker.m1 .milestone-date { color: #3b82f6; }
.milestone-marker.m2 .milestone-date { color: #ec4899; }
.milestone-marker.m3 .milestone-date { color: #f59e0b; }
.milestone-marker.m4 .milestone-date { color: #15b69e; }
.milestone-marker.wave .milestone-date { color: #f59e0b; }

/* Today Marker */
.today-marker {
  position: absolute;
  top: 2.5rem;
  bottom: 0;
  width: 2px;
  background: #15b69e;
  z-index: 10;
}

.today-marker::before {
  content: 'TODAY';
  position: absolute;
  top: -1.25rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #15b69e;
  white-space: nowrap;
}

/* Milestone Descriptions Grid */
.milestones-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: #2a2a2a;
  border: 1px solid #2a2a2a;
  margin-top: 2rem;
}

.milestone-card {
  background: #1a1a1a;
  padding: 1.25rem;
  transition: background 0.2s ease;
}

.milestone-card:hover {
  background: #1f1f1f;
}

.milestone-card.wave {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(236, 72, 153, 0.05));
}

.milestone-card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.milestone-card-dot {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  transform: rotate(45deg);
}

.milestone-card.m1 .milestone-card-dot { background: #3b82f6; }
.milestone-card.m2 .milestone-card-dot { background: #ec4899; }
.milestone-card.m3 .milestone-card-dot { background: #f59e0b; }
.milestone-card.m4 .milestone-card-dot { background: #15b69e; }
.milestone-card.wave .milestone-card-dot {
  background: #f59e0b;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);
}

.milestone-card-date {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #666666;
}

.milestone-card.m1 .milestone-card-date { color: #3b82f6; }
.milestone-card.m2 .milestone-card-date { color: #ec4899; }
.milestone-card.m3 .milestone-card-date { color: #f59e0b; }
.milestone-card.m4 .milestone-card-date { color: #15b69e; }
.milestone-card.wave .milestone-card-date { color: #f59e0b; }

.milestone-card-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.milestone-card-desc {
  font-size: 0.8125rem;
  color: #a0a0a0;
  line-height: 1.5;
}

.milestone-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.75rem;
}

.milestone-card-tag {
  font-size: 0.6875rem;
  padding: 0.1875rem 0.5rem;
  background: rgba(21, 182, 158, 0.15);
  color: #15b69e;
  border: 1px solid rgba(21, 182, 158, 0.2);
}

.milestone-card.wave .milestone-card-tag {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.2);
}

/* ----------------------------------------
   RESPONSIVE STYLES
   ---------------------------------------- */
@media (max-width: 768px) {
  .gantt-container {
    padding: 1.5rem 1rem;
  }

  .payment-items {
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .investment-table th,
  .investment-table td,
  .monthly-table th,
  .monthly-table td {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
  }
}
