/* MINIMAL CORPORATE DESIGN */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #ffffff;
    --bg-alt: #f5f5f5;
    --text: #1a1a1a;
    --text-light: #666666;
    --text-lighter: #999999;
    --border: #e0e0e0;
    --accent: #1a1a1a;
}

html, body {
    width: 100%;
    height: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

/* PAGE LOGIN */

.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 20px;
    background: linear-gradient(135deg, #ffffff 0%, #f5f5f5 100%);
}

.login-box {
    width: 100%;
    max-width: 100%;
    padding: 60px;
}

.login-logo {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo img {
    display: inline-block;
    opacity: 0.9;
}

.login-box h1 {
    text-align: center;
    color: var(--accent);
    margin-bottom: 30px;
    font-size: 48px;
    font-weight: 300;
    letter-spacing: -1px;
}

.subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 60px;
    font-size: 14px;
    font-weight: 400;
}

.warning-box {
    max-width: 500px;
    margin: -30px auto 60px !important;
    padding: 14px 16px !important;
    background: #fff5f5;
    color: #c00;
    border: 1px solid #f0b0b0;
    border-left: 4px solid #c00;
    font-size: 13px !important;
    text-align: center !important;
}

.form-group {
    margin-bottom: 30px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    color: var(--text);
    font-weight: 500;
    font-size: 13px;
    letter-spacing: 0.5px;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.05);
}

.btn-login {
    width: 100%;
    max-width: 500px;
    margin: 30px auto 0;
    display: block;
    padding: 14px;
    background: var(--accent);
    color: white;
    border: 1px solid var(--accent);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.btn-login:hover {
    background: rgba(26, 26, 26, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-login:active {
    transform: scale(0.98);
}

.error-message {
    max-width: 500px;
    margin: 25px auto 0;
    padding: 14px 16px;
    background: #fee;
    color: #c00;
    border: 1px solid #f0b0b0;
    border-left: 4px solid #c00;
    display: none;
    font-size: 13px;
    text-align: center;
}

.error-message.show {
    display: block;
    animation: slideIn 0.3s ease;
}

.success-message {
    max-width: 500px;
    margin: 25px auto 0;
    padding: 14px 16px;
    background: #efe;
    color: #060;
    border: 1px solid #b0f0b0;
    border-left: 4px solid #060;
    display: none;
    font-size: 13px;
    text-align: center;
}

.success-message.show {
    display: block;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* NAVBAR */

.navbar {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    user-select: none;
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 15px;
}

.navbar-logo {
    opacity: 0.85;
}

.navbar-title {
    color: var(--accent);
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.navbar-menu {
    display: flex;
    gap: 30px;
    align-items: center;
    justify-content: flex-end;
}

.navbar-profile-container {
    position: relative;
}

.navbar-profile {
    color: var(--text);
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    padding: 8px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-avatar {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.navbar-username {
    display: inline-block;
}

.navbar-profile:hover {
    background: var(--bg-alt);
    border-color: var(--accent);
    color: var(--accent);
}

.profile-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 3px;
    min-width: 160px;
    margin-top: 6px;
    display: none;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.profile-menu.active {
    display: block;
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.profile-menu-item {
    display: block;
    width: 100%;
    padding: 10px 14px;
    color: var(--text);
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    background: none;
    cursor: pointer;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.profile-menu-item:last-child {
    border-bottom: none;
}

.profile-menu-item:hover {
    background: var(--bg-alt);
    color: var(--accent);
}

.nav-link {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 13px;
    border-bottom: 2px solid transparent;
}

.nav-link:hover {
    color: var(--accent);
}

.nav-link.active {
    color: var(--accent);
    border-bottom: 2px solid var(--accent);
}

.btn-logout {
    background: var(--bg);
    color: var(--text);
    border: 1px solid var(--border);
    padding: 10px 18px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-logout:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.btn-support {
    background: var(--accent);
    color: white;
    border: 1px solid var(--accent);
    padding: 8px 16px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 3px;
}

.btn-support:hover {
    background: rgba(26, 26, 26, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* TICKET FORM */

.ticket-form-container {
    max-width: 600px;
    margin: 0 auto;
}

.ticket-form {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 40px;
    border-radius: 4px;
}

.ticket-form .form-group {
    margin-bottom: 25px;
    max-width: none;
    margin-left: 0;
    margin-right: 0;
}

.ticket-form label {
    display: block;
    margin-bottom: 10px;
    color: var(--text);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.5px;
}

.ticket-form input,
.ticket-form select,
.ticket-form textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
    border-radius: 3px;
}

.ticket-form input:focus,
.ticket-form select:focus,
.ticket-form textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.05);
}

.ticket-form textarea {
    resize: vertical;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.btn-submit {
    flex: 1;
    padding: 12px 24px;
    background: var(--accent);
    color: white;
    border: 1px solid var(--accent);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border-radius: 3px;
}

.btn-submit:hover {
    background: rgba(26, 26, 26, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-submit:active {
    transform: scale(0.98);
}

.btn-cancel {
    flex: 1;
    padding: 12px 24px;
    background: var(--bg);
    color: var(--text);
    border: 1px solid var(--border);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border-radius: 3px;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-cancel:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* MAIN CONTENT */

.main-content {
    background: var(--bg);
    min-height: calc(100vh - 80px);
    padding: 50px 40px;
}

.section {
    max-width: 1400px;
    margin: 0 auto;
    display: none;
    animation: fadeIn 0.3s ease;
}

.section.active {
    display: block;
}

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

.section-header {
    margin-bottom: 50px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.section-header h2 {
    font-size: 36px;
    color: var(--accent);
    margin-bottom: 8px;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.section-header p {
    color: var(--text-light);
    font-size: 13px;
}

/* DASHBOARD */

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.dashboard-card {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 30px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.dashboard-card:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.dashboard-card h3 {
    font-size: 16px;
    color: var(--accent);
    margin-bottom: 12px;
    font-weight: 600;
}

.dashboard-card p {
    color: var(--text-light);
    font-size: 13px;
}

/* DOCUMENTS */

.documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 30px;
}

.document-item {
    background: var(--bg);
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s ease;
}

.document-item:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateX(4px);
}

.doc-icon {
    font-size: 32px;
    min-width: 40px;
}

.doc-info {
    flex: 1;
}

.doc-info h3 {
    font-size: 15px;
    color: var(--accent);
    margin-bottom: 4px;
    font-weight: 600;
}

.doc-info p {
    color: var(--text-lighter);
    font-size: 12px;
}

.btn-download {
    background: var(--accent);
    color: white;
    padding: 8px 16px;
    border: 1px solid var(--accent);
    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    white-space: nowrap;
}

.btn-download:hover {
    background: rgba(26, 26, 26, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ANNONCES */

.announcements-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 30px;
}

.announcement-item {
    background: var(--bg);
    border: 1px solid var(--border);
    border-left: 4px solid var(--accent);
    padding: 25px;
    display: flex;
    gap: 25px;
    transition: all 0.3s ease;
}

.announcement-item:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.announcement-date {
    background: var(--bg-alt);
    color: var(--accent);
    padding: 12px 16px;
    border: 1px solid var(--border);
    font-size: 11px;
    font-weight: 600;
    text-align: center;
    min-width: 90px;
    height: fit-content;
}

.announcement-content h3 {
    font-size: 15px;
    color: var(--accent);
    margin-bottom: 10px;
    font-weight: 600;
}

.announcement-content p {
    color: var(--text-light);
    font-size: 13px;
    line-height: 1.6;
}

/* TEAM */

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.team-card {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 30px 25px;
    text-align: center;
    transition: all 0.3s ease;
}

.team-card:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.team-avatar {
    font-size: 48px;
    margin-bottom: 15px;
}

.team-card h3 {
    font-size: 15px;
    color: var(--accent);
    margin-bottom: 8px;
    font-weight: 600;
}

.team-card p {
    color: var(--text-light);
    font-size: 12px;
}

/* FOOTER */

.footer {
    background: var(--bg-alt);
    color: var(--text-light);
    text-align: center;
    padding: 30px;
    margin-top: 60px;
    font-size: 12px;
    border-top: 1px solid var(--border);
}

.footer-logo {
    display: block;
    margin: 0 auto 15px;
    opacity: 0.7;
}

.footer p {
    margin: 0;
}

/* RESPONSIVE */

@media (max-width: 768px) {
    .navbar-container {
        flex-direction: column;
        gap: 15px;
        padding: 15px 20px;
    }

    .navbar-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 20px;
        width: 100%;
    }

    .main-content {
        padding: 30px 20px;
    }

    .login-box {
        padding: 40px 20px;
    }

    .section-header h2 {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .document-item,
    .announcement-item {
        flex-direction: column;
    }

    .announcement-date {
        min-width: 100%;
    }

    .login-box {
        padding: 30px 20px;
    }

    .login-box h1 {
        font-size: 32px;
    }
}

/* HR DEPARTMENT MODAL */

.hr-details-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    overflow-y: auto;
    padding: 20px;
}

.hr-modal-content {
    max-width: 900px;
    margin: 40px auto;
    background: var(--bg);
    border-radius: 4px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.hr-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-alt);
}

.hr-modal-header h2 {
    font-size: 24px;
    color: var(--text);
}

.btn-close-modal {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.btn-close-modal:hover {
    color: var(--text);
}

.employees-list {
    padding: 30px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.employee-card {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: var(--bg);
    transition: all 0.3s ease;
}

.employee-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.employee-avatar {
    font-size: 32px;
    flex-shrink: 0;
}

.employee-info {
    flex: 1;
}

.employee-info h3 {
    font-size: 16px;
    margin-bottom: 5px;
    color: var(--text);
}

.employee-role {
    font-size: 12px;
    color: var(--text-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.employee-email {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 4px;
}

.employee-phone {
    font-size: 13px;
    color: var(--text-light);
}

@media (max-width: 768px) {
    .hr-details-modal {
        padding: 10px;
    }

    .hr-modal-content {
        margin: 20px auto;
    }

    .hr-modal-header {
        padding: 20px;
    }

    .hr-modal-header h2 {
        font-size: 20px;
    }

    .employees-list {
        padding: 20px;
        grid-template-columns: 1fr;
    }
}

/* STATISTICS DASHBOARD */

.stats-container {
    margin-top: 15px;
    padding: 15px;
    background: var(--bg-alt);
    border-radius: 4px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    text-align: center;
}

.stat-label {
    font-size: 11px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 20px;
    font-weight: 600;
    color: var(--text);
}

.stat-divider {
    grid-column: 1 / -1;
    height: 1px;
    background: var(--border);
    margin: 10px 0;
}

.departments-chart {
    grid-column: 1 / -1;
    padding-top: 15px;
}

.departments-chart h4 {
    margin: 0 0 12px 0;
    font-size: 13px;
    color: var(--text);
    font-weight: 600;
}

.department-bars {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dept-bar-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
}

.dept-bar-item label {
    width: 80px;
    color: var(--text-light);
    font-weight: 500;
}

.dept-bar-bg {
    flex: 1;
    height: 20px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
}

.dept-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #1a1a1a 0%, #4a4a4a 100%);
    transition: width 0.3s ease;
}

.dept-count {
    width: 45px;
    text-align: right;
    color: var(--text);
    font-weight: 600;
}

/* ANNOUNCEMENTS */

.announcement-item {
    display: flex;
    gap: 15px;
    padding: 15px;
    border: 1px solid var(--border);
    border-radius: 4px;
    margin-bottom: 10px;
    background: var(--bg);
    transition: all 0.2s ease;
    position: relative;
}

.announcement-item:hover {
    border-color: var(--text-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.announcement-item.priority-high {
    border-left: 4px solid #dc3545;
    background: rgba(220, 53, 69, 0.02);
}

.announcement-date {
    font-size: 11px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 100px;
    font-weight: 600;
}

.announcement-content {
    flex: 1;
}

.announcement-content h3 {
    margin: 0 0 6px 0;
    font-size: 15px;
    color: var(--text);
    font-weight: 600;
}

.announcement-content p {
    margin: 0;
    font-size: 13px;
    color: var(--text-light);
    line-height: 1.5;
}

.priority-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #dc3545;
    color: white;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.locations-container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 20px;
    height: calc(100vh - 300px);
    min-height: 600px;
}

.map-container {
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
    background: #ffffff;
    height: auto;
    aspect-ratio: 16 / 9;
}

.world-map-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.world-map-svg {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    filter: brightness(0) saturate(100%) invert(90%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(95%) contrast(90%);
}

.map-markers {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.map-marker {
    position: absolute;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transform: translate(-50%, -50%);
    cursor: pointer;
    pointer-events: auto;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.map-marker:hover {
    transform: translate(-50%, -50%) scale(1.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.map-marker.clicked {
    animation: clickPop 0.3s ease-out;
}

@keyframes clickPop {
    0% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.8); }
    100% { transform: translate(-50%, -50%) scale(1); }
}

.map-marker.headquarters {
    animation: pulse 2s infinite;
}

.map-marker.headquarters.clicked {
    animation: clickPop 0.3s ease-out;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.5); }
    70% { box-shadow: 0 0 0 10px rgba(220, 53, 69, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0); }
}

.location-popup-box {
    position: absolute;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 100;
    width: 280px;
    animation: popupFadeIn 0.2s ease-out;
}

@keyframes popupFadeIn {
    0% { opacity: 0; transform: scale(0.9); }
    100% { opacity: 1; transform: scale(1); }
}

.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-alt);
}

.popup-header h3 {
    margin: 0;
    font-size: 16px;
    color: var(--text);
}

.popup-close {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.popup-close:hover {
    color: var(--text);
}

.popup-body {
    padding: 15px;
    font-size: 13px;
    color: var(--text-light);
}

.popup-body p {
    margin: 6px 0;
}

.popup-type {
    font-weight: 600;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 11px;
}

.locations-sidebar {
    border: 1px solid var(--border);
    border-radius: 4px;
    background: var(--bg-alt);
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.locations-sidebar h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: var(--text);
}

.locations-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.location-card {
    padding: 15px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.location-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateX(4px);
}

.location-card.headquarters {
    border-left: 4px solid #dc3545;
    background: #fff5f5;
}

.location-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
    gap: 10px;
}

.location-card-header h4 {
    margin: 0;
    font-size: 14px;
    color: var(--text);
}

.location-type {
    display: inline-block;
    padding: 3px 8px;
    background: var(--accent);
    color: white;
    font-size: 10px;
    font-weight: 600;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.location-card-body {
    font-size: 12px;
    color: var(--text-light);
    line-height: 1.6;
}

.location-card-body p {
    margin: 5px 0;
}

.location-popup {
    font-size: 12px;
    max-width: 200px;
}

.location-popup h3 {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: var(--text);
}

.location-popup p {
    margin: 4px 0;
    color: var(--text-light);
}

.btn-google-maps {
    display: inline-block;
    margin-top: 10px;
    padding: 8px 12px;
    background: #1a1a1a;
    color: white;
    text-decoration: none;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.btn-google-maps:hover {
    background: #333;
}

.leaflet-container {
    background: #ffffff;
}

@media (max-width: 1024px) {
    .locations-container {
        grid-template-columns: 1fr;
        height: auto;
        min-height: 600px;
    }

    .map-container {
        height: 400px;
    }

    .locations-sidebar {
        max-height: 300px;
    }
}

@media (max-width: 768px) {
    .map-container {
        height: 350px;
    }

    .locations-sidebar {
        max-height: 250px;
        padding: 15px;
    }

    .location-card {
        padding: 12px;
    }

    .location-card-header h4 {
        font-size: 13px;
    }

    .location-card-body {
        font-size: 11px;
    }
}

/* HR PAGE STYLES */

.hr-filters {
    margin-bottom: 30px;
    padding: 20px;
    background: var(--bg-alt);
    border-radius: 4px;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    flex: 1;
    min-width: 300px;
}

.search-input,
.filter-select {
    flex: 1;
    min-width: 150px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text);
    border-radius: 3px;
    font-family: inherit;
    font-size: 14px;
}

.search-input::placeholder {
    color: var(--text-lighter);
}

.search-input:focus,
.filter-select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.05);
}

.employees-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.employees-grid.list-view {
    grid-template-columns: 1fr;
}

.view-toggle {
    display: flex;
    gap: 5px;
}

.btn-back-dashboard {
    padding: 8px 16px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
}

.btn-back-dashboard:hover {
    background: rgba(26, 26, 26, 0.8);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.view-btn {
    padding: 10px 15px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text-light);
    border-radius: 3px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.view-btn:hover {
    border-color: var(--accent);
    color: var(--text);
}

.view-btn.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.employee-card-large.list-view {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.employee-card-large.list-view .employee-header {
    flex: 1;
    margin-bottom: 0;
}

.employee-card-large.list-view .employee-header h3 {
    font-size: 15px;
}

.employee-card-large.list-view .employee-role {
    display: inline-block;
    margin-right: 20px;
}

.employee-card-large.list-view .employee-dept {
    display: inline-block;
    margin-right: 20px;
    margin-bottom: 0;
}

.employee-card-large.list-view .btn-view-details {
    width: auto;
    padding: 8px 16px;
    flex-shrink: 0;
}

.employee-card-large {
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: var(--bg);
    cursor: pointer;
    transition: all 0.3s ease;
}

.employee-card-large:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.employee-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
    gap: 10px;
}

.employee-header h3 {
    font-size: 16px;
    margin: 0;
    color: var(--text);
}

.status-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.status-badge.active {
    background: #d4edda;
    color: #155724;
}

.status-badge.terminated {
    background: #f8d7da;
    color: #721c24;
}

.employee-card-large .employee-role {
    font-size: 13px;
    color: var(--text-light);
    font-weight: 600;
    margin: 0 0 8px 0;
}

.employee-card-large .employee-dept {
    font-size: 12px;
    color: var(--text-lighter);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 15px 0;
}

.btn-view-details {
    width: 100%;
    padding: 10px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-view-details:hover {
    background: var(--text);
    color: var(--bg);
}

/* STATISTICS PAGE */

.stats-overview {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.stat-card:hover {
    border-color: var(--text-light);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-info h4 {
    margin: 0 0 6px 0;
    font-size: 12px;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.stat-number {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
}

.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.chart-container {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 20px;
}

.chart-container h3 {
    margin: 0 0 20px 0;
    font-size: 14px;
    color: var(--text);
    font-weight: 600;
}

.chart-container canvas {
    max-height: 300px;
}

.stats-table-section {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 20px;
    margin-top: 30px;
}

.stats-table-section h3 {
    margin: 0 0 20px 0;
    font-size: 14px;
    color: var(--text);
    font-weight: 600;
}

.stats-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.stats-table thead {
    background: var(--bg-alt);
}

.stats-table th {
    padding: 12px;
    text-align: left;
    color: var(--text);
    font-weight: 600;
    border-bottom: 2px solid var(--border);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 11px;
}

.stats-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border);
    color: var(--text-light);
}

.stats-table tr:hover {
    background: var(--bg-alt);
}

.stats-table tr:last-child td {
    border-bottom: none;
}

/* SUBSIDIARIES */

.subsidiaries-section {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 20px;
    margin: 30px 0;
}

.subsidiaries-section h3 {
    margin: 0 0 20px 0;
    font-size: 14px;
    color: var(--text);
    font-weight: 600;
}

.subsidiaries-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.subsidiary-card {
    padding: 18px;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.subsidiary-card:hover {
    border-color: var(--text);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.subsidiary-card h4 {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: var(--text);
    font-weight: 600;
}

.subsidiary-employees {
    margin: 6px 0;
    font-size: 12px;
    color: var(--text-light);
    font-weight: 500;
}

.subsidiary-focus {
    margin: 6px 0 0 0;
    font-size: 12px;
    color: var(--text-lighter);
    font-style: italic;
}
    .charts-grid {
        grid-template-columns: 1fr;
    }

    .stats-overview {
        grid-template-columns: repeat(2, 1fr);
    }

    .stats-table {
        font-size: 11px;
    }

    .stats-table th,
    .stats-table td {
        padding: 8px;
    }


/* EMPLOYEE MODAL */

.employee-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2000;
    overflow-y: auto;
    padding: 20px;
}

.employee-modal .modal-content {
    max-width: 600px;
    margin: 40px auto;
    background: var(--bg);
    border-radius: 4px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-alt);
}

.modal-header h2 {
    margin: 0;
    font-size: 22px;
    color: var(--text);
}

.btn-close-modal {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.btn-close-modal:hover {
    color: var(--text);
}

.modal-body {
    padding: 25px;
}

.employee-details {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.detail-row:last-of-type {
    border-bottom: none;
}

.detail-label {
    font-weight: 600;
    color: var(--text);
    font-size: 14px;
}

.detail-value {
    color: var(--text-light);
    font-size: 14px;
}

.ceo-actions {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px solid var(--border);
}

.btn-fire {
    width: 100%;
    padding: 12px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 10px;
}

.btn-fire:hover:not(:disabled) {
    background: #c82333;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.btn-fire:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .hr-filters {
        flex-direction: column;
    }

    .filter-group {
        flex-direction: column;
        min-width: auto;
    }

    .search-input,
    .filter-select {
        width: 100%;
    }

    .employees-grid {
        grid-template-columns: 1fr;
    }

    .employee-modal .modal-content {
        margin: 20px auto;
    }

    .modal-header {
        padding: 20px;
    }

    .modal-body {
        padding: 20px;
    }
}
/* USER MANAGEMENT */

.users-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.create-user-section,
.users-list-section {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    padding: 30px;
    border-radius: 4px;
}

.create-user-section h3,
.users-list-section h3 {
    font-size: 18px;
    color: var(--text);
    margin-bottom: 20px;
    font-weight: 600;
}

.create-user-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.create-user-form .form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 0;
}

.create-user-form label {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.create-user-form input,
.create-user-form select {
    padding: 10px 12px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text);
    border-radius: 3px;
    font-family: inherit;
    font-size: 13px;
}

.create-user-form input:focus,
.create-user-form select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.05);
}

.form-message {
    padding: 12px 15px;
    border-radius: 3px;
    font-size: 13px;
    display: none;
    text-align: center;
}

.form-message.show {
    display: block;
}

.form-message.success {
    background: #efe;
    color: #060;
    border: 1px solid #b0f0b0;
}

.form-message.error {
    background: #fee;
    color: #c00;
    border: 1px solid #f0b0b0;
}

.users-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
}

.users-table thead {
    background: var(--bg-alt);
}

.users-table th {
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    font-size: 12px;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border);
}

.users-table td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}

.users-table tr:hover {
    background: #fafafa;
}

.users-table tr:last-child td {
    border-bottom: none;
}

.btn-delete-user {
    padding: 6px 12px;
    background: #dc3545;
    color: white;
    border: 1px solid #dc3545;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-delete-user:hover {
    background: #c82333;
    border-color: #c82333;
}

@media (max-width: 1024px) {
    .users-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .users-container {
        gap: 20px;
    }

    .create-user-section,
    .users-list-section {
        padding: 20px;
    }

    .users-table {
        font-size: 12px;
    }

    .users-table th,
    .users-table td {
        padding: 8px 10px;
    }
}

/* DIVISIONS SECTION STYLES */

.divisions-grid {
    margin-bottom: 20px;
}

.division-card {
    border: 1px solid #ccc;
    border-radius: 1px;
    padding: 20px;
    background: #fff;
    transition: all 0.2s;
}

.division-card:hover {
    border-color: #000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.division-name {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #000;
}

.division-info {
    font-size: 13px;
    color: #666;
    margin: 8px 0;
    line-height: 1.5;
}

.division-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.btn-edit, .btn-delete {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #000;
    background: #fff;
    color: #000;
    border-radius: 1px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-edit:hover {
    background: #000;
    color: #fff;
}

.btn-delete {
    border-color: #d32f2f;
    color: #d32f2f;
}

.btn-delete:hover {
    background: #d32f2f;
    color: #fff;
}