/* ========== LAYOUT ========== */
.two-page-spread {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    min-height: calc(100vh - 100px); /* Account for nav height */
    background-color: #f2e7c9 
  }
  
  .spread-left,
  .spread-right {   
    flex: 1 1 45%;
    min-width: 350px;
    padding: 20px;
    position: relative;
  }
  
  
  
  .spread-right {
    background-color: #f2e7c9;
    /*background-image: url('../assets/images/textures/paper-texture.png');*/
  }

  @media (max-width: 1024px) {
    .two-page-spread {
      flex-direction: column;
    }
  
    .spread-left,
    .spread-right {
      flex: 1 1 100%;
      min-width: 100%;
    }
  
    .illustration-page {
      border-bottom: 2px solid #000;
      padding-bottom: 40px;
    }
  
    .comic-illustration {
      padding: 80px 20px 20px;
    }
  }
  
  /* ========== LEFT PAGE ========== */
  .spread-left {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-color: #f2e7c9;
    background-repeat: repeat;
    box-sizing: border-box;
    height: 100%;
    z-index: 1;
  }
  
  .spread-left::after {
    content: "";
    position: absolute;
    inset: 0;
    background-color: #f2e7c9;
    z-index: -1;
  }
 
  .illustration-page {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    height: 100%;
  }
  
  .topic-label {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 10;
  }
  
  .topic-number {
    display: inline-block;
    background-color: #d95e40;
    color: white;
    font-family: 'Bangers', cursive;
    font-size: 24px;
    padding: 5px 15px;
    border: 3px solid #000;
    transform: rotate(-3deg);
    margin-bottom: 10px;
  }
  
  .topic-title {
    font-family: 'Bangers', cursive;
    font-size: 48px;
    color: #000;
    text-shadow: 2px 2px 0 #fff;
    margin: 0;
    padding: 0 20px;
    text-align: center;
  }
  
  .comic-illustration {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 30px 20px;
    box-sizing: border-box;
    background-color: transparent;
  }
  
 /* Mobile-specific adjustments */
@media (max-width: 768px) {
    .comic-illustration {
      padding: 10px 10px 50px; /* Less padding on mobile */
      margin-top: 0;
      margin-bottom: 10px;
    }
  
  }
  
  /* ========== RIGHT PAGE ========== */
  .content-page {
    background-color: #f7f2e4;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px 20px;
  }
  
  .content-page .section:nth-child(odd) {
    background-color: #86b6c6;
  }
  
  .content-page .section:nth-child(even) {
    background-color: #9a7bb8;
    color: #fff;
  }
  
  .section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
  }
  
  /* ========== CIA ICONS ========== */
  .cia-icons {
    display: flex;
    gap: 8px;
    position: absolute;
    top: 0;
    right: 10px;
  }
  
  .cia-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 8px;
    border: 2px solid #000;
    border-radius: 5px;
    font-weight: bold;
    box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  }
  
  .cia-icon img {
    width: 16px;
    height: 16px;
    margin-right: 4px;
  }
  
  .confidentiality {
    background-color: #ffcccb;
  }
  
  .integrity {
    background-color: #c1e1c1;
  }
  
  .availability {
    background-color: #c6def9;
  }
  
  /* ========== TECH DECODER ========== */
  .tech-decoder {
    position: relative;
    margin-top: 20px;
    background-color: #fff8e1;
    border: 3px solid #000;
    border-radius: 5px;
    padding: 20px;
    transform: rotate(-2deg);
    box-shadow: 5px 5px 0 rgba(0, 0, 0, 0.2);
    font-family: 'Andale Mono', 'Segoe UI', sans-serif;
    max-width: 100%;
    overflow-y: auto;
    margin-top: 20px;
    flex-grow: 1; /* Only if you want it to push content down */
  }
  
  
  .tech-decoder::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    background-color: transparent;
    border: 3px solid #000;
    border-radius: 5px;
    z-index: -1;
    clip-path: polygon(
      0% 5%, 5% 0%, 10% 5%, 15% 0%, 20% 5%, 25% 0%, 30% 5%, 35% 0%, 40% 5%,
      45% 0%, 50% 5%, 55% 0%, 60% 5%, 65% 0%, 70% 5%, 75% 0%, 80% 5%,
      85% 0%, 90% 5%, 95% 0%, 100% 5%, 100% 100%, 0% 100%
    );
  }
  
  .decoder-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    border-bottom: 2px dashed #d95e40;
    padding-bottom: 5px;
  }
  
  .decoder-icon {
    width: 50px;
    height: 50px;
    margin-right: 8px;
  }
  
  .decoder-header h4 {
    font-family: 'Andale Mono', cursive;
    font-size: 18px;
    color: #d95e40;
    margin: 0;
    letter-spacing: 1px;
  }
  
  .term {
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px dotted #ccc;
  }
  
  .term:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
  }
  
  .term-name {
    font-weight: bold;
    display: block;
    font-size: 14px;
    color: #333;
  }
  
  .term-def {
    display: block;
    font-size: 13px;
    line-height: 1.3;
    color: #555;
  }
  
  @media (max-width: 600px) {
    .tech-decoder {
      position: relative;
      bottom: auto;
      left: auto;
      right: auto;
      transform: none;
      max-height: none;
      width: 100%;
      margin-top: 20px;
      padding: 16px;
    }
  
    .tech-decoder.mobile-bottom {
      margin-bottom: 20px;
    }
  
    .term-name,
    .term-def {
      font-size: 12px;
    }
  
    .decoder-icon {
      width: 40px;
      height: 40px;
    }
  }
  
  /* ========== TOC + NAVIGATION ========== */
  .toc-button {
    background-color: #e6a74c;
    position: relative;
    margin: 0 5px;
  }
  
  .toc-button::after {
    content: "MENU";
    position: absolute;
    bottom: -25px;
    left: 50%;
    transform: translateX(-50%);
    font-family: 'Bangers', cursive;
    font-size: 12px;
    color: #333;
  }
  
  .toc-button:hover {
    background-color: #d95e40;
  }
  
  
  @media (max-width: 768px) {
    .two-page-spread {
      min-height: auto; /* Let content drive height */
    }
    .topic-label {
        position: relative;
        top: 0;
        left: 0;
        text-align: center;
        width: 100%;
        margin-top: 10px;
        z-index: 5;
      }
    .spread-left {
      height: auto;
      padding: 0;
      display: flex;
      flex-direction: column;
    }
  
    .full-page-comic {
        width: 95vw;       /* slightly less than full viewport */
        height: auto;      /* maintain aspect ratio */
        max-height: 90vh;
        object-fit: contain; /* prevents cropping */
        display: block;
      }
    
    .comic-illustration {
        padding: 0;
        margin: 0 auto;     /* centers image horizontally */
        display: flex;
        justify-content: center;
        align-items: center;
        margin-top: 30px;
      }
      .topic-number {
        display: inline-block;
        font-size: 20px;
        padding: 4px 12px;
        transform: none;
        margin: 0 auto;
      }
    
      .feedback-button {
        position: absolute;
        top: 10px;
        right: 10px;
        z-index: 5;
        font-size: 14px;
        padding: 6px 10px;
      }
      .feedback-button1 {
        position: absolute;
        top: 10px;
        left: 10px;
        z-index: 5;
        font-size: 14px;
        padding: 6px 10px;
      }
  }


   .real-incident {
    background-color: #fff9e6;
    border: 2px solid #000;
    border-left: 6px solid #d95e40;
    padding: 12px 15px 10px;
    margin: 12px 0 0;
  }
  
  .real-incident-label {
    font-family: 'Bangers', cursive;
    font-size: 14px;
    color: #d95e40;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 6px;
    display: block;
  }
  
  .real-incident p {
    font-size: 13px;
    line-height: 1.45;
    color: #333;
    margin: 0;
  }
  
  .real-incident .incident-source {
    display: block;
    font-size: 11px;
    color: #888;
    margin-top: 5px;
    font-style: italic;
  }
  
  .llm-connections {
    background-color: #f2e7c9;
    border: 2px solid #000;
    border-left: 6px solid #86b6c6;
    padding: 15px 20px;
    margin-top: 25px;
  }
  .llm-connections-label {
    font-family: 'Bangers', cursive;
    font-size: 13px;
    color: #5a7a8a;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 7px;
    display: block;
  }
  .llm-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }
  .llm-tag {
    background-color: #86b6c6;
    border: 2px solid #000;
    font-family: 'Bangers', cursive;
    font-size: 11px;
    letter-spacing: 0.5px;
    padding: 3px 8px;
    display: inline-block;
  }
  .llm-tag-desc {
    font-size: 11px;
    color: #555;
    margin-top: 5px;
    line-height: 1.35;
  }

  .spread-left .real-incident,
  .spread-left .tech-decoder,
  .spread-left .llm-connections {
    background-color: #f2e7c9 !important;
  }