body {
  margin: 0; 
  font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Roboto', sans-serif; 
  background-color: #1A0B3D; 
  color: #FFFFFF;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.content-wrapper {
  max-width: 1600px;
  width: 100%;
}

main.flex-grow-1 {
  min-height: calc(100vh - 60px); /* Subtract footer height */
}

header.chatbot-header {
  text-align: center; 
  padding-left: 0.5rem; 
  padding-right: 0.5rem; 
  box-sizing: border-box;
  margin-bottom: 2rem;
}

.bbc-full-logo {
  height: 120px; 
  width: 100%; 
  object-fit: contain;
  margin-bottom: 0.5rem;
}

.tagline {
  font-size: 1.125rem;
  font-weight: 400;
  color: #B8B8D1;
  margin: 0;
  letter-spacing: 0.3px;
}

.card-custom { 
  background-color: #2D1B4E; 
  border-radius: 1rem; 
  padding: 2rem; 
  color: white;  
  text-align: center; 
  transition: box-shadow 0.3s ease, background-color 0.3s ease;
  border: 1px solid #4A4068;
  min-height: 420px;
}

.card-custom:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  background-color: #362451;
}

.card-custom:focus-within {
  outline: 2px solid #4A90E2;
  outline-offset: 2px;
}

.card-link-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

.card-link-card:hover,
.card-link-card:focus,
.card-link-card:visited {
  color: inherit;
  text-decoration: none;
}

.card-link-card:focus-visible {
  outline: 2px solid #4A90E2;
  outline-offset: 2px;
}

.card-custom img { 
  width: 170px; 
  height: 170px; 
  object-fit: cover; 
  border-radius: 10%; 
  margin-bottom: 1rem; 
  background: #ead6d6; 
  padding: 2px;
}

.card-custom h3 {
  font-size: 1.375rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  letter-spacing: 0.3px;
}

.card-custom .access-label {
  font-size: 1rem;
  color: #4A90E2;
  font-weight: 500;
  margin-bottom: 1rem;
}

.card-custom .card-description {
  font-size: 1rem; 
  color: #B8B8D1;
  line-height: 1.6;
  margin-bottom: 0;
}
    .chatbot input {
      width: 100%;
      padding: 0.75rem 1rem;
      border-radius: 0.5rem;
      border: none;
      outline: none;
      background-color: #FFFFFF;
      color: #333333;
      font-size: 0.875rem;
      transition: box-shadow 0.3s ease;
      cursor: pointer;
    }
    
    .chatbot input:hover {
      box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.3);
    }
    
    .chatbot input:focus {
      box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.5);
      outline: 2px solid #4A90E2;
      outline-offset: 2px;
    }

    .latest-news {
      background-color: rgba(45, 27, 78, 0.5);
      border-radius: 1rem;
      padding: 1.5rem;
      padding-bottom: 2rem;
      margin-top: 3.3rem;
      margin-bottom: 2rem;
      border: 1px solid #4A4068;
    }
    
    .latest-news h2 {
      font-size: 1.5rem;
      font-weight: 600;
      border-bottom: 2px solid #4A90E2;
      padding-bottom: 0.75rem;
      margin-bottom: 1.25rem;
      letter-spacing: 0.3px;
    }
    
    .news-card {
      background-color: #2D1B4E;
      border-radius: 0.75rem;
      overflow: hidden;
      transition: box-shadow 0.3s ease, transform 0.2s ease;
      margin-bottom: 1rem;
      border: 1px solid #4A4068;
    }
    
    .news-card:hover {
      transform: translateY(-2px);
      box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
    
    .news-card:focus-within {
      outline: 2px solid #4A90E2;
      outline-offset: 2px;
    }
    
    .news-card img {
      width: 100%;
      height: 180px;
      object-fit: cover;
      display: block;
    }	
    
    .news-card div {
      padding: 1rem 1.25rem;
      background: rgba(0,0,0,0.3);
    }
    
    .news-card h5 {
      font-size: 1rem;
      font-weight: 600;
      margin-bottom: 0.5rem;
      color: #FFFFFF;
    }
    
    .news-card p {
      font-size: 0.875rem;
      color: #B8B8D1;
      margin-bottom: 0;
      line-height: 1.4;
    }

    .news-card a,
    .news-card a:hover,
    .news-card a:focus,
    .news-card a:visited {
      display: block;
      color: inherit;
      text-decoration: none;
    }

    footer.chatbot-footer {
      text-align: center;
      background-color: #C84B3C;
      padding: 1rem;
      font-weight: 500;
      color: white;
      font-size: 0.875rem;
      margin-top: auto;
    }
    
    .footer-content {
      display: flex;
      justify-content: center;
      align-items: center;
      flex-wrap: wrap;
      gap: 0.5rem;
    }
    
    .footer-item {
      display: inline-block;
    }
    
    .footer-divider {
      color: rgba(255,255,255,0.6);
      margin: 0 0.25rem;
    }
    
    .footer-link {
      color: white;
      text-decoration: none;
      transition: text-decoration 0.2s ease;
    }
    
    .footer-link:hover {
      text-decoration: underline;
      text-decoration-thickness: 2px;
    }
    
    .footer-link:focus {
      outline: 2px solid white;
      outline-offset: 2px;
      border-radius: 2px;
    }

    @media (max-width: 576px) {
      .bbc-full-logo {
        height: 80px; 
        max-width: 100%;
      }
      
      .tagline {
        font-size: 0.875rem;
      }
      
      header.chatbot-header {
        padding-top: 1rem !important;
      }
      
      .logo {
        margin-top: 0.2rem !important; 
        padding-bottom: 0.5rem !important;
      }
      
      .latest-news {
        margin-top: 2rem;
      }
      
      .card-custom {
        padding: 1.5rem;
      }
      
      .card-custom img {
        width: 140px;
        height: 140px;
      }
      
      .footer-content {
        flex-direction: column;
        gap: 0.25rem;
      }
      
      .footer-divider {
        display: none;
      }
    }
    
    @media (min-width: 577px) and (max-width: 1024px) {
      .bbc-full-logo {
        height: 100px;
      }
      
      .latest-news {
        margin-top: 2.5rem;
      }
    }
    
    @media (min-width: 1400px) {
      .card-custom {
        padding: 2.5rem;
      }
      
      .card-custom img {
        width: 200px;
        height: 200px;
      }
      
      .bbc-full-logo {
        height: 140px;
      }
      
      .tagline {
        font-size: 1.375rem;
      }
      
      .card-custom h3 {
        font-size: 1.5rem;
      }
      
      .card-custom .access-label {
        font-size: 1.125rem;
      }
      
      .card-custom .card-description {
        font-size: 1.125rem;
      }
      
      .latest-news h2 {
        font-size: 1.875rem;
      }
      
      .news-card h5 {
        font-size: 1.125rem;
      }
      
      .news-card p {
        font-size: 1rem;
      }
      
      .news-card img {
        height: 200px;
      }
    }
    
    @media (min-width: 1920px) {
      .content-wrapper {
        max-width: 1800px;
      }
      
      header.chatbot-header {
        padding-top: 4rem !important;
      }
      
      .card-custom {
        min-height: 480px;
      }
    }
    
    @media (prefers-contrast: high) {
      .card-custom {
        border: 2px solid #4A90E2;
      }
      
      .card-link:focus,
      .chatbot input:focus,
      .footer-link:focus {
        outline-width: 3px;
      }
    }
    
    @media (prefers-reduced-motion: reduce) {
      *,
      *::before,
      *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
      }

      .spinner-border,
      .spinner-grow {
        animation-duration: 0.75s !important;
        animation-iteration-count: infinite !important;
      }
    }