/* Admin Panel Styles */
.admin-body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow: hidden; /* Prevent full page scroll, handle in main */
}

.admin-layout {
    display: flex;
    height: 100vh;
    width: 100vw;
}

/* Sidebar */
.admin-sidebar {
    width: 280px;
    background: var(--bg-card);
    border-right: 1px solid var(--border-glass);
    display: flex;
    flex-direction: column;
    padding: 30px 0;
    position: relative;
    z-index: 10;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 0 25px;
    margin-bottom: 40px;
    font-size: 1.4rem;
    font-weight: 700;
    color: white;
}

.sidebar-logo .logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, var(--primary), #00b3cc);
    border-radius: 10px;
    color: var(--bg-dark);
}

.sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 25px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-item i {
    font-size: 1.25rem;
}

.nav-item:hover, .nav-item.active {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 4px;
    background: var(--primary);
    border-radius: 0 4px 4px 0;
}

.badge {
    margin-left: auto;
    background: var(--primary);
    color: #000;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 2px 8px;
    border-radius: 20px;
    position: static !important;
}

.sidebar-footer {
    padding: 0 25px;
    margin-top: auto;
}

/* Main Content */
.admin-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

/* Topbar */
.admin-topbar {
    height: 70px;
    border-radius: 0;
    border-top: none;
    border-right: none;
    border-left: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
}

.search-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0,0,0,0.2);
    padding: 8px 15px;
    border-radius: 20px;
    width: 300px;
    border: 1px solid var(--border-glass-light);
}

.search-wrap input {
    background: transparent;
    border: none;
    color: var(--text-main);
    outline: none;
    width: 100%;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.admin-profile img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

/* Notifications */
.notification-wrapper {
    position: relative;
}
.notif-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    font-weight: bold;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-dark);
}
.notif-dropdown {
    position: absolute;
    top: 50px;
    right: 0;
    width: 340px;
    max-height: 400px;
    display: flex;
    flex-direction: column;
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
    transition: var(--transition);
}
.notif-dropdown.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}
.notif-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-glass);
}
.notif-header h3 {
    font-size: 1rem;
    margin: 0;
}
.mark-read-btn {
    font-size: 0.75rem;
    color: var(--primary);
}
.mark-read-btn:hover {
    text-decoration: underline;
}
.notif-body {
    overflow-y: auto;
    padding: 10px;
}
.notif-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.2);
    margin-bottom: 8px;
    transition: var(--transition);
    border-left: 3px solid transparent;
}
.notif-item.warning {
    border-left-color: #f59e0b;
    background: rgba(245, 158, 11, 0.05);
}
.notif-item.alert {
    border-left-color: #ef4444;
    background: rgba(239, 68, 68, 0.05);
}
.notif-item:hover {
    background: rgba(255, 255, 255, 0.05);
}
.notif-icon {
    font-size: 1.5rem;
    color: var(--primary);
}
.notif-item.warning .notif-icon { color: #f59e0b; }
.notif-item.alert .notif-icon { color: #ef4444; }

.notif-content h4 {
    font-size: 0.85rem;
    margin-bottom: 4px;
}
.notif-content p {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.notif-time {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 5px;
    display: block;
}

/* Dashboard Content */
.admin-views-container {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.admin-view {
    display: none;
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}
.admin-view.active-view {
    display: block;
}

.page-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 25px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--primary);
}

.stat-info h3 {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 5px;
}

.stat-info p {
    font-size: 1.5rem;
    font-weight: 700;
}

/* Panels */
.dashboard-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.panel {
    padding: 20px;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.panel-header h2 {
    font-size: 1.2rem;
}

/* Message List (Dashboard) */
.msg-list-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    border-radius: 12px;
    margin-bottom: 10px;
    background: rgba(0,0,0,0.2);
    cursor: pointer;
    transition: var(--transition);
}

.msg-list-item:hover {
    background: rgba(255,255,255,0.05);
}

.msg-list-item.unread {
    border-left: 3px solid var(--primary);
    background: rgba(0, 229, 255, 0.05);
}

.msg-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.msg-details {
    flex: 1;
    overflow: hidden;
}

.msg-details h4 {
    font-size: 0.95rem;
    margin-bottom: 3px;
}

.msg-details p {
    font-size: 0.8rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.msg-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Small Property Item for Admin Panel */
.admin-prop-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}
.admin-prop-item img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
}
.admin-prop-info h4 {
    font-size: 0.9rem;
    margin-bottom: 2px;
}
.admin-prop-info span {
    font-size: 0.8rem;
    color: var(--primary);
}
