/* ==========================================================================
   Landlord Panel Styles
   Independent styling for the Landlord admin panel.
   ========================================================================== */

/* --- Color Variables --- */
:root {
    --ll-primary: #1a237e;
    --ll-primary-light: #3949ab;
    --ll-primary-dark: #0d1642;
    --ll-accent: #00bcd4;
    --ll-accent-light: #4dd0e1;
    --ll-bg: #f0f2f5;
    --ll-sidebar-bg: #1a237e;
    --ll-sidebar-text: #c5cae9;
    --ll-sidebar-active: #ffffff;
    --ll-card-bg: #ffffff;
    --ll-text: #333333;
    --ll-text-muted: #757575;
    --ll-border: #e0e0e0;
    --ll-success: #43a047;
    --ll-danger: #e53935;
    --ll-warning: #fb8c00;
    --ll-info: #1e88e5;
}

/* --- Base Layout --- */
.landlord-body {
    margin: 0;
    padding: 0;
    font-family: 'Nunito', sans-serif;
    background-color: var(--ll-bg);
    color: var(--ll-text);
    min-height: 100vh;
}

.landlord-wrapper {
    display: flex;
    min-height: 100vh;
}

/* --- Top Bar --- */
.landlord-topbar {
    background: linear-gradient(135deg, var(--ll-primary), var(--ll-primary-light));
    color: #fff;
    padding: 0 30px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.landlord-topbar .brand {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.landlord-topbar .brand i {
    font-size: 1.5rem;
}

.landlord-topbar .user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.9rem;
}

.landlord-topbar .user-info .user-name {
    opacity: 0.9;
}

.landlord-topbar .btn-logout {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 5px 15px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.landlord-topbar .btn-logout:hover {
    background: rgba(255,255,255,0.25);
}

/* --- Sidebar --- */
.landlord-sidebar {
    width: 220px;
    background: var(--ll-sidebar-bg);
    color: var(--ll-sidebar-text);
    position: fixed;
    top: 56px;
    left: 0;
    bottom: 0;
    overflow-y: auto;
    padding-top: 20px;
    z-index: 999;
    transition: width 0.3s;
}

.landlord-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.landlord-sidebar li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 24px;
    color: var(--ll-sidebar-text);
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.landlord-sidebar li a:hover {
    background: rgba(255,255,255,0.08);
    color: var(--ll-sidebar-active);
}

.landlord-sidebar li.active a {
    background: rgba(255,255,255,0.12);
    color: var(--ll-sidebar-active);
    border-left-color: var(--ll-accent);
    font-weight: 600;
}

.landlord-sidebar li a i {
    font-size: 1.3rem;
    width: 28px;
    text-align: center;
}

.landlord-sidebar .sidebar-section {
    padding: 15px 24px 5px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    opacity: 0.5;
    font-weight: 700;
}

/* --- Main Content --- */
.landlord-content {
    margin-left: 220px;
    margin-top: 56px;
    padding: 30px;
    flex: 1;
    min-height: calc(100vh - 56px);
}

/* --- Dashboard Cards --- */
.stat-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--ll-card-bg);
    border-radius: 10px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

.stat-card .stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
}

.stat-card .stat-icon.total { background: linear-gradient(135deg, var(--ll-primary-light), var(--ll-primary)); color: #fff; }
.stat-card .stat-icon.active { background: linear-gradient(135deg, #66bb6a, var(--ll-success)); color: #fff; }
.stat-card .stat-icon.suspended { background: linear-gradient(135deg, #ffa726, var(--ll-warning)); color: #fff; }

.stat-card .stat-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
    color: var(--ll-text);
}

.stat-card .stat-info p {
    margin: 2px 0 0;
    font-size: 0.85rem;
    color: var(--ll-text-muted);
}

/* --- Page Header --- */
.landlord-page-header {
    margin-bottom: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.landlord-page-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ll-text);
    margin: 0;
}

/* --- Card / Panel Styles --- */
.ll-card {
    background: var(--ll-card-bg);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    overflow: hidden;
}

.ll-card .card-header {
    background: var(--ll-primary);
    color: #fff;
    padding: 15px 20px;
    font-weight: 600;
    font-size: 1rem;
}

.ll-card .card-body {
    padding: 20px;
}

/* --- Tables --- */
.ll-table {
    width: 100%;
    border-collapse: collapse;
}

.ll-table thead th {
    background: var(--ll-bg);
    color: var(--ll-text-muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 16px;
    border-bottom: 2px solid var(--ll-border);
    text-align: left;
}

.ll-table tbody td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--ll-border);
    font-size: 0.9rem;
}

.ll-table tbody tr:hover {
    background: rgba(26,35,126,0.02);
}

/* --- Badges --- */
.ll-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.ll-badge-success { background: #e8f5e9; color: var(--ll-success); }
.ll-badge-warning { background: #fff3e0; color: var(--ll-warning); }
.ll-badge-danger { background: #ffebee; color: var(--ll-danger); }

/* --- Buttons --- */
.ll-btn {
    padding: 8px 18px;
    border-radius: 6px;
    border: none;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
}

.ll-btn-primary {
    background: var(--ll-primary);
    color: #fff;
}

.ll-btn-primary:hover {
    background: var(--ll-primary-light);
    color: #fff;
    text-decoration: none;
}

.ll-btn-accent {
    background: var(--ll-accent);
    color: #fff;
}

.ll-btn-accent:hover {
    background: var(--ll-accent-light);
    color: #fff;
    text-decoration: none;
}

.ll-btn-outline {
    background: transparent;
    border: 1px solid var(--ll-border);
    color: var(--ll-text);
}

.ll-btn-outline:hover {
    border-color: var(--ll-primary);
    color: var(--ll-primary);
    text-decoration: none;
}

.ll-btn-sm {
    padding: 5px 12px;
    font-size: 0.8rem;
}

.ll-btn-danger {
    background: var(--ll-danger);
    color: #fff;
}

.ll-btn-danger:hover {
    background: #c62828;
    color: #fff;
    text-decoration: none;
}

/* --- Login Page --- */
.landlord-login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--ll-primary-dark) 0%, var(--ll-primary) 50%, var(--ll-primary-light) 100%);
}

.landlord-login-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    padding: 50px 40px;
    width: 100%;
    max-width: 420px;
}

.landlord-login-card h2 {
    text-align: center;
    color: var(--ll-primary);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.landlord-login-card .login-subtitle {
    text-align: center;
    color: var(--ll-text-muted);
    font-size: 0.9rem;
    margin-bottom: 30px;
}

.landlord-login-card .form-group {
    margin-bottom: 20px;
}

.landlord-login-card label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ll-text);
    margin-bottom: 5px;
    display: block;
}

.landlord-login-card input[type="email"],
.landlord-login-card input[type="password"] {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--ll-border);
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.landlord-login-card input:focus {
    border-color: var(--ll-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(26,35,126,0.1);
}

.landlord-login-card .btn-login {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, var(--ll-primary), var(--ll-primary-light));
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.landlord-login-card .btn-login:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26,35,126,0.3);
}

.landlord-login-card .remember-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    font-size: 0.85rem;
    color: var(--ll-text-muted);
}

.landlord-login-card .error-message {
    background: #ffebee;
    color: var(--ll-danger);
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 20px;
}

/* --- Footer --- */
.landlord-footer {
    margin-left: 220px;
    padding: 15px 30px;
    text-align: center;
    font-size: 0.8rem;
    color: var(--ll-text-muted);
    border-top: 1px solid var(--ll-border);
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .landlord-sidebar {
        width: 60px;
    }
    .landlord-sidebar li a span {
        display: none;
    }
    .landlord-sidebar .sidebar-section {
        display: none;
    }
    .landlord-content {
        margin-left: 60px;
    }
    .landlord-footer {
        margin-left: 60px;
    }
    .landlord-login-card {
        margin: 20px;
        padding: 30px 25px;
    }
}
