/* 
  Teclipse Education Hub
  Enhanced Modern, Professional Theme
*/

:root {
    /* Color Palette */
    --primary-color: #0F3460;
    /* Deep Rich Blue */
    --accent-color: #E94560;
    /* Vibrant Red/Pink Accent */
    --accent-hover: #D63D56;
    --secondary-blue: #16213E;
    /* Dark Navy for depth */

    /* Light Theme (Default) */
    --bg-color: #F8F9FA;
    /* Slightly off-white for less glaring contrast */
    --bg-secondary: #EAECEF;
    /* Soft gray-blue */
    --text-main: #1A1A2E;
    --text-muted: #535C68;
    --card-bg: #FFFFFF;
    --border-color: #D1D8E0;
    --nav-bg: rgba(255, 255, 255, 0.85);

    /* Shadows - softer, deeper */
    --shadow-sm: 0 4px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);

    /* Geometry */
    --radius-md: 0.75rem;
    --radius-xl: 1.25rem;
    --radius-2xl: 2rem;

    /* Transitions */
    --transition-fast: 0.2s ease-out;
    --transition-smooth: 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    --navbar-height: 64px;
}

/* Dark Theme Variables */
[data-theme="dark"] {
    --bg-color: #1A1A2E;
    /* Deep space background */
    --bg-secondary: #16213E;
    --text-main: #F4F4F9;
    --text-muted: #A0A5B5;
    --card-bg: #16213E;
    --border-color: #2D3A56;
    --nav-bg: rgba(26, 26, 46, 0.85);

    --primary-color: #4A90E2;
    /* Brighter blue for dark mode */
    --accent-color: #E94560;
    --accent-hover: #FF5A76;
    --secondary-blue: #0F3460;

    --shadow-sm: 0 4px 10px rgba(0, 0, 0, 0.25);
    --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.6);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 5rem;
}

/* Prevent horizontal scroll caused by offscreen transforms or wide elements */
html, body { overflow-x: hidden; }

/* Ensure nav container sizing and prevent content shift */
.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

/* Always show subtitle next to logo in navbar */
.navbar .logo-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.navbar .logo-text span {
    display: block;
    font-size: 0.75rem;
    color: var(--primary-color);
    margin-top: 2px;
}

/* Mobile: center logo text and ensure it doesn't overflow */
@media (max-width: 480px) {
    .nav-container {
        padding: 0.6rem 1rem;
        align-items: center;
        gap: 0.5rem;
    }

    .logo {
        display: flex;
        align-items: center;
        gap: 0.6rem;
    }

    .logo-text {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        line-height: 1;
        white-space: nowrap;
    }

    .logo-text span {
        font-size: 0.65rem;
        color: var(--primary-color);
    }
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--transition-smooth), color var(--transition-smooth);
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--text-main);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

h2 {
    font-size: 2.75rem;
    margin-bottom: 0.75rem;
}

p {
    color: var(--text-muted);
    text-align: justify;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

li {
    list-style: none;
}

.section-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 6rem 0;
}

.bg-secondary {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.section-header p {
    text-align: center;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.85rem 1.75rem;
    border-radius: var(--radius-xl);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
    outline: none;
    letter-spacing: 0.02em;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-blue));
    color: #FFFFFF;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--secondary-blue), var(--primary-color));
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    color: #FFFFFF;
}

.btn-outline {
    background-color: transparent;
    color: var(--text-main);
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: #FFFFFF;
}

.btn-block {
    width: 100%;
}

.icon-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-main);
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    transition: background-color var(--transition-fast);
}

.icon-btn:hover {
    background-color: var(--bg-secondary);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--nav-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--border-color);
    transition: all var(--transition-smooth);
    height: var(--navbar-height);
}

/* Keep navbar height stable to avoid layout jumps when scrolled */
.navbar.scrolled {
    box-shadow: var(--shadow-md);
}

/* Ensure nav-container controls spacing so changes to .navbar don't shift content */
.nav-container {
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

/* Ensure content doesn't sit under the fixed navbar */
body { padding-top: var(--navbar-height); }

/* Reduce extra top space for admin pages so header sits closer to navbar */
.admin-body {
    padding-top: calc(var(--navbar-height) - 8px);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-img {
    height: 50px;
    object-fit: contain;
}

.logo-text {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -0.02em;
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.logo-text span {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 1rem;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-main);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-login {
    padding: 0.6rem 1.5rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    font-size: 0.95rem;
    font-weight: 600;
}

.btn-login:hover {
    border-color: var(--primary-color);
    background-color: var(--primary-color);
    color: #FFF;
}

.mobile-menu-btn {
    display: none;
}

/* Mobile Sidebar */
.mobile-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100vh;
    background-color: var(--bg-color);
    z-index: 2001;
    transform: translateX(-120%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 5px 0 25px rgba(0, 0, 0, 0.15);
    padding: 2rem;
    border-right: 1px solid var(--border-color);
}

.mobile-sidebar.open {
    transform: translateX(0);
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.sidebar-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* Ensure overlay doesn't capture pointer events when hidden */
.sidebar-overlay {
    pointer-events: none;
}
.sidebar-overlay.open {
    pointer-events: auto;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
}

.mobile-links {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.mobile-links a {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-main);
    display: block;
}

/* Center mobile menu text and items */
.mobile-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    text-align: center;
}

.mobile-links a.active {
    color: var(--primary-color);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 3000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.modal.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    background-color: var(--bg-color);
    padding: 3rem;
    border-radius: var(--radius-2xl);
    width: 90%;
    max-width: 450px;
    position: relative;
    box-shadow: var(--shadow-lg);
    transform: translateY(-30px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--border-color);
}

.modal.show .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 32px;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.2s;
}

.close-modal:hover {
    color: var(--accent-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 6rem;
    max-width: 1280px;
    margin: 0 auto;
    padding-left: 2rem;
    padding-right: 2rem;
}

.hero-content {
    flex: 1;
    padding-right: 3rem;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.hero-title span {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    max-width: 550px;
    line-height: 1.7;
}

.hero-btns {
    display: flex;
    gap: 1.25rem;
}

.hero-illustration {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

/* Abstract Tech Animation */
.abstract-tech {
    width: 400px;
    height: 400px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.tech-ring {
    position: absolute;
    border-radius: 50%;
    border: 2px solid transparent;
}

.ring-1 {
    width: 250px;
    height: 250px;
    border-color: var(--primary-color);
    opacity: 0.15;
    animation: rotate 30s linear infinite;
}

.ring-2 {
    width: 350px;
    height: 350px;
    border: 2px dashed var(--accent-color);
    opacity: 0.2;
    animation: rotate 20s linear infinite reverse;
}

.center-node {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-blue));
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    box-shadow: var(--shadow-lg);
    animation: morph 8s ease-in-out infinite, glow 4s ease-in-out infinite alternate;
}

.tech-node {
    position: absolute;
    border-radius: 50%;
}

.satellite-1 {
    width: 25px;
    height: 25px;
    background-color: var(--accent-color);
    top: 15%;
    left: 20%;
    box-shadow: 0 0 20px rgba(233, 69, 96, 0.6);
    animation: float 4s ease-in-out infinite;
}

.satellite-2 {
    width: 35px;
    height: 35px;
    background-color: var(--primary-color);
    bottom: 20%;
    right: 15%;
    box-shadow: 0 0 20px rgba(15, 52, 96, 0.5);
    animation: float 5s ease-in-out infinite 1s;
}

.satellite-3 {
    width: 18px;
    height: 18px;
    background-color: #F8B500;
    top: 50%;
    left: 85%;
    box-shadow: 0 0 15px rgba(248, 181, 0, 0.5);
    animation: float 6s ease-in-out infinite 2s;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes morph {
    0% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }

    50% {
        border-radius: 70% 30% 30% 70% / 70% 70% 30% 30%;
    }

    100% {
        border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    }
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

@keyframes glow {
    0% {
        box-shadow: 0 0 20px rgba(15, 52, 96, 0.3);
    }

    100% {
        box-shadow: 0 0 40px rgba(15, 52, 96, 0.8);
    }
}

/* Benefits */
.benefits {
    position: relative;
    overflow: hidden;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
    position: relative;
    z-index: 2;
}

.benefit-card {
    background-color: var(--card-bg);
    padding: 3rem;
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-smooth);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.benefit-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.benefit-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.benefit-card:hover::before {
    transform: scaleX(1);
}

.icon-wrapper {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(15, 52, 96, 0.1), rgba(233, 69, 96, 0.1));
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.benefit-card h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.benefit-card p {
    font-size: 1.1rem;
    line-height: 1.7;
}

/* Courses (Square Grid) */
.course-categories {
    display: flex;
    flex-direction: column;
    gap: 4.5rem;
}

.category-title {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.category-title::before {
    content: '';
    display: block;
    width: 8px;
    height: 24px;
    background-color: var(--accent-color);
    border-radius: 4px;
}

.course-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
}

.course-card {
    background-color: var(--card-bg);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    aspect-ratio: 1 / 1;
    padding: 1.5rem;
    gap: 1.25rem;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.course-card::after {
    content: '';
    position: absolute;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(233, 69, 96, 0.1) 0%, transparent 70%);
    top: -50px;
    right: -50px;
    border-radius: 50%;
    transition: transform 0.5s ease;
}

.course-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.course-card:hover::after {
    transform: scale(2);
}

.course-icon {
    font-size: 4rem;
    color: var(--primary-color);
    transition: transform 0.3s ease;
    z-index: 2;
}

.course-card:hover .course-icon {
    transform: scale(1.1);
    color: var(--accent-color);
}

.course-card h4 {
    font-size: 1.1rem;
    font-weight: 600;
    z-index: 2;
    line-height: 1.4;
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h2 {
    margin-bottom: 1.5rem;
    position: relative;
    display: inline-block;
}

.about-text h2::after {
    content: '';
    position: absolute;
    width: 40%;
    height: 3px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.15rem;
    line-height: 1.8;
}

.about-gallery {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 200px 200px;
    gap: 1.5rem;
}

.gallery-img {
    background-color: var(--border-color);
    border-radius: var(--radius-2xl);
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow-md);
    transition: transform 0.4s ease;
}

.gallery-img:hover {
    transform: scale(1.03);
    z-index: 10;
    position: relative;
}

.img-1 {
    grid-column: 1 / 2;
    grid-row: 1 / 3;
    background-image: linear-gradient(to bottom, rgba(15, 52, 96, 0.2), rgba(15, 52, 96, 0.6)), url('https://images.unsplash.com/photo-1517245386807-bb43f82c33c4?auto=format&fit=crop&q=80&w=800');
}

.img-2 {
    background-image: linear-gradient(to bottom, rgba(15, 52, 96, 0.1), rgba(15, 52, 96, 0.4)), url('https://images.unsplash.com/photo-1522202176988-66273c2fd55f?auto=format&fit=crop&q=80&w=800');
}

.img-3 {
    background-image: linear-gradient(to bottom, rgba(15, 52, 96, 0.1), rgba(15, 52, 96, 0.4)), url('https://images.unsplash.com/photo-1524178232363-1fb2b075b655?auto=format&fit=crop&q=80&w=800');
}

/* Reviews Slider */
.reviews {
    overflow: hidden;
}

.testimonial-slider-container {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
}

.testimonial-slider {
    flex: 1;
    display: flex;
    overflow: hidden;
    position: relative;
    min-height: 280px;
    padding: 10px;
}
.testimonial-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.5s ease;
    
    background-color: var(--card-bg);
    padding: 2.5rem;
    border-radius: var(--radius-2xl);
    border: 1px solid var(--border-color);
    text-align: center;
    box-shadow: var(--shadow-md);
}
.testimonial-slide.active {
    opacity: 1;
    transform: translateX(0);
    z-index: 2;
    
}

.slider-btn {
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.75rem;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-btn:hover,
.slider-btn:focus {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    outline: none;
    transform: scale(1.1);
}

.testimonial-slide .stars {
    color: #F8B500;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 0.25rem;
}

.review-text {
    font-size: 1.25rem;
    font-style: italic;
    margin-bottom: 1.5rem;
    line-height: 1.7;
    color: var(--text-main);
    text-align: center;
}

.reviewer-name {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Feedback Form */
.feedback-wrapper {
    display: flex;
    gap: 4rem;
    align-items: flex-start;
    background-color: var(--card-bg);
    padding: 4rem;
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.feedback-info {
    flex: 1;
    min-width: 300px;
}

.feedback-info h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.feedback-info p {
    font-size: 1.1rem;
    line-height: 1.8;
}

.feedback-form-container {
    flex: 1.2;
    min-width: 320px;
    width: 100%;
}

.form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-main);
}

input,
textarea {
    padding: 0.85rem 1.2rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: inherit;
    outline: none;
    transition: all var(--transition-fast);
    font-size: 1rem;
}

input:focus,
textarea:focus {
    border-color: var(--primary-color);
    background-color: var(--card-bg);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.star-rating {
    display: flex;
    gap: 0.5rem;
}

.star {
    font-size: 1.75rem;
    color: var(--border-color);
    cursor: pointer;
    transition: color 0.1s, transform 0.2s;
}

.star:hover,
.star.active {
    color: #F8B500;
    transform: scale(1.1);
}

/* WhatsApp Floating Icon */
.whatsapp-float {
    position: fixed;
    width: 65px;
    height: 65px;
    bottom: 30px;
    right: 30px;
    background-color: #25D366;
    color: #FFF;
    border-radius: 50%;
    text-align: center;
    font-size: 38px;
    box-shadow: 0px 5px 15px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.whatsapp-float:hover {
    transform: scale(1.15) rotate(5deg);
    color: #FFF;
    box-shadow: 0px 8px 25px rgba(37, 211, 102, 0.6);
}

.wa-tooltip {
    position: absolute;
    right: 80px;
    background-color: var(--card-bg);
    color: var(--text-main);
    padding: 10px 16px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    transform: translateX(10px);
    border: 1px solid var(--border-color);
}

.whatsapp-float:hover .wa-tooltip {
    opacity: 1;
    transform: translateX(0);
}

.pulse-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #25D366;
    animation: pulse 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    pointer-events: none;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.8);
        opacity: 0;
    }
}

/* Footer */
.footer {
    background-color: var(--secondary-blue);
    padding: 5rem 0 2rem;
    color: rgba(255, 255, 255, 0.8);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 3rem;
    flex-wrap: wrap;
    gap: 3rem;
}

.footer-brand .logo-text {
    color: #FFFFFF;
}

.footer-brand .logo-text span {
    color: var(--accent-color);
}

.footer-brand p {
    font-size: 1rem;
    margin-top: 1rem;
    color: rgba(255, 255, 255, 0.6);
    max-width: 300px;
}

.footer-links {
    display: flex;
    gap: 2.5rem;
}

.footer-links a {
    font-weight: 500;
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #FFFFFF;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
}

.contact-icon-card {
    background-color: var(--card-bg);
    color: var(--primary-color) !important;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    text-decoration: none;
}

.contact-icon-card:hover {
    background-color: var(--primary-color);
    color: #ffffff !important;
    transform: translateY(-2px);
}

.mail-card {
    background-color: var(--card-bg);
    color: var(--text-main) !important;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-xl);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow-sm);
    margin-top: 0.5rem;
    transition: all 0.3s ease;
    text-decoration: none;
    font-weight: 500;
}

.mail-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}


/* Admin UI adjustments */
.admin-body {
    background-color: var(--bg-secondary);
}

.admin-main-page {
    min-height: 80vh;
    padding: 3rem 0;
}

.admin-panel {
    background-color: var(--card-bg);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    overflow: hidden;
    margin-top: 2rem;
}

.panel-header {
    padding: 1.5rem 2.5rem;
    border-bottom: 1px solid var(--border-color);
    background-color: var(--bg-secondary);
}

.feedback-table-container {
    overflow-x: auto;
}

/* Mobile card view for admin feedback */
.admin-feedback-cards {
    display: none;
    padding: 0.5rem 1rem;
    box-sizing: border-box;
}

@media (max-width: 700px) {
    /* show mobile cards and hide table */
    .admin-feedback-cards { display: block !important; }
    .feedback-table { display: none !important; }
    .feedback-table-container { max-height: none; }
}

.admin-feedback-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
    border-radius: 12px;
    margin-bottom: 0.75rem;
    box-shadow: var(--shadow-sm);
}

/* Simple spinner */
.spinner {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 4px solid rgba(0,0,0,0.08);
    border-top-color: var(--primary-color);
    animation: spin 0.9s linear infinite;
    display: inline-block;
}

@keyframes spin { to { transform: rotate(360deg); } }

.admin-feedback-card .card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.admin-feedback-card .card-name { font-weight: 700; color: var(--primary-color); }
.admin-feedback-card .card-date { color: var(--text-muted); font-size: 0.9rem; }
.admin-feedback-card .card-body { color: var(--text-main); margin-bottom: 0.5rem; }
.admin-feedback-card .card-email a { color: var(--primary-color); }
.admin-feedback-card .card-message { margin-top: 0.5rem; }

/* Center file upload block in admin page */
#upload-achievement-form { margin: 0 auto; }
.file-upload-block { margin: 0 auto; }

/* Admin-specific header spacing and logo sizing */
.admin-body .logo-img.admin-logo-img { height: 36px; width: auto; }
.admin-main-page .section-container { padding-left: 2rem; padding-right: 2.5rem; }
.admin-header-actions { flex-shrink: 0; }

/* Admin brand: two-line layout (Teclipse / Education Hub) */
.admin-body .logo-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1;
    overflow: visible;
}
.admin-body .logo-text span {
    font-size: 0.75rem;
    color: var(--primary-color);
    margin-top: 2px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Header actions responsiveness: prevent clipping and allow wrapping on tight screens */
.admin-header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}
.admin-header-actions .btn {
    font-size: 0.92rem;
    padding: 0.5rem 0.9rem;
}

@media (max-width: 700px) {
    /* give admin header more breathing room and allow buttons to wrap */
    .admin-main-page .section-container { padding-left: 1rem; padding-right: 1rem; }
    .admin-header-actions { flex-wrap: wrap; justify-content: flex-end; gap: 0.45rem; }
    .admin-body .logo-text { font-size: 1.02rem; }
    .admin-body .logo-img.admin-logo-img { height: 28px; }
}

@media (max-width: 420px) {
    .admin-header-actions { width: 100%; justify-content: flex-end; }
    .admin-header-actions .btn { flex: 0 0 auto; }
}

/* Responsive admin header: stack buttons under title on very small screens */
@media (max-width: 540px) {
    .admin-header-row { flex-direction: column; align-items: flex-start; }
    .admin-header-row h2 { margin-bottom: 0.6rem; }
    .admin-header-actions { width: 100%; justify-content: flex-end; }
}

.feedback-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    text-align: left;
}

.feedback-table th,
.feedback-table td {
    padding: 1.25rem 2.5rem;
    border-bottom: 1px solid var(--border-color);
}

.feedback-table th {
    background-color: var(--bg-secondary);
    font-weight: 700;
    color: var(--text-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.feedback-table tr:hover td {
    background-color: var(--bg-secondary);
}

.btn-danger {
    background-color: var(--accent-color);
    color: white;
    border-radius: 0.5rem;
    padding: 0.6rem 1.2rem;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-danger:hover {
    background-color: #D63D56;
    transform: scale(1.05);
}

.empty-state {
    text-align: center;
    padding: 4rem;
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Mobile Adjustments (Max 768px) */
@media (max-width: 992px) {
    .hero-title {
        font-size: 3.5rem;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .feedback-wrapper {
        padding: 3rem;
    }
}

@media (max-width: 768px) {

    .nav-links,
    .btn-login {
        display: none;
    }

/* Admin header responsive controls: keep both buttons visible on small screens */
@media (max-width: 700px) {
    .back-to-website { display: inline-flex !important; }
    #change-pass-btn { display: inline-flex !important; }
}

/* make admin cards more spacious on small screens */
@media (max-width: 480px) {
    .admin-feedback-card {
        padding: 1rem;
        border-radius: 14px;
        font-size: 0.98rem;
    }
    .admin-feedback-card .card-message { margin-top: 0.75rem; }
}

    .mobile-menu-btn {
        display: flex;
    }

    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 8rem;
        justify-content: center;
    }

    .hero-content {
        padding-right: 0;
        margin-bottom: 3rem;
    }

    .hero-title {
        font-size: 3rem;
    }

    .hero-subtitle {
        margin: 0 auto 2rem;
    }

    .hero-btns {
        justify-content: center;
        flex-wrap: wrap;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .feedback-wrapper {
        padding: 2rem;
        gap: 2rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }

    .section-container {
        padding: 0 1.5rem;
    }
}

/* Small Screens Mobile (Max 480px) */
@media (max-width: 480px) {
    section {
        padding: 4rem 0;
    }

    .course-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .course-card {
        padding: 1rem;
        gap: 0.75rem;
        border-radius: 1rem;
    }

    .course-icon {
        font-size: 3rem;
    }

    .course-card h4 {
        font-size: 0.95rem;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .about-gallery {
        grid-template-rows: 150px 150px;
    }

    .benefit-card {
        padding: 1.5rem;
    }

    .testimonial-slide {
        padding: 2rem 1.5rem;
    }

    .review-text {
        font-size: 1.05rem;
    }

    .logo-img {
        height: 40px;
    }

    .logo-text {
        font-size: 1.2rem;
    }

    .logo-text span {
        font-size: 0.65rem;
    }

    .footer-brand .logo-text span {
        color: var(--primary-color);
    }

    .footer-content {
        flex-direction: column !important;
        text-align: center !important;
        gap: 2rem !important;
    }

    .footer-founders {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .footer-founders p {
        text-align: center;
    }

    .founder-entry {
        justify-content: center !important;
    }

    .footer-brand .logo {
        justify-content: center;
    }

    .footer-brand p {
        margin-left: auto;
        margin-right: auto;
    }

    .footer-founders div {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }

    .footer-links {
        display: flex;
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 15px;
    }

    .logo-text {
        font-size: 1.5rem;
        align-items: center;
        text-align: center;
    }

    #achievements-gallery {
        grid-template-columns: 1fr;
    }

    .nav-actions {
        display: flex;
    }

    .btn-login {
        display: none;
    }

    .admin-main-page {
        padding: 5px;
    }

    .form {
        width: 100%;
    }

    .modal-content {
        padding: 1.5rem;
        width: 95%;
    }

    .section-container {
        padding: 0 1rem;
    }

    .hero {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* --- Admin Panel Input Styling --- */
input[type="file"] {
    background: var(--card-bg) !important;
    border: 1px dashed var(--border-color) !important;
    border-radius: var(--radius-sm) !important;
    padding: 0.75rem !important;
}

input[type="file"]::file-selector-button {
    background-color: var(--primary-color) !important;
    color: #fff !important;
    padding: 0.5rem 1.25rem;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    margin-right: 1.5rem;
    transition: background-color 0.3s ease;
    font-size: 0.9rem;
}

input[type="file"]::file-selector-button:hover {
    background-color: var(--accent-color) !important;
}

/* Responsive fixes for small screens: prevent overlap, remove forced min-widths, and avoid zooming */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .logo-img {
        height: 40px;
    }

    .logo-text {
        font-size: 1rem;
        line-height: 1;
    }

    .logo-text span {
        font-size: 0.65rem;
        margin-top: 2px;
        display: block;
    }

    .nav-container {
        padding: 0.6rem 1rem;
    }

    .section-container {
        padding: 0 1rem;
    }

    /* Make hero stack on small screens */
    .hero {
        flex-direction: column;
        padding-top: 5rem;
    }

    .hero-content {
        padding-right: 0;
    }

    .abstract-tech {
        width: 260px;
        height: 260px;
    }

    /* Admin feedback table responsiveness: allow horizontal scroll and wrap cells */
    .feedback-table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .feedback-table {
        width: 100% !important;
        min-width: 0 !important;
        table-layout: fixed;
    }

    .feedback-table th,
    .feedback-table td {
        white-space: normal;
        word-wrap: break-word;
        max-width: 180px;
        padding: 0.5rem 0.75rem;
        vertical-align: top;
    }

    .feedback-table th:last-child,
    .feedback-table td:last-child {
        text-align: right;
    }

    /* File upload and form controls should be full width to avoid overlap */
    .file-upload-block {
        width: 100%;
        box-sizing: border-box;
        padding: 1.25rem;
    }

    .form .input-group label {
        display: block;
        margin-bottom: 0.35rem;
        font-size: 0.95rem;
    }

    .form input,
    .form textarea,
    .form select {
        width: 100%;
    }

    /* Prevent images and tables from forcing zoom/overflow */
    img,
    table {
        max-width: 100%;
        height: auto;
    }

    /* Make mobile sidebar occupy more of the screen */
    .mobile-sidebar {
        width: 85%;
    }
}

@media (max-width: 420px) {
    /* Keep the small secondary logo text visible (stacked) */
    .logo-text span {
        display: block;
        font-size: 0.65rem;
        color: var(--primary-color);
        text-transform: none;
        margin-top: 2px;
        line-height: 1;
    }

    .logo-text {
        font-size: 0.95rem;
        flex-direction: column;
        align-items: flex-start;
    }

    .logo-img {
        height: 36px;
    }
}

/* Extra small screens: stack feedback and reduce padding to avoid overlap */
@media (max-width: 480px) {
    .feedback-wrapper {
        flex-direction: column;
        gap: 1.25rem;
        padding: 1.5rem;
        border-radius: 12px;
    }

    .feedback-info {
        min-width: 0;
        order: 1;
        padding-bottom: 0.5rem;
    }

    .feedback-info h2 {
        font-size: 1.5rem;
    }

    .feedback-form-container {
        min-width: 0;
        order: 2;
        width: 100%;
    }

    /* Reserve space at bottom so floating action doesn't cover inputs */
    .feedback-form-container {
        padding-bottom: 120px;
        box-sizing: border-box;
    }

    .input-group label {
        font-size: 0.9rem;
    }

    input,
    textarea {
        font-size: 0.95rem;
        padding: 0.75rem 0.9rem;
    }

    .btn {
        font-size: 0.95rem;
        padding: 0.7rem 1rem;
    }

    /* Move WhatsApp float slightly up and smaller to avoid covering inputs */
    .whatsapp-float {
        width: 54px;
        height: 54px;
        bottom: 24px; /* keep it visually stable and near bottom-right */
        right: 16px;
        font-size: 32px;
    }

    .wa-tooltip {
        display: none;
    }

    .pulse-ring {
        display: none;
    }
    /* For very narrow screens, keep WhatsApp visible but above inputs */
    @media (max-width: 380px) {
        .whatsapp-float { bottom: 110px; right: 12px; }
    }
}

/* Admin page: make feedback table responsive on small screens and center file-upload */
@media (max-width: 768px) {
    .feedback-table {
        min-width: 0;
        width: 100%;
        table-layout: fixed;
    }

    .feedback-table th,
    .feedback-table td {
        word-break: break-word;
        white-space: normal;
    }

    .file-upload-block {
        margin: 0 auto;
        max-width: 520px;
        display: block;
    }
}

/* Center file upload on large screens too */
.file-upload-block {
    margin: 0 auto;
    max-width: 700px;
}
