/* =================================
   Global Styles & Reset
   ================================= */
:root {
    /* Primary Colors */
    --color-primary-dark: #0d2b57;
    --color-primary-darker: #051d39;
    --color-accent: #F5A623;
    --color-accent-hover: #e67e2f;
    --color-accent-light: #FFC45D;
    
    /* Neutrals */
    --color-white: #ffffff;
    --color-text-dark: #111827;
    --color-text-body: #444444;
    --color-text-light: #666666;
    --color-text-lighter: #6b7280;
    --color-text-subtitle: #555555;
    --color-bg-light: #f7fafc;
    --color-bg-lighter: #f9fafb;
    --color-border: #e0e7ff;
    
    /* Typography */
    --font-family: 'Poppins', sans-serif;
    --font-size-h1: 2.5rem;
    --font-size-h2: 2.5rem;
    --font-size-h3: 1.5rem;
    --font-size-h4: 1.1rem;
    --font-size-body: 1rem;
    --font-size-small: 0.95rem;
    --font-size-smaller: 0.9rem;
    
    --line-height-heading: 1.2;
    --line-height-body: 1.8;
    --line-height-relaxed: 1.7;
}

*{
    margin: 0;
    padding: 0;
    font-family: var(--font-family);
}

/* Skip to main content link - visible on focus */
.skip-to-main {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--color-primary-dark);
    color: var(--color-white);
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
    font-weight: 600;
}

.skip-to-main:focus {
    top: 0;
}

/* Global Heading Consistency */
h1 {
    font-size: var(--font-size-h1);
    font-weight: 700;
    line-height: var(--line-height-heading);
    letter-spacing: -0.02em;
}

h2 {
    font-size: var(--font-size-h2);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
    margin-bottom: 24px;
    color: var(--color-primary-dark);
}

h3 {
    font-size: var(--font-size-h3);
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
}

h4 {
    font-size: var(--font-size-h4);
    font-weight: 600;
}

h5, h6 {
    font-size: 1rem;
    font-weight: 600;
}

p {
    color: var(--color-text-body);
    font-size: var(--font-size-body);
    font-weight: 400;
    line-height: var(--line-height-body);
}

/* Ensure images are responsive */
img {
    max-width: 100%;
    height: auto;
}

/* =================================
   Header & Hero Section
   ================================= */
.header{
    min-height: 100vh ;
    width: 100%;
    background-image: linear-gradient(rgba(4,9,30,0.7), rgba(4,9,30,0.7)), url(images/background.jpg);
    background-position: center;
    background-size: cover;
    position: relative;
    display: flex;
    flex-direction: column;
}
nav{
    display: flex;
    /* reduced top spacing so the nav / toolbar and logo sit closer to the top */
    padding: 20px 6% 14px 6%;
    justify-content: space-between;
    align-items: center;
    transform: translateY(-120%);
    transition: transform .45s ease-out;
    gap: 16px;
    flex-wrap: wrap;
    flex-wrap: nowrap;
}
nav img{
    /* increased default logo size; keep responsive with max-width */
    width: 220px;
    max-width: 100%;
    height: auto;
}
.nav-links{
    flex:1;
    text-align: center;
}
.nav-links ul li{
    list-style: none;
    display: inline-block;
    padding: 8px 12px;
    position: relative;
}
.nav-links ul li a{
    color: var(--color-white);
    text-decoration: none;
    font-size: 18px;
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
}

.nav-links ul li::after{
    content: '';
    width: 0%;
    height: 2px;
    background: var(--color-accent);
    display: block;
    margin: auto ;
    transition: 0.5s;
}

.nav-links ul li:hover::after{
    width: 100%;
}

.nav-links ul li.active::after,
.nav-links ul li a[aria-current="page"]::after {
    width: 100%;
    background: var(--color-accent);
}

/* Navigation Actions (Sign in button on desktop) */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Auth button styles */
.btn-auth {
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    background: transparent;
    border: 2px solid var(--color-white);
    color: var(--color-white);
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    white-space: nowrap;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-auth:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--color-white);
    transform: translateY(-1px);
}

.btn-auth:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5), 0 0 0 2px var(--color-primary-dark);
}

.btn-auth:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 2px;
}

/* User pill (when logged in) */
.user-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 20px;
    color: var(--color-white);
    font-size: 14px;
    font-weight: 600;
}

.btn-logout {
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(239, 68, 68, 0.8);
    color: var(--color-white);
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 1);
}

/* Mobile nav auth container */
.nav-links ul li.nav-auth-container {
    display: none !important;
}

.text-box{
    width: 90%;
    color: var(--color-primary-dark);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    text-align: center;
}

.text-box h1{
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: -1px;
    color: var(--color-primary-dark);
}

.text-box p{
    font-size: 1.25rem;
    font-weight: 300;
    margin-bottom: 40px;
    max-width: 600px;
    line-height: 1.6;
    margin-left: auto;
    margin-right: auto;
    color: var(--color-primary-dark);
}
.hero-btn{
    display: inline-block;
    text-decoration: none;
    color: var(--color-white);
    border: 1px solid var(--color-white);
    padding: 12px 34px;
    font-size: 13px;
    background: transparent;
    position: relative;
    cursor: pointer;
}
.hero-btn:hover{
    border: 1px solid var(--color-accent);
    background: var(--color-accent);
    transition: 1s;
}
nav .fa{
    display: none
}

/* Slide nav into place when ready */
body.nav-ready nav{
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce){
    nav{ transform: none !important; transition: none !important; }
}

/* =================================
   Homepage Sections (Index)
   ================================= */

/* Hero Section Enhancements */
.homepage-section {
    width: 100%;
    padding: 100px 20px;
}

@media (max-width: 768px) {
    .homepage-section {
        padding: 60px 20px;
    }
}

@media (max-width: 600px) {
    .homepage-section {
        padding: 40px 16px;
    }
}

.homepage-section h2 {
    text-align: center;
    font-size: 2.8rem;
    color: var(--color-primary-dark);
    font-weight: 700;
    margin-bottom: 16px;
}

.homepage-section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: var(--color-text-subtitle);
    max-width: 700px;
    margin: 0 auto 60px;
    line-height: 1.8;
    font-weight: 400;
}

/* Four Tab Section */
.four-tabs-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .four-tabs-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 600px) {
    .four-tabs-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.four-tab {
    background: var(--color-white);
    border-radius: 16px;
    padding: 40px 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(13, 43, 87, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    min-height: 350px;
    border: 2px solid transparent;
}

.four-tab:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(13, 43, 87, 0.15);
}

.four-tab:focus-within {
    outline: none;
    border-color: var(--color-primary-dark);
    box-shadow: 0 20px 50px rgba(13, 43, 87, 0.15);
}

/* =================================
     Dropdown Menu Animation
     ================================= */
.nav-links ul li.has-dropdown{ position: relative; }
.nav-links ul li.has-dropdown > .dropdown{
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    min-width: 180px;
    list-style: none;
    background: var(--color-white);
    border: 1px solid rgba(17,24,39,0.12);
    border-radius: 10px;
    padding: 8px 0;
    box-shadow: 0 10px 24px rgba(15,23,42,0.25);
    opacity: 0;
    transform: translateY(-10px);
    visibility: hidden;
    pointer-events: none;
    transition: transform .25s ease, opacity .25s ease, visibility 0s linear .25s;
    z-index: 9999;
}
.nav-links ul li.has-dropdown > .dropdown li{ display:block; }
.nav-links ul li.has-dropdown > .dropdown a{
    display:block;
    padding: 8px 14px;
    color: var(--color-text-dark);
    text-decoration: none;
    white-space: nowrap;
}
.nav-links ul li.has-dropdown > .dropdown a:hover{ background: #f3f4f6; }
.nav-links ul li.has-dropdown.open > .dropdown{
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    pointer-events: auto;
    transition: transform .25s ease, opacity .25s ease, visibility 0s;
}

/* Also show on hover for desktop */
@media (min-width: 769px) {
    .nav-links ul li.has-dropdown:hover > .dropdown{
        opacity: 1;
        transform: translateY(0);
        visibility: visible;
        pointer-events: auto;
    }
}

/* Mobile: dropdown fits within the slide-out menu */
@media (max-width: 768px){
    .nav-links{ text-align: left; }
    .nav-links ul li.has-dropdown > .dropdown{
        position: static;
        background: transparent;
        border: none;
        box-shadow: none;
        padding: 0;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
        overflow: hidden;
        max-height: 0;
        transition: max-height .25s ease;
    }
    .nav-links ul li.has-dropdown.open > .dropdown{ max-height: 240px; }
    .nav-links ul li.has-dropdown > .dropdown a{ color: #fff; padding: 6px 0; }
    
    /* Mobile: show auth button in menu, hide desktop version */
    .nav-links ul li.nav-auth-container {
        display: list-item !important;
        border-top: 1px solid rgba(255, 255, 255, 0.15);
        padding-top: 12px;
        margin-top: 12px;
        padding: 12px 0 0 0;
    }
    .nav-actions {
        display: none !important;
    }
}

.four-tab-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.four-tab:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 45px rgba(13, 43, 87, 0.15);
}

/* =================================
   Slide-In Reveal Utilities (site-wide)
   ================================= */
.slide-in-left,
.slide-in-right,
.slide-in-up{
    opacity: 0;
    transform: translate3d(0,0,0);
    will-change: transform, opacity;
}
.slide-in-left{ transform: translateX(-28px); }
.slide-in-right{ transform: translateX(28px); }
.slide-in-up{ transform: translateY(24px); }

.slide-in-left.in-view,
.slide-in-right.in-view,
.slide-in-up.in-view{
    opacity: 1;
    transform: none;
    transition:
        transform .60s cubic-bezier(0.22, 1, 0.36, 1) var(--si-delay, 0ms),
        opacity .60s cubic-bezier(0.22, 1, 0.36, 1) var(--si-delay, 0ms);
}

@media (prefers-reduced-motion: reduce){
    .slide-in-left,
    .slide-in-right,
    .slide-in-up{
        opacity: 1;
        transform: none;
        transition: none;
    }
}

.four-tab-icon {
    font-size: 48px;
    color: var(--color-accent);
    margin-bottom: 20px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.four-tab h3 {
    font-size: 1.6rem;
    color: var(--color-primary-dark);
    font-weight: 700;
    margin-bottom: 12px;
}

.four-tab p {
    color: var(--color-text-light);
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 24px;
    flex-grow: 1;
}

.four-tab-btn {
    display: inline-block;
    background: var(--color-accent);
    color: var(--color-white);
    padding: 12px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s ease;
    align-self: center;
}

.four-tab-btn:hover {
    background: var(--color-accent-hover);
}

/* Quick Links Section */
.quick-links-section {
    background: #f7fafc;
    padding: 80px 20px;
}

.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 25px;
    max-width: 1200px;
    margin: 0 auto;
}

.quick-link-card {
    background: var(--color-white);
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 6px 16px rgba(13, 43, 87, 0.06);
    transition: all 0.3s ease;
}

.quick-link-card:hover {
    box-shadow: 0 10px 25px rgba(13, 43, 87, 0.12);
    transform: translateY(-4px);
}

.quick-link-card i {
    font-size: 36px;
    color: var(--color-accent);
    margin-bottom: 12px;
}

.quick-link-card h4 {
    font-size: 1.1rem;
    color: var(--color-primary-dark);
    font-weight: 600;
    margin-bottom: 8px;
}

.quick-link-card p {
    color: var(--color-text-light);
    font-size: 1rem;
    margin-bottom: 16px;
    line-height: 1.6;
}

.quick-link-card a {
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.quick-link-card a:hover {
    color: var(--color-accent-hover);
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, var(--color-primary-dark) 0%, #1a3a6e 100%);
    padding: 80px 20px;
    text-align: center;
    color: var(--color-white);
}

.cta-section h2 {
    color: var(--color-white);
    font-size: 2.2rem;
    margin-bottom: 16px;
}

.cta-section p {
    font-size: 1.1rem;
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    color: var(--color-white);
}

.cta-btn {
    display: inline-block;
    background: var(--color-accent);
    color: var(--color-white);
    padding: 16px 40px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.05rem;
    transition: all 0.3s ease;
    box-shadow: 0 8px 18px rgba(255, 140, 58, 0.3);
}

.cta-btn:hover {
    background: var(--color-accent-hover);
    box-shadow: 0 12px 24px rgba(255, 140, 58, 0.4);
    transform: translateY(-2px);
}

/* Footer Styling */
.footer {
    background: var(--color-primary-dark);
    color: var(--color-white);
}

.footer h4 {
    color: var(--color-white);
}

.footer p {
    color: #d0d8e0;
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer i {
    color: var(--color-accent);
}

@media (max-width: 768px) {
    .text-box h1 {
        font-size: 2.5rem;
    }

    .text-box p {
        font-size: 1rem;
    }

    .homepage-section h2 {
        font-size: 1.8rem;
    }

    .four-tab h3 {
        font-size: 1.3rem;
    }

    .quick-links-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {
    .text-box h1{
        font-size: 20px;
    }
    .nav-links{
        position:absolute;
        background: var(--color-accent);
        height: 100vh;
        width: 200px;
        top: 0;
        right: -200px;
        text-align: left;
        z-index: 2;
        transition: 1s;

    }
    /* reduce nav padding on small screens so header remains compact */
    nav{
        padding: 12px 6%;
    }
    nav .fa{
        display: block;
        color:#fff;
        margin: 10px;
        font-size: 22px;
        cursor: pointer;
    }

    /* reduce logo size on small screens so header stays tidy */
    nav img{
        width: 140px;
    }


    .nav-links ul{
        padding: 30px;
    }

}
/* ----course---- */
.course{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 100px;
}

p{
    color: #666;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.6;
}

.row{
    margin-top: 5%;
    display: flex;
    justify-content: space-between;
}
.course-col{
    flex-basis: 31%;
    background: #fff3f3;
    border-radius: 10px;
    margin-bottom: 5%;
    padding: 20px 12px;
    box-sizing: border-box;
    transition: 0.5s;
}
.course-col:hover{
    box-shadow: 0 0 20px 0px rgba(0,0,0,0.2);
}
@media(max-width: 700px) {
    .row{
        flex-direction: column;
    }
}
/* -------CAMPUS-------- */
.campus{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 50px;
}
/* -------Hides part of the image-------- */
.campus-col{
    flex-basis: 32%;
    border-radius: 10px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}
.campus-col img{
    width: 100%;
    display: block;
}
.layer{
    /* start transparent and hidden; reveal on hover */
    background: rgba(226,0,0,0);
    height: 100%;
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    opacity: 0;
    transition: background 0.3s ease, opacity 0.3s ease;
    z-index: 2;
}

.campus-col:hover .layer{
    background: rgba(245, 166, 35, 0.7);
    opacity: 1;
}
.layer h3{
    width: 100%;
    font-weight: 500;
    color: #fff;
    font-size: 50px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    position: absolute;
    transition: 0.5s;

}
.layer:hover h3{
    bottom: 49%;
    opacity: 1;

}

.facilities{
    width: 80%;
    margin: auto;
    text-align: center;
    padding-top: 100px;

}
.facilities-col{
    flex-basis: 31%;
    border-radius: 10px;
    margin-bottom: 5%;
    text-align: left;
}
.facilities-col img{
    width: 100%;
    border-radius: 10px;
}
.facilities-col p{
    padding: 0;
}
.facilities-col h3{
    margin-top: 16px;
    margin-bottom: 15px;
    text-align: left;
}
/* ===== Testimonials (soft cards) ===== */
.testimonials{
  width: 80%;
  margin: 0 auto;
  padding: 80px 0;
  text-align: center;
}

.testimonials h1{
  font-size: 56px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.testimonials > p{
  max-width: 760px;
  margin: 12px auto 48px;
  font-size: 20px;
  line-height: 1.6;
  color: var(--color-text-lighter);
  padding: 0;
}

.testimonials .row{
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 48px;
  flex-wrap: nowrap;
  overflow-x: auto;
}

.testimonials-col{
  flex: 1 1 520px;
  max-width: 600px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  text-align: left;

  background: #fff3f0;
  border-radius: 20px;
  padding: 32px 36px;
  color: var(--color-text-dark);
  box-shadow: 0 12px 32px rgba(0,0,0,.06);
}

.testimonials-col img{
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 56px;
  margin: 0 8px 0 0;
}

.testimonials-col p{
  margin: 0 0 16px;
  padding: 0;
  font-size: 18px;
  line-height: 1.7;
  color: var(--color-text-lighter);
}

.testimonials-col h3{
  margin: 0;
  font-size: 24px;
  font-weight: 700;
  color: var(--color-text-dark);
}

.testimonials-col .stars{
  margin-top: 6px;
  font-size: 16px;
  color: #f59e0b;
}
.testimonials-col i {
    color: var(--color-accent);
    margin-right: 4px;
    font-size: 18px;
}
@media(max-width: 700px) {
    .testimonials-col img{
        margin-left: 0px;
        margin-right: 15px;
    }
}
/* ----footer---- */
.footer{
    width: 100%;
    text-align: center;
    padding: 30px 0;
}
.footer h4{
    margin-bottom: 25px;
    margin-top: 20px;
    font-weight: 600;
}
.icons i{
    color: var(--color-accent);
    margin: 0 13px;
    cursor: pointer;
    padding: 18px 0;
}
.fa-heart-o{
    color: #ff0000;
}

/* ------ about us page ----- */
.sub-header{
    height: 50vh;
    width: 100%;
    background-image: linear-gradient(rgba(4,9,30,0.7), rgba(4,9,30,0.7)), url(images/background.jpg);
    background-position: center;
    background-size: cover;
    text-align: center;
    color: #fff;
}
.sub-header h1{
    margin-top: 100px;
}
.about-us{
    width: 80%;
    margin: auto;
    padding-top: 80px;;
    padding-bottom: 50px;
}
.about-col{
    flex-basis: 48%;
    padding: 30px 2px;
}
.about-col img{
    width: 100%;
}
.about-col h1{
    padding-top: 0;
}
.about-col p{
    padding: 15px 0 25px;
}
.red-btn{
    border: 1px solid var(--color-accent);
    background:transparent;
    color: var(--color-accent);
}
.red-btn:hover{
    color: var(--color-white);
    background: var(--color-accent);
}
/* Remove duplicate dropdown block: consolidated above */
.nav-links ul li .dropdown a {
    display: block;
    padding: 10px 14px;
    color: var(--color-text-dark); /* dark text for contrast */
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
    border-radius: 6px;
    text-align: center; /* center dropdown text horizontally */
    pointer-events: auto;
}
.nav-links ul li .dropdown a:hover {
    background: rgba(15,23,42,0.04);
}

/* If dropdown is near the right edge (last one or last two items), anchor to the right so it opens leftwards */
.nav-links ul li.has-dropdown:nth-last-child(-n+2) > .dropdown {
    right: 0;
    left: auto;
    transform-origin: top right;
}

/* --- Mobile behavior --- */
@media (max-width: 700px) {
  /* Your menu becomes a slide-out; make dropdown stack and always visible under COURSE */
  .nav-links ul li .dropdown {
    position: static;
    display: block;
    border: none;
    box-shadow: none;
    background: transparent;
    padding: 0;
    margin-top: 6px;
  }
  .nav-links ul li .dropdown a {
    padding: 8px 0 8px 16px; /* indent child links under COURSE */
    border-radius: 6px;
  }
}

/* =================================
   About Page Dropdowns
   ================================= */
.about-dropdowns {
    width: 80%;
    margin: 60px auto;
    padding: 40px 0;
}

.dropdowns-container h2 {
    text-align: center;
    font-size: 32px;
    margin-bottom: 40px;
    color: #333;
}

.dropdown-item {
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.dropdown-header {
    width: 100%;
    padding: 20px;
    background: #f8f9fa;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    transition: background 0.3s ease;
}

.dropdown-header:hover {
    background: #e9ecef;
}

.dropdown-header i {
    transition: transform 0.3s ease;
}

.dropdown-content {
    display: none;
    padding: 20px;
    background: #fff;
    border-top: 1px solid #ddd;
    max-height: 500px;
    overflow-y: auto;
}

.dropdown-content p {
    margin: 0;
    color: #555;
}

.dropdown-content a {
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.dropdown-content a:hover {
    color: var(--color-accent-hover);
    text-decoration: underline;
}

@media (max-width: 700px) {
    .about-dropdowns {
        width: 90%;
    }

    .dropdowns-container h2 {
        font-size: 24px;
    }

    .dropdown-header {
        padding: 15px;
        font-size: 14px;
    }
}

/* =================================
   Blog Page Styles
   ================================= */
.blog-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 16px 60px;
}

.blog-intro {
    text-align: left;
    margin-bottom: 28px;
}

.blog-intro h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #0b2345;
    margin-bottom: 8px;
}

.blog-intro p {
    font-size: 0.98rem;
    color: var(--color-text-lighter);
}

/* ===== GRID: 3 COLUMNS ===== */
#blog-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(260px, 1fr));
    gap: 28px;
}

@media (max-width: 960px) {
    #blog-list {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }
}

@media (max-width: 640px) {
    #blog-list {
        grid-template-columns: 1fr;
    }
}

/* ===== BLOG CARDS ===== */
.post-card {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 240px;
    background: #f4f7ff;
    border-radius: 32px;
    padding: 28px 26px 24px;
    border: 1px solid #e0e7ff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 26px 70px rgba(15, 23, 42, 0.18);
    background: #edf3ff;
}

/* Subtle tint per category */
.post-anxiety { background: #f3f6ff; }
.post-sleep { background: #f5f7ff; }
.post-academic { background: #f3f9ff; }
.post-depression { background: #f7f4ff; }
.post-social { background: #f5f8ff; }
.post-mindfulness { background: #f3fbff; }
.post-talking { background: #f4f7ff; }
.post-balance { background: #f7f8ff; }
.post-confidence { background: #f6f4ff; }
.post-support { background: #f7f3ff; }

.post-label {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0.03em;
    color: #425577;
    margin-bottom: 16px;
}

.post-title {
    font-size: 1.4rem;
    line-height: 1.3;
    font-weight: 700;
    color: #0b2345;
    margin: 0;
}

.post-learn {
    margin-top: 30px;
    font-size: 1rem;
    font-weight: 600;
    color: #0b2345;
    display: inline-flex;
    align-items: center;
}

.post-learn span {
    border-bottom: 3px solid var(--color-accent);
    padding-bottom: 3px;
}

/* ===== DETAIL VIEW ===== */
#blog-detail {
    display: none;
    margin-top: 40px;
}

.detail-card {
    background: var(--color-white);
    border-radius: 24px;
    border: 1px solid #e5e7eb;
    padding: 26px 26px 24px;
    box-shadow: 0 16px 50px rgba(15, 23, 42, 0.10);
}

.detail-title {
    font-size: 1.9rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #0b2345;
}

.detail-meta {
    font-size: 0.86rem;
    color: var(--color-text-lighter);
    margin-bottom: 22px;
}

.detail-body p {
    line-height: 1.7;
    margin-bottom: 14px;
    font-size: 0.98rem;
    color: #1f2933;
}

.btn-row {
    margin-top: 20px;
}

.btn-back {
    appearance: none;
    border-radius: 999px;
    padding: 9px 18px;
    border: 1px solid #cbd5e1;
    background: var(--color-white);
    font-size: 0.9rem;
    cursor: pointer;
    font-weight: 500;
    color: #0b2345;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.btn-back i {
    font-size: 0.85rem;
}

.btn-back:hover {
    background: #e5edff;
    border-color: #2563eb;
    transform: translateY(-1px);
}

@media (max-width: 650px) {
    .detail-card {
        padding: 20px 18px;
        border-radius: 20px;
    }
    .detail-title {
        font-size: 1.6rem;
    }
}

/* =================================
   Accessibility & Focus States
   ================================= */

/* Focus states for all interactive elements */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Enhanced focus states for buttons */
.btn-back:focus-visible,
.btn-auth:focus-visible,
.cta-btn:focus-visible,
.four-tab-btn:focus-visible,
.hero-btn:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.25);
}

/* Enhanced focus for links */
a:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Enhanced focus for form elements */
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    border-color: var(--color-accent);
}

/* Active state for navigation dropdowns - only open when explicitly toggled */
.nav-links ul li.has-dropdown.open > .dropdown,
.nav-links ul li.has-dropdown[aria-expanded="true"] > .dropdown {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
    pointer-events: auto;
}

/* Keyboard navigation visible indicator */
.nav-links ul li a:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: -2px;
    border-radius: 4px;
    box-shadow: inset 0 0 0 2px var(--color-accent);
}

/* Dropdown items focus state */
.nav-links ul li .dropdown a:focus-visible {
    background: rgba(245, 166, 35, 0.1);
    outline: 2px solid var(--color-accent);
    outline-offset: -2px;
}

/* Skip to main content focus */
.skip-to-main:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 2px;
}

/* Card focus states */
.post-card:focus-visible,
.quick-link-card:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Dropdown button accessibility */
.dropdown-header:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    background: rgba(245, 166, 35, 0.05);
}

/* ========================================
   Auth Modal Styles (Sign In / Register)
   ======================================== */

.ym-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    z-index: 10000;
    overflow-y: auto;
}

.ym-modal-overlay.is-open {
    display: flex;
}

/* Modal card */
.ym-modal {
    width: 100%;
    max-width: 480px;
    background: #fff;
    color: #111;
    border-radius: 18px;
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.35);
    padding: 28px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    margin: auto;
}

.ym-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: #fff;
    cursor: pointer;
    font-size: 16px;
}

/* Head */
.ym-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.ym-title {
    margin: 0;
    font-size: clamp(28px, 6vw, 34px);
    font-weight: 900;
    letter-spacing: -0.02em;
}

.ym-subtitle {
    margin: 0 0 10px 0;
    color: #444;
    font-size: 18px;
}

.ym-chip {
    padding: 8px 18px;
    border-radius: 999px;
    background: #fff;
    border: 1.5px solid #111;
    font-weight: 700;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.ym-chip:hover {
    background: #f5f5f5;
}

/* Form */
.ym-label {
    display: block;
    margin: 12px 0 6px;
    font-size: clamp(14px, 3vw, 16px);
    font-weight: 700;
    color: #111;
}

.ym-req {
    color: #b91c1c;
}

.ym-input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1.5px solid #ccc;
    font-size: clamp(14px, 3vw, 16px);
    outline: none;
    box-sizing: border-box;
    background: #fff;
    transition: border-color 0.2s ease;
}

.ym-input:focus {
    border-color: #111;
    box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.08);
}

.ym-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 12px 0 8px;
    flex-wrap: wrap;
}

.ym-check {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: clamp(13px, 3vw, 16px);
    font-weight: 600;
    color: #111;
}

.ym-check input {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.ym-link {
    border: 0;
    background: transparent;
    color: #0066cc;
    text-decoration: underline;
    font-size: clamp(13px, 3vw, 15px);
    cursor: pointer;
    padding: 0;
    font-weight: 600;
}

.ym-link:hover {
    color: #004fa3;
}

.ym-primary {
    width: 100%;
    margin-top: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    border: 0;
    background: #222;
    color: #fff;
    font-size: clamp(14px, 3vw, 18px);
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

.ym-primary:hover:not(:disabled) {
    background: #111;
}

.ym-primary:active:not(:disabled) {
    transform: translateY(1px);
}

.ym-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.ym-primary-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.ym-or {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 14px 0;
}

.ym-or-line {
    height: 1px;
    background: #ddd;
    flex: 1;
}

.ym-or-text {
    color: #666;
    font-weight: 600;
    font-size: 13px;
}

.ym-provider {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1.5px solid #111;
    background: #fff;
    font-size: clamp(14px, 3vw, 16px);
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.ym-provider:hover:not(:disabled) {
    background: #f5f5f5;
}

.ym-provider-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    background: #f0f0f0;
    border: 1px solid #ddd;
}

.ym-legal {
    margin: 10px 0 0 0;
    color: #666;
    font-size: clamp(12px, 2.5vw, 14px);
    line-height: 1.5;
}

.ym-msg {
    margin-top: 10px;
    min-height: 16px;
    font-size: clamp(13px, 2.5vw, 15px);
    color: #c41e3a;
    font-weight: 700;
}
