/* property.css - Professional Property Records System */
:root {
    --primary-blue: #1a56db;
    --primary-dark: #1e40af;
    --primary-light: #3b82f6;
    --secondary-color: #6b7280;
    --light-bg: #f9fafb;
    --card-bg: #ffffff;
    --border-color: #e5e7eb;
    --text-primary: #111827;
    --text-secondary: #4b5563;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --transition: all 0.2s ease-in-out;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--light-bg);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
}

/* Main Container - FIXED */
.container {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 1.5rem;
    width: 100%;
}

/* Page Header */
.container h1 {
    text-align: center;
    color: var(--primary-dark);
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--primary-light);
    font-size: 2rem;
    font-weight: 700;
}

/* Header Actions - Professional Layout */
.header-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    flex-wrap: wrap;
}

/* Search Container */
.search-container {
    flex: 1;
    min-width: 300px;
    display: flex;
    gap: 0.5rem;
}

.search-input {
    flex: 1;
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    transition: var(--transition);
    background: var(--light-bg);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-btn {
    padding: 0.875rem 2rem;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.search-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Export Button */
.export-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: #10b981;
    color: white;
    text-decoration: none;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-weight: 600;
    transition: var(--transition);
    white-space: nowrap;
}

.export-btn:hover {
    background: #0da271;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* Table Container - Professional Design */
.table-container {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    overflow: hidden;
    margin-bottom: 2rem;
}

.table-container table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1000px; /* Ensures all columns are visible on desktop */
}

.table-container thead {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-dark) 100%);
}

.table-container th {
    padding: 1rem 1.25rem;
    text-align: left;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1);
    white-space: nowrap;
}

.table-container td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
    font-size: 0.9375rem;
}

.table-container tbody tr {
    transition: var(--transition);
}

.table-container tbody tr:hover {
    background-color: #f8fafc;
}

.table-container tbody tr:nth-child(even) {
    background-color: #f9fafb;
}

.table-container tbody tr:nth-child(even):hover {
    background-color: #f3f4f6;
}

/* Column Widths for Better Layout */
.table-container th:nth-child(1),
.table-container td:nth-child(1) {
    width: 100px;
    text-align: center;
}

.table-container th:nth-child(2),
.table-container td:nth-child(2) {
    width: 120px;
}

.table-container th:nth-child(3),
.table-container td:nth-child(3) {
    width: 300px;
}

.table-container th:nth-child(4),
.table-container td:nth-child(4) {
    width: 150px;
}

.table-container th:nth-child(5),
.table-container td:nth-child(5) {
    width: 300px;
}

.table-container th:nth-child(6),
.table-container td:nth-child(6) {
    width: 120px;
}

.table-container th:nth-child(7),
.table-container td:nth-child(7) {
    width: 120px;
}

/* Photo Cell */
.photo-cell {
    text-align: center;
}

.property-photo {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: var(--radius-md);
    border: 2px solid var(--border-color);
    transition: var(--transition);
}

.property-photo:hover {
    transform: scale(1.1);
    border-color: var(--primary-blue);
}

.no-photo {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-bg);
    border-radius: var(--radius-md);
    border: 2px dashed var(--border-color);
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin: 0 auto;
}

/* Text Styles */
.table-container td:nth-child(3) {
    font-weight: 600;
    color: var(--text-primary);
}

.table-container td:nth-child(4) {
    font-family: 'SF Mono', Monaco, Consolas, monospace;
    color: var(--text-primary);
}

/* No Data Message */
.no-data {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
    font-size: 1.125rem;
    background: var(--light-bg);
    border-radius: var(--radius-lg);
    margin: 2rem 0;
}

.no-data i {
    font-size: 3rem;
    color: #d1d5db;
    margin-bottom: 1rem;
    display: block;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .container {
        padding: 0 1rem;
        margin: 1rem auto;
    }
    
    .header-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-container {
        min-width: 100%;
    }
    
    .export-btn {
        align-self: flex-start;
    }
}

@media (max-width: 768px) {
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: var(--radius-md);
    }
    
    .table-container table {
        min-width: 1000px; /* Keeps all columns accessible on mobile via scroll */
    }
    
    .container h1 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }
    
    .search-input,
    .search-btn,
    .export-btn {
        font-size: 0.875rem;
        padding: 0.75rem 1rem;
    }
    
    .table-container th,
    .table-container td {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
    
    .property-photo,
    .no-photo {
        width: 50px;
        height: 50px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 0.75rem;
    }
    
    .header-actions {
        padding: 1rem;
    }
    
    .search-container {
        flex-direction: column;
    }
    
    .search-btn {
        width: 100%;
    }
}

/* Print Styles */
@media print {
    .header-actions,
    .search-container,
    .export-btn {
        display: none;
    }
    
    .table-container {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .table-container th {
        background: #f1f5f9 !important;
        color: #000 !important;
        -webkit-print-color-adjust: exact;
    }
    
    body {
        background: white !important;
    }
    
    .container {
        margin: 0;
        padding: 0;
        max-width: 100%;
    }
}

/* Loading Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.table-container tbody tr {
    animation: fadeIn 0.3s ease-out;
}

/* Status Indicators (Optional - Add if needed) */
.status-active,
.status-inactive {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-active {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.status-inactive {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.bold {
    font-weight: 600;
}

.mono {
    font-family: 'SF Mono', Monaco, Consolas, monospace;
}