/* Home Page Specific Styles */

/* Intro Popup */
.intro-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7); /* Deep slate semi-transparent mask */
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.intro-popup-overlay.visible {
    opacity: 1;
    visibility: visible;
}

.intro-popup-content {
    width: 92%;
    max-width: 680px;
    max-height: 85vh;
    text-align: center;
    position: relative;
    background: transparent;
    border-radius: var(--radius-xl);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45);
    overflow: visible;
}

.close-popup {
    position: absolute;
    top: 10px; /* Positioned closer to the corner */
    right: 10px; /* Positioned closer to the corner */
    background: rgba(15, 23, 42, 0.7); /* High contrast dark glass style */
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-white);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}

.close-popup:hover {
    background: var(--primary-yellow);
    color: var(--text-dark);
    transform: rotate(90deg) scale(1.15);
    border-color: transparent;
    box-shadow: var(--shadow-md);
}

.intro-img {
    width: 100%;
    max-height: 80vh;
    height: auto;
    object-fit: contain;
    background: transparent;
    border-radius: var(--radius-xl);
}


/* Hero Section */
.hero-section {
    position: relative;
    min-height: 75vh; /* Reduced from 100vh for compact premium structure */
    max-height: 780px; /* Limits excessive expansion on ultra-wide screens */
    background: var(--bg-light);
    display: flex;
    align-items: center;
    padding: 120px 0 60px; /* Reduced paddings */
    overflow: hidden;
}

.hero-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    z-index: 0;
}

.shape-1 {
    top: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: rgba(14, 165, 233, 0.2);
}

.shape-2 {
    bottom: 10%;
    right: -5%;
    width: 400px;
    height: 400px;
    background: rgba(245, 158, 11, 0.2);
}

.shape-3 {
    top: 40%;
    left: 40%;
    width: 300px;
    height: 300px;
    background: rgba(56, 189, 248, 0.2);
}

.hero-container {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr; /* Optimized horizontal balance */
    gap: 3rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 2.85rem; /* Reduced from 3.5rem for extreme elegance */
    line-height: 1.25;
    margin: 1rem 0;
    color: var(--text-dark);
}

.hero-line-slider {
    position: relative;
    display: inline-grid;
    min-height: 1.25em;
    overflow: hidden;
    vertical-align: bottom;
    color: var(--primary-blue);
}

.hero-line-slider > span {
    grid-area: 1 / 1;
    display: inline-block;
    background: var(--gradient-sunset);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0;
    transform: translateY(80%);
    animation: hero-line-slide 5.6s ease-in-out infinite;
}

.hero-line-slider > span:nth-child(2) {
    animation-delay: 2.8s;
}

@keyframes hero-line-slide {
    0% {
        opacity: 0;
        transform: translateY(80%);
    }
    12%,
    44% {
        opacity: 1;
        transform: translateY(0);
    }
    56%,
    100% {
        opacity: 0;
        transform: translateY(-80%);
    }
}

.text-gradient {
    background: var(--gradient-sunset);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.badge {
    display: inline-block;
    padding: 0.4rem 0.9rem;
    background: rgba(14, 165, 233, 0.08);
    color: var(--primary-blue);
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.825rem;
    border: 1px solid rgba(14, 165, 233, 0.15);
}

.hero-subtext {
    font-size: 1.15rem; /* Reduced slightly for proportion */
    color: var(--text-muted);
    margin-bottom: 1.75rem; /* Reduced from 2.5rem */
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image-wrapper {
    position: relative;
}

.hero-image {
    padding: 1rem;
    border-radius: 2rem;
}

.hero-image img {
    border-radius: 1.5rem;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.floating-badge {
    position: absolute;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    padding: 1rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 2;
}

.badge-left {
    bottom: 20%;
    left: -10%;
}

.badge-right {
    top: 20%;
    right: -10%;
}

.icon-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.floating-badge .bold {
    display: block;
    font-weight: 700;
    color: var(--text-dark);
}

.floating-badge span:not(.bold) {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid var(--text-muted);
    border-radius: 15px;
    display: block;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--primary-blue);
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll-wheel 2s infinite;
}

@keyframes scroll-wheel {
    0% { top: 8px; opacity: 1; }
    100% { top: 25px; opacity: 0; }
}

/* Announcement Ticker */
.announcement-ticker-wrap {
    padding: 0;
    background: var(--bg-white);
    position: relative;
    z-index: 5;
}

.ticker-container {
    display: grid;
    grid-template-columns: minmax(230px, 0.34fr) minmax(0, 1fr);
    align-items: stretch;
    gap: 0;
    width: 100%;
    max-width: none;
    margin-top: 0;
    padding: 0;
    border-radius: 0;
    background: var(--bg-white);
    border-top: 1px solid rgba(14, 165, 233, 0.14);
    border-bottom: 1px solid rgba(14, 165, 233, 0.14);
    box-shadow: 0 22px 55px -30px rgba(15, 23, 42, 0.45);
    overflow: hidden;
}

.ticker-title {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.95rem 1.25rem;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(14, 165, 233, 0.14));
    border-right: 1px solid rgba(14, 165, 233, 0.14);
}

.ticker-title span {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--text-dark);
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 800;
}

.ticker-title i {
    color: var(--primary-yellow);
}

.ticker-content {
    position: relative;
    display: flex;
    align-items: center;
    min-width: 0;
    overflow: hidden;
    background:
        linear-gradient(90deg, var(--bg-white) 0%, rgba(255, 255, 255, 0) 10%),
        linear-gradient(270deg, var(--bg-white) 0%, rgba(255, 255, 255, 0) 10%);
}

.ticker-content::before,
.ticker-content::after {
    content: "";
    position: absolute;
    top: 0;
    width: 70px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.ticker-content::before {
    left: 0;
    background: linear-gradient(90deg, var(--bg-white), rgba(255, 255, 255, 0));
}

.ticker-content::after {
    right: 0;
    background: linear-gradient(270deg, var(--bg-white), rgba(255, 255, 255, 0));
}

.ticker-text-move {
    display: flex;
    width: max-content;
    min-width: 100%;
    animation: announcement-marquee 12s linear infinite;
    will-change: transform;
}

.ticker-content:hover .ticker-text-move,
.ticker-content:focus-within .ticker-text-move {
    animation-play-state: paused;
}

.ticker-group {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 1rem;
    padding: 0.95rem 0;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    flex: 0 0 auto;
    padding: 0.62rem 1rem;
    border-radius: var(--radius-full);
    background: rgba(248, 250, 252, 0.92);
    border: 1px solid rgba(14, 165, 233, 0.1);
    color: var(--text-dark);
    font-size: 0.96rem;
    font-weight: 600;
    line-height: 1.35;
    white-space: nowrap;
}

.ticker-item i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 50%;
    background: rgba(14, 165, 233, 0.1);
    color: var(--primary-blue);
    font-size: 0.8rem;
    flex: 0 0 auto;
}

@keyframes announcement-marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
    .hero-line-slider > span {
        position: static;
        opacity: 1;
        transform: none;
        animation: none;
    }

    .hero-line-slider > span:nth-child(2) {
        display: none;
    }

    .ticker-text-move {
        animation: none;
        flex-wrap: wrap;
        width: 100%;
        padding: 0.65rem;
    }
}

/* About Preview */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
}

.about-images {
    position: relative;
}

.img-main {
    width: 90%;
    border-radius: 2rem;
}

.img-overlay {
    position: absolute;
    width: 50%;
    bottom: -10%;
    right: 0;
    border-radius: 1.5rem;
    border: 10px solid var(--bg-white);
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.text-blue { color: var(--primary-blue); }

/* Stats Section */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}

.stat-card {
    padding: 2.5rem 1rem;
}

.stat-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.stat-card h3 {
    font-size: 3rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.stat-card p {
    color: var(--text-muted);
    font-weight: 500;
}

/* Academics Section Styling */
.academics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2.5rem;
}

.academic-card {
    background: var(--bg-white) !important;
    border: 1px solid rgba(14, 165, 233, 0.08) !important;
    border-radius: var(--radius-xl);
    padding: 2.5rem 2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.academic-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-blue-light) !important;
    box-shadow: var(--shadow-glow-blue);
}

.academic-icon-wrapper {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.academic-card:hover .academic-icon-wrapper {
    transform: scale(1.1) rotate(8deg);
}

.academic-icon-wrapper.icon-blue {
    background: rgba(14, 165, 233, 0.08);
    color: var(--primary-blue);
}

.academic-icon-wrapper.icon-yellow {
    background: rgba(245, 158, 11, 0.08);
    color: var(--primary-yellow);
}

.academic-card h4 {
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
    color: var(--text-dark);
}

.academic-card-text {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Student Life Section Styling */
.life-grid {
    display: grid;
    grid-template-columns: 1.1fr 1.3fr;
    gap: 5rem;
    align-items: center;
}

.life-features {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.life-feature-item {
    display: flex;
    gap: 1.25rem;
    align-items: center;
    background: var(--bg-light);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(0, 0, 0, 0.02);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.life-feature-item:hover {
    background: var(--bg-white);
    transform: translateX(6px);
    box-shadow: var(--shadow-sm);
    border-color: rgba(14, 165, 233, 0.12);
}

.life-feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.life-feature-icon.icon-blue {
    background: rgba(14, 165, 233, 0.08);
    color: var(--primary-blue);
}

.life-feature-icon.icon-yellow {
    background: rgba(245, 158, 11, 0.08);
    color: var(--primary-yellow);
}

.life-feature-content {
    display: flex;
    flex-direction: column;
}

.life-feature-title {
    margin: 0 0 0.25rem 0;
    font-size: 1.1rem;
    color: var(--text-dark);
    font-weight: 600;
}

.life-feature-desc {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.life-images {
    position: relative;
    height: 480px;
    width: 100%;
}

.life-img-1 {
    position: absolute;
    top: 0;
    left: 0;
    width: 62%;
    border-radius: var(--radius-xl);
    z-index: 1;
    box-shadow: var(--shadow-lg);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.life-img-2 {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 65%;
    border-radius: var(--radius-xl);
    z-index: 2;
    border: 6px solid var(--bg-white);
    box-shadow: var(--shadow-xl);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.life-images img:hover {
    transform: scale(1.03) translateY(-4px);
    z-index: 3;
}

/* Campus Moments */
.campus-moments {
    position: relative;
    overflow: hidden;
}

.moments-grid {
    display: grid;
    grid-template-columns: 1.25fr 1fr 1fr;
    grid-auto-rows: 220px;
    gap: 1rem;
}

.moment-card {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    min-height: 0;
    isolation: isolate;
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.12), rgba(245, 158, 11, 0.12));
}

.moment-card-large {
    grid-row: span 2;
}

.moment-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.55s ease;
}

.moment-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.62));
    z-index: 1;
}

.moment-card span {
    position: absolute;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 2;
    color: var(--bg-white);
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 800;
    text-shadow: 0 3px 14px rgba(15, 23, 42, 0.45);
}

.moment-card:hover img {
    transform: scale(1.08);
}

/* Testimonials */
.testimonials-section {
    position: relative;
    overflow: hidden;
}

.testimonials-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 12% 22%, rgba(14, 165, 233, 0.1), transparent 30%),
        radial-gradient(circle at 88% 18%, rgba(245, 158, 11, 0.12), transparent 28%);
    pointer-events: none;
}

.testimonials-section .container {
    position: relative;
    z-index: 1;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.6rem;
    align-items: stretch;
}

.testimonial-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 100%;
    padding: 2.1rem;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(14, 165, 233, 0.1);
}

.testimonial-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gradient-sunset);
    opacity: 0.9;
}

.testimonial-card:hover {
    transform: translateY(-8px);
    border-color: rgba(14, 165, 233, 0.24);
    box-shadow: 0 24px 50px -28px rgba(15, 23, 42, 0.45);
}

.quote-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(14, 165, 233, 0.08);
    font-size: 1.25rem;
}

.testimonial-rating {
    display: flex;
    justify-content: center;
    gap: 0.25rem;
    color: var(--primary-yellow);
    margin-bottom: 1.1rem;
    font-size: 0.95rem;
}

.testimonial-text {
    color: var(--text-dark);
    font-size: 1rem;
    line-height: 1.75;
    margin-bottom: 1.6rem;
    flex: 1;
}

.testimonial-author {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 0.8rem;
    align-items: center;
    justify-content: center;
    text-align: left;
    padding-top: 1.1rem;
    border-top: 1px solid rgba(100, 116, 139, 0.14);
}

.author-avatar {
    grid-row: span 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--gradient-sky);
    color: var(--bg-white);
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.86rem;
    box-shadow: var(--shadow-glow-blue);
}

.author-name {
    margin: 0;
    font-size: 1rem;
    color: var(--text-dark);
}

.author-sub {
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.4;
}

/* Responsive */
@media (max-width: 991px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .hero-section {
        min-height: auto;
        padding: 100px 0 50px;
    }
    
    .hero-content h1 {
        font-size: 2.35rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .badge-left, .badge-right {
        display: none;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
    
    .about-text .section-title {
        text-align: center !important;
    }
    
    .feature-list {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .life-grid {
        grid-template-columns: 1fr;
        gap: 3.5rem;
    }

    .life-text .section-title {
        text-align: center !important;
    }

    .life-images {
        height: 380px;
        max-width: 480px;
        margin: 0 auto;
    }

    .ticker-container {
        grid-template-columns: 1fr;
        margin-top: 0;
    }

    .ticker-title {
        align-items: center;
        text-align: center;
        border-right: 0;
        border-bottom: 1px solid rgba(14, 165, 233, 0.14);
    }

    .ticker-text-move {
        animation-duration: 12s;
    }

    .moments-grid {
        grid-template-columns: 1fr 1fr;
        grid-auto-rows: 210px;
    }

    .moment-card-large {
        grid-column: span 2;
        grid-row: span 1;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
        max-width: 640px;
        margin: 0 auto;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 1.85rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .life-images {
        height: 280px;
    }

    .life-feature-item {
        flex-direction: column;
        text-align: center;
        padding: 1.25rem 1rem;
        gap: 0.75rem;
    }

    .ticker-title {
        padding: 1rem;
    }

    .ticker-content::before,
    .ticker-content::after {
        width: 34px;
    }

    .ticker-group {
        gap: 0.75rem;
    }

    .ticker-item {
        max-width: 78vw;
        white-space: normal;
        padding: 0.6rem 0.85rem;
        font-size: 0.9rem;
    }

    .testimonial-card {
        padding: 1.7rem 1.35rem;
    }

    .testimonial-author {
        justify-content: start;
    }

    .moments-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: 230px;
    }

    .moment-card-large {
        grid-column: auto;
    }
}
