/* styles/packetDetail.css - Simplified Mobile-Friendly Version */


/* --- Main Content --- */
.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  width: 100%;
  box-sizing: border-box;
}

/* --- Page Header --- */
.packet-header {
  text-align: center;
  margin-bottom: 2rem;
}

.packet-header h1 {
  font-size: clamp(1.5rem, 5vw, 2.5rem);
  color: var(--dark-green);
  margin: 0 0 0.5rem 0;
}

.packet-header .subtitle {
  font-size: clamp(0.9rem, 2.5vw, 1.125rem);
  color: var(--text-color);
  margin: 0;
  padding: 0 1rem;
}

/* --- Content Grid: MOBILE FIRST (Critical Fix) --- */
.content-grid {
  display: block;
  width: 100%;
}

.samples-column {
  width: 100%;
  margin-bottom: 1.5rem;
}

.cta-column {
  width: 100%;
  position: static; /* Explicitly prevent sticky on mobile */
  margin-bottom: 1.5rem;
}

/* Desktop ONLY: Two-column layout with sticky sidebar */
@media (min-width: 1024px) {
  .content-grid {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
  }

  .samples-column {
    flex: 2;
    width: auto;
    margin-bottom: 0;
  }

  .cta-column {
    flex: 1;
    width: auto;
    position: sticky;
    top: 2rem;
    margin-bottom: 0;
  }
}

/* --- Card Styling --- */
.sample-feature-card {
  border: 1px solid var(--light-gray);
  border-radius: 0.5rem;
  padding: 1rem;
  background: var(--background-color);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

@media (min-width: 768px) {
  .sample-feature-card {
    padding: 1.5rem;
  }
}

/* --- Sample Sections --- */
.sample-section {
  margin-bottom: 2rem;
}

.sample-section:last-of-type {
  margin-bottom: 0;
}

.sample-section h2 {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  color: var(--steel-blue);
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--pale-turquoise);
  text-align: center;
}

.sample-section p {
  font-size: clamp(0.85rem, 2vw, 0.95rem);
  line-height: 1.6;
  margin-bottom: 1rem;
  text-align: center;
  color: var(--text-color);
}

/* --- Edital Tree --- */
.edital-tree-wrapper {
  max-height: 400px;
  overflow-y: auto;
}

.edital-tree-container ul {
  list-style: none;
  padding-left: 1rem;
  margin: 0;
}

.edital-tree-container li {
  margin-bottom: 0.3rem;
  font-size: clamp(0.8rem, 2vw, 0.9rem);
  line-height: 1.4;
  color: var(--text-color);
}

.edital-tree-container li span {
  font-weight: 500;
}

/* --- Flashcards & Questions --- */
.flashcard-front {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px dashed var(--light-gray);
}

.flashcard-front strong,
.flashcard-back strong,
.answers-body strong {
  color: var(--steel-blue);
  display: block;
  margin-bottom: 0.5rem;
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  font-weight: 600;
}

.flashcard-sample .flashcard-front p,
.flashcard-sample .flashcard-back p,
.question-body p {
  font-size: clamp(0.85rem, 2vw, 0.95rem);
  margin: 0;
  line-height: 1.5;
  color: var(--text-color);
}

.question-body {
  margin-bottom: 1.5rem;
}

.answer-option {
  padding: 0.75rem;
  border-radius: 0.25rem;
  margin-bottom: 0.5rem;
  border: 1px solid var(--light-gray);
  background-color: var(--background-color);
  font-size: clamp(0.8rem, 2vw, 0.9rem);
  line-height: 1.5;
  color: var(--text-color);
}

.correct-answer {
  border-color: var(--btn-secondary-bg);
  background-color: #e9f5ec;
}

.correct-indicator {
  margin-left: 0.5rem;
  font-weight: bold;
  color: var(--btn-secondary-bg);
  display: inline-block;
}

/* --- CTA Box --- */
.cta-box {
  background: var(--secondary-bg-color, #f8f9fa);
  padding: 1.5rem;
  border-radius: 0.5rem;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  border: 1px solid var(--light-gray);
}

.cta-box h3 {
  font-size: clamp(1.2rem, 4vw, 1.6rem);
  color: var(--dark-green);
  margin: 0 0 1rem 0;
  font-weight: 700;
}

.cta-box p {
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  color: var(--text-color);
  margin-bottom: 1rem;
  line-height: 1.5;
}

.cta-box ul {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
  text-align: left;
  font-size: clamp(0.85rem, 2vw, 0.95rem);
}

.cta-box li {
  margin-bottom: 0.5rem;
  line-height: 1.4;
  padding-left: 1.5rem;
  position: relative;
}

.cta-box li::before {
  content: '✓';
  color: var(--light-green);
  font-weight: bold;
  position: absolute;
  left: 0;
  font-size: 1rem;
}

/* --- CTA Button --- */
.btn-cta {
  display: block;
  width: 100%;
  padding: 0.875rem 1rem;
  background-color: var(--btn-primary-bg);
  color: white;
  text-decoration: none;
  border-radius: 0.375rem;
  border: none;
  font-weight: bold;
  font-size: clamp(0.9rem, 2.5vw, 1.1rem);
  margin-bottom: 1rem;
  cursor: pointer;
  transition: background-color 0.2s ease;
  min-height: 48px;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  line-height: 1.3;
}

.btn-cta:hover {
  background-color: var(--btn-primary-hover);
}

.login-prompt {
  font-size: clamp(0.85rem, 2vw, 0.9rem);
  color: var(--text-color);
  margin: 0;
}

.login-prompt a {
  color: var(--steel-blue);
  text-decoration: none;
  font-weight: 600;
}

.login-prompt a:hover {
  text-decoration: underline;
}

.how-it-works-promo {
  margin: 2rem 0;
  padding: 1rem;
  background-color: rgba(255, 255, 255, 0.5); /* Lighter background */
  border-radius: 6px;
  border: 1px dashed var(--steel-blue);
}

.how-it-works-promo h4 {
  margin-top: 0;
  color: var(--steel-blue);
}

/* --- Utility: Prevent horizontal overflow --- */
.main-content *,
.main-content *::before,
.main-content *::after {
  max-width: 100%;
  box-sizing: border-box;
}
