/* Townhome Initiative Presentation - Visual Style */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600&display=swap');

/* Design Tokens - scaled for large monitor presentation */
:root {
  --font-sans: "DM Sans", Arial, sans-serif;

  --w-regular: 400;
  --w-medium: 500;
  --w-semibold: 600;

  --t-hero: 70px;
  --t-title: 60px;
  --t-body: 29px;
  --t-secondary: 22px;
  --t-micro: 18px;

  --bg: #ffffff;
  --text: #111111;
  --text-secondary: #888888;
  --surface: #eeeeee;

  --accent: #ffab40;
  --link: #6a9aa8;

  --dark-bg: #362f2f;
  --dark-text: #ffffff;
  --dark-secondary: rgba(255, 255, 255, 0.7);

  --stage-padding: 52px;
  --radius: 18px;
  --transition-ms: 200ms;
}

/* Reset */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
}

/* Stage Container - 16:9 centered */
.stage {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

/* Individual Slide */
.slide {
  width: 100vw;
  height: 100vh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  flex-direction: column;
  padding: var(--stage-padding);
  background: var(--bg);
  position: relative;
  overflow: hidden;
}

.slide.dark {
  background: var(--dark-bg);
  color: var(--dark-text);
}

.slide.dark .eyebrow,
.slide.dark .text-secondary {
  color: var(--dark-secondary);
}

/* Eyebrow Label */
.eyebrow {
  font-size: var(--t-micro);
  font-weight: var(--w-medium);
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}

/* Titles */
.slide-title {
  font-size: var(--t-title);
  font-weight: var(--w-semibold);
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-title {
  font-size: var(--t-hero);
  font-weight: var(--w-semibold);
  line-height: 1.05;
  margin-bottom: 16px;
}

/* Subtitle */
.subtitle {
  font-size: var(--t-body);
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* Two Column Layout */
.slide-content {
  flex: 1;
  display: grid;
  grid-template-columns: 3.75fr 8.25fr;
  gap: 60px;
  align-items: start;
  min-height: 0;
}

.text-column {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding-top: 5vh;
}

.visual-column {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100%;
}

/* Full Width Layout */
.slide-content.full-width {
  grid-template-columns: 1fr;
}

.slide-content.full-width .text-column {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  padding-right: 0;
}

/* Cover Slide Layout */
.slide.cover {
  justify-content: center;
  align-items: center;
  text-align: center;
}

.slide.cover .hero-title {
  max-width: 900px;
}

.slide.cover .subtitle {
  font-size: var(--t-body);
  max-width: 800px;
}

.slide.cover .subtitle-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.slide.cover .subtitle-link:hover {
  opacity: 0.85;
}

.slide.cover .meta {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  margin-top: 40px;
}

/* Bullets */
.bullets {
  list-style: none;
  padding: 0;
}

.bullets li {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  line-height: 1.45;
  margin-bottom: 0.8em;
  padding-left: 24px;
  position: relative;
}

.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 0.35em;
  height: 0.35em;
  background: var(--accent);
  border-radius: 50%;
}

.slide.dark .bullets li::before {
  background: var(--accent);
}

/* Status Chip */
.status-chip {
  display: inline-block;
  font-size: var(--t-micro);
  font-weight: var(--w-medium);
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 16px;
}

.status-chip.working {
  background: #c8e6c9;
  color: #2e7d32;
}

.status-chip.in-progress {
  background: #fff3e0;
  color: #e65100;
}

.status-chip.planned {
  background: #e3f2fd;
  color: #1565c0;
}

/* Screenshot Frame Placeholder */
.screenshot-frame {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--surface);
  border: 1px solid #ddd;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.screenshot-frame .placeholder-icon {
  width: 48px;
  height: 48px;
  background: #ccc;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 24px;
  color: #888;
}

.screenshot-frame .placeholder-label {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  text-align: center;
  padding: 0 20px;
}

/* Chip Label on Screenshot */
.screenshot-frame .chip-label {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: var(--t-micro);
  font-weight: var(--w-medium);
  background: var(--accent);
  color: var(--text);
  padding: 4px 10px;
  border-radius: 6px;
}

/* Caption */
.caption {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  margin-top: 12px;
  text-align: center;
  max-width: 100%;
}

/* Timeline Strip */
.timeline-strip {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 20px 0;
  width: 100%;
}

.timeline-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  position: relative;
}

.timeline-node::before {
  content: "";
  position: absolute;
  top: 12px;
  left: 50%;
  width: 100%;
  height: 3px;
  background: var(--surface);
}

.timeline-node:last-child::before {
  display: none;
}

.timeline-dot {
  width: 24px;
  height: 24px;
  background: var(--accent);
  border-radius: 50%;
  position: relative;
  z-index: 1;
  margin-bottom: 12px;
}

.timeline-dot.completed {
  background: #4caf50;
}

.timeline-dot.current {
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(255, 171, 64, 0.3);
}

.timeline-label {
  font-size: var(--t-micro);
  font-weight: var(--w-medium);
  text-align: center;
  color: var(--text);
}

/* Metric Cards */
.metric-cards {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.metric-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  min-width: 180px;
  flex: 1;
}

.metric-card .number {
  font-size: 32px;
  font-weight: var(--w-semibold);
  color: var(--accent);
  margin-bottom: 8px;
}

.metric-card .label {
  font-size: var(--t-secondary);
  font-weight: var(--w-medium);
  margin-bottom: 4px;
}

.metric-card .note {
  font-size: var(--t-micro);
  color: var(--text-secondary);
}

/* Three Column Layout (for status boards, retrospectives) */
.three-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  width: 100%;
}

.column-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
}

.column-card h4 {
  font-size: var(--t-secondary);
  font-weight: var(--w-semibold);
  margin-bottom: 16px;
  color: var(--text);
}

.column-card.working h4 { color: #2e7d32; }
.column-card.in-progress h4 { color: #e65100; }
.column-card.planned h4,
.column-card.risks h4 { color: #1565c0; }

.column-card ul {
  list-style: none;
  padding: 0;
}

.column-card li {
  font-size: var(--t-secondary);
  margin-bottom: 10px;
  padding-left: 16px;
  position: relative;
}

.column-card li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* Workflow Panel */
.workflow-panel {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 24px;
  width: 100%;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
}

.workflow-steps {
  list-style: none;
}

.workflow-steps li {
  font-size: var(--t-secondary);
  padding: 8px 0;
  border-bottom: 1px solid #ddd;
  display: flex;
  align-items: center;
  gap: 12px;
}

.workflow-steps li:last-child {
  border-bottom: none;
}

.step-number {
  width: 24px;
  height: 24px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: var(--t-micro);
  font-weight: var(--w-semibold);
  flex-shrink: 0;
}

.workflow-diagram {
  background: #e0e0e0;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-secondary);
  font-size: var(--t-secondary);
}

/* Before/After Comparison */
.comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  width: 100%;
}

.comparison-panel {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
}

.comparison-panel h4 {
  font-size: var(--t-secondary);
  font-weight: var(--w-semibold);
  margin-bottom: 16px;
}

.comparison-panel.before h4 {
  color: #c62828;
}

.comparison-panel.after h4 {
  color: #2e7d32;
}

/* Hierarchy Graphic */
.hierarchy {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 20px;
}

.hierarchy-node {
  background: var(--surface);
  border: 2px solid var(--accent);
  border-radius: 8px;
  padding: 12px 24px;
  font-size: var(--t-secondary);
  font-weight: var(--w-medium);
}

.hierarchy-connector {
  width: 2px;
  height: 20px;
  background: var(--accent);
}

/* Appendix Links */
.appendix-list {
  list-style: none;
  padding: 0;
}

.appendix-list li {
  font-size: var(--t-body);
  margin-bottom: 16px;
}

.appendix-list a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition-ms);
}

.appendix-list a:hover {
  border-bottom-color: var(--link);
}

/* Navigation Indicator */
.nav-indicator {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 100;
}

.nav-dot {
  width: 10px;
  height: 10px;
  background: var(--surface);
  border-radius: 50%;
  cursor: pointer;
  transition: all var(--transition-ms);
}

.nav-dot:hover {
  background: var(--text-secondary);
}

.nav-dot.active {
  background: var(--accent);
  transform: scale(1.3);
}

/* Slide Counter */
.slide-counter {
  position: fixed;
  bottom: 20px;
  right: 20px;
  font-size: var(--t-micro);
  color: var(--text-secondary);
  z-index: 100;
}

/* Keyboard Hint */
.keyboard-hint {
  position: fixed;
  bottom: 20px;
  left: 20px;
  font-size: var(--t-micro);
  color: var(--text-secondary);
  opacity: 0.6;
  z-index: 100;
}

/* Responsive Scaling */
@media (max-width: 1200px) {
  :root {
    --t-hero: 52px;
    --t-title: 44px;
    --t-body: 22px;
    --t-secondary: 18px;
    --t-micro: 15px;
    --stage-padding: 36px;
  }
  
  .slide-content {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .text-column {
    padding-right: 0;
  }
  
  .three-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --t-hero: 40px;
    --t-title: 34px;
    --t-body: 20px;
    --t-secondary: 16px;
    --t-micro: 14px;
    --stage-padding: 28px;
  }
  
  .nav-indicator {
    display: none;
  }
}

/* Slide Transitions */
.slide {
  opacity: 1;
  transition: opacity var(--transition-ms) ease;
}

/* Ensure proper stacking */
.slide-header {
  flex-shrink: 0;
}

/* Agenda Layout */
.agenda-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 550px;
  margin: 0;
  padding: 20px 0;
}

.agenda-section {
  text-align: left;
  margin-bottom: 0;
}

.agenda-heading {
  font-size: var(--t-body);
  font-weight: var(--w-semibold);
  color: var(--text);
  margin-bottom: 8px;
  padding-left: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.agenda-heading::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 20px;
  background: var(--accent);
  border-radius: 2px;
  flex-shrink: 0;
}

.agenda-items {
  list-style: none;
  padding: 0;
  margin: 0;
  margin-left: 16px;
  padding-left: 20px;
  border-left: 1px solid #ddd;
}

.agenda-items li {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  padding: 4px 0;
  padding-left: 0;
  position: relative;
  line-height: 1.4;
}

.agenda-items li::before {
  content: none;
}

/* Agenda slide content - left aligned */
.slide-content.agenda-content {
  display: block;
  padding-top: 20px;
}

/* Profile Image */
.profile-image-frame {
  width: 27em;
  height: 36em;
  background: var(--surface);
  border-radius: 0;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

.profile-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Flat image - no frame/container */
.flat-image {
  width: 100%;
  max-height: 95%;
  object-fit: contain;
}

/* Image label */
.image-label {
  display: block;
  font-size: var(--t-secondary);
  font-weight: var(--w-semibold);
  color: var(--text);
  margin-bottom: 0.5em;
  text-align: center;
}

/* Pinboard collage */
.pinboard-collage {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.pinboard-img {
  position: absolute;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: 3px solid #fff;
  background: #fff;
  object-fit: cover;
  transition: transform 0.2s ease, z-index 0.2s ease;
}

.pinboard-img:hover {
  z-index: 10;
  transform: scale(1.05) rotate(0deg) !important;
}

/* Stacked images layout */
.stacked-images {
  display: flex;
  flex-direction: row;
  gap: 1em;
  height: 100%;
  align-items: center;
  justify-content: center;
}

.stacked-image-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.stacked-image-item .flat-image {
  max-height: 70vh;
  width: 100%;
  object-fit: contain;
}

/* Image Carousel */
.image-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Carousel items - supports both img elements and div containers */
.carousel-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* When carousel-img is an actual image */
img.carousel-img {
  object-fit: contain;
}

/* When carousel-img is a div container */
div.carousel-img {
  display: flex;
  align-items: center;
  justify-content: center;
}

div.carousel-img > img {
  max-width: 100%;
  max-height: 90%;
  object-fit: contain;
}

.carousel-img.active {
  opacity: 1;
  pointer-events: auto;
}

/* For carousel items that are stacked images */
.carousel-img .stacked-images {
  width: 100%;
  max-height: 90%;
}

.carousel-counter {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  padding: 4px 12px;
  border-radius: 4px;
  font-size: var(--t-micro);
}

/* Click Zones for Navigation */
.click-zone {
  position: fixed;
  top: 0;
  width: 50%;
  height: 100%;
  z-index: 999;
  cursor: pointer;
  background: transparent;
  pointer-events: none;
}

.click-zone-left {
  left: 0;
  cursor: pointer;
}

.click-zone-right {
  right: 0;
  cursor: pointer;
}

/* Success Criteria Panel */
.success-criteria-panel {
  background: #fafafa;
  padding: 1.5em;
  max-width: 50em;
  font-size: 1.5em;
  line-height: 1.4;
  align-self: center;
  margin: 0 auto;
}

.criteria-title {
  font-size: 1.4em;
  font-weight: var(--w-semibold);
  margin-bottom: 0.8em;
  color: var(--text);
}

.criteria-section {
  margin-bottom: 0.8em;
}

.milestone-heading {
  font-size: 1.1em;
  font-weight: var(--w-semibold);
  margin-bottom: 0.3em;
  color: var(--text);
}

.criteria-item {
  display: flex;
  align-items: flex-start;
  gap: 0.6em;
  margin-bottom: 0.4em;
  color: var(--text);
  font-size: 1em;
}

.indicator {
  width: 1em;
  height: 1em;
  border-radius: 2px;
  flex-shrink: 0;
  margin-top: 0.15em;
}

.indicator.interest {
  background: #e9c46a;  /* golden yellow */
}

.indicator.adoption {
  background: #f4a261;  /* warm peach/orange */
}

.indicator.production {
  background: #e76f51;  /* terracotta red */
}

.indicator.performance {
  background: #9c89b8;  /* muted purple */
}

.indicator.revenue {
  background: #2a9d8f;  /* teal green */
}

/* Solution Groups (Product Solution slide) */
.solution-group {
  margin-bottom: 1.2em;
}

.solution-heading {
  font-size: var(--t-body);
  font-weight: var(--w-semibold);
  color: var(--text);
  margin-bottom: 0.5em;
  display: flex;
  align-items: center;
  gap: 0.6em;
}

.solution-heading::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 1.2em;
  background: var(--accent);
  border-radius: 2px;
  flex-shrink: 0;
}

.solution-items {
  list-style: none;
  padding: 0;
  margin: 0;
  margin-left: 14px;
  padding-left: 20px;
  border-left: 1px solid #ddd;
}

.solution-items li {
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  padding: 0;
  margin-bottom: 0.8em;
  line-height: 1.4;
}

.solution-items a,
.slide-content a {
  color: #9ab3bc;
  text-decoration: underline;
  text-decoration-color: #c5d4d9;
}

.solution-items a:hover,
.slide-content a:hover {
  color: #7a9aa6;
}

/* Demo link */
.demo-link {
  margin-top: 1.5em;
  font-size: var(--t-secondary);
  color: var(--text-secondary);
  position: relative;
  z-index: 1000;
}

.demo-link a {
  color: #9ab3bc;
  text-decoration: underline;
  text-decoration-color: #c5d4d9;
  position: relative;
  z-index: 1000;
}

.demo-link a:hover {
  color: #7a9aa6;
}

/* Highlight text */
.highlight {
  background: rgba(255, 171, 64, 0.3);
  padding: 0.1em 0.15em 0.1em 0;
  margin-left: 0;
  border-radius: 3px;
  color: var(--text);
  font-weight: var(--w-medium);
}

.criteria-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1em;
  margin-top: 1.5em;
  padding-top: 1em;
  border-top: 1px solid #ddd;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4em;
  font-size: 0.9em;
}

.legend-item .indicator {
  width: 0.8em;
  height: 0.8em;
}

/* ========== DEV MODE - Grid Debug ========== */
/* Toggle with 'G' key */
body.show-grid .slide-content {
  background-image: 
    repeating-linear-gradient(90deg, rgba(255,0,0,0.1) 0, rgba(255,0,0,0.1) 1px, transparent 1px, transparent 100%);
  background-size: calc(100% / 12) 100%;
}

body.show-grid .slide-content > * {
  outline: 2px dashed rgba(255, 100, 0, 0.6);
  outline-offset: -2px;
}

body.show-grid .slide-header {
  outline: 2px dashed rgba(0, 150, 255, 0.6);
}

body.show-grid .bullets li,
body.show-grid .agenda-section,
body.show-grid .column-card {
  outline: 1px dotted rgba(0, 200, 100, 0.5);
}

body.show-grid .profile-image-frame,
body.show-grid .screenshot-frame {
  outline: 2px solid rgba(255, 0, 255, 0.6);
}

body.show-grid::after {
  content: "GRID MODE (G to toggle)";
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  background: #ff5722;
  color: white;
  padding: 6px 16px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  z-index: 9999;
}
/* ========== END DEV MODE ========== */
