/* =========================================================
   Index / Planning Guide page styles
   - Uses global brand/background/nav from styles.css
   - Adds PDF-style step boxes with right-side images
   ========================================================= */

/* Top section layout: content + right rail */
.index-top-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  align-items: start;
}

.index-sub-ital{
  display: block;
  margin-top: 6px;
  font-family: "Plantin MT Pro", "Times New Roman", serif;
  font-style: normal;
  font-weight: 200;
  opacity: 0.9;
  letter-spacing: 0.01em;
}

/* CTA buttons (reuse .btn-pill, add stronger primary/secondary) */
.index-cta-row{
  margin-top: 16px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.index-cta-row-bottom{ margin-top: 14px; }

/* Primary Start Planning CTA */
.index-btn-primary{
  background: #596e5e;
  border-color: #596e5e !important;
  color: #ffffff;
  font-weight: 600;
  padding: 12px 18px;
  gap: 10px;
}

.index-btn-primary:hover{
  background: #4c5f50;
  border-color: #4c5f50 !important;
}

/* Diagonal arrow */
.index-cta-arrow{
  font-size: 16px;
  line-height: 1;
  transform: translateY(-1px);
}
.index-btn-secondary{
  border-color: rgba(89,110,94,0.20) !important;
  background: rgba(255,255,255,0.55);
}

/* Right rail cards */
.index-rail{
  display: grid;
  gap: 14px;
}

.index-sidecard{
  background: rgba(255,255,255,0.60);
  border: 1px solid var(--divider-subtle);
  border-radius: 12px;
  padding: 16px;
}

.index-sidecard-title{
  margin: 0 0 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 12px;
  color: rgba(38, 43, 38, 0.72);
}

.index-sidecard-actions{
  display: grid;
  gap: 10px;
}

.index-video-btn{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(255,255,255,0.75);
  text-decoration: none;
  color: var(--brand-text);
  font-size: 14px;
}
.index-video-btn:hover{ background: rgba(255,255,255,0.92); }

.index-video-icon{
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.index-video-icon img{ width: 22px; height: 22px; display:block; }

/* Symbol key */
.index-key{ display: grid; gap: 10px; }
.index-key-row{
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: center;
  gap: 10px;
}
.index-key-symbol{
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  border: 1px solid var(--divider-subtle);
  background: rgba(250, 247, 237, 0.75);
  font-weight: 700;
  color: var(--brand-dark);
}
.index-key-text{
  font-size: 13px;
  line-height: 1.45;
  color: rgba(38, 43, 38, 0.84);
}

/* On-page links */
.index-links{
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.7;
  color: rgba(38, 43, 38, 0.84);
}
.index-links a{
  color: var(--brand-dark);
  text-decoration: none;
}
.index-links a:hover{ text-decoration: underline; }

/* Guide sections */
.guide-section{
  background: rgba(255,255,255,0.60);
  border: 1px solid var(--divider-subtle);
  border-radius: 16px;

  /* keep your existing vertical padding, but reserve space on the right for the image */
  padding: 18px 240px 18px 18px;

  /* allows absolute-positioned image to anchor to the whole card */
  position: relative;
}

.guide-section-cream{
  background: rgba(250, 247, 237, 0.72);
}

.guide-kicker{
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(38, 43, 38, 0.72);
  margin-bottom: 8px;
}

.guide-title{
  margin: 0 0 10px;
  font-family: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 600;
  font-size: 20px;
  color: var(--brand-text);
}

/* Decorative bar (like PDF) */
.guide-bar{
  height: 10px;
  width: 55%;
  border-radius: 999px;
  background: var(--brand-accent);
  opacity: 0.85;
  margin: 10px 0 14px;
}
.guide-bar-dark{ background: var(--brand-dark); }
.guide-bar-cream{ background: #efe9d7; }

/* Section 3 â€“ Additional Subjects bar color */
#additional .guide-bar{
  background: #babbac;
}

.guide-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.guide-text p{
  margin: 0 0 10px;
  color: rgba(38, 43, 38, 0.86);
  font-size: 14px;
  line-height: 1.65;
}

.guide-last{ margin-bottom: 0 !important; }

.guide-list{
  margin: 10px 0 10px;
  padding-left: 18px;
  color: rgba(38, 43, 38, 0.86);
  font-size: 14px;
  line-height: 1.65;
}

.guide-image{
  position: absolute;
  right: 18px;          /* matches left padding for symmetry */
  top: 50%;
  transform: translateY(-50%);  /* THIS is the â€œcenter on whole cardâ€ */

  width: 210px;         /* container width for the image column */
  display: flex;
  justify-content: flex-end;  /* keep the same horizontal behavior you liked */
}

.guide-image img{
  width: min(180px, 100%);
  height: auto;
  border-radius: 14px;
  filter: none;
}

/* Responsive */
@media (max-width: 980px){
  .index-top-grid{ grid-template-columns: 1fr; }
  .guide-grid{ grid-template-columns: 1fr; }
  .guide-image{ justify-content: flex-start; }
}

@media (max-width: 980px){
  .index-top-grid{ grid-template-columns: 1fr; }
  .guide-grid{ grid-template-columns: 1fr; }
  .guide-image{ justify-content: flex-start; }

  /* NEW: revert to normal stacking */
  .guide-section{
    padding: 18px;
  }
  .guide-image{
    position: static;
    top: auto;
    right: auto;
    transform: none;
    width: auto;
    margin-top: 12px;
  }
}

/* Guide text links */
.guide-text a,
.guide-list a{
  color: #596e5e;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  font-weight: 500;
}

.guide-text a:hover,
.guide-list a:hover{
  color: #445a4c; /* slightly darker on hover */
}

/* =========================================================
   Print / PDF
   ========================================================= */

@page { margin: 0.5in; }

@media print {
  /* Hide app chrome */
  .app-header,
  .index-cta-row,
  .print-tip-overlay,
  .print-tip-backdrop,
  .print-tip-modal{
    display: none !important;
  }

  body{
    background: #ffffff !important;
  }

  .main-content{
    padding: 0 !important;
  }

  /* Keep each section together when possible */
  .guide-section{
    break-inside: avoid;
    page-break-inside: avoid;
    box-shadow: none !important;
  }

  /* Print-friendly image placement (avoid absolute positioning quirks) */
  .guide-image{
    position: static !important;
    transform: none !important;
    width: auto !important;
    margin-left: 0 !important;
  }

  .guide-grid{
    grid-template-columns: 1fr 220px !important;
  }

  .guide-image img{
    width: 180px !important;
    filter: none !important;
  }
}
