/* Override: smaller shadows for print */
:root { --shadow-base: 4px 4px 0 0 rgba(0,0,0,0.12); }

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

body {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.4;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 900;
  color: var(--color-text);
  letter-spacing: -0.02em;
}

/* ============================================
   HANDOUT PAGE STRUCTURE
   ============================================ */
.handout {
  width: 100%;
  max-width: 10in;
  margin: 0 auto;
  padding: 0.5in 0.6in;
  page-break-after: always;
  min-height: 100vh;
}

.handout:last-child {
  page-break-after: auto;
}

.handout-title {
  font-size: 1.6rem;
  margin-bottom: 0.3in;
  padding-bottom: 0.1in;
  border-bottom: 3px solid var(--color-border);
  display: flex;
  align-items: center;
  gap: 0.3em;
}

.handout-title .accent-bar {
  display: inline-block;
  width: 8px;
  height: 1.4em;
  background: var(--color-accent);
  border: 2px solid var(--color-border);
  flex-shrink: 0;
}

.handout-subtitle {
  font-size: 0.85rem;
  font-weight: 600;
  color: #444;
  margin-top: -0.2in;
  margin-bottom: 0.2in;
}

/* ============================================
   HANDOUT 1: SCRUM BOARD
   ============================================ */
.scrum-board-meta {
  display: flex;
  gap: 0.3in;
  margin-bottom: 0.2in;
}

.scrum-board-meta .field {
  flex: 1;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 0.1in 0;
  border-bottom: var(--border-base);
}

.scrum-board-meta .field span {
  font-weight: 400;
  color: #666;
}

.scrum-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 2px solid var(--color-border);
  width: 100%;
  height: calc(100vh - 2.6in);
  max-height: 7in;
}

.scrum-board .board-col {
  border-right: 2px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

.scrum-board .board-col:last-child {
  border-right: none;
}

.scrum-board .board-header {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.85rem;
  text-align: center;
  padding: 0.15in 0.1in;
  background: var(--color-accent);
  border-bottom: 2px solid var(--color-border);
}

.scrum-board .board-body {
  flex: 1;
  padding: 0.1in;
  background: repeating-linear-gradient(
    to bottom,
    transparent,
    transparent 1in,
    #e0e0e0 1in,
    #e0e0e0 calc(1in + 1px)
  );
}

.board-bottom-fields {
  margin-top: 0.15in;
  display: flex;
  flex-direction: column;
  gap: 0.1in;
}

.board-bottom-fields .field {
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.08in 0;
  border-bottom: var(--border-base);
}

.board-bottom-fields .field span {
  font-weight: 400;
  color: #666;
}

/* ============================================
   HANDOUT 2: BACKLOG CARDS
   ============================================ */
.backlog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(4, 1fr);
  width: 100%;
  height: calc(100vh - 2.8in);
  max-height: 7.5in;
}

.backlog-card {
  border: 2px dashed #888;
  padding: 0.15in;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.backlog-card .card-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  margin-bottom: 0.05in;
}

.backlog-card .card-size {
  display: inline-block;
  background: var(--color-accent);
  border: 2px solid var(--color-border);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.85rem;
  padding: 0.02in 0.12in;
  margin-bottom: 0.05in;
  width: fit-content;
}

.backlog-card .card-desc {
  font-size: 0.8rem;
  color: #444;
  line-height: 1.3;
}

.backlog-note {
  margin-top: 0.1in;
  font-size: 0.75rem;
  color: #666;
  font-style: italic;
}

/* ============================================
   HANDOUT 3: RETROSPECTIVE FORMATS
   ============================================ */
.retro-section {
  margin-bottom: 0.25in;
}

.retro-section-title {
  font-size: 1.1rem;
  margin-bottom: 0.1in;
  padding: 0.05in 0.15in;
  background: var(--color-primary);
  color: #fff;
  border: 2px solid var(--color-border);
  box-shadow: 3px 3px 0 0 rgba(0,0,0,0.12);
  display: inline-block;
}

.retro-3col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 2px solid var(--color-border);
  height: 1.8in;
}

.retro-3col .retro-col {
  border-right: 2px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

.retro-3col .retro-col:last-child {
  border-right: none;
}

.retro-col-header {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.8rem;
  text-align: center;
  padding: 0.06in;
  background: var(--color-accent);
  border-bottom: 2px solid var(--color-border);
}

.retro-col-body {
  flex: 1;
}

.retro-2x2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  border: 2px solid var(--color-border);
  height: 1.8in;
}

.retro-2x2 .retro-cell {
  border-right: 2px solid var(--color-border);
  border-bottom: 2px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

.retro-2x2 .retro-cell:nth-child(2),
.retro-2x2 .retro-cell:nth-child(4) {
  border-right: none;
}

.retro-2x2 .retro-cell:nth-child(3),
.retro-2x2 .retro-cell:nth-child(4) {
  border-bottom: none;
}

.retro-5row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border: 2px solid var(--color-border);
  height: 1.8in;
}

.retro-5row .retro-col {
  border-right: 2px solid var(--color-border);
  display: flex;
  flex-direction: column;
}

.retro-5row .retro-col:last-child {
  border-right: none;
}

/* ============================================
   HANDOUT 4: TEAM CANVAS
   ============================================ */
.canvas-grid {
  display: grid;
  gap: 0.15in;
}

.canvas-row-top {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.15in;
}

.canvas-row-mid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.15in;
  margin-top: 0.15in;
}

.canvas-row-bottom {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.15in;
  margin-top: 0.15in;
}

.canvas-box {
  border: 1px solid #999;
  padding: 0.12in;
  display: flex;
  flex-direction: column;
}

.canvas-box.large {
  min-height: 1.8in;
}

.canvas-box.medium {
  min-height: 1.2in;
}

.canvas-box-label {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.8rem;
  color: var(--color-text);
  padding: 0 0 0.05in 0;
  margin-bottom: 0.05in;
  border-bottom: 2px solid var(--color-border);
}

.canvas-box-body {
  flex: 1;
  border-top: 1px dotted #ccc;
  padding-top: 0.05in;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  body {
    font-size: 12px;
  }

  .handout {
    padding: 0.3in 0.4in;
    min-height: auto;
    height: auto;
    max-width: none;
  }

  .scrum-board {
    height: 7.2in;
    max-height: none;
  }

  .backlog-grid {
    height: 7.8in;
    max-height: none;
  }

  .canvas-box.large {
    min-height: 1.6in;
  }

  .canvas-box.medium {
    min-height: 1.1in;
  }

  .handout-title {
    font-size: 1.4rem;
  }

  .retro-3col,
  .retro-2x2,
  .retro-5row {
    height: 1.6in;
  }

  /* Avoid shadow ink waste */
  .canvas-box {
    box-shadow: 3px 3px 0 0 rgba(0,0,0,0.08);
  }
}

@page {
  margin: 0.4in;
}

/* Landscape hint for Handout 1 */
.handout-landscape {
  /* Browsers vary in support; this is a hint */
}

@page scrum-board-page {
  size: landscape;
}

.handout-landscape {
  page: scrum-board-page;
}

/* Screen-only divider between handouts */
@media screen {
  .handout {
    border-bottom: 4px dashed #ccc;
    margin-bottom: 0.5in;
  }

  .handout:last-child {
    border-bottom: none;
  }
}
