/* Custom CSS for Property Management System */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --info-color: #0dcaf0;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 70vh;
    display: flex;
    align-items: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.25rem;
}

.card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: box-shadow 0.15s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.card-header {
    background-color: transparent;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
    font-weight: 600;
}

.btn {
    border-radius: 6px;
    font-weight: 500;
    padding: 0.5rem 1rem;
}

.btn-group-sm .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.table {
    background-color: white;
}

.table th {
    border-top: none;
    font-weight: 600;
    color: #495057;
    background-color: #f8f9fa;
}

.badge {
    font-size: 0.75em;
    font-weight: 500;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.invalid-feedback {
    font-size: 0.875em;
}

.alert {
    border: none;
    border-radius: 8px;
}

.navbar-nav .nav-link {
    font-weight: 500;
    transition: color 0.15s ease-in-out;
}

.navbar-nav .nav-link:hover {
    color: rgba(255, 255, 255, 0.8) !important;
}

.dropdown-menu {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.175);
    border-radius: 8px;
}

.modal-content {
    border: none;
    border-radius: 10px;
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
}

/* Dashboard specific styles */
.dashboard-card {
    transition: transform 0.2s ease-in-out;
}

.dashboard-card:hover {
    transform: translateY(-2px);
}

.stats-card {
    background: linear-gradient(45deg, var(--primary-color), #495057);
    color: white;
    border-radius: 10px;
}

.stats-card .card-footer {
    background-color: rgba(0, 0, 0, 0.1);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.stats-card .card-footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
}

.stats-card .card-footer a:hover {
    color: white;
}

/* Custom form styles */
.form-floating > label {
    opacity: 0.65;
}

.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label {
    opacity: 1;
    color: var(--primary-color);
}

/* Loading spinner */
.spinner-border {
    width: 1rem;
    height: 1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-section {
        min-height: 50vh;
        text-align: center;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .btn-group-sm .btn {
        padding: 0.2rem 0.4rem;
        font-size: 0.8rem;
    }
    
    .table-responsive {
        font-size: 0.9rem;
    }
}

/* Premium dark navbar */
.bg-gradient-primary {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2) !important;
    border-bottom: 1px solid #34495e !important;
}

/* Navbar brand icon styling */
.navbar-brand-icon {
    width: 42px !important;
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%) !important;
    border-radius: 10px !important;
    margin-right: 1rem !important;
    transition: all 0.3s ease !important;
    border: 2px solid #ecf0f1 !important;
    box-shadow: 0 3px 10px rgba(231, 76, 60, 0.3) !important;
}

.navbar-brand-icon:hover {
    transform: translateY(-2px) scale(1.05) !important;
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.4) !important;
    background: linear-gradient(135deg, #c0392b 0%, #e74c3c 100%) !important;
}

.navbar-brand-icon i {
    font-size: 1.3rem !important;
    color: white !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3) !important;
}

/* Compact navigation styles */
.nav-link-compact {
    font-size: 0.8rem !important;
    padding: 0.3rem 0.5rem !important;
    white-space: normal !important;
    line-height: 1.2 !important;
    text-align: center !important;
    margin: 0 0.1rem !important;
    border-radius: 6px !important;
    transition: all 0.2s ease !important;
    color: #ecf0f1 !important;
    min-height: 40px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
}

.nav-link-compact:hover {
    background-color: rgba(52, 73, 94, 0.7) !important;
    transform: translateY(-1px);
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
}

.nav-link-compact i {
    font-size: 0.8rem;
    margin-bottom: 0.1rem !important;
    margin-right: 0 !important;
    display: block !important;
}

/* Multi-line text for longer menu items */
.nav-link-multiline {
    font-size: 0.7rem !important;
    line-height: 1.1 !important;
}

/* Make navbar more compact on all screens */
.navbar-nav .nav-item {
    margin-right: 0.05rem;
}

.navbar {
    padding: 0.4rem 1rem !important;
}

/* Ultra compact for smaller screens */
@media (max-width: 1400px) {
    .nav-link-compact {
        font-size: 0.75rem !important;
        padding: 0.25rem 0.4rem !important;
        min-height: 38px !important;
    }
    
    .nav-link-multiline {
        font-size: 0.65rem !important;
    }
    
    .nav-link-compact i {
        font-size: 0.75rem;
    }
}

@media (max-width: 1200px) {
    .nav-link-compact {
        font-size: 0.7rem !important;
        padding: 0.2rem 0.35rem !important;
        min-height: 36px !important;
    }
    
    .nav-link-multiline {
        font-size: 0.6rem !important;
    }
    
    .navbar-brand-icon {
        width: 38px !important;
        height: 38px !important;
        margin-right: 0.8rem !important;
    }
    
    .navbar-brand-icon i {
        font-size: 1.1rem !important;
    }
}

@media (max-width: 992px) {
    .nav-link-compact {
        font-size: 0.65rem !important;
        padding: 0.2rem 0.3rem !important;
        min-height: 34px !important;
    }
    
    .nav-link-multiline {
        font-size: 0.55rem !important;
    }
    
    .navbar-brand-icon {
        width: 35px !important;
        height: 35px !important;
        margin-right: 0.6rem !important;
    }
    
    .navbar-brand-icon i {
        font-size: 1rem !important;
    }
}

/* Animation for page transitions */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Status badges */
.badge.bg-success {
    background-color: var(--success-color) !important;
}

.badge.bg-warning {
    background-color: var(--warning-color) !important;
    color: var(--dark-color) !important;
}

.badge.bg-danger {
    background-color: var(--danger-color) !important;
}

.badge.bg-info {
    background-color: var(--info-color) !important;
    color: var(--dark-color) !important;
}

.badge.bg-secondary {
    background-color: var(--secondary-color) !important;
}

/* Automata Powered By Footer */
.automata-footer {
    margin-top: 3rem;
    padding: 1rem 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-top: 1px solid #dee2e6;
    position: relative;
    overflow: hidden;
}

.automata-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(13, 110, 253, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(102, 126, 234, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.automata-powered {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.875rem;
    color: #6c757d;
    letter-spacing: 0.5px;
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 400;
}

.automata-powered strong {
    font-weight: 600;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.automata-powered:hover {
    transform: translateY(-1px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.automata-footer:hover .automata-powered {
    background: linear-gradient(135deg, #5a67d8, #667eea);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Responsive adjustments for Automata footer */
@media (max-width: 768px) {
    .automata-footer {
        margin-top: 2rem;
        padding: 0.75rem 0;
    }
    
    .automata-powered {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .automata-powered {
        font-size: 0.75rem;
        letter-spacing: 0.3px;
    }
}
