/* Main Styles for Internship Management System */

:root {
    --primary-color: #28a745;
    --primary-dark: #218838;
    --primary-light: #48c774;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --info-color: #17a2b8;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --body-bg: #f5f5f5;
    --sidebar-bg: #343a40;
    --sidebar-active: #28a745;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--body-bg);
    color: #333;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 48px 0 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
    background-color: var(--sidebar-bg);
}

.sidebar-sticky {
    position: relative;
    top: 0;
    height: calc(100vh - 48px);
    padding-top: .5rem;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar .nav-link {
    font-weight: 500;
    color: rgba(255, 255, 255, .75);
    padding: .75rem 1rem;
    border-left: 3px solid transparent;
}

.sidebar .nav-link:hover {
    color: #fff;
    background-color: rgba(40, 167, 69, 0.1);
    border-left: 3px solid rgba(40, 167, 69, 0.5);
}

.sidebar .nav-link.active {
    color: #fff;
    background-color: rgba(40, 167, 69, 0.2);
    border-left: 3px solid var(--sidebar-active);
}

.sidebar .nav-link .feather {
    margin-right: 4px;
    color: #999;
}

.sidebar .nav-link.active .feather {
    color: inherit;
}

.sidebar-heading {
    font-size: .75rem;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .5);
    padding: 1rem;
}

/* Navbar Styles */
.navbar-brand {
    padding-top: .75rem;
    padding-bottom: .75rem;
    font-size: 1rem;
    background-color: var(--primary-color);
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .25);
}

.navbar .navbar-toggler {
    top: .25rem;
    right: 1rem;
}

.navbar .form-control {
    padding: .75rem 1rem;
    border-width: 0;
    border-radius: 0;
}

/* Card Styles */
.card {
    border-radius: 0.5rem;
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: rgba(40, 167, 69, 0.05);
    border-bottom: 1px solid rgba(40, 167, 69, 0.1);
    padding: 1rem;
}

/* Button Styles */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Badge Styles */
.badge-primary {
    background-color: var(--primary-color);
}

/* Form Styles */
.form-control:focus {
    border-color: var(--primary-light);
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

/* Table Styles */
.table th {
    border-top: none;
    border-bottom: 2px solid var(--primary-light);
}

/* Custom Styles */
.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

.border-primary {
    border-color: var(--primary-color) !important;
}

/* Mobile Responsiveness */
@media (max-width: 767.98px) {
    .sidebar {
        position: static;
        height: auto;
        padding-bottom: 1rem;
    }
    
    .sidebar-sticky {
        height: auto;
    }
    
    main {
        padding-top: 1rem !important;
    }
    
    .card {
        margin-bottom: 1rem;
    }
    
    .table-responsive {
        margin-bottom: 1rem;
    }
}

/* Time In/Out Buttons */
.btn-time-in {
    background-color: var(--success-color);
    border-color: var(--success-color);
    color: white;
    font-weight: bold;
    padding: 1rem 2rem;
    transition: all 0.3s ease;
}

.btn-time-in:hover {
    background-color: #218838;
    border-color: #1e7e34;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.btn-time-out {
    background-color: var(--danger-color);
    border-color: var(--danger-color);
    color: white;
    font-weight: bold;
    padding: 1rem 2rem;
    transition: all 0.3s ease;
}

.btn-time-out:hover {
    background-color: #c82333;
    border-color: #bd2130;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Status Badges */
.badge {
    padding: 0.5em 0.75em;
    font-weight: 500;
}

/* Login/Signup Forms */
.auth-form {
    max-width: 400px;
    margin: 0 auto;
}

/* Map Container */
.map-container {
    height: 300px;
    border-radius: 0.5rem;
    overflow: hidden;
    margin-bottom: 1rem;
}

/* Profile Image */
.profile-image {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
}

/* Chat Styles */
.chat-container {
    height: 400px;
    overflow-y: auto;
}

.chat-message {
    padding: 0.75rem;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    max-width: 80%;
}

.chat-message-sent {
    background-color: var(--primary-light);
    color: white;
    margin-left: auto;
}

.chat-message-received {
    background-color: #f1f1f1;
    margin-right: auto;
}

/* Dashboard Stats */
.stat-card {
    border-left: 4px solid var(--primary-color);
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Animations */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Print Styles */
@media print {
    .sidebar, .navbar, .btn, .no-print {
        display: none !important;
    }
    
    body {
        padding: 0;
        background-color: white;
    }
    
    .container-fluid {
        padding: 0;
    }
    
    main {
        padding: 0 !important;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}