/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Top Header */
.top-header {
    background: #1a1a1a;
    color: white;
    padding: 10px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.student-login-btn {
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    background: #ff9800;
    border-radius: 5px;
    transition: background 0.3s;
    display: inline-block;
    border: 1px solid #ff9800;
}

.student-login-btn:hover {
    background: #ff8c00;
    border-color: #ff8c00;
}

.college-logo {
    height: 60px !important;
    width: auto;
    max-width: 120px;
    object-fit: contain;
    border-radius: 5px;
}

.college-info {
    flex: 1;
}

.college-name {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 3px;
}

.college-address {
    font-size: 14px;
    opacity: 0.9;
}

/* Navigation */
.main-nav {
    background-color: #2a5298;
    padding: 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: relative;
}

.main-nav .container {
    position: relative;
    min-height: 50px;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 5px;
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1001;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-toggle:focus {
    outline: 2px solid rgba(255,255,255,0.5);
    outline-offset: 2px;
}

.mobile-menu-toggle span {
    width: 100%;
    height: 3px;
    background-color: white;
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
    pointer-events: none;
    display: block;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.nav-menu {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin: 0;
    padding: 0;
    transition: max-height 0.3s ease;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    display: block;
    color: white;
    text-decoration: none;
    padding: 15px 20px;
    transition: background-color 0.3s;
}

.nav-menu a:hover {
    background-color: #1e3c72;
}

.nav-menu a i {
    margin-right: 5px;
}

/* Hero Section */
.hero-section {
    position: relative;
    width: 100%;
    min-height: 500px;
    background-image: url('../../images/slider-img.jpg');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.8) 0%, rgba(42, 82, 152, 0.8) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 80px 20px;
    text-align: center;
    color: white;
}

.hero-title {
    font-size: 48px;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease-out;
}

.hero-subtitle {
    font-size: 24px;
    margin-bottom: 30px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease-out 0.2s backwards;
}

.hero-btn {
    display: inline-block;
    padding: 15px 40px;
    background: white;
    color: #1e3c72;
    text-decoration: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 1s ease-out 0.4s backwards;
}

.hero-btn:hover {
    background: #ff9800;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Companies/Partners Scrolling Section */
.companies-scroll-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    margin-top: 30px;
    padding: 30px 0;
    background: #f5f5f5;
    border-radius: 8px;
}

.companies-scroll-wrapper {
    width: 100%;
    overflow: hidden;
    position: relative;
}

.companies-scroll {
    display: flex;
    align-items: center;
    gap: 30px;
    animation: scrollCompanies 30s linear infinite;
    width: max-content;
    flex-wrap: nowrap;
    white-space: nowrap;
    will-change: transform;
}

.companies-scroll:hover {
    animation-play-state: paused;
}

.company-logo-item {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-width: 180px;
    max-width: 220px;
    height: 110px;
    border: 1px solid rgba(0,0,0,0.05);
}

.company-logo-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.12);
}

.company-logo {
    max-width: 160px;
    max-height: 70px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: filter 0.3s ease, transform 0.3s ease;
    display: block;
}

.company-logo-item:hover .company-logo {
    transform: scale(1.05);
}

@keyframes scrollCompanies {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Main Content */
.main-content {
    min-height: 500px;
    padding: 40px 0;
    background-color: white;
}

.page-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 3px solid #2a5298;
}

.page-header h1 {
    color: #1e3c72;
    font-size: 36px;
    margin-bottom: 10px;
}

/* Cards */
.card {
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.card h2 {
    color: #2a5298;
    margin-bottom: 20px;
    font-size: 28px;
}

.card h3 {
    color: #1e3c72;
    margin-top: 20px;
    margin-bottom: 15px;
    font-size: 22px;
}

/* Grid Layouts */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.grid-item {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.grid-item:hover {
    transform: translateY(-5px);
}

/* Message Cards */
.message-card {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.message-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #2a5298;
}

.message-content h3 {
    color: #1e3c72;
    margin-bottom: 10px;
}

.message-content p {
    color: #666;
    line-height: 1.8;
}

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.3s;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

/* Staff Cards */
.staff-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.staff-card {
    text-align: center;
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.staff-photo {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #2a5298;
    margin-bottom: 15px;
}

.staff-card h3 {
    color: #1e3c72;
    margin-bottom: 10px;
}

.staff-card p {
    color: #666;
    margin-bottom: 5px;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    font-family: inherit;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: #2a5298;
    color: white;
    text-decoration: none;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #1e3c72;
}

.btn-success {
    background-color: #28a745;
}

.btn-success:hover {
    background-color: #218838;
}

.btn-danger {
    background-color: #dc3545;
}

.btn-danger:hover {
    background-color: #c82333;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
}

table th,
table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

table th {
    background-color: #2a5298;
    color: white;
    font-weight: 600;
}

table tr:hover {
    background-color: #f5f5f5;
}

/* Footer */
.footer {
    background-color: #1e3c72;
    color: white;
    padding: 40px 0 20px;
    margin-top: 50px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h3 {
    margin-bottom: 15px;
    font-size: 20px;
}

.footer-section p {
    margin-bottom: 10px;
    opacity: 0.9;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 8px;
}

.footer-section a {
    color: white;
    text-decoration: none;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.footer-section a:hover {
    opacity: 1;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    font-size: 24px;
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.2);
    opacity: 0.9;
}

/* Admin Panel Styles */
/* Top Menubar */
.admin-topbar {
    background-color: #1e3c72;
    color: white;
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    z-index: 1001;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.admin-topbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 20px;
    max-width: 100%;
}

.admin-topbar-left {
    display: flex;
    align-items: center;
}

.admin-topbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.topbar-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s;
    font-size: 14px;
    background-color: transparent;
    border: 1px solid transparent;
}

.topbar-btn:hover {
    background-color: #2a5298;
    border-color: rgba(255,255,255,0.2);
}

.topbar-btn.active {
    background-color: #2a5298;
    border-color: #ff9800;
}

.topbar-btn i {
    font-size: 16px;
}

.topbar-btn span {
    font-size: 14px;
}

@media (max-width: 768px) {
    .topbar-btn span {
        display: none;
    }
    .topbar-btn {
        padding: 8px 12px;
    }
}

.admin-sidebar {
    background-color: #1e3c72;
    height: calc(100vh - 60px);
    width: 250px;
    position: fixed;
    left: 0;
    top: 60px;
    padding-top: 0;
    z-index: 1000;
    overflow-y: auto;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

.admin-sidebar ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.admin-sidebar ul li {
    margin: 0;
}

.admin-sidebar ul li a {
    display: block;
    color: white;
    padding: 15px 20px;
    text-decoration: none;
    transition: background-color 0.3s;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.admin-sidebar ul li a:hover {
    background-color: #2a5298;
}

.admin-sidebar ul li a.active {
    background-color: #2a5298;
    border-left: 4px solid #ff9800;
}

.admin-content {
    margin-left: 250px;
    margin-top: 60px;
    padding: 20px;
    min-height: calc(100vh - 60px);
}

/* Login Pages */
.login-container {
    max-width: 400px;
    margin: 100px auto;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.login-container h2 {
    text-align: center;
    color: #1e3c72;
    margin-bottom: 30px;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive */
@media (max-width: 1200px) {
    .grid[style*="grid-template-columns: repeat(4, 1fr)"] {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 768px) {
    /* Hero Section Mobile */
    .hero-section {
        min-height: 400px;
        background-attachment: scroll; /* Remove fixed on mobile for better performance */
    }
    
    .hero-content {
        padding: 60px 20px;
    }
    
    .hero-title {
        font-size: 32px;
        margin-bottom: 15px;
    }
    
    .hero-subtitle {
        font-size: 18px;
        margin-bottom: 25px;
    }
    
    .hero-btn {
        padding: 12px 30px;
        font-size: 16px;
    }
    
    .main-nav .container {
        padding-right: 70px; /* Add space for toggle button */
    }
    
    .mobile-menu-toggle {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    .nav-menu {
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        width: 100%;
        position: absolute;
        top: 100%;
        left: 0;
        background-color: #2a5298;
        box-shadow: 0 5px 10px rgba(0,0,0,0.2);
        z-index: 1000;
        transition: max-height 0.4s ease-in-out, opacity 0.3s ease;
        opacity: 0;
    }
    
    .nav-menu.active {
        max-height: 800px;
        overflow-y: auto;
        opacity: 1;
    }
    
    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-menu li:last-child {
        border-bottom: none;
    }
    
    .nav-menu a {
        padding: 15px 20px;
        width: 100%;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .header-content > div:first-child {
        width: 100%;
        justify-content: center;
    }
    
    .header-content > div:last-child {
        width: 100%;
        text-align: center;
    }
    
    .student-login-btn {
        width: 100%;
        max-width: 200px;
    }
    
    /* Companies Section Mobile */
    .companies-scroll-container {
        padding: 20px 0;
        min-height: 100px;
    }
    
    .companies-scroll {
        gap: 20px;
        animation: scrollCompanies 25s linear infinite;
    }
    
    .company-logo-item {
        padding: 15px 20px;
        min-width: 140px;
        max-width: 170px;
        height: 90px;
    }
    
    .company-logo {
        max-width: 130px;
        max-height: 60px;
        width: auto;
        height: auto;
    }
    
    .admin-topbar {
        height: auto;
        min-height: 60px;
        padding: 5px 0;
    }
    
    .admin-topbar-content {
        flex-direction: column;
        gap: 8px;
        padding: 10px;
        height: auto;
    }
    
    .admin-topbar-left h2 {
        font-size: 16px !important;
    }
    
    .admin-topbar-right {
        flex-wrap: wrap;
        justify-content: center;
        width: 100%;
        gap: 5px;
    }
    
    .topbar-btn {
        padding: 6px 10px;
        font-size: 12px;
    }
    
    .topbar-btn i {
        font-size: 14px;
    }
    
    .admin-sidebar {
        width: 100%;
        position: relative;
        min-height: auto;
        height: auto;
        top: 0;
    }
    
    .admin-content {
        margin-left: 0;
        margin-top: 0;
        padding: 15px;
    }
    
    .grid[style*="grid-template-columns: repeat(4, 1fr)"] {
        grid-template-columns: 1fr !important;
    }
    
    .message-card {
        flex-direction: column;
        text-align: center;
    }
    
    .message-photo {
        margin: 0 auto;
    }
}
