/* ===========================================
   PRIME CONTRACTORS - CSS MEJORADO Y RESPONSIVO
   =========================================== */

/* Variables CSS mejoradas del index_mejorado.html */
:root {
    --prime-yellow: #FFAA00;
    --prime-earth: #E2853D;
    --prime-onyx: #434343;
    --prime-night: #1E1E1E;
    
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --info: #3B82F6;
    
    --white: #FFFFFF;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    
    --gradient-primary: linear-gradient(135deg, var(--prime-yellow) 0%, var(--prime-earth) 100%);
    --gradient-dark: linear-gradient(135deg, var(--prime-onyx) 0%, var(--prime-night) 100%);
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--gray-900);
    background-color: var(--gray-50);
}

/* LAYOUT PRINCIPAL */
.app {
    display: flex;
    min-height: 100vh;
}

/* SIDEBAR MEJORADO */
.sidebar {
    width: 280px;
    background: var(--gradient-dark);
    color: var(--white);
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-xl);
    position: fixed;
    height: 100vh;
    z-index: 1000;
    transform: translateX(0);
    transition: transform var(--transition);
}

.sidebar.hidden {
    transform: translateX(-100%);
}

.sidebar-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

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

.logo-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.logo-text .prime {
    font-size: 1.25rem;
    font-weight: 700;
    display: block;
}

.logo-text .sub {
    font-size: 0.75rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* NAVEGACIÓN */
.nav-section {
    padding: 1rem 0;
}

.nav-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--gray-400);
    padding: 0 1.5rem 0.75rem;
    letter-spacing: 0.05em;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: var(--gray-300);
    text-decoration: none;
    transition: all var(--transition);
    border-left: 3px solid transparent;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 0.875rem;
}

.nav-item:hover {
    color: var(--white);
    background: rgba(255, 255, 255, 0.05);
    border-left-color: var(--prime-yellow);
}

.nav-item.active {
    color: var(--prime-yellow);
    background: rgba(255, 170, 0, 0.1);
    border-left-color: var(--prime-yellow);
}

.nav-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    margin-left: 280px;
    transition: margin-left var(--transition);
    min-height: 100vh;
    background: var(--gray-50);
}

.main-content.expanded {
    margin-left: 0;
}

/* HEADER */
.header {
    background: var(--white);
    padding: 1rem 2rem;
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sidebar-toggle {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray-600);
    padding: 0.5rem;
    border-radius: 8px;
    transition: all var(--transition);
}

.sidebar-toggle:hover {
    background: var(--gray-100);
    color: var(--prime-yellow);
}

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: var(--gray-100);
    border-radius: 25px;
}

.user-avatar {
    width: 32px;
    height: 32px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-weight: 600;
    font-size: 0.875rem;
}

.user-details {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-900);
    line-height: 1;
}

.user-role {
    font-size: 0.75rem;
    color: var(--gray-500);
}

.logout-btn {
    background: none;
    border: none;
    color: var(--gray-600);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all var(--transition);
}

.logout-btn:hover {
    background: var(--gray-100);
    color: var(--danger);
}

/* CONTENT AREA */
.content {
    padding: 2rem;
}

.section {
    display: none;
}

.section.active {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

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

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

@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

.stat-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all var(--transition);
    border-left: 4px solid var(--prime-yellow);
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Estilos específicos para las nuevas tarjetas de contratos */
.stat-card.contracts-approved {
    border-left-color: #10b981;
}

.stat-card.contracts-approved:hover {
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.15);
}

.stat-card.contracts-contractors {
    border-left-color: #3b82f6;
}

.stat-card.contracts-contractors:hover {
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.15);
}

.stat-card.contracts-pending {
    border-left-color: #f59e0b;
}

.stat-card.contracts-pending:hover {
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.15);
}

.stat-icon {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

/* Iconos específicos para contratos */
.contracts-approved .stat-icon {
    background: linear-gradient(135deg, #10b981, #059669);
}

.contracts-contractors .stat-icon {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.contracts-pending .stat-icon {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.stat-info {
    flex: 1;
}

.stat-number {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--gray-900);
    line-height: 1;
}

/* Números con colores específicos para contratos */
.contracts-approved .stat-number {
    color: #059669;
}

.contracts-contractors .stat-number {
    color: #1d4ed8;
}

.contracts-pending .stat-number {
    color: #d97706;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray-600);
    margin-top: 0.25rem;
    font-weight: 600;
}

.stat-trend {
    font-size: 0.75rem;
    color: var(--success);
    margin-top: 0.25rem;
    font-weight: 500;
}

/* CARDS */
.card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    margin-bottom: 2rem;
}

.card-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var (--gray-900);
}

.card-body {
    padding: 1.5rem;
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: left var(--transition);
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--white);
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
    border-radius: 8px;
    font-size: 0.875rem;
    padding: 0.625rem 1.25rem;
    font-weight: 500;
}

.btn-secondary:hover {
    background: var(--gray-50);
    border-color: var(--gray-400);
    color: var(--gray-800);
}

.btn-success {
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    color: var(--white);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, #DC2626 100%);
    color: var(--white);
}

.btn-warning {
    background: linear-gradient(135deg, var(--warning) 0%, #D97706 100%);
    color: var(--white);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
}

/* PROJECTS GRID */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.project-card {
    background: var(--white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition);
    cursor: pointer;
    position: relative;
    border: 1px solid var(--gray-200);
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.project-header {
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--gray-50) 0%, var(--white) 100%);
}

.project-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.project-category {
    display: inline-block;
    background: var(--gradient-primary);
    color: var(--white);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.project-body {
    padding: 1.5rem;
}

.project-description {
    color: var(--gray-600);
    margin-bottom: 1rem;
    font-size: 0.875rem;
    line-height: 1.5;
}

.project-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.project-detail {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.detail-label {
    font-size: 0.75rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.detail-value {
    font-weight: 600;
    color: var(--gray-900);
    font-size: 0.875rem;
}

.project-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-top: 1px solid var(--gray-200);
    background: var(--gray-50);
}

.project-budget {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--prime-yellow);
}

/* CONTRACTORS GRID */
.contractors-grid {
    display: grid;
    gap: 1.5rem;
}

.contractor-card {
    background: var(--white);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: all var(--transition);
    border-left: 4px solid var(--prime-earth);
}

.contractor-card:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-lg);
}

.contractor-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.contractor-avatar {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--white);
}

.contractor-info {
    flex: 1;
}

.contractor-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.25rem;
}

.contractor-business {
    font-size: 0.875rem;
    color: var(--gray-600);
    margin-bottom: 0.25rem;
}

.contractor-email {
    font-size: 0.75rem;
    color: var(--gray-500);
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.status-pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.status-inactive {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

/* BIDS GRID */
.bids-grid {
    display: grid;
    gap: 1.5rem;
}

.bid-card {
    background: var(--white);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--prime-earth);
    transition: all var(--transition);
}

.bid-card:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-lg);
}

.bid-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.bid-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
}

.bid-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-submitted {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.status-accepted {
    background: rgba(16, 185, 129, 0.1);
    color: var (--success);
}

.status-rejected {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.bid-content {
    margin-bottom: 1rem;
}

.bid-amount {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1rem;
    background: var(--gray-50);
    border-radius: 12px;
}

.amount-label {
    font-size: 0.875rem;
    color: var(--gray-600);
}

.amount-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--prime-earth);
}

.bid-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bid-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-200);
}

.bid-date {
    font-size: 0.875rem;
    color: var(--gray-500);
}

.bid-actions {
    display: flex;
    gap: 0.5rem;
}

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

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 0.875rem;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--gray-300);
    border-radius: 10px;
    font-size: 0.875rem;
    transition: all var(--transition);
    background: var(--white);
}

.form-input:focus {
    outline: none;
    border-color: var(--prime-yellow);
    box-shadow: 0 0 0 3px rgba(255, 170, 0, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* MODALS - MEJORADOS */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    animation: fadeIn 0.3s ease-out;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 20px;
    max-width: 600px;
    width: 100%;
    max-height: 85vh;
    overflow: hidden;
    animation: slideInScale 0.3s ease-out;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--gray-200);
}

.modal-content.large {
    max-width: 900px;
}

@keyframes slideInScale {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(1rem);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 2.5rem 1.5rem 2.5rem;
    border-bottom: 1px solid var(--gray-200);
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: 20px 20px 0 0;
    position: relative;
}

.modal-header h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: var(--white);
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    font-weight: bold;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.modal-body {
    padding: 2.5rem;
    max-height: 65vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--gray-300) transparent;
}

.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: transparent;
}

.modal-body::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 3px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--gray-400);
}

.modal-footer {
    padding: 1.5rem 2.5rem 2rem 2.5rem;
    border-top: 1px solid var(--gray-200);
    background: var(--gray-50);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    border-radius: 0 0 20px 20px;
}

/* ESTILOS PARA FORMULARIOS EN MODALES */
.contractor-edit-form,
.contract-generation-form {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.form-sections {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-section {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 1.5rem;
    transition: border-color var(--transition);
}

.form-section:hover {
    border-color: var(--prime-yellow);
}

.form-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--prime-onyx);
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--gray-100);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--gray-700);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.875rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all var(--transition);
    background: var(--white);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--prime-yellow);
    box-shadow: 0 0 0 3px rgba(255, 170, 0, 0.1);
    transform: translateY(-1px);
}

.form-group small {
    color: var(--gray-500);
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* FORM ACTIONS STYLES */
.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-200);
}

.form-actions .btn {
    min-width: 120px;
}

/* SUCCESS MESSAGE STYLES */
.success-message {
    text-align: center;
    padding: 2rem 1rem;
}

.success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
}

.success-message h4 {
    color: var(--success);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.success-message p {
    color: var(--gray-600);
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.contract-details {
    background: var(--gray-50);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    text-align: left;
}

.contract-details strong {
    color: var(--prime-onyx);
    display: block;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.contract-details ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.contract-details li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contract-details li:last-child {
    border-bottom: none;
}

.contract-details li strong {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gray-700);
}

/* RESPONSIVE MODAL DESIGN */
@media (max-width: 768px) {
    .modal {
        padding: 1rem;
    }
    
    .modal-content {
        max-width: 100%;
        max-height: 95vh;
    }
    
    .modal-header {
        padding: 1.5rem 1.5rem 1rem 1.5rem;
    }
    
    .modal-header h3 {
        font-size: 1.25rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .modal-footer {
        padding: 1rem 1.5rem 1.5rem 1.5rem;
        flex-direction: column;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .form-section {
        padding: 1rem;
    }
}

/* NOTIFICATIONS */
.notification {
    position: fixed;
    top: 80px;
    right: 1rem;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-xl);
    z-index: 9999;
    transform: translateX(100%);
    opacity: 0;
    transition: all var(--transition);
    max-width: 320px;
    border-left: 4px solid var(--gray-400);
    overflow: hidden;
}

.notification.slide-in {
    transform: translateX(0);
    opacity: 1;
}

.notification.slide-out {
    transform: translateX(100%);
    opacity: 0;
}

.notification-success {
    border-left-color: var(--success);
}

.notification-error {
    border-left-color: var(--danger);
}

.notification-warning {
    border-left-color: var(--warning);
}

.notification-info {
    border-left-color: var(--info);
}

.notification-content {
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.notification-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.notification-message {
    flex: 1;
    font-weight: 500;
    color: var(--gray-800);
    font-size: 0.875rem;
}

.notification-close {
    background: none;
    border: none;
    color: var(--gray-400);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 6px;
    transition: all var(--transition);
    flex-shrink: 0;
}

.notification-close:hover {
    color: var(--gray-600);
    background: var(--gray-100);
}

/* ========================================
   PÁGINA COMPLETA DE CONTRATISTA
   ======================================== */

.contractor-page-wrapper {
  width: 100%;
  min-height: 100vh;
  background: #f8f9fa;
  overflow-x: hidden;
}

/* Navegación de regreso */
.page-navigation {
  background: white;
  border-bottom: 1px solid #e9ecef;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.back-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.page-breadcrumb {
  color: #ffffff;
  font-size: 0.9rem;
}

.page-breadcrumb span:last-child {
  color: #495057;
  font-weight: 500;
}

/* Header expandido del contratista */
.contractor-page-header {
  background: linear-gradient(135deg, #434343 0%, #555555 100%);
  color: white;
  padding: 2rem;
  margin-bottom: 0;
}

.contractor-hero-section {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 2rem;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}

.contractor-avatar-xl {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: bold;
  border: 4px solid rgba(255, 255, 255, 0.3);
}

.contractor-primary-info {
  flex: 1;
}

.contractor-name {
  font-size: 2.5rem;
  font-weight: bold;
  margin: 0 0 0.5rem 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.business-name {
  font-size: 1.5rem;
  font-weight: 300;
  margin: 0 0 1.5rem 0;
  opacity: 0.9;
}

.contact-info-expanded {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.contact-icon {
  font-size: 1.1rem;
}

.contact-text {
  font-size: 0.95rem;
  opacity: 0.9;
}

.contractor-status-section {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.status-indicator-large {
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-weight: bold;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.quick-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.contractor-stats-sidebar {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  min-width: 250px;
}

/* Navegación de pestañas */
.page-tabs-navigation {
  background: white;
  border-bottom: 1px solid #e9ecef;
  position: sticky;
  top: 73px;
  z-index: 99;
}

.tabs-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  overflow-x: auto;
  padding: 0 2rem;
}

.page-tab-btn {
  background: none;
  border: none;
  padding: 1rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: #ffffff;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.page-tab-btn:hover {
  color: #495057;
  background: #f8f9fa;
}

.page-tab-btn.active {
  color: #0066cc;
  border-bottom-color: #0066cc;
  background: rgba(0, 102, 204, 0.05);
}

/* Área de contenido */
.page-content-area {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.page-tab-panel {
  display: none;
}

.page-tab-panel.active {
  display: block;
}

/* Resumen (Overview) */
.overview-dashboard {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.overview-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 1px solid #e9ecef;
}

.overview-card h3 {
  margin: 0 0 1rem 0;
  color: #495057;
  font-size: 1.1rem;
  font-weight: 600;
}

.status-overview {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.status-indicator-xl {
  display: inline-block;
  padding: 1rem 2rem;
  border-radius: 50px;
  font-weight: bold;
  font-size: 1.1rem;
  text-align: center;
}

.status-details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.status-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #f1f3f4;
}

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

.status-item label {
  font-weight: 500;
  color: #ffffff;
}

.projects-summary {
  display: flex;
  justify-content: space-around;
  text-align: center;
}

.summary-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: bold;
  color: #0066cc;
}

.stat-label {
  font-size: 0.85rem;
  color: #ffffff;
  margin-top: 0.25rem;
}

.performance-metrics {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.metric-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
}

/* Actividad reciente */
.recent-activity-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.recent-activity-section h3 {
  margin: 0 0 1.5rem 0;
  color: #495057;
}

.activity-timeline {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.activity-item {
  display: flex;
  align-items: start;
  gap: 1rem;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid #f1f3f4;
  background: #fafbfc;
}

.activity-icon {
  font-size: 1.5rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e9ecef;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.activity-content {
  flex: 1;
}

.activity-message {
  font-weight: 500;
  color: #495057;
  margin-bottom: 0.25rem;
}

.activity-date {
  font-size: 0.85rem;
  color: #ffffff;
}

/* Perfil expandido */
.profile-page-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.profile-sections-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
}

.profile-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e9ecef;
}

.section-header h3 {
  margin: 0;
  color: #495057;
  font-size: 1.2rem;
}

.info-grid-expanded {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.info-item-large {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.info-item-large label {
  font-weight: 600;
  color: #495057;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.info-item-large span {
  font-size: 1rem;
  color: #212529;
}

.specialties-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

.specialty-card {
  background: linear-gradient(135deg, #ff8c42 0%, #f4623a 100%);
  color: white;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(255, 140, 66, 0.3);
}

.certifications-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.certification-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.cert-name {
  font-weight: 500;
  color: #495057;
}

.cert-date {
  font-size: 0.85rem;
  color: #ffffff;
}

.no-data-large {
  text-align: center;
  padding: 3rem;
  color: #ffffff;
  font-size: 1.1rem;
}

.no-data-large small {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Documentos expandidos */
.documents-page-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.documents-page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.documents-page-header h3 {
  margin: 0;
  color: #495057;
}

.documents-actions {
  display: flex;
  gap: 1rem;
}

.documents-status-overview {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.status-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
}

.status-card {
  text-align: center;
  padding: 1.5rem;
  border-radius: 12px;
  color: white;
}

.status-card.approved {
  background: linear-gradient(135deg, #28a745, #20c997);
}

.status-card.pending {
  background: linear-gradient(135deg, #ffc107, #fd7e14);
}

.status-card.rejected {
  background: linear-gradient(135deg, #dc3545, #e83e8c);
}

.status-number {
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.25rem;
}

.status-label {
  font-size: 0.9rem;
  opacity: 0.9;
}

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

.required-documents-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.required-documents-section h4 {
  margin: 0 0 1.5rem 0;
  color: #495057;
}

.requirements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.requirement-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.req-icon {
  font-size: 1.5rem;
}

.req-label {
  flex: 1;
  font-weight: 500;
  color: #495057;
}

.req-status {
  font-size: 0.85rem;
  color: #ffffff;
}

/* Barra de acciones flotante */
.floating-actions-bar {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1000;
}

.floating-btn {
  border-radius: 50px;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.floating-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Estados de status mejorados */
.status-pending {
  background: #ffc107;
  color: #212529;
}

.status-active, .status-approved {
  background: #28a745;
  color: white;
}

.status-inactive, .status-rejected {
  background: #dc3545;
  color: white;
}

.status-submitted {
  background: #17a2b8;
  color: white;
}

/* Responsive para página de contratista */
@media (max-width: 768px) {
  .contractor-hero-section {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.5rem;
  }
  
  .contractor-avatar-xl {
    margin: 0 auto;
  }
  
  .contractor-name {
    font-size: 2rem;
  }
  
  .page-content-area {
    padding: 1rem;
  }
  
  .profile-sections-grid {
    grid-template-columns: 1fr;
  }
  
  .documents-grid {
    grid-template-columns: 1fr;
  }
  
  .floating-actions-bar {
    position: relative;
    bottom: auto;
    right: auto;
    flex-direction: row;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
  }
}

/* Progress bar para documentos */
.documents-progress {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.progress-bar {
  flex: 1;
  height: 8px;
  background: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #28a745, #20c997);
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 0.85rem;
  font-weight: 500;
  color: #495057;
  min-width: 80px;
}

/* Variables CSS */
:root {
    --prime-yellow: #FFAA00;
    --prime-earth: #E2853D;
    --prime-onyx: #434343;
    --prime-night: #1E1E1E;
    --white: #FFFFFF;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-500: #6B7280;
    --gray-700: #374151;
    --gray-900: #111827;
    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --info: #3B82F6;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--gray-50);
    color: var(--gray-900);
}

/* Chat Mejorado */
.chat-container {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 1.5rem;
    height: calc(100vh - 200px);
    max-height: 700px;
}

.chat-sidebar {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.chat-header {
    padding: 1.25rem;
    background: linear-gradient(135deg, var(--prime-yellow) 0%, var(--prime-earth) 100%);
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0;
}

.chat-search {
    padding: 1rem;
    border-bottom: 1px solid var(--gray-200);
}

.chat-search input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    font-size: 0.875rem;
    transition: var(--transition);
}

.chat-search input:focus {
    outline: none;
    border-color: var(--prime-yellow);
}

.chat-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
}

.chat-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem;
    margin-bottom: 0.5rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all var(--transition);
    position: relative;
}

.chat-item:hover {
    background: var(--gray-50);
}

.chat-item.active {
    background: var(--gray-100);
    border-left: 3px solid var(--prime-yellow);
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--white);
    font-size: 0.875rem;
}

.chat-info {
    flex: 1;
}

.chat-name {
    font-weight: 600;
    color: var(--gray-900);
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.chat-preview {
    font-size: 0.75rem;
    color: var(--gray-500);
}

.chat-window {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.badge {
    background: var(--prime-yellow);
    color: var(--prime-onyx);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    margin-left: auto;
}

/* NO DATA STATE */
.no-data {
    text-align: center;
    padding: 3rem 1.5rem;
    color: var(--gray-500);
    font-style: italic;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

/* OVERLAY FOR MOBILE SIDEBAR */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
}

.overlay.show {
    opacity: 1;
    visibility: visible;
}

/* LOADING SCREEN */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, var(--prime-yellow) 0%, var(--prime-earth) 50%, var(--prime-onyx) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    color: white;
    opacity: 1;
    visibility: visible;
    transition: all 0.5s ease-out;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.prime-logo-loader {
    text-align: center;
    margin-bottom: 2rem;
}

.logo-animation {
    position: relative;
    display: inline-block;
    margin-bottom: 1.5rem;
}

.logo-animation .logo-icon {
    font-size: 4rem;
    animation: logoFloat 2s ease-in-out infinite;
    display: block;
    margin-bottom: 1rem;
}

.building-blocks {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.block {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 3px;
    animation: blockBuild 1.5s ease-in-out infinite;
}

.block-1 { animation-delay: 0s; }
.block-2 { animation-delay: 0.3s; }
.block-3 { animation-delay: 0.6s; }

.loading-text-container h1.prime-text {
    font-size: 2.25rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.loading-text-container h2.planning-text {
    font-size: 1.125rem;
    font-weight: 400;
    letter-spacing: 0.05em;
    margin: 0 0 1rem 0;
    opacity: 0.9;
}

.loading-text-container p.loading-text {
    font-size: 1rem;
    font-weight: 300;
    opacity: 0.8;
    margin: 0;
}

.loading-progress {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 12px;
    animation: progressFill 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes blockBuild {
    0%, 100% { 
        transform: translateY(0px) scale(1);
        opacity: 0.7;
    }
    50% { 
        transform: translateY(-8px) scale(1.1);
        opacity: 1;
    }
}

@keyframes progressFill {
    0% { transform: translateX(-100%); }
    50% { transform: translateX(0%); }
    100% { transform: translateX(100%); }
}

/* AUTH SECTION STYLES */
.auth-section {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--gray-50) 0%, var(--gray-100) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.auth-container {
    width: 100%;
    max-width: 28rem;
}

.auth-card {
    background: var(--white);
    border-radius: 20px;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    border: 1px solid var(--gray-200);
}

.auth-header {
    text-align: center;
    padding: 2rem 1.5rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--white);
    position: relative;
}

.auth-logo {
    margin-bottom: 1rem;
}

.brand-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--white);
    text-decoration: none;
}

.brand-text .prime {
    font-size: 1.5rem;
    font-weight: 700;
    display: block;
    letter-spacing: 0.05em;
}

.brand-text .sub {
    font-size: 0.75rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.auth-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.auth-header p {
    opacity: 0.9;
    margin: 0;
    font-size: 1rem;
}

.language-toggle {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    color: white;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition);
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.auth-tabs {
    display: flex;
    background: var(--gray-100);
    margin: 0 1.5rem;
    border-radius: 12px;
    padding: 0.25rem;
}

.tab-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    color: var(--gray-600);
    transition: all var(--transition);
}

.tab-btn.active {
    background: var(--white);
    color: var(--prime-yellow);
    box-shadow: var(--shadow-sm);
}

.auth-form {
    display: none;
    padding: 1.5rem;
}

.auth-form.active {
    display: block;
}

.auth-form .form-group {
    margin-bottom: 1.25rem;
}

.auth-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.auth-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 0.875rem;
}

.auth-form input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--gray-300);
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    transition: all var(--transition);
    background: var(--white);
}

.auth-form input:focus {
    outline: none;
    border-color: var(--prime-yellow);
    box-shadow: 0 0 0 3px rgba(255, 170, 0, 0.1);
    transform: translateY(-1px);
}

.auth-form .btn {
    width: 100%;
    margin-top: 1rem;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
}

/* CONTRACTOR DETAILS */
.contractor-details {
    margin: 1rem 0;
}

.contractor-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.contractor-specialties {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.contractor-actions {
    display: flex;
    gap: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-200);
}

/* PROJECT ACTIONS */
.project-actions {
    display: flex;
    gap: 0.5rem;
}

/* ========================================
   PÁGINA COMPLETA DE CONTRATISTA
   ======================================== */

.contractor-page-wrapper {
  width: 100%;
  min-height: 100vh;
  background: #f8f9fa;
  overflow-x: hidden;
}

/* Navegación de regreso */
.page-navigation {
  background: white;
  border-bottom: 1px solid #e9ecef;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.back-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.page-breadcrumb {
  color: #ffffff;
  font-size: 0.9rem;
}

.page-breadcrumb span:last-child {
  color: #495057;
  font-weight: 500;
}

/* Header expandido del contratista */
.contractor-page-header {
  background: linear-gradient(135deg, #434343 0%, #555555 100%);
  color: white;
  padding: 2rem;
  margin-bottom: 0;
}

.contractor-hero-section {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 2rem;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}

.contractor-avatar-xl {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: bold;
  border: 4px solid rgba(255, 255, 255, 0.3);
}

.contractor-primary-info {
  flex: 1;
}

.contractor-name {
  font-size: 2.5rem;
  font-weight: bold;
  margin: 0 0 0.5rem 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.business-name {
  font-size: 1.5rem;
  font-weight: 300;
  margin: 0 0 1.5rem 0;
  opacity: 0.9;
}

.contact-info-expanded {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.contact-icon {
  font-size: 1.1rem;
}

.contact-text {
  font-size: 0.95rem;
  opacity: 0.9;
}

.contractor-status-section {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.status-indicator-large {
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-weight: bold;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.quick-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.contractor-stats-sidebar {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  min-width: 250px;
}

/* Navegación de pestañas */
.page-tabs-navigation {
  background: white;
  border-bottom: 1px solid #e9ecef;
  position: sticky;
  top: 73px;
  z-index: 99;
}

.tabs-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  overflow-x: auto;
  padding: 0 2rem;
}

.page-tab-btn {
  background: none;
  border: none;
  padding: 1rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: #ffffff;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.page-tab-btn:hover {
  color: #495057;
  background: #f8f9fa;
}

.page-tab-btn.active {
  color: #0066cc;
  border-bottom-color: #0066cc;
  background: rgba(0, 102, 204, 0.05);
}

/* Área de contenido */
.page-content-area {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.page-tab-panel {
  display: none;
}

.page-tab-panel.active {
  display: block;
}

/* Resumen (Overview) */
.overview-dashboard {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.overview-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  border: 1px solid #e9ecef;
}

.overview-card h3 {
  margin: 0 0 1rem 0;
  color: #495057;
  font-size: 1.1rem;
  font-weight: 600;
}

.status-overview {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.status-indicator-xl {
  display: inline-block;
  padding: 1rem 2rem;
  border-radius: 50px;
  font-weight: bold;
  font-size: 1.1rem;
  text-align: center;
}

.status-details {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.status-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #f1f3f4;
}

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

.status-item label {
  font-weight: 500;
  color: #ffffff;
}

.projects-summary {
  display: flex;
  justify-content: space-around;
  text-align: center;
}

.summary-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: bold;
  color: #0066cc;
}

.stat-label {
  font-size: 0.85rem;
  color: #ffffff;
  margin-top: 0.25rem;
}

.performance-metrics {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.metric-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
}

/* Actividad reciente */
.recent-activity-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.recent-activity-section h3 {
  margin: 0 0 1.5rem 0;
  color: #495057;
}

.activity-timeline {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.activity-item {
  display: flex;
  align-items: start;
  gap: 1rem;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid #f1f3f4;
  background: #fafbfc;
}

.activity-icon {
  font-size: 0.5rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e9ecef;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.activity-content {
  flex: 1;
}

.activity-message {
  font-weight: 500;
  color: #495057;
  margin-bottom: 0.25rem;
}

.activity-date {
  font-size: 0.85rem;
  color: #ffffff;
}

/* Perfil expandido */
.profile-page-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.profile-sections-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
}

.profile-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e9ecef;
}

.section-header h3 {
  margin: 0;
  color: #495057;
  font-size: 1.2rem;
}

.info-grid-expanded {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.info-item-large {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.info-item-large label {
  font-weight: 600;
  color: #495057;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.info-item-large span {
  font-size: 1rem;
  color: #212529;
}

.specialties-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

.specialty-card {
  background: linear-gradient(135deg, #ff8c42 0%, #f4623a 100%);
  color: white;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(255, 140, 66, 0.3);
}

.certifications-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.certification-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.cert-name {
  font-weight: 500;
  color: #495057;
}

.cert-date {
  font-size: 0.85rem;
  color: #ffffff;
}

.no-data-large {
  text-align: center;
  padding: 3rem;
  color: #ffffff;
  font-size: 1.1rem;
}

.no-data-large small {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Documentos expandidos */
.documents-page-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.documents-page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.documents-page-header h3 {
  margin: 0;
  color: #495057;
}

.documents-actions {
  display: flex;
  gap: 1rem;
}

.documents-status-overview {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.status-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
}

.status-card {
  text-align: center;
  padding: 1.5rem;
  border-radius: 12px;
  color: white;
}

.status-card.approved {
  background: linear-gradient(135deg, #28a745, #20c997);
}

.status-card.pending {
  background: linear-gradient(135deg, #ffc107, #fd7e14);
}

.status-card.rejected {
  background: linear-gradient(135deg, #dc3545, #e83e8c);
}

.status-number {
  font-size: 2rem;
  font-weight: bold;
  margin-bottom: 0.25rem;
}

.status-label {
  font-size: 0.9rem;
  opacity: 0.9;
}

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

.required-documents-section {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.required-documents-section h4 {
  margin: 0 0 1.5rem 0;
  color: #495057;
}

.requirements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.requirement-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border-radius: 8px;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
}

.req-icon {
  font-size: 0.5rem;
}

.req-label {
  flex: 1;
  font-weight: 500;
  color: #495057;
}

.req-status {
  font-size: 0.85rem;
  color: #ffffff;
}

/* Barra de acciones flotante */
.floating-actions-bar {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1000;
}

.floating-btn {
  border-radius: 50px;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.floating-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Estados de status mejorados */
.status-pending {
  background: #ffc107;
  color: #212529;
}

.status-active, .status-approved {
  background: #28a745;
  color: white;
}

.status-inactive, .status-rejected {
  background: #dc3545;
  color: white;
}

.status-submitted {
  background: #17a2b8;
  color: white;
}

/* Responsive para página de contratista */
@media (max-width: 768px) {
  .contractor-hero-section {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.5rem;
  }
  
  .contractor-avatar-xl {
    margin: 0 auto;
  }
  
  .contractor-name {
    font-size: 2rem;
  }
  
  .page-content-area {
    padding: 1rem;
  }
  
  .profile-sections-grid {
    grid-template-columns: 1fr;
  }
  
  .documents-grid {
    grid-template-columns: 1fr;
  }
  
  .floating-actions-bar {
    position: relative;
    bottom: auto;
    right: auto;
    flex-direction: row;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
  }
}

/* Progress bar para documentos */
.documents-progress {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.progress-bar {
  flex: 1;
  height: 8px;
  background: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #28a745, #20c997);
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 0.85rem;
  font-weight: 500;
  color: #495057;
  min-width: 80px;
}

/* ========================================
   DASHBOARDS ESPECIALES PARA CONTRATISTAS
   ======================================== */

.pending-contractor-dashboard,
.rejected-contractor-dashboard {
  max-width: 800px;
  margin: 2rem auto;
  padding: 2rem;
  background: white;
  border-radius: 15px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.status-notice,
.rejection-notice {
  text-align: center;
  padding: 2rem;
}

.status-icon {
  font-size: 4rem;
  margin-bottom: 1rem;
  animation: pulse 2s infinite;
}

.rejection-icon {
  font-size: 4rem;
  margin-bottom: 1rem;
  color: #e74c3c;
}

.status-notice h1,
.rejection-notice h1 {
  color: #2c3e50;
  margin-bottom: 1rem;
  font-size: 2.5rem;
}

.status-notice p,
.rejection-notice p {
  color: #7f8c8d;
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.verification-steps {
  background: #f8f9fa;
  padding: 2rem;
  border-radius: 10px;
  margin: 2rem 0;
  border-left: 4px solid #3498db;
}

.verification-steps h3 {
  color: #2c3e50;
  margin-bottom: 1rem;
}

.verification-steps ol {
  padding-left: 1.5rem;
}

.verification-steps li {
  margin-bottom: 0.5rem;
  color: #34495e;
}

.expected-timeline {
  background: #e8f5e8;
  padding: 1.5rem;
  border-radius: 10px;
  margin: 1.5rem 0;
  border-left: 4px solid #27ae60;
}

.expected-timeline h4 {
  color: #27ae60;
  margin-bottom: 0.5rem;
}

.rejection-reason {
  background: #ffeaea;
  padding: 1.5rem;
  border-radius: 10px;
  margin: 1.5rem 0;
  border-left: 4px solid #e74c3c;
}

.rejection-reason h3 {
  color: #e74c3c;
  margin-bottom: 0.5rem;
}

.next-steps {
  background: #f0f8ff;
  padding: 1.5rem;
  border-radius: 10px;
  margin: 1.5rem 0;
  border-left: 4px solid #3498db;
}

.next-steps h3 {
  color: #3498db;
  margin-bottom: 1rem;
}

.next-steps ul {
  padding-left: 1.5rem;
}

.next-steps li {
  margin-bottom: 0.5rem;
  color: #34495e;
}

.action-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}

.action-buttons .btn {
  min-width: 180px;
  padding: 12px 24px;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.btn-secondary {
  background: #95a5a6;
  color: white;
  border: none;
}

.btn-secondary:hover {
  background: #7f8c8d;
  transform: translateY(-2px);
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* ========================================
   DASHBOARD RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
  .pending-contractor-dashboard,
  .rejected-contractor-dashboard {
    margin: 1rem;
    padding: 1.5rem;
  }
  
  .status-notice h1,
  .rejection-notice h1 {
    font-size: 2rem;
  }
  
  .action-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .action-buttons .btn {
    width: 100%;
    max-width: 300px;
  }
}

/* ============================================
   DASHBOARD FIXES - Override de colores y tamaños
   ============================================ */

/* Arreglar color de stat-label en el dashboard para que no sea blanco */
.dashboard-stats .stat-label,
.stats-grid .stat-label,
.dashboard-overview .stat-label {
  color: var(--gray-600) !important;
}

/* Asegurar que los iconos del dashboard tengan buen tamaño */
.dashboard-stats .stat-icon,
.stats-grid .stat-icon,
.dashboard-overview .stat-icon {
  font-size: 1.5rem !important;
}

/* ========================================
   MODAL DE RESTABLECIMIENTO DE CONTRASEÑA
   ======================================== */

.reset-options {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.option-card {
  border: 1px solid #e1e5e9;
  border-radius: 8px;
  padding: 20px;
  background: #fafbfc;
  transition: all 0.3s ease;
}

.option-card:hover {
  border-color: #007bff;
  box-shadow: 0 2px 8px rgba(0, 123, 255, 0.15);
}

.option-card h4 {
  color: #2c3e50;
  margin: 0 0 10px 0;
  font-size: 16px;
  font-weight: 600;
}

.option-card p {
  color: #6c757d;
  margin: 0 0 15px 0;
  font-size: 14px;
  line-height: 1.4;
}

.password-form {
  margin-top: 15px;
}

.password-form .form-group {
  margin-bottom: 15px;
}

.password-form .form-group:last-child {
  margin-bottom: 0;
  margin-top: 20px;
}

.password-form label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
  color: #495057;
  font-size: 13px;
}

.password-form .form-control {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 14px;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.password-form .form-control:focus {
  outline: none;
  border-color: #80bdff;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.password-form .form-control[style*="border-color: red"] {
  border-color: #dc3545 !important;
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.contractor-info {
  background: #f8f9fa;
  padding: 12px;
  border-radius: 4px;
  font-size: 13px;
  color: #495057;
  border-left: 3px solid #007bff;
}

/* Botones específicos para cada opción */
.option-card .btn {
  min-width: 140px;
}

.option-card .btn-primary {
  background-color: #007bff;
  border-color: #007bff;
}

.option-card .btn-warning {
  background-color: #ffc107;
  border-color: #ffc107;
  color: #212529;
}

.option-card .btn-success {
  background-color: #28a745;
  border-color: #28a745;
}

.option-card .btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Responsive design para el modal de reset */
@media (max-width: 768px) {
  .reset-options {
    gap: 15px;
  }
  
  .option-card {
    padding: 15px;
  }
  
  .option-card h4 {
    font-size: 15px;
  }
  
  .option-card .btn {
    width: 100%;
    min-width: auto;
  }
  
  .password-form .form-group {
    margin-bottom: 12px;
  }
}

/* Estados de validación visual */
.password-form .form-control.valid {
  border-color: #28a745;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328a745' d='m2.3 6.73.8-.77-.8-.77-.8.77c-.39.39-.39 1.04 0 1.43l.02.02c.39.39 1.03.39 1.42 0L8.7 2.3c.39-.39.39-1.04 0-1.43-.39-.39-1.04-.39-1.43 0L2.3 6.73z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px 16px;
}

.password-form .form-control.invalid {
  border-color: #dc3545;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath d='m5.8 4.6 2.4 2.4M8.2 4.6l-2.4 2.4'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 16px 16px;
}

/* Loading states para botones */
.btn.loading {
  position: relative;
  color: transparent !important;
}

.btn.loading::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: button-loading-spinner 1s ease infinite;
}

@keyframes button-loading-spinner {
  from {
    transform: rotate(0turn);
  }
  to {
    transform: rotate(1turn);
  }
}

/* Mejorar estilos de modal existentes */
.modal-content.large {
  max-width: 800px;
}

.modal-header h3 {
  color: #2c3e50;
  font-weight: 600;
}

.modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
}

.modal-footer .contractor-info {
  flex: 1;
  min-width: 200px;
}

@media (max-width: 576px) {
  .modal-footer {
    flex-direction: column;
    align-items: stretch;
  }
  
  .modal-footer .contractor-info {
    order: -1;
    margin-bottom: 10px;
  }
}
