/* 
   Residence Management System - "Sugar Soft" Concept Theme
   Based on User Provided Reference Images (Clay/Soft UI)
*/

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Palette from Reference */
    --bg-body: #Eef2f6;
    /* Soft Blue-Grey Background */
    --bg-surface: #ffffff;

    --primary: #10141a;
    /* Deep Black/Charcoal from 'Lufga' image */
    --primary-text: #ffffff;

    --text-main: #1e293b;
    --text-secondary: #64748b;

    /* Soft Accents (Pastels) */
    --accent-blue: #83A2DB;
    /* From Reference */
    --accent-red: #CE6969;
    /* From Reference */
    --accent-green: #86efac;
    --accent-yellow: #fde047;

    /* Metrics */
    --sidebar-width: 80px;
    /* Narrow rail like reference */
    --header-height: 80px;

    /* The "Sugar" Roundness */
    --radius-card: 32px;
    /* Very rounded corners */
    --radius-pill: 100px;

    /* Depth */
    --shadow-soft:
        0 4px 6px -1px rgba(0, 0, 0, 0.02),
        0 10px 15px -3px rgba(0, 0, 0, 0.03),
        0 0 0 1px rgba(255, 255, 255, 0.5) inset;
    /* Inner light bevel */

    --shadow-floating:
        0 20px 25px -5px rgba(0, 0, 0, 0.05),
        0 8px 10px -6px rgba(0, 0, 0, 0.01);
}

/* Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    outline: none;
}

body {
    background-color: var(--bg-body);
    font-family: 'Outfit', sans-serif;
    /* Geometric, friendly sans */
    color: var(--text-main);
    line-height: 1.5;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.2s ease;
}

ul {
    list-style: none;
}

/* --- Layout --- */
.app-container {
    display: flex;
    min-height: 100vh;
    color: var(--primary);
}

.nav-item.active {
    background: white;
    color: var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.nav-item.active::after {
    content: '';
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 4px;
    background: var(--primary);
    border-radius: 50%;
}

/* Main Content Area */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 1600px;
    margin: 0 auto;
}

/* Top Navigation (Pills) */
/* Top Navigation Layout */
.topbar-layout {
    display: grid;
    grid-template-columns: 1fr minmax(0, auto) 1fr;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.top-nav {
    grid-column: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-width: 0;
}

.pill-menu {
    display: flex;
    background: #e2e6eb;
    /* slightly darker than body */
    padding: 0.4rem;
    border-radius: var(--radius-pill);
    gap: 0.5rem;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.04);
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    /* Hide scrollbar for cleaner look */
}

.pill-menu::-webkit-scrollbar {
    display: none;
}

.pill-link {
    padding: 0.6rem 1.8rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-secondary);
    transition: 0.3s;
}

.pill-link:hover {
    color: var(--text-main);
}

.pill-link.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    transform: scale(1.02);
}

/* Header UI Elements */
.header-actions {
    grid-column: 3;
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.search-pill {
    background: white;
    border-radius: var(--radius-pill);
    padding: 0.6rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    box-shadow: var(--shadow-soft);
    width: 220px;
    transition: width 0.3s ease, box-shadow 0.2s;
}

.search-pill:focus-within {
    width: 280px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.search-pill input {
    border: none;
    background: transparent;
    font-size: 0.9rem;
    width: 100%;
    font-family: inherit;
    font-weight: 500;
    color: var(--text-main);
}

.search-pill input:focus {
    outline: none;
}

.circle-btn {
    width: 44px;
    height: 44px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
    box-shadow: var(--shadow-soft);
    cursor: pointer;
    transition: 0.2s;
}

.circle-btn:hover {
    transform: translateY(-2px);
    color: var(--primary);
}

/* Dashboard Cards - "The Clay Look" */
.content-grid {
    display: grid;
    grid-template-columns: 2fr 1.2fr;
    gap: 2rem;
}

.clay-card {
    background: var(--bg-surface);
    border-radius: var(--radius-card);
    padding: 2rem;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
}

.clay-card h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.2rem;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

/* Stats Row */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-bubble-card {
    background: white;
    border-radius: 28px;
    padding: 1.5rem;
    box-shadow: var(--shadow-soft);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.2s;
}

.stat-bubble-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-floating);
}

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

.stat-info .value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.1;
}

.stat-info .label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Status Colors */
.primary-light {
    background: #EEF2FF;
    color: #4F46E5;
}

.blue-light {
    background: #EFF6FF;
    color: #3B82F6;
}

.green-light {
    background: #ECFDF5;
    color: #10B981;
}

.red-light {
    background: #FEF2F2;
    color: #EF4444;
}

.amber-light {
    background: #FFFBEB;
    color: #F59E0B;
}

/* Tables */
.soft-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 0.8rem;
    /* Space between rows */
}

.soft-table th {
    text-align: left;
    padding: 0 1rem;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.soft-table td {
    background: #f8fafc;
    /* Slightly different from card bg */
    padding: 1.25rem 1rem;
    font-weight: 600;
    color: var(--text-main);
}

.soft-table td:first-child {
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
}

.soft-table td:last-child {
    border-top-right-radius: 16px;
    border-bottom-right-radius: 16px;
}

.soft-table tr:hover td {
    background: #f1f5f9;
    transform: scale(1.01);
    transition: 0.2s;
}

/* User Avatar Stack */
.avatar-stack {
    display: flex;
}

.avatar-stack img,
.avatar-stack .placeholder {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 3px solid white;
    margin-left: -10px;
    background: #ddd;
}

.avatar-stack .placeholder:first-child {
    margin-left: 0;
}

/* Buttons */
.btn-pill {
    padding: 0.8rem 1.6rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: 0.2s;
}

.btn-black {
    background: var(--primary);
    color: white;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.btn-black:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.3);
}

.btn-outline {
    background: white;
    border: 2px solid #e2e8f0;
    color: var(--text-main);
}

.btn-outline:hover {
    border-color: var(--text-main);
}

/* Badges */
.status-pill {
    padding: 0.4rem 1rem;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 700;
}

.status-pill.success {
    background: #dcfce7;
    color: #166534;
}

.status-pill.warning {
    background: #fef3c7;
    color: #92400e;
}

.status-pill.danger {
    background: #fee2e2;
    color: #991b1b;
}

/* NOTE: Responsive styles are handled by mobile.css */

/* --- Residences Page Specifics --- */
.header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.action-btn-pill {
    background: var(--primary);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: var(--radius-pill);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.action-btn-pill:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    color: white;
}

.empty-state-card {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-soft);
}

.empty-icon-bubble {
    width: 80px;
    height: 80px;
    background: var(--bg-body);
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--text-secondary);
}

.residences-grid-soft {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

.residence-card-soft {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.residence-card-soft:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.1);
}

.res-card-header {
    height: 120px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.res-logo-floating {
    width: 80px;
    height: 80px;
    background: white;
    border-radius: 20px;
    padding: 10px;
    object-fit: contain;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    position: absolute;
    bottom: -30px;
}

.res-icon-placeholder {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    padding: 10px;
    position: absolute;
    bottom: -30px;
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.res-card-body {
    padding: 3rem 1.5rem 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.res-name {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.4rem;
    font-weight: 700;
}

.res-meta-stack {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
}

.res-meta-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    padding: 0.5rem;
    background: #f8fafc;
    border-radius: 12px;
}

.res-meta-item ion-icon {
    font-size: 1.2rem;
    color: var(--accent-blue);
}

.res-actions-divider {
    height: 1px;
    background: #e2e8f0;
    margin-bottom: 1rem;
    margin-top: auto;
}

.res-card-actions {
    display: flex;
    justify-content: space-around;
}

.icon-btn-soft {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: 0.2s;
    background: transparent;
    font-size: 1.2rem;
}

.icon-btn-soft:hover {
    background: #f1f5f9;
    color: var(--primary);
    transform: scale(1.1);
}

.icon-btn-soft.danger:hover {
    background: #fee2e2;
    color: #ef4444;
}

/* Animations */
.fade-in {
    animation: fadeIn 0.5s ease;
}

.fade-in-up {
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Rooms Page Specifics --- */
.filter-pills-row {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
}

.filter-pill {
    background: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-pill);
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-soft);
    transition: 0.2s;
    white-space: nowrap;
}

.filter-pill.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(16, 20, 26, 0.2);
}

.filter-pill:hover:not(.active) {
    transform: translateY(-2px);
    background: #f8fafc;
}

.rooms-grid-soft {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.room-card-soft {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: white;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.5);
    /* subtle border */
}

.room-card-soft:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.room-status-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Reusing stats colors but for backgrounds */
.status-available {
    background: #10B981;
}

.status-occupied {
    background: #F59E0B;
}

.status-maintenance {
    background: #EF4444;
}

.room-content {
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.room-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
    letter-spacing: -1px;
}

.room-type {
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

.room-pricing {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.price-tag {
    background: #f1f5f9;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.price-tag span {
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 700;
}

.price-tag.monthly {
    background: #EEF2FF;
    color: #4F46E5;
}

.room-actions-hover {
    margin-top: auto;
    display: flex;
    justify-content: center;
    gap: 1rem;
    opacity: 0.6;
    transition: 0.2s;
    border-top: 1px solid #f1f5f9;
    padding-top: 1rem;
}

.room-card-soft:hover .room-actions-hover {
    opacity: 1;
}

/* --- Utilities --- */
.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-end {
    justify-content: flex-end;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.text-sm {
    font-size: 0.85rem;
}

.font-bold {
    font-weight: 700;
}

.text-primary {
    color: var(--text-main);
}

/* .text-secondary is already used as a variable, but as a class it is useful too */
.text-secondary-color {
    color: var(--text-secondary);
}

/* --- Clients Page --- */
.avatar-circle {
    width: 40px;
    height: 40px;
    background: #e0e7ff;
    color: #4338ca;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
}

.id-badge {
    background: #f1f5f9;
    padding: 0.2rem 0.6rem;
    border-radius: 6px;
    font-family: monospace;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* --- Forms --- */
.form-group {
    margin-bottom: 1.5rem;
}

.grid .form-group {
    margin-bottom: 0;
    /* Let grid gap handle spacing here */
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    color: var(--text-main);
    font-weight: 600;
}

.form-control {
    width: 100%;
    padding: 0.8rem 1.2rem;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    font-family: inherit;
    font-size: 0.95rem;
    color: var(--text-main);
    background: #f8fafc;
    transition: 0.2s;
    height: 48px;
    /* Fixed height for consistency */
}

.form-control:focus {
    border-color: var(--accent-blue);
    background: white;
    box-shadow: 0 0 0 4px rgba(131, 162, 219, 0.1);
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2em;
    padding-right: 2.5rem;
}

/* --- Color Utilities (Light/Pastel) --- */
.blue-light {
    background: #eff6ff;
    color: #2563eb;
}

.green-light {
    background: #f0fdf4;
    color: #16a34a;
}

.amber-light {
    background: #fffbeb;
    color: #d97706;
}

.red-light {
    background: #fef2f2;
    color: #dc2626;
}

.bg-gray-100 {
    background: #f3f4f6;
}

.bg-red-50 {
    background: #fef2f2;
}

.text-gray-600 {
    color: #4b5563;
}

.text-red-400 {
    color: #f87171;
}

.text-danger {
    color: #dc2626;
}

/* --- Invoices Page --- */
.filter-grid {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.filter-grid .col {
    flex: 1;
    min-width: 150px;
}

.filter-grid .col.actions {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.action-btn-pill.small {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
}

.btn-text {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-text:hover {
    color: var(--text-main);
    text-decoration: underline;
}

.status-pill {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
}

/* --- Reports Page --- */
.hover-lift {
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-floating);
}

.row-flex {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
}

.flex-grow {
    flex: 1;
}

.badge-count {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 700;
}

.export-list {
    display: flex;
    flex-direction: column;
}

.export-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
}

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

.action-btn-pill.simple {
    background: transparent;
    color: var(--text-main);
    box-shadow: none;
    border: 1px solid #e2e8f0;
}

.action-btn-pill.simple:hover {
    background: #f8fafc;
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
}

/* --- Core Layout (Matches View Classes) --- */
.dashboard-layout {
    display: flex;
    min-height: 100vh;
    padding: 1.5rem;
    gap: 2rem;
    position: relative;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    width: 0;
    /* Flexbox trick to prevent overflow */
    gap: 1.5rem;
}

/* Ensure tables don't overflow parent */
.table-responsive {
    overflow-x: auto;
    border-radius: 1rem;
}

/* --- Reports Layout Fixes --- */
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* --- Reports Layout Fixes --- */
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-bubble-card .value.small {
    font-size: 1.25rem;
    /* Smaller than the main dashboard stats */
    font-weight: 700;
    color: var(--text-main);
}

/* --- Spacing Utilities --- */
.mb-6 {
    margin-bottom: 2rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.text-right {
    text-align: right;
}

/* ========================================
   SIDEBAR STYLES (Desktop Default)
   ======================================== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-surface);
    border-radius: var(--radius-pill);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.5rem 0;
    gap: 0;
    box-shadow: var(--shadow-soft);
    position: sticky;
    top: 1.5rem;
    height: calc(100vh - 3rem);
    z-index: 100;
    overflow: hidden;
    flex-shrink: 0;
    scrollbar-width: none;
}

.sidebar::-webkit-scrollbar {
    display: none;
}

.logo-bubble {
    width: 48px;
    height: 48px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
}

.nav-item {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: transparent;
    font-size: 1.4rem;
    position: relative;
    flex-shrink: 0;
}

.nav-item:last-child {
    margin-bottom: 0;
}

.nav-item:hover {
    background: rgba(0, 0, 0, 0.04);
    transform: scale(1.1);
    color: var(--primary);
}

/* Disable scale on mobile/touch - text must remain readable */
@media (max-width: 640px),
(hover: none) {
    .nav-item:hover {
        transform: none;
        background: rgba(99, 102, 241, 0.06);
    }

    .nav-item:active {
        background: rgba(99, 102, 241, 0.12);
    }
}

.nav-item.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.nav-item.active::after {
    display: none;
}