/* CSS Variables */
:root {
  --primary-color: #6366f1;
  --secondary-color: #a855f7;
  --accent-color: #06b6d4;
  --dark-bg: #0f172a;
  --darker-bg: #1e293b;
  --card-bg: rgba(30, 41, 59, 0.8);
  --border-color: rgba(148, 163, 184, 0.3);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  --glass-bg: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.2);
  --shadow: rgba(0, 0, 0, 0.3);
  --glow: rgba(99, 102, 241, 0.4);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --border-radius: 16px;
  --sidebar-width: 280px;
  --topbar-height: 80px;
}

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

body {
  font-family: 'Inter', sans-serif;
  margin: 0;
  padding: 0;
  background: var(--dark-bg);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(600px circle at 20% 20%, rgba(120, 119, 198, 0.08), transparent 40%),
    radial-gradient(800px circle at 80% 80%, rgba(161, 161, 170, 0.06), transparent 40%),
    radial-gradient(1000px circle at 50% 50%, rgba(6, 182, 212, 0.04), transparent 50%);
  pointer-events: none;
  animation: floatingParticles 20s ease-in-out infinite;
  z-index: -1;
}

@keyframes floatingParticles {
  0%, 100% { transform: translateY(0) rotate(0deg); opacity: 0.3; }
  25% { transform: translateY(-10px) rotate(90deg); opacity: 0.5; }
  50% { transform: translateY(-20px) rotate(180deg); opacity: 0.6; }
  75% { transform: translateY(-10px) rotate(270deg); opacity: 0.5; }
}

/* Login Styles */
#login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.1);

    .login-form {
        padding: 40px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.95);
        width: 400px;
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.2);
        backdrop-filter: blur(20px);
        animation: slideInBounce 0.6s ease-out;
        text-align: center;

        .login-logo {
            width: 150px;
            height: auto;
            margin-bottom: 20px;
            transition: all 0.3s ease;
            filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));

            &:hover {
                transform: scale(1.05) rotate(-2deg);
                filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.15));
            }
        }

        h2 {
            text-align: center;
            margin-bottom: 30px;
            color: #2c3e50;
            font-weight: 600;
            font-size: 1.8em;
            animation: fadeInDown 0.5s ease-out;
        }

    }
}

@keyframes slideInBounce {
    0% { opacity: 0; transform: scale(0.3); }
    50% { opacity: 1; transform: scale(1.05); }
    70% { transform: scale(0.9); }
    100% { opacity: 1; transform: scale(1); }
}

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

.login-form label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
    transition: color 0.3s ease;
}

.login-form input {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: 2px solid #e1e8ed;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);

    &:focus {
        outline: none;
        border-color: #667eea;
        box-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
        transform: translateY(-2px);

        &::placeholder {
            color: transparent;
        }
    }

    &::placeholder {
        color: #aab8c2;
        transition: color 0.3s ease;
    }
}

.login-form .google-signin-btn {
    width: 100%;
    padding: 15px;
    background: #4285F4;
    color: #ffffff;
    border: 2px solid #3367D6;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(66, 133, 244, 0.3);

    &:hover {
        background: #3367D6;
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(66, 133, 244, 0.4);
    }

    &:active {
        transform: translateY(0);
    }
}

.login-form button {
    border: none;
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;

    &:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    }

    &:active {
        transform: translateY(0);
    }
}

.error {
    color: #e74c3c;
    text-align: center;
    margin-top: 15px;
    background: rgba(231, 76, 60, 0.1);
    padding: 10px;
    border-radius: 8px;
    animation: shake 0.4s ease-in-out;
    @include border-radius(8px);
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Dashboard Styles */
#dashboard-container {
    padding: 30px;
    min-height: 100vh;
    animation: fadeInUp 0.8s ease-out;
}

header {
    margin-bottom: 30px;
    background: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(20px);
    padding: 30px;
    border-radius: 24px;
    box-shadow: 0 20px 60px var(--shadow);
    border: 1px solid var(--border-color);
    animation: slideInLeft 0.6s ease-out;
    position: relative;
    z-index: 10;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

header h1 {
    margin: 0 0 20px 0;
    color: var(--text-primary);
    font-size: 2.5em;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.controls-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
}

#search-bar {
    flex: 2;
    padding: 16px 20px;
    border: 2px solid var(--border-color);
    border-radius: 16px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: var(--card-bg);
    color: var(--text-primary);
    min-width: 250px;
    backdrop-filter: blur(10px);
}

#search-bar:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 30px var(--glow);
    transform: translateY(-2px);
    background: var(--card-bg);
}

#search-bar::placeholder {
    color: var(--text-secondary);
}

/* Custom Dropdown */
.custom-dropdown {
    flex: 1;
    min-width: 150px;
    position: relative;
}

.dropdown-selected {
    padding: 16px 20px;
    border: 2px solid var(--border-color);
    border-radius: 16px;
    background: var(--card-bg);
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    min-height: 52px;
}

.dropdown-selected:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 25px rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
}

.dropdown-selected.open {
    border-color: var(--primary-color);
    box-shadow: 0 0 30px var(--glow);
    border-radius: 16px 16px 0 0;
}

.dropdown-arrow {
    transition: transform 0.3s ease;
    font-size: 0.8em;
    color: var(--text-secondary);
}

.dropdown-selected.open .dropdown-arrow {
    transform: rotate(180deg);
}

.selected-text {
    font-weight: 500;
    color: var(--text-primary);
}

.dropdown-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-top: none;
    border-radius: 0 0 16px 16px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.3s ease;
    backdrop-filter: blur(20px);
    box-shadow: 0 10px 40px var(--shadow);
    z-index: 2000;
}

.dropdown-options.open {
    max-height: 250px;
    opacity: 1;
}

.dropdown-option {
    padding: 14px 20px 18px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-secondary);
    font-weight: 500;
    border-bottom: 1px solid var(--border-color);
}

.dropdown-option:last-child {
    border-bottom: none;
}

.dropdown-option:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
    transform: translateX(5px);
    border-left: 4px solid var(--primary-color);
    padding-left: 16px;
}

.dropdown-option.selected {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary-color);
    font-weight: 600;
    border-left: 4px solid var(--primary-color);
    padding-left: 16px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--card-bg);
    padding: 16px 20px;
    border-radius: 16px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    cursor: pointer;
}

.checkbox-container:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 25px rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
}

#rent-checkbox {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-color);
    cursor: pointer;
    transition: transform 0.2s ease;
    border-radius: 4px;
}

#rent-checkbox:hover {
    transform: scale(1.1);
}

label[for="rent-checkbox"] {
    margin: 0;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-primary);
    transition: color 0.3s ease;
    user-select: none;
}

.checkbox-container:hover label {
    color: var(--primary-color);
}

/* Tabs */
.tabs {
    display: flex;
    background: var(--card-bg);
    border-radius: 20px;
    padding: 8px;
    margin-bottom: 40px;
    backdrop-filter: blur(20px);
    box-shadow: 0 10px 40px var(--shadow);
    border: 1px solid var(--border-color);
    animation: slideInRight 0.6s ease-out;
    z-index: 1;
    position: relative;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.tab-button {
    flex: 1;
    padding: 18px 30px;
    background: none;
    border: none;
    cursor: pointer;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.tab-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    transition: left 0.3s ease;
    z-index: -1;
    border-radius: 16px;
}

.tab-button.active::before {
    left: 0;
}

.tab-button.active {
    color: white;
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
    transform: translateY(-2px);
}

.tab-button:hover {
    color: white;
    transform: translateY(-1px);
}

.tab-button:hover::before {
    left: 0;
}

/* Tab Panes */
.tab-pane {
    display: none;
    padding: 20px 0;
    animation: fadeInTab 0.4s ease-out;
}

@keyframes fadeInTab {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-pane.active {
    display: block;
}

/* Posts List */
.posts-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(550px, 1fr));
    gap: 30px;
    animation: fadeInList 0.6s ease-out;
}

@keyframes fadeInList {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes postSlideIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.post {
    border-radius: 28px;
    background: var(--card-bg);
    box-shadow: 0 20px 60px var(--shadow);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(25px);
    padding: 0;
    transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
    animation: postSlideIn 0.7s ease-out forwards;
    display: flex;
    flex-direction: column;
    min-height: 320px;
    cursor: pointer;
    border: 1px solid var(--border-color);
}

.post::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.03), transparent);
    transition: left 1s ease;
    z-index: 1;
}

.post:hover::before {
    left: 100%;
}

.post:hover {
    transform: translateY(-20px) scale(1.02);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-color);
}

.post.rented {
    border: 2px solid var(--warning-color);
    box-shadow: 0 20px 60px rgba(245, 158, 11, 0.2);
}

.post.rented::after {
    content: 'RENTED';
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--warning-color);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.7em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 3;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.post.approving {
    animation: approvePulse 1s ease-out;
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.15) 0%, rgba(34, 197, 94, 0.15) 100%);
    border: 3px solid #28a745;
    box-shadow: 0 25px 50px rgba(40, 167, 69, 0.3);
}

@keyframes approvePulse {
    0% { transform: scale(1); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15); }
    50% { transform: scale(1.04); box-shadow: 0 35px 80px rgba(40, 167, 69, 0.3); }
    100% { transform: scale(1); box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15); }
}

.post.rejecting {
    animation: rejectShake 0.8s ease-in-out;
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.15) 0%, rgba(237, 173, 181, 0.15) 100%);
    border: 3px solid #dc3545;
    box-shadow: 0 25px 50px rgba(220, 53, 69, 0.3);
}

@keyframes rejectShake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-8px); }
    20%, 40%, 60%, 80% { transform: translateX(8px); }
}

.post.removing {
    animation: removeFadeOut 1s ease-out forwards;
}

@keyframes removeFadeOut {
    to {
        opacity: 0;
        transform: scale(0.9) rotate(10deg) translateY(30px);
        filter: blur(5px);
    }
}

/* Premium Post Header */
.post-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    padding: 20px 25px;
    color: white;
    position: relative;
    overflow: hidden;
}

.post-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="40" r="1.5" fill="rgba(255,255,255,0.08)"/><circle cx="60" cy="80" r="1" fill="rgba(255,255,255,0.06)"/></svg>');
    background-size: 50px 50px;
    opacity: 0.1;
}

.post h3 {
    margin: 0 0 12px 0;
    font-size: 1.4em;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.price-display {
    font-size: 1.6em;
    font-weight: 900;
    color: #FFD700;
    text-shadow: 0 2px 8px rgba(255, 215, 0, 0.5);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.price-display::before {
    content: '$';
    font-size: 1.2em;
}

.category-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Premium Post Content */
.post-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.user-details {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.profile-img, .user-details .profile-img, img[src*="profile"] {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
    min-height: 50px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid rgba(102, 126, 234, 0.3) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
    transition: all 0.3s ease !important;
    clip-path: circle(50%) !important;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    display: block;
}

.profile-img:hover {
    transform: scale(1.1);
    border-color: #667eea;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.user-info h4 {
    margin: 0;
    font-size: 1.1em;
    font-weight: 700;
    color: var(--text-primary);
}

.post-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 15px;
}

.detail-item {
    background: rgba(99, 102, 241, 0.05);
    padding: 12px 16px;
    border-radius: 12px;
    border-left: 4px solid rgba(99, 102, 241, 0.2);
    transition: all 0.3s ease;
    font-size: 0.9em;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.detail-item:hover {
    background: rgba(99, 102, 241, 0.08);
    border-left-color: var(--primary-color);
    transform: translateX(2px);
    border-color: var(--primary-color);
}

.detail-item strong {
    color: var(--primary-color);
    font-weight: 700;
}

.description-preview {
    background: var(--darker-bg);
    padding: 16px;
    border-radius: 12px;
    font-style: italic;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 20px;
    border-left: 4px solid var(--border-color);
    position: relative;
    border: 1px solid var(--border-color);
}

.description-preview::before {
    content: '"';
    font-size: 2em;
    color: rgba(102, 126, 234, 0.3);
    position: absolute;
    top: -5px;
    left: 10px;
    font-family: serif;
}

.image-gallery {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.post-img {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    object-fit: cover;
    transition: all 0.3s ease;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    border: 2px solid transparent;
}

.post-img:hover {
    transform: scale(1.1) rotate(2deg);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    border-color: #667eea;
}

.post-actions {
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%);
    margin: 0 -25px -25px -25px;
    padding: 20px 25px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Status Badge */
.status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

.status-badge.pending {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
    box-shadow: 0 3px 10px rgba(243, 156, 18, 0.3);
}

.status-badge.approved {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
    box-shadow: 0 3px 10px rgba(39, 174, 96, 0.3);
}

.status-badge.rejected {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    box-shadow: 0 3px 10px rgba(231, 76, 60, 0.3);
}

.post-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.button {
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.4s ease;
}

.button:hover::before {
    left: 100%;
}

.approve {
    background: linear-gradient(135deg, #28a745 0%, #34d058 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.approve:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
}

.reject, .remove {
    background: linear-gradient(135deg, #dc3545 0%, #e35d6a 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

.reject:hover, .remove:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(220, 53, 69, 0.4);
}

/* User Info */
.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.user-info h3 {
    margin: 0;
    font-size: 1.1em;
    color: #2c3e50;
}

.profile-img {
    max-width: 60px;
    height: auto;
    border-radius: 50%;
    border: 3px solid rgba(102, 126, 234, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.profile-img:hover {
    transform: scale(1.1);
    border-color: #667eea;
}

/* Post Images */
.post-images {
    display: flex;
    gap: 15px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.post-img {
    max-width: 120px;
    height: auto;
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.post-img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 40px;
    padding: 30px 0;
    flex-wrap: wrap;
}

.pagination button {
    padding: 14px 24px;
    border: 2px solid var(--border-color);
    background: var(--card-bg);
    color: var(--text-primary);
    cursor: pointer;
    border-radius: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px var(--shadow);
}

.pagination button:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.3);
    border-color: var(--primary-color);
}

.pagination button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
    border-color: var(--border-color);
}

.pagination span {
    font-weight: 700;
    color: var(--text-primary);
    background: var(--card-bg);
    padding: 14px 24px;
    border-radius: 14px;
    box-shadow: 0 6px 20px var(--shadow);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
}

/* Rent Toggle Button */
.rent-toggle-btn {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.75em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
    position: relative;
    overflow: hidden;
}

.rent-toggle-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.4s ease;
}

.rent-toggle-btn:hover::before {
    left: 100%;
}

.rent-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.rent-toggle-btn.available {
    background: linear-gradient(135deg, var(--success-color), #059669);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.rent-toggle-btn.available:hover {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.rent-toggle-btn.loading {
    background: var(--card-bg);
    color: var(--text-secondary);
    cursor: not-allowed;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Click Ripple Effect */
.click-ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transform: scale(0);
    animation: ripple 0.6s linear;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Force Circular Profile Images */
.post .profile-img,
.user-details img,
img[alt*="profile"],
img[alt*="Profile"] {
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    -webkit-border-radius: 50% !important;
    -moz-border-radius: 50% !important;
    clip-path: circle(50%) !important;
    -webkit-clip-path: circle(50%) !important;
    shape-outside: circle(50%);
    display: block !important;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    padding: 15px 20px;
    box-shadow: 0 8px 25px var(--shadow);
    border-left: 4px solid;
    animation: toastSlideIn 0.4s ease-out;
    display: flex;
    align-items: center;
    gap: 10px;
    opacity: 1;
    transform: translateX(100%);
    transition: all 0.4s ease;
    color: var(--text-primary);
}

.toast.success {
    border-left-color: #28a745;
}

.toast.success::before {
    content: '✓';
    color: #28a745;
    font-size: 1.2em;
    font-weight: bold;
}

.toast.error {
    border-left-color: #dc3545;
}

.toast.error::before {
    content: '✕';
    color: #dc3545;
    font-size: 1.2em;
    font-weight: bold;
}

.toast.info {
    border-left-color: #17a2b8;
}

.toast.info::before {
    content: 'ℹ';
    color: #17a2b8;
    font-size: 1.2em;
    font-weight: bold;
}

@keyframes toastSlideIn {
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast.hide {
    transform: translateX(100%);
    opacity: 0;
}

/* Sidebar Styles */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--glass-border);
  transition: var(--transition);
  z-index: 100;
  overflow-y: auto;
  box-shadow: 4px 0 20px var(--shadow);
}

.sidebar.collapsed {
  width: 70px;
}

.sidebar-header {
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--text-primary);
  font-size: 1.2em;
}

.sidebar-logo img {
  width: 40px;
  height: 40px;
}

.collapsed .sidebar-logo span,
.collapsed .nav-text {
  opacity: 0;
  pointer-events: none;
}

.sidebar-toggle {
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 1.5em;
  padding: 5px;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.sidebar-toggle:hover {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary-color);
}

.sidebar-nav {
  padding: 0 20px;
}

.nav-item {
  display: block;
  padding: 15px 20px;
  margin-bottom: 5px;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--border-radius);
  transition: var(--transition);
  position: relative;
  display: flex;
  align-items: center;
  gap: 15px;
  font-weight: 500;
}

.nav-item:hover {
  color: var(--primary-color);
  background: rgba(99, 102, 241, 0.1);
  transform: translateX(5px);
}

.nav-item.active {
  color: white;
  background: var(--primary-color);
  box-shadow: 0 0 20px var(--glow);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  width: 4px;
  height: 100%;
  background: white;
  border-radius: 0 2px 2px 0;
}

.nav-icon {
  font-size: 1.2em;
  min-width: 20px;
}

/* Main Content */
.main-content {
  margin-left: var(--sidebar-width);
  transition: margin-left 0.3s ease;
}

.collapsed .main-content {
  margin-left: 70px;
}

.dashboard-main {
  padding: 20px;
}

/* Topbar */
.topbar {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  padding: 20px 30px;
  margin-bottom: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 20px var(--shadow);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  font-size: 1.5em;
  padding: 10px;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-weight: 500;
}

.breadcrumb-item.active {
  color: var(--primary-color);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar-right .search-container {
  position: relative;
}

.search-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  font-size: 1.2em;
}

.notification-btn {
  position: relative;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 1.2em;
  padding: 10px;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.notification-btn:hover {
  color: var(--primary-color);
  background: rgba(99, 102, 241, 0.1);
}

.notification-badge {
  position: absolute;
  top: 5px;
  right: 5px;
  background: var(--error-color);
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 0.8em;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

.user-menu {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 10px;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.user-menu:hover {
  background: rgba(99, 102, 241, 0.1);
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-color);
}

.user-info h4 {
  margin: 0;
  font-size: 0.9em;
  color: var(--text-primary);
}

.user-role {
  font-size: 0.8em;
  color: var(--text-secondary);
}

.user-menu-toggle {
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.user-menu-toggle .arrow-down {
  font-size: 1em;
}

.user-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  box-shadow: 0 10px 30px var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: var(--transition);
  z-index: 200;
  min-width: 150px;
}

.user-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 12px 20px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
  border-bottom: 1px solid var(--border-color);
}

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

.dropdown-item:hover {
  color: var(--primary-color);
  background: rgba(99, 102, 241, 0.1);
}

/* Stats Cards */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.stat-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 25px;
  box-shadow: 0 8px 32px var(--shadow);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 20px;
}

.stat-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px var(--shadow);
  border-color: var(--primary-color);
}

.stat-icon {
  font-size: 2.5em;
  opacity: 0.8;
}

.stat-content {
  flex: 1;
}

.stat-number {
  font-size: 2.5em;
  font-weight: 800;
  margin: 0;
  color: var(--text-primary);
  animation: statGlow 2s infinite;
}

@keyframes statGlow {
  0%, 100% { text-shadow: none; }
  50% { text-shadow: 0 0 20px var(--glow); }
}

.stat-label {
  margin: 5px 0 0 0;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 1em;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-sparkline {
  flex-shrink: 0;
  width: 80px;
  height: 60px;
}

/* Actions Bar */
.actions-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  gap: 20px;
  flex-wrap: wrap;
}

.filters-container {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.filter-group label {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9em;
}

.filter-select {
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  color: var(--text-primary);
  font-size: 0.9em;
}

.btn-group {
  display: flex;
  gap: 10px;
}

.btn-outline,
.btn-primary {
  padding: 12px 20px;
  border-radius: var(--border-radius);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid var(--primary-color);
}

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

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

.btn-primary {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

/* View Toggle */
.view-toggle {
  display: flex;
  background: var(--darker-bg);
  border-radius: var(--border-radius);
  padding: 4px;
  margin-bottom: 20px;
}

.view-toggle-btn {
  flex: 1;
  padding: 12px 20px;
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: calc(var(--border-radius) - 4px);
  transition: var(--transition);
  font-weight: 500;
}

.view-toggle-btn.active {
  background: var(--primary-color);
  color: white;
  box-shadow: 0 0 10px var(--glow);
}

.view-content {
  display: none;
}

.view-content.active {
  display: block;
}

/* Data Table */
.data-table-container {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 8px 32px var(--shadow);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9em;
}

.data-table thead th {
  background: var(--darker-bg);
  color: var(--text-primary);
  font-weight: 600;
  padding: 16px;
  text-align: left;
  border-bottom: 2px solid var(--border-color);
  position: relative;
  cursor: pointer;
  transition: var(--transition);
}

.data-table thead th:hover {
  background: rgba(99, 102, 241, 0.1);
}

.table-header-text {
  display: inline-block;
  margin-right: 8px;
}

.sort-icon {
  transition: transform 0.3s ease;
}

.sort-icon.sorted-asc {
  transform: rotate(180deg);
  color: var(--primary-color);
}

.sort-icon.sorted-desc {
  color: var(--primary-color);
}

.data-table tbody td {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.data-table tbody tr:nth-child(even) {
  background: rgba(99, 102, 241, 0.05);
}

.data-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.08);
}

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

/* Cards View */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 20px;
}

/* Post Cards (for cards view) */
.post-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 20px;
  box-shadow: 0 8px 32px var(--shadow);
  transition: var(--transition);
  cursor: pointer;
}

.post-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px var(--shadow);
  border-color: var(--primary-color);
}

/* Pagination */
.pagination-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  flex-wrap: wrap;
  gap: 20px;
}

.pagination-info {
  color: var(--text-secondary);
  font-weight: 500;
}

.pagination-controls {
  display: flex;
  gap: 10px;
}

.pagination-controls button {
  padding: 10px 15px;
  border: 1px solid var(--border-color);
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.pagination-controls button:hover:not(.disabled) {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

.pagination-controls button.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Modals */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: modalFadeIn 0.3s ease-out;
}

.modal.active {
  display: flex;
}

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

.modal-content {
  background: var(--glass-bg);
  backdrop-filter: blur(25px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius);
  padding: 30px;
  box-shadow: 0 20px 60px var(--shadow);
  max-width: 500px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from { transform: scale(0.9) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  font-size: 1.5em;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover {
  color: var(--primary-color);
  transform: rotate(90deg);
}

/* Skeleton Loading */
.skeleton-loader {
  animation: skeletonPulse 2s infinite;
}

.skeleton {
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.2) 25%, rgba(148, 163, 184, 0.1) 50%, rgba(148, 163, 184, 0.2) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.5s infinite;
  border-radius: var(--border-radius);
}

@keyframes skeletonPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes skeletonShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }

  .cards-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  }

  :root {
    --sidebar-width: 250px;
  }

  .sidebar.collapsed {
    width: 60px;
  }

  .collapsed .main-content {
    margin-left: 60px;
  }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
  }

  .collapsing .main-content {
    margin-left: 0;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .topbar {
    flex-direction: column;
    gap: 15px;
    padding: 15px 20px;
  }

  .topbar-left,
  .topbar-right {
    width: 100%;
  }

  .actions-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .filters-container {
    order: 2;
  }

  .btn-group {
    order: 1;
    justify-content: center;
  }

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

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

  .data-table {
    font-size: 0.8em;
  }

  .data-table thead th,
  .data-table tbody td {
    padding: 10px;
  }

  .modal-content {
    padding: 20px;
    width: 95%;
  }
}

@media (max-width: 480px) {
  #dashboard-container {
    padding: 10px;
  }

  .topbar {
    padding: 10px 15px;
  }

  .stat-card {
    padding: 20px;
    gap: 15px;
  }

  .stat-number {
    font-size: 2em;
  }

  .filters-container {
    flex-direction: column;
  }

  .filter-select {
    width: 100%;
  }
}
