@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;500;700&display=swap');

:root {
    --sidebar-bg: #0f172a;
    --sidebar-hover: #1e293b;
    --sidebar-text: #94a3b8;
    --main-bg: #f8fafc;
    --panel-bg: #ffffff;
    --border: #e2e8f0;
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --text-main: #1e293b;
}

body {
    font-family: 'Inter', sans-serif;
    background: #000;
    color: var(--text-main);
    margin: 0;
    display: flex;
    height: 100vh;
    overflow: hidden;
    font-size: 14px;
}

#pantalla-login {
    position: fixed;
    inset: 0;
    background: url('https://images.unsplash.com/photo-1541888079634-11883be1c02c') center/cover;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-container {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 900px;
}

.login-info {
    color: white;
    max-width: 400px;
    background: rgba(15, 23, 42, 0.85);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #334155;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
}

.login-info h2 {
    color: var(--primary);
    margin-top: 0;
    border: none;
    padding: 0;
    font-size: 24px;
}

.login-info p.sub {
    color: #94a3b8;
    font-size: 14px;
    margin-bottom: 25px;
}

.login-box {
    background: rgba(15, 23, 42, 0.95);
    padding: 40px;
    border-radius: 8px;
    width: 100%;
    max-width: 400px;
    color: white;
    border: 1px solid #334155;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
}

.login-box h2 {
    text-align: center;
    color: #fff;
    margin-top: 0;
    letter-spacing: 2px;
    border: none;
    padding: 0;
}

.login-box input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    background: #1e293b;
    border: 1px solid #475569;
    color: white;
    border-radius: 4px;
    box-sizing: border-box;
}

.login-box button {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 10px;
}

.login-box button:hover {
    background: var(--primary-hover);
}

#app-layout {
    display: none;
    width: 100%;
    height: 100vh;
}

.sidebar {
    width: 260px;
    background: var(--sidebar-bg);
    display: flex;
    flex-direction: column;
    border-right: 1px solid #1e293b;
}

.sidebar-logo {
    padding: 25px 20px;
    color: white;
    font-size: 20px;
    font-weight: 700;
    border-bottom: 1px solid #1e293b;
    letter-spacing: 1px;
    display: flex;
    flex-direction: column;
}

.sidebar-logo span {
    font-size: 11px;
    color: var(--sidebar-text);
    font-weight: 300;
    letter-spacing: 3px;
    margin-top: 5px;
}

.sidebar-menu {
    padding: 20px 0;
    flex: 1;
    overflow-y: auto;
}

.menu-btn {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 12px 25px;
    color: var(--sidebar-text);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.menu-btn:hover,
.menu-btn.active-btn {
    background: var(--sidebar-hover);
    color: white;
    border-left: 3px solid var(--primary);
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid #1e293b;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--main-bg);
    overflow: hidden;
}

.topbar {
    background: var(--panel-bg);
    height: 70px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 30px;
    gap: 20px;
}

.user-chip {
    background: #f1f5f9;
    padding: 6px 15px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 13px;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mi-avatar-top {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    object-fit: cover;
}

.bell-wrapper {
    position: relative;
    cursor: pointer;
    padding: 5px;
}

.bell-icon {
    font-size: 20px;
}

.badge {
    position: absolute;
    top: -2px;
    right: -5px;
    background: #ef4444;
    color: white;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 5px;
    border-radius: 10px;
    display: none;
}

.notif-dropdown {
    position: absolute;
    top: 40px;
    right: 0;
    width: 300px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
    display: none;
    z-index: 1000;
    overflow: hidden;
}

.notif-header {
    padding: 12px 15px;
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notif-header button {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 12px;
    cursor: pointer;
    padding: 0;
}

.notif-list {
    max-height: 300px;
    overflow-y: auto;
}

.notif-item {
    padding: 12px 15px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 13px;
}

.notif-item.unread {
    background: #eff6ff;
}

.panels-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}

.panel {
    display: none;
    max-width: 1200px;
    margin: 0 auto;
}

.panel.activo {
    display: block;
}

.carousel-box {
    width: 100%;
    height: 350px;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
}

.slide.active {
    opacity: 1;
}

.carousel-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.4) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 50px;
    color: white;
}

h2 {
    margin-top: 0;
    border-bottom: 1px solid var(--border);
    padding-bottom: 15px;
    color: #0f172a;
}

.card {
    background: var(--panel-bg);
    padding: 25px;
    border-radius: 8px;
    border: 1px solid var(--border);
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

input[type="text"],
input[type="password"],
input[type="url"],
textarea,
select {
    width: 100%;
    padding: 12px;
    margin: 8px 0 20px 0;
    border: 1px solid var(--border);
    border-radius: 4px;
    box-sizing: border-box;
    font-family: inherit;
    font-size: 14px;
}

.btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: 0.2s;
}

.btn:hover {
    background: var(--primary-hover);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-main);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

th,
td {
    padding: 15px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

th {
    background: #f8fafc;
    color: #64748b;
    font-size: 12px;
    text-transform: uppercase;
}

tr:hover {
    background: #f1f5f9;
    cursor: pointer;
}

.tag-prio {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
}

.prio-Alta {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #f87171;
}

.prio-Media {
    background: #fef3c7;
    color: #d97706;
    border: 1px solid #fbbf24;
}

.prio-Baja {
    background: #dcfce7;
    color: #16a34a;
    border: 1px solid #4ade80;
}

.tag-estado {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.est-Abierta {
    background: #ebf8ff;
    color: #2b6cb0;
}

.est-EnInvestigacion {
    background: #fef08a;
    color: #854d0e;
}

.est-Resuelta {
    background: #dcfce7;
    color: #15803d;
}

.est-Cerrada {
    background: #e2e8f0;
    color: #475569;
}

.chat-box {
    height: 350px;
    overflow-y: auto;
    padding: 15px;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 6px;
    margin-bottom: 15px;
}

.msg {
    background: white;
    padding: 15px;
    border-radius: 6px;
    border: 1px solid var(--border);
    margin-bottom: 12px;
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.msg-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e2e8f0;
    flex-shrink: 0;
    background: white;
}

.msg span.autor {
    font-weight: bold;
    color: var(--primary);
    font-size: 13px;
}

.msg span.fecha {
    font-size: 11px;
    color: #94a3b8;
    float: right;
}

.grid-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 8px;
    border: 1px solid var(--border);
    text-align: center;
}

.stat-card h3 {
    margin: 0;
    font-size: 13px;
    color: #64748b;
    border: none;
    padding: 0;
    text-transform: uppercase;
}

.stat-card div {
    font-size: 32px;
    font-weight: bold;
    color: var(--primary);
    margin-top: 10px;
}

#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
}

.toast {
    background: #1e293b;
    color: white;
    padding: 15px 20px;
    margin-top: 10px;
    border-radius: 6px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    animation: slideIn 0.3s forwards;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }

    to {
        transform: translateX(0);
    }
}