/* ===== MAIN CONTENT ===== */
.main-content {
    flex: 1;
    padding: 2rem 2.5rem;
    background: #f4f7fc;
    min-height: 100vh;
}

/* ===== PAGE HEADER ===== */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #0b1a33;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin: 0;
}

.page-header h2 i {
    color: #2563eb;
}

.page-subtitle {
    color: #64748b;
    margin: 0.2rem 0 0 2.5rem;
    font-size: 0.95rem;
}

.header-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.btn-primary {
    background: #2563eb;
    color: white;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-primary:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
    color: white;
    text-decoration: none;
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #e2e8f0;
    color: #0b1a33;
}

.btn-close-list {
    background: #fee2e2;
    color: #991b1b;
    border: none;
    padding: 0.4rem 1rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-close-list:hover {
    background: #991b1b;
    color: white;
}

/* ===== SEARCH SECTION ===== */
.search-section {
    margin-bottom: 2rem;
}

.search-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: white;
    padding: 0.3rem;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    border: 1.5px solid #e2e8f0;
    transition: all 0.2s;
    flex-wrap: wrap;
}

.search-wrapper:focus-within {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.search-icon {
    color: #94a3b8;
    padding-left: 1rem;
    font-size: 1rem;
}

.search-input {
    flex: 1;
    padding: 0.7rem 0.5rem;
    border: none;
    outline: none;
    font-size: 0.95rem;
    background: transparent;
    color: #0b1a33;
    min-width: 200px;
}

.search-input::placeholder {
    color: #94a3b8;
}

.btn-search {
    background: #2563eb;
    color: white;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-search:hover {
    background: #1d4ed8;
}

.btn-clear {
    background: #f1f5f9;
    color: #475569;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 12px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-clear:hover {
    background: #e2e8f0;
    color: #0b1a33;
    text-decoration: none;
}

/* ===== COMPACT OVERVIEW CONTAINER ===== */
.overview-container {
    background: white;
    border-radius: 16px;
    padding: 1rem 1.25rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.2s;
}

.overview-container:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.overview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.overview-header h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: #0b1a33;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.overview-header h3 i {
    color: #2563eb;
    font-size: 0.9rem;
}

.total-assets {
    font-size: 0.85rem;
    color: #64748b;
}

.total-assets strong {
    color: #0b1a33;
    font-size: 0.95rem;
}

/* ===== COMPACT CATEGORY GRID ===== */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 0.6rem;
}

.category-card {
    background: #f8fafc;
    border-radius: 10px;
    padding: 0.6rem 0.75rem;
    border-left: 3px solid #2563eb;
    transition: all 0.15s;
}

.category-card:hover {
    background: #f1f5f9;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.3rem;
}

.category-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: #0b1a33;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.category-total {
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    background: white;
    padding: 0.05rem 0.5rem;
    border-radius: 10px;
}

.category-statuses {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.7rem;
    padding: 0.05rem 0.3rem;
    border-radius: 4px;
    background: white;
    border-left: 2px solid #e2e8f0;
}

.status-item .status-icon {
    font-size: 0.7rem;
    width: 1rem;
    text-align: center;
}

.status-item .status-label {
    flex: 1;
    color: #1e293b;
    font-weight: 500;
}

.status-item .status-count {
    font-weight: 700;
    color: #0b1a33;
    font-size: 0.75rem;
}

/* Status Colors */
.status-item.status-new {
    border-left-color: #22c55e;
}
.status-item.status-new .status-label {
    color: #166534;
}

.status-item.status-old {
    border-left-color: #eab308;
}
.status-item.status-old .status-label {
    color: #92400e;
}

.status-item.status-damaged {
    border-left-color: #ef4444;
}
.status-item.status-damaged .status-label {
    color: #991b1b;
}

.status-item.status-for-sale {
    border-left-color: #3b82f6;
}
.status-item.status-for-sale .status-label {
    color: #1e40af;
}

.status-item.status-for-repair {
    border-left-color: #8b5cf6;
}
.status-item.status-for-repair .status-label {
    color: #6d28d9;
}

.status-item.status-default {
    border-left-color: #94a3b8;
}
.status-item.status-default .status-label {
    color: #475569;
}

/* ===== TABLE ===== */
.table-container {
    background: white;
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    overflow-x: auto;
    animation: slideDown 0.3s ease;
}

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

.table-header-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #f1f5f9;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.record-count {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
}

.assets-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.assets-table thead {
    background: #f8fafc;
}

.assets-table th {
    text-align: left;
    padding: 0.9rem 1rem;
    font-weight: 600;
    color: #475569;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e2e8f0;
}

.assets-table td {
    padding: 0.9rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    color: #1e293b;
}

.assets-table tbody tr:hover {
    background: #f8fafc;
}

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

/* ===== BADGES ===== */
.asset-tag {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: #2563eb;
    background: #eff6ff;
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
}

.category-badge {
    background: #f1f5f9;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    color: #475569;
}

.asset-description {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.brand-name {
    font-weight: 500;
    color: #0b1a33;
}

.spec-preview {
    font-size: 0.8rem;
    color: #94a3b8;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.status-dot {
    font-size: 0.5rem;
}

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

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

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

.status-for-sale {
    background: #dbeafe;
    color: #1e40af;
}

.status-for-repair {
    background: #fce7f3;
    color: #9d174d;
}

.company-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
}

.company-nebg {
    background: #dcfce7;
    color: #166534;
}

.company-fa {
    background: #dbeafe;
    color: #1e40af;
}

.company-n\\/a {
    background: #f1f5f9;
    color: #64748b;
}

/* ===== ACTION BUTTONS ===== */
.action-buttons {
    display: flex;
    gap: 0.3rem;
    align-items: center;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.15s;
    text-decoration: none;
    font-size: 0.85rem;
}

.btn-view {
    background: #eff6ff;
    color: #2563eb;
}

.btn-view:hover {
    background: #2563eb;
    color: white;
}

.btn-edit {
    background: #fef3c7;
    color: #92400e;
}

.btn-edit:hover {
    background: #92400e;
    color: white;
}

.btn-delete {
    background: #fee2e2;
    color: #991b1b;
}

.btn-delete:hover {
    background: #991b1b;
    color: white;
}

/* ===== PAGINATION ===== */
.pagination-wrapper {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
}

.pagination-wrapper nav {
    display: flex;
    justify-content: center;
}

.pagination-wrapper .pagination {
    display: flex;
    gap: 0.3rem;
    list-style: none;
    padding: 0;
}

.pagination-wrapper .pagination li a,
.pagination-wrapper .pagination li span {
    padding: 0.5rem 0.9rem;
    border-radius: 8px;
    color: #475569;
    text-decoration: none;
    transition: all 0.15s;
    border: 1px solid #e2e8f0;
    background: white;
}

.pagination-wrapper .pagination li a:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
}

.pagination-wrapper .pagination li.active span {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}

.pagination-wrapper .pagination li.disabled span {
    color: #94a3b8;
    cursor: not-allowed;
    opacity: 0.6;
}

/* ===== EMPTY STATES ===== */
.empty-overview {
    text-align: center;
    padding: 1.5rem;
    color: #94a3b8;
}

.empty-overview i {
    font-size: 2rem;
    color: #cbd5e1;
    margin-bottom: 0.3rem;
}

.empty-overview p {
    font-size: 0.9rem;
    margin: 0;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
}

.empty-state i {
    font-size: 4rem;
    color: #cbd5e1;
    margin-bottom: 1rem;
}

.empty-state p {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.empty-subtext {
    font-size: 0.95rem;
    color: #94a3b8;
    margin-bottom: 1.5rem;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .search-wrapper {
        flex-direction: column;
        align-items: stretch;
        padding: 0.75rem;
    }

    .search-icon {
        display: none;
    }

    .search-input {
        min-width: auto;
        padding: 0.6rem;
        border: 1px solid #e2e8f0;
        border-radius: 8px;
        background: #f9fafc;
    }

    .btn-search,
    .btn-clear {
        width: 100%;
        justify-content: center;
    }

    .header-actions {
        width: 100%;
        flex-direction: column;
    }

    .header-actions .btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 1.2rem 1rem;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-subtitle {
        margin-left: 0;
    }

    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .overview-container {
        padding: 0.8rem 1rem;
    }

    .table-container {
        padding: 0.8rem;
    }

    .assets-table {
        font-size: 0.85rem;
    }

    .assets-table th,
    .assets-table td {
        padding: 0.6rem 0.5rem;
    }

    .action-buttons {
        flex-direction: row;
        gap: 0.2rem;
    }

    .btn-action {
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    .category-grid {
        grid-template-columns: 1fr 1fr;
    }

    .table-header-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }

    .assets-table th:nth-child(4),
    .assets-table td:nth-child(4),
    .assets-table th:nth-child(6),
    .assets-table td:nth-child(6) {
        display: none;
    }
}