/* css/style.css */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #7e22ce;
    --light: #f8fafc;
    --dark: #0f172a;
    --gray: #64748b;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f1f5f9;
    color: var(--dark);
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header y navegación */
header {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
}

.logo-icon {
    background: white;
    color: var(--primary);
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    transition: var(--transition);
}

nav a:hover {
    color: #e2e8f0;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: white;
    transition: var(--transition);
}

nav a:hover::after {
    width: 100%;
}

nav a.active {
    font-weight: 700;
}

nav a.active::after {
    width: 100%;
}

/* Hero section */
.hero {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('https://placehold.co/1200x600/2563eb/white?text=Inversi%C3%B3n+Inmobiliaria') no-repeat center center;
    background-size: cover;
    color: white;
    padding: 6rem 0;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero h1 span {
    color: #93c5fd;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid var(--primary);
    cursor: pointer;
}

.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    margin-left: 1rem;
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

/* Formularios */
.form-container {
    max-width: 500px;
    margin: 3rem auto;
    background: white;
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
}

.form-title {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.75rem;
    color: var(--dark);
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark);
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    margin: 0.5rem 0;
}

.checkbox-group input {
    margin-right: 0.5rem;
    margin-top: 0.25rem;
}

.checkbox-group label {
    margin-bottom: 0;
}

.btn-block {
    width: 100%;
    padding: 0.875rem;
    font-size: 1.125rem;
}

/* Tarjetas de propiedades */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.property-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1);
}

.property-header {
    padding: 1.5rem 1.5rem 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.property-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.property-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.status-exclusive {
    background: rgba(126, 34, 206, 0.1);
    color: var(--secondary);
}

.status-premium {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
}

.property-location {
    display: flex;
    align-items: center;
    color: var(--gray);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.property-description {
    color: var(--gray);
    margin-bottom: 1.5rem;
    padding: 0 1.5rem;
}

.property-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    padding: 0 1.5rem 1.5rem;
}

.stat-item {
    text-align: center;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray);
    margin-bottom: 0.25rem;
}

.stat-value {
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--dark);
}

/* Dashboard */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: var(--card-shadow);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.icon-blue {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
}

.icon-green {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.icon-purple {
    background: rgba(126, 34, 206, 0.1);
    color: var(--secondary);
}

.icon-orange {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.stat-info h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.stat-info p {
    color: var(--gray);
    font-weight: 500;
}

/* Tabla de clientes */
.table-container {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    margin: 2rem 0;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 1rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

th {
    background: #f8fafc;
    font-weight: 600;
    color: var(--dark);
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background: #f8fafc;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.badge-pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.commissioned-yes {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.commissioned-no {
    background: rgba(100, 116, 139, 0.1);
    color: var(--gray);
}

/* Footer */
footer {
    background: var(--dark);
    color: white;
    padding: 3rem 0 1.5rem;
    margin-top: 4rem;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 700;
}

.footer-logo-icon {
    background: var(--primary);
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.footer-text {
    color: #94a3b8;
    margin-bottom: 2rem;
    max-width: 600px;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
}

.copyright {
    color: #94a3b8;
    font-size: 0.9rem;
}

/* Mensajes de alerta */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border-left: 4px solid var(--success);
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    border-left: 4px solid var(--danger);
}

/* Nuevos badges para roles */
.badge-premium {
    background: rgba(251, 191, 36, 0.1);
    color: #d97706;
}

.badge-institutional {
    background: rgba(103, 232, 249, 0.1);
    color: #0891b2;
}

.badge-developer {
    background: rgba(34, 197, 94, 0.1);
    color: #15803d;
}

.badge-family {
    background: rgba(192, 132, 252, 0.1);
    color: #7e22ce;
}

.badge-agent {
    background: rgba(249, 115, 22, 0.1);
    color: #c2410c;
}

/* Utilidades */
.mr-2 {
    margin-right: 0.5rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.text-center {
    text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .hero h1 {
        font-size: 2.25rem;
    }
    
    .btn-secondary {
        margin-left: 0;
        margin-top: 1rem;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .property-stats {
        grid-template-columns: 1fr;
    }
    
    .properties-grid {
        grid-template-columns: 1fr;
    }
    
    table {
        font-size: 0.875rem;
    }
    
    th, td {
        padding: 0.75rem 1rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .logo {
        font-size: 1.25rem;
    }
    
    .logo-icon {
        width: 35px;
        height: 35px;
    }
    
    nav ul {
        gap: 1rem;
        font-size: 0.9rem;
    }
    
    .hero {
        padding: 4rem 0;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .form-container {
        padding: 1.5rem;
    }
    
    .btn {
        padding: 0.625rem 1.25rem;
        font-size: 0.9375rem;
    }
}