/* Responsive CSS for Mobile and Tablets */

/* ============================================
   Hamburger Menu Styles
   ============================================ */

/* Hide hamburger on desktop */
.nav-toggle {
  display: none;
}

.hamburger {
  display: none;

}

/* ============================================
   Mobile First Approach
   ============================================ */

/* Mobile devices (up to 768px) */
@media screen and (max-width: 768px) {
  
  /* Navigation - Mobile Menu */
  .nav-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
  }
  
  /* Hamburger Icon */
  .hamburger {
    display: block;
    position: fixed;
    top: 15px;
    right: 20px;
    z-index: 1001;
    cursor: pointer;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    padding: 0;
  }
  
  .hamburger span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: #ff6c00;
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: 0.25s ease-in-out;
  }
  
  .hamburger span:nth-child(1) {
    top: 0px;
  }
  
  .hamburger span:nth-child(2) {
    top: 10px;
  }
  
  .hamburger span:nth-child(3) {
    top: 20px;
  }
  
  /* Transform hamburger to X when menu is open */
  .nav-toggle:checked ~ .hamburger span:nth-child(1) {
    top: 10px;
    transform: rotate(135deg);
  }
  
  .nav-toggle:checked ~ .hamburger span:nth-child(2) {
    opacity: 0;
    left: -60px;
  }
  
  .nav-toggle:checked ~ .hamburger span:nth-child(3) {
    top: 10px;
    transform: rotate(-135deg);
  }
  
  .nav-bg img {
    padding-top: 10px;
    height: 80px !important;
    width: auto;
  }
  
  /* Hide menu by default, show when checkbox is checked */
  .new_nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.98);
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding-top: 80px;
    padding-bottom: 20px;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    overflow-y: auto;
    font-size: 1.2em;
    z-index: 999;
  }
  
  /* Show menu when checkbox is checked */
  .nav-toggle:checked ~ .new_nav {
    transform: translateX(0);
  }
  
  .new_nav > a {
    margin-bottom: 20px;
    width: 100%;
    text-align: center;
  }
  
  .new_nav > a img {
    margin: 0 auto;
  }
  
  .new_nav div {
    width: 100%;
    margin: 10px 0;
    padding: 15px 0;
    margin-left: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .new_nav div:last-child {
    border-bottom: none;
  }
  
  .new_nav div:hover {
    height: auto;
    padding-top: 15px;
    background-color: rgba(0, 128, 0, 0.3);
  }
  
  /* Close menu when clicking on a link */
  .new_nav div a,
  .new_nav > a {
    display: block;
    width: 100%;
    padding: 10px;
  }
  
  /* Overlay Text - Mobile */
  .overlay {
    top: 15%;
    font-size: 1rem;
    padding: 0 20px;
  }
  
  .ipta {
    font-size: 3rem !important;
    margin-top: 60px;
  }
  
  .south_africa {
    font-size: 2rem !important;
    margin-top: -30px;
  }
  
  .overlay p {
    font-size: 0.9rem !important;
    padding: 0 10px;
  }
  
  .overlay .logo {
    height: 60px !important;
    padding-top: 15px;
  }
  
  /* Slideshow - Mobile */
  .slideshow-container {
    max-height: 50vh;
    margin-top: 80px;
  }
  
  .slideshow-container img {
    height: 50vh;
    object-fit: cover;
  }
  
  .prev, .next {
    font-size: 14px;
    padding: 10px;
    margin-top: -15px;
  }
  
  .dot {
    height: 10px;
    width: 10px;
    margin: 0 3px;
  }
  
  /* Container Horizontal Layouts - Stack on Mobile */
  .container-hor1 {
    flex-direction: column;
    height: auto;
  }
  
  .student-week,
  .science-week {
    width: 100% !important;
    min-height: 200px;
    padding: 20px 0;
  }
  
  .student-week h2,
  .science-week h2 {
    font-size: 1.5em !important;
    margin-top: 10% !important;
    padding: 0 20px !important;
  }
  
  .container-hor2 {
    flex-direction: column;
  }
  
  /* Week Pages - Mobile */
  .week1-row1,
  .week2-row1 {
    flex-direction: column;
    padding-left: 20px !important;
    padding-bottom: 20px !important;
    font-size: 1.2rem !important;
    margin-top: 5rem;
  }
  
  .week1-row1 h1,
  .week2-row1 h1 {
    padding-left: 0 !important;
    font-size: 1.5rem !important;
    margin-bottom: 10px;
  }
  
  .week1-row2,
  .week2-row2 {
    flex-direction: column;
    padding-left: 20px !important;
    padding-right: 20px !important;
    padding-bottom: 50px !important;
    font-size: 1rem !important;
  }
  
  .week1-row2 p,
  .week2-row2 p {
    width: 100% !important;
    margin-bottom: 20px;
  }
  
  .week1-row2 img,
  .week2-row2 img {
    width: 100% !important;
    padding-right: 0 !important;
  }
  
  /* Key Dates - Mobile */
  .key-dates p {
    font-size: 16px !important;
    padding: 0 20px;
  }
  
  /* Committee Sections - Mobile */
  .site-testimonial {
    padding: 2rem 1rem;
  }
  
  .site-testimonial .section-title h2 {
    font-size: 1.8rem !important;
  }
  
  .site-testimonial .section-title p {
    font-size: 1rem;
    padding: 0 10px;
  }
  
  .site-testimonial .col-lg-4,
  .site-testimonial .col-md-6 {
    width: 100% !important;
    margin-bottom: 1.5rem;
  }
  
  .site-testimonial-item {
    padding: 1.5rem;
  }
  
  .site-testimonial-item .thumb img {
    width: 60px;
    height: 60px;
  }
  
  .site-testimonial-item .person h5 {
    font-size: 1.1rem;
  }
  
  /* Form - Mobile */
  .form-container {
    padding: 1.5rem;
    width: 95% !important;
    margin: 0 auto;
  }
  
  .SW {
    font-size: 2.5rem !important;
    padding-left: 1rem !important;
    margin-top: 4rem;
  }
  
  input, select, textarea {
    font-size: 1rem !important;
    padding: 0.6rem 0.8rem;
  }
  
  button {
    font-size: 1rem;
    padding: 0.8rem;
  }
  
  /* Map - Mobile */
  .map {
    border: 10px solid white;
  }
  
  .map iframe {
    height: 300px !important;
  }
  
  /* Footer - Mobile */
  .footer {
    font-size: 0.7em;
    padding: 15px 10px;
  }
}

/* ============================================
   Tablet devices (769px to 1024px)
   ============================================ */
@media screen and (min-width: 769px) and (max-width: 1024px) {
  
  /* Navigation - Tablet */
  .nav-bg img {
    height: 120px !important;
  }
  
  .new_nav {
    font-size: 1.3em;
    height: 5rem;
  }
  
  .new_nav div {
    margin-left: 20px;
    padding: 10px 15px;
  }
  
  /* Overlay Text - Tablet */
  .overlay {
    top: 18%;
    font-size: 1.5rem;
  }
  
  .ipta {
    font-size: 6rem !important;
    margin-top: 80px;
  }
  
  .south_africa {
    font-size: 4rem !important;
    margin-top: -60px;
  }
  
  .overlay p {
    font-size: 1.2rem !important;
  }
  
  .overlay .logo {
    height: 90px !important;
  }
  
  /* Slideshow - Tablet */
  .slideshow-container {
    max-height: 70vh;
  }
  
  .slideshow-container img {
    height: 70vh;
  }
  
  /* Container Horizontal Layouts - Tablet */
  .container-hor1 {
    height: 40vh;
  }
  
  .student-week h2,
  .science-week h2 {
    font-size: 2.2em !important;
    margin-top: 20% !important;
  }
  
  /* Week Pages - Tablet */
  .week1-row1,
  .week2-row1 {
    padding-left: 80px !important;
    font-size: 1.6rem !important;
  }
  
  .week1-row1 h1,
  .week2-row1 h1 {
    padding-left: 60px !important;
    font-size: 2rem !important;
  }
  
  .week1-row2,
  .week2-row2 {
    padding-left: 80px !important;
    padding-right: 80px !important;
    font-size: 1.4rem !important;
  }
  
  .week1-row2 p,
  .week2-row2 p {
    width: 45%;
  }
  
  .week1-row2 img,
  .week2-row2 img {
    width: 50%;
    padding-right: 80px;
  }
  
  /* Key Dates - Tablet */
  .key-dates p {
    font-size: 20px !important;
  }
  
  /* Committee Sections - Tablet */
  .site-testimonial .col-lg-4 {
    width: 50% !important;
  }
  
  .site-testimonial .section-title h2 {
    font-size: 2.2rem !important;
  }
  
  /* Form - Tablet */
  .form-container {
    max-width: 800px;
    padding: 2rem;
  }
  
  .SW {
    font-size: 4rem !important;
  }
  
  input, select, textarea {
    font-size: 1.2rem;
  }
  
  /* Map - Tablet */
  .map iframe {
    height: 450px !important;
  }
}

/* ============================================
   Small Mobile devices (up to 480px)
   ============================================ */
@media screen and (max-width: 480px) {
  
  /* Navigation - Small Mobile */
  .nav-bg img {
    height: 60px !important;
  }
  
  .hamburger {
    top: 12px;
    right: 15px;
    width: 25px;
    height: 20px;
  }
  
  .hamburger span {
    height: 2.5px;
  }
  
  .hamburger span:nth-child(1) {
    top: 0px;
  }
  
  .hamburger span:nth-child(2) {
    top: 8px;
  }
  
  .hamburger span:nth-child(3) {
    top: 16px;
  }
  
  .nav-toggle:checked ~ .hamburger span:nth-child(1),
  .nav-toggle:checked ~ .hamburger span:nth-child(3) {
    top: 8px;
  }
  
  .new_nav {
    font-size: 1em;
    padding-top: 70px;
  }
  
  .new_nav div {
    padding: 12px 0;
    font-size: 0.95em;
  }
  
  /* Overlay Text - Small Mobile */
  .overlay {
    top: 12%;
    font-size: 0.8rem;
  }
  
  .ipta {
    font-size: 2rem !important;
    margin-top: 40px;
  }
  
  .south_africa {
    font-size: 1.5rem !important;
    margin-top: -20px;
  }
  
  .overlay p {
    font-size: 0.75rem !important;
  }
  
  .overlay .logo {
    height: 50px !important;
    padding-top: 10px;
  }
  
  /* Slideshow - Small Mobile */
  .slideshow-container {
    max-height: 40vh;
    margin-top: 70px;
  }
  
  .slideshow-container img {
    height: 40vh;
  }
  
  .prev, .next {
    font-size: 12px;
    padding: 8px;
  }
  
  /* Container Horizontal Layouts - Small Mobile */
  .student-week,
  .science-week {
    min-height: 150px;
  }
  
  .student-week h2,
  .science-week h2 {
    font-size: 1.2em !important;
    padding: 0 15px !important;
  }
  
  /* Week Pages - Small Mobile */
  .week1-row1,
  .week2-row1 {
    padding-left: 15px !important;
    font-size: 1rem !important;
  }
  
  .week1-row1 h1,
  .week2-row1 h1 {
    font-size: 1.2rem !important;
  }
  
  .week1-row2,
  .week2-row2 {
    padding-left: 15px !important;
    padding-right: 15px !important;
    font-size: 0.9rem !important;
  }
  
  /* Key Dates - Small Mobile */
  .key-dates p {
    font-size: 14px !important;
  }
  
  /* Committee Sections - Small Mobile */
  .site-testimonial {
    padding: 1.5rem 0.5rem;
  }
  
  .site-testimonial .section-title h2 {
    font-size: 1.5rem !important;
  }
  
  .site-testimonial-item {
    padding: 1rem;
  }
  
  .site-testimonial-item .thumb img {
    width: 50px;
    height: 50px;
  }
  
  /* Form - Small Mobile */
  .form-container {
    padding: 1rem;
  }
  
  .SW {
    font-size: 2rem !important;
    padding-left: 0.5rem !important;
  }
  
  input, select, textarea {
    font-size: 0.9rem !important;
    padding: 0.5rem 0.6rem;
  }
  
  /* Map - Small Mobile */
  .map {
    border: 5px solid white;
  }
  
  .map iframe {
    height: 250px !important;
  }
}

/* ============================================
   Landscape Mobile devices (up to 768px height)
   ============================================ */
@media screen and (max-width: 768px) and (orientation: landscape) {
  
  .slideshow-container {
    max-height: 100vh;
  }
  
  .slideshow-container img {
    height: 100vh;
  }
  
  .overlay {
    top: 10%;
  }
  
  .ipta {
    font-size: 4rem !important;
    margin-top: 20px;
  }
  
  .south_africa {
    font-size: 2.5rem !important;
    margin-top: -30px;
  }
  
  .container-hor1 {
    height: 40vh;
  }
}

/* ============================================
   Touch-friendly improvements for mobile
   ============================================ */
@media (hover: none) and (pointer: coarse) {
  
  .prev, .next {
    padding: 20px;
    font-size: 24px;
  }
  
  .dot {
    height: 18px;
    width: 18px;
    margin: 0 5px;
  }
  
  button {
    min-height: 44px;
    min-width: 44px;
  }
  
  .new_nav div {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

/* ============================================
   Print styles
   ============================================ */
@media print {
  .nav-bg,
  .prev,
  .next,
  .dot {
    display: none;
  }
  
  .slideshow-container {
    max-height: none;
  }
  
  .slideshow-container img {
    height: auto;
  }
}

