.widgets-sidebar {
    /* Comentado temporalmente
    width: 20%;
    min-width: 250px;
    height: 100vh;
    position: fixed;
    left: 250px;
    top: 0;
    background-color: #f8f9fa;
    border-right: 1px solid #dee2e6;
    padding: 1rem;
    overflow-y: auto;
    z-index: 999;
    */
}

/* Excluir el módulo de contratos de las reglas de widgets */
.contract-container .widgets-sidebar {
    width: auto !important;
    min-width: auto !important;
    position: static !important;
    left: auto !important;
    top: auto !important;
    height: auto !important;
    z-index: auto !important;
}

.widget {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

.widget-header,
.calendar-widget .widget-header,
.reminders-widget .widget-header {
    background: linear-gradient(135deg, #e0e4ea 0%, #f5f6fa 100%);
    color: #333;
    padding: 8px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.widget-title {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 16px;
}

.widget-title i {
    margin-right: 8px;
    font-size: 18px;
}

.widget-actions {
    display: flex;
    gap: 5px;
}

.btn-icon {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    padding: 6px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

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

.widget-content {
    padding: 0;
}

/* Ajuste del contenido principal para la barra de widgets */
.main-content {
    /* Comentado temporalmente para evitar conflictos con otros módulos
    margin-left: calc(250px + 20%);
    width: calc(100% - 250px - 20%);
    */
}

/* Excluir el módulo de contratos de las reglas de ancho */
.contract-container .main-content {
    margin-left: 0 !important;
    width: 100% !important;
}

/* Estilos específicos para cada widget */
.calendar-widget .calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.weather-widget .weather-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.weather-widget .temperature {
    font-size: 1.5rem;
    font-weight: bold;
}

.reminders-widget {
    min-height: 200px;
}

.reminders-widget .reminder-item {
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.reminders-widget .reminder-item:last-child {
    border-bottom: none;
}

.reminders-widget .reminder-item:hover {
    background-color: #f8f9fa;
    border-radius: 4px;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    margin-left: -0.5rem;
    margin-right: -0.5rem;
}

.reminders-widget .reminder-item.text-danger {
    border-left: 3px solid #dc3545;
    padding-left: 0.75rem;
    margin-left: -0.75rem;
}

.reminders-widget .reminder-item strong {
    font-size: 0.9rem;
    line-height: 1.3;
}

.reminders-widget .reminder-item small {
    font-size: 0.8rem;
    line-height: 1.2;
}

.reminders-widget .reminder-item .bi-exclamation-triangle-fill {
    font-size: 0.9rem;
    margin-top: 0.1rem;
}

/* Animación de carga para recordatorios */
.reminders-widget .text-center {
    padding: 0.5rem 0;
}

.reminders-widget .bi-hourglass-split {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Estado vacío */
.reminders-widget .text-muted {
    font-style: italic;
    text-align: center;
    padding: 0.5rem 0;
    font-size: 0.8rem;
}

/* Error en carga */
.reminders-widget .text-danger {
    text-align: center;
    padding: 0.5rem 0;
    font-weight: 500;
    font-size: 0.8rem;
}

/* Ajustes para cuando la barra lateral está colapsada */
#sidebar.active + .widgets-sidebar {
    /* Comentado temporalmente
    left: 80px;
    */
}

#sidebar.active + .widgets-sidebar + .main-content {
    /* Comentado temporalmente para evitar conflictos con otros módulos
    margin-left: calc(80px + 20%);
    width: calc(100% - 80px - 20%);
    */
}

/* Excluir el módulo de contratos de las reglas de ancho cuando el sidebar está colapsado */
.contract-container #sidebar.active + .widgets-sidebar + .main-content {
    margin-left: 0 !important;
    width: 100% !important;
}

.calendar-widget .event-google {
    background: #34a853 !important;
    color: white !important;
}

/* === ESTILOS PARA CALENDARIO TIPO GOOGLE === */

.calendar-widget-nav button {
    border: none !important;
    background: transparent !important;
    font-size: 1.2rem;
    color: #6c757d;
    line-height: 1;
    padding: 0 0.25rem !important;
}

.calendar-widget-nav button:hover {
    color: #343a40;
}

.calendar-widget .widget-body {
    padding: 0.3rem 0.8rem 0.8rem;
}

.calendar-widget .fc-scrollgrid,
.calendar-widget .fc-scrollgrid-section > * {
    border: none !important;
}

.calendar-widget .fc-daygrid-day {
    border-color: transparent !important;
    position: relative;
}

/* Borde para días con eventos */
.calendar-widget .fc-daygrid-day.has-events {
    border: 2px solid #1976d2 !important;
    border-radius: 4px;
}

.calendar-widget .fc-daygrid-day-frame {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    height: 32px;
    padding: 1px 0;
    position: relative;
}

.calendar-widget .fc-daygrid-day-number {
    width: 24px;
    height: 24px;
    line-height: 24px;
    text-align: center;
    border-radius: 50%;
    padding: 0 !important;
    font-size: 0.75rem;
    color: #0d6efd;
    text-decoration: none !important;
    position: absolute;
    top: 2px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.calendar-widget .fc-day-today .fc-daygrid-day-number {
    background-color: #0d6efd;
    color: white !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.calendar-widget .fc-col-header-cell {
    border: none !important;
}

.calendar-widget .fc-col-header-cell-cushion {
    font-weight: 500;
    color: #6c757d;
    font-size: 0.7rem;
    padding: 0.3rem 0 !important;
    text-decoration: none !important;
}

.calendar-widget .fc-daygrid-dot-event {
    display: none !important;
}

/* Ocultar completamente todos los eventos de FullCalendar en el widget */
.calendar-widget .fc-event,
.calendar-widget .fc-event-main,
.calendar-widget .fc-event-title,
.calendar-widget .fc-daygrid-event,
.calendar-widget .fc-daygrid-day-events {
    display: none !important;
}

/* Ocultar el contenedor de eventos */
.calendar-widget .fc-daygrid-day-events {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
}

/* Reducir el tamaño general del widget de calendario */
.calendar-widget {
    max-height: 280px;
    overflow: hidden;
}

.calendar-widget .fc {
    font-size: 0.75rem;
}

.calendar-widget .fc table {
    font-size: 0.75rem;
}

.mini-calendar-event-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    gap: 2px;
    min-height: 8px;
    z-index: 1;
}

.mini-calendar-event-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #1976d2;
    display: inline-block;
    flex-shrink: 0;
}

.mini-calendar-event-plus {
    font-size: 0.7em;
    color: #1976d2;
    font-weight: bold;
    vertical-align: middle;
    line-height: 1;
    flex-shrink: 0;
}

/* === ESTILOS PARA TABLA DE RECORDATORIOS === */

.reminders-table-container {
    max-height: 320px;
    overflow-y: auto;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    margin: -0.5rem; /* Compensar el padding del widget-body */
}

.reminders-table-header {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    position: sticky;
    top: 0;
    z-index: 10;
}

.reminders-table-row {
    display: grid;
    grid-template-columns: 2.2fr 1.3fr 1.2fr 0.8fr;
    gap: 6px;
    padding: 6px 8px;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: #495057;
}

.reminders-table-body .reminders-table-row {
    border-bottom: 1px solid #e9ecef;
    font-weight: normal;
    color: #212529;
    transition: background-color 0.2s ease;
    padding: 8px 8px;
}

.reminders-table-body .reminders-table-row:hover {
    background-color: #f8f9fa;
}

.reminders-table-body .reminders-table-row:last-child {
    border-bottom: none;
}

.reminders-table-cell {
    padding: 2px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.2;
}

.reminders-table-cell.sortable {
    cursor: pointer;
    user-select: none;
    transition: color 0.2s ease;
}

.reminders-table-cell.sortable:hover {
    color: #0d6efd;
}

.reminders-table-cell.sortable i {
    font-size: 0.65rem;
    margin-left: 3px;
    opacity: 0.6;
}

.reminders-table-cell.sortable:hover i {
    opacity: 1;
}

.reminders-table-cell.sortable.sort-asc i::before {
    content: "\f12c"; /* bi-arrow-up */
}

.reminders-table-cell.sortable.sort-desc i::before {
    content: "\f12f"; /* bi-arrow-down */
}

/* Estilos para tipos de recordatorios */
.reminder-type {
    padding: 1px 4px;
    border-radius: 8px;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.reminder-type.critical {
    background-color: #dc3545;
    color: white;
}

.reminder-type.normal {
    background-color: #6c757d;
    color: white;
}

.reminder-type.urgent {
    background-color: #fd7e14;
    color: white;
}

/* Estados de vencimiento */
.reminder-overdue {
    color: #dc3545;
    font-weight: 600;
}

.reminder-due-today {
    color: #fd7e14;
    font-weight: 600;
}

.reminder-due-soon {
    color: #ffc107;
    font-weight: 600;
}

/* Optimizar el widget body para recordatorios */
.reminders-widget .widget-body {
    padding: 0.5rem;
}

/* Scrollbar personalizado más delgado */
.reminders-table-container::-webkit-scrollbar {
    width: 4px;
}

.reminders-table-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 2px;
}

.reminders-table-container::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 2px;
}

.reminders-table-container::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Botón de agregar recordatorio */
.reminders-widget .widget-actions .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.8rem;
}

/* Mejorar la legibilidad del texto en las celdas */
.reminders-table-cell strong {
    font-size: 0.75rem;
    line-height: 1.1;
}

.reminders-table-cell small {
    font-size: 0.65rem;
    line-height: 1.1;
    opacity: 0.8;
}

/* === ESTILOS PARA MODAL DE DETALLES === */

.reminder-detail-section {
    margin-bottom: 1.5rem;
}

.reminder-detail-section h6 {
    font-weight: 600;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid #e9ecef;
    padding-bottom: 0.5rem;
}

.reminder-status-card {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1rem;
}

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

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

.status-label {
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
}

.status-value {
    font-weight: 500;
    font-size: 0.9rem;
}

/* Mejorar tooltips */
.reminders-table-row[title] {
    position: relative;
}

.reminders-table-row[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    white-space: pre-line;
    z-index: 1000;
    max-width: 300px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    pointer-events: none;
}

.reminders-table-row[title]:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
    z-index: 1000;
    pointer-events: none;
}

/* Estilos para el modal */
#reminderDetailsModal .modal-dialog {
    max-width: 800px;
}

#reminderDetailsModal .modal-header {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
}

#reminderDetailsModal .modal-title {
    color: #495057;
    font-weight: 600;
}

#reminderDetailsModal .modal-title i {
    margin-right: 0.5rem;
    color: #0d6efd;
}

#reminderDetailsModal .alert {
    margin-bottom: 0;
    font-size: 0.9rem;
}

#reminderDetailsModal .alert i {
    margin-right: 0.5rem;
}

/* Responsive para el modal */
@media (max-width: 768px) {
    #reminderDetailsModal .modal-dialog {
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }
    
    .status-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    
    .reminder-status-card {
        margin-top: 1rem;
    }
}

/* Animación para el modal */
.modal.fade .modal-dialog {
    transition: transform 0.3s ease-out;
    transform: translate(0, -50px);
}

.modal.show .modal-dialog {
    transform: none;
}

/* Mejorar el cursor hover en las filas */
.reminders-table-row {
    transition: all 0.2s ease;
}

.reminders-table-row:hover {
    background-color: #f8f9fa;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Estilos para encabezados ordenables */
.sortable-header {
    cursor: pointer;
    user-select: none;
    position: relative;
    transition: background-color 0.2s ease;
}

.sortable-header:hover {
    background-color: rgba(0, 123, 255, 0.1);
}

.sortable-header .sort-icon {
    margin-left: 5px;
    font-size: 0.8em;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.sortable-header:hover .sort-icon {
    opacity: 1;
}

.sortable-header[data-sort="title"] .sort-icon,
.sortable-header[data-sort="due_date"] .sort-icon,
.sortable-header[data-sort="creator"] .sort-icon,
.sortable-header[data-sort="urgency"] .sort-icon,
.sortable-header[data-sort="status"] .sort-icon {
    color: #007bff;
}

/* Animación para el reordenamiento */
.reminder-row {
    transition: all 0.3s ease;
}

/* Estilos para el modal de recordatorios */
#remindersMainModal .modal-dialog {
    max-width: 90%;
}

#remindersMainModal .modal-body {
    max-height: 70vh;
    overflow-y: auto;
}

/* Tooltips personalizados */
.tooltip {
    font-size: 0.875rem;
}

/* Responsive para móviles */
@media (max-width: 768px) {
    .sortable-header {
        font-size: 0.875rem;
    }
    
    .sortable-header .sort-icon {
        font-size: 0.7em;
    }
    
    #remindersMainModal .modal-dialog {
        max-width: 95%;
        margin: 10px;
    }
}

/* Widget de Recordatorios */
.reminders-list {
    max-height: 300px;
    overflow-y: auto;
}

.reminder-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

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

.reminder-info {
    flex: 1;
}

.reminder-title {
    font-weight: 500;
    margin-bottom: 2px;
}

.reminder-date {
    font-size: 12px;
    color: #666;
}

.reminder-urgent {
    color: #dc3545;
    font-weight: 600;
}

.reminder-overdue {
    color: #dc3545;
    font-weight: 600;
}

.reminder-actions {
    display: flex;
    gap: 5px;
}

.reminder-actions .btn {
    padding: 2px 6px;
    font-size: 11px;
}

/* Widget del Clima */
.weather-widget {
    min-height: 200px;
}

.weather-loading {
    text-align: center;
    padding: 40px 20px;
}

.loading-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.weather-error {
    text-align: center;
    padding: 20px;
    color: #dc3545;
}

.weather-error i {
    font-size: 24px;
    margin-bottom: 10px;
}

.weather-location {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    color: #666;
    font-size: 14px;
}

.weather-location i {
    margin-right: 5px;
    color: #667eea;
}

.weather-current {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.weather-icon {
    margin-right: 15px;
}

.weather-icon img {
    width: 60px;
    height: 60px;
}

.weather-info {
    flex: 1;
}

.weather-temp {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    line-height: 1;
}

.weather-desc {
    font-size: 16px;
    color: #666;
    margin: 5px 0;
    text-transform: capitalize;
}

.weather-feels {
    font-size: 12px;
    color: #999;
}

.weather-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.weather-detail {
    display: flex;
    align-items: center;
    font-size: 12px;
    color: #666;
}

.weather-detail i {
    margin-right: 5px;
    width: 14px;
    color: #667eea;
}

.weather-forecast {
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.weather-forecast h4 {
    font-size: 14px;
    margin-bottom: 10px;
    color: #333;
}

.forecast-list {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-top: 10px;
}

.forecast-day {
    text-align: center;
    padding: 8px 4px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.forecast-day img {
    width: 25px;
    height: 25px;
    margin: 3px auto;
}

.forecast-day .day {
    font-size: 9px;
    color: #666;
    margin-bottom: 2px;
    font-weight: 600;
    text-transform: uppercase;
}

.forecast-day .temp {
    font-size: 10px;
    font-weight: 600;
    color: #333;
    line-height: 1.2;
}

.weather-updated {
    text-align: center;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #eee;
    color: #999;
    font-size: 11px;
}

/* Modal del Clima */
.weather-modal-location {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.weather-modal-location h4 {
    color: #333;
    margin-bottom: 5px;
}

.current-weather-card {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    margin-bottom: 20px;
}

.weather-icon-large img {
    width: 100px;
    height: 100px;
    margin-bottom: 15px;
}

.temp-large {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 10px;
}

.desc-large {
    font-size: 18px;
    margin-bottom: 8px;
    text-transform: capitalize;
}

.feels-large {
    font-size: 14px;
    opacity: 0.9;
}

.weather-details-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    height: 100%;
}

.weather-details-card h5 {
    margin-bottom: 15px;
    color: #333;
}

.detail-item {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    font-size: 14px;
}

.detail-item i {
    margin-right: 10px;
    width: 16px;
    color: #667eea;
}

.forecast-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.forecast-day {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.forecast-date {
    margin-bottom: 10px;
}

.day-name {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.day-date {
    font-size: 12px;
    color: #666;
}

.forecast-icon img {
    width: 40px;
    height: 40px;
    margin: 8px 0;
}

.forecast-temps {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 8px 0;
}

.temp-max {
    font-weight: 600;
    color: #dc3545;
}

.temp-min {
    font-weight: 600;
    color: #007bff;
}

.forecast-desc {
    font-size: 12px;
    color: #666;
    margin-bottom: 5px;
    text-transform: capitalize;
}

.forecast-humidity {
    font-size: 11px;
    color: #999;
}

.weather-modal-info {
    margin-top: 20px;
}

.info-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    height: 100%;
}

.info-card h6 {
    color: #333;
    margin-bottom: 10px;
}

.info-card p {
    font-size: 13px;
    color: #666;
    margin-bottom: 8px;
}

.weather-modal-error {
    padding: 40px 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .weather-details {
        grid-template-columns: 1fr;
    }
    
    .forecast-list {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }
    
    .forecast-day {
        padding: 6px 2px;
        min-height: 70px;
    }
    
    .forecast-day img {
        width: 20px;
        height: 20px;
    }
    
    .forecast-day .day {
        font-size: 8px;
    }
    
    .forecast-day .temp {
        font-size: 9px;
    }
    
    .forecast-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }
    
    .current-weather-card {
        margin-bottom: 15px;
    }
    
    .temp-large {
        font-size: 36px;
    }
}

/* Estados de visibilidad */
.weather-detail.hidden {
    display: none;
}

.weather-forecast.hidden {
    display: none;
}

.weatherwidget-io-container {
    text-align: center;
    padding: 10px;
}

.weatherwidget-io {
    display: inline-block;
    text-decoration: none;
    color: #333;
    font-weight: bold;
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.weatherwidget-io:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    text-decoration: none;
    color: white;
}

/* Asegurar que el widget se ajuste al contenedor */
.weatherwidget-io iframe {
    max-width: 100% !important;
    height: auto !important;
    min-height: 200px;
}

/* === ESTILOS OPTIMIZADOS PARA WIDGET DE CLIMA EN SIDEBAR === */

/* Contenedor principal del widget de clima */
.weather-widget-container {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    border-radius: 8px;
    background: #f8f9fa;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Header del widget de clima */
.weather-widget-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8px 12px;
    text-align: center;
    border-radius: 8px 8px 0 0;
}

.weather-widget-header .weather-city-name {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* Contenedor del iframe */
.weather-widget-iframe {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
    background: white;
    border-radius: 0 0 8px 8px;
}

/* Estilos específicos para el iframe de Meteored */
.weather-widget-iframe iframe {
    width: 100% !important;
    height: 180px !important;
    max-height: 180px !important;
    border: none !important;
    overflow: hidden !important;
    display: block !important;
    transform: scale(0.9);
    transform-origin: top left;
    margin: 0 !important;
    padding: 0 !important;
}

/* Responsive para el widget de clima */
@media (max-width: 768px) {
    .weather-widget-iframe {
        height: 150px;
    }
    
    .weather-widget-iframe iframe {
        height: 150px !important;
        max-height: 150px !important;
        transform: scale(0.85);
    }
    
    .weather-widget-header .weather-city-name {
        font-size: 12px;
    }
}

/* Ajustes para pantallas muy pequeñas */
@media (max-width: 480px) {
    .weather-widget-iframe {
        height: 120px;
    }
    
    .weather-widget-iframe iframe {
        height: 120px !important;
        max-height: 120px !important;
        transform: scale(0.8);
    }
}

/* Estados de carga y error */
.weather-widget-container.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 180px;
    background: #f8f9fa;
}

.weather-widget-container.error {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 180px;
    background: #f8f9fa;
    color: #dc3545;
    font-size: 12px;
    text-align: center;
    padding: 20px;
}

/* Animación de carga */
.weather-widget-container.loading::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2px solid #667eea;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: weather-spin 1s linear infinite;
}

@keyframes weather-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* === WIDGET COMPACTO DE CLIMA === */

/* Widget compacto personalizado */
.compact-weather-widget {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 15px;
}

.compact-weather-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
}

.compact-weather-header i {
    font-size: 12px;
}

.compact-weather-content {
    padding: 12px;
}

.compact-weather-main {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.compact-weather-icon {
    font-size: 24px;
    color: #667eea;
    width: 40px;
    text-align: center;
}

.compact-weather-info {
    flex: 1;
}

.compact-weather-temp {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    line-height: 1;
}

.compact-weather-desc {
    font-size: 12px;
    color: #666;
    margin-top: 2px;
    text-transform: capitalize;
}

.compact-weather-details {
    display: flex;
    gap: 15px;
    padding-top: 8px;
    border-top: 1px solid #eee;
}

.compact-weather-detail {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: #666;
}

.compact-weather-detail i {
    color: #667eea;
    font-size: 10px;
}

.compact-weather-footer {
    background: #f8f9fa;
    padding: 6px 12px;
    text-align: center;
    font-size: 10px;
    color: #999;
}

/* Widget compacto de Meteored */
.meteored-compact-widget {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 15px;
}

.meteored-compact-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
}

.meteored-compact-header i {
    font-size: 12px;
}

.meteored-compact-iframe {
    width: 100%;
    height: 140px;
    overflow: hidden;
    position: relative;
    background: white;
}

.meteored-compact-iframe iframe {
    width: 100% !important;
    height: 140px !important;
    max-height: 140px !important;
    border: none !important;
    overflow: hidden !important;
    display: block !important;
    transform: scale(0.85);
    transform-origin: top left;
    margin: 0 !important;
    padding: 0 !important;
}

/* Responsive para widgets compactos */
@media (max-width: 768px) {
    .compact-weather-main {
        gap: 8px;
    }
    
    .compact-weather-icon {
        font-size: 20px;
        width: 30px;
    }
    
    .compact-weather-temp {
        font-size: 16px;
    }
    
    .compact-weather-desc {
        font-size: 11px;
    }
    
    .compact-weather-details {
        gap: 10px;
    }
    
    .meteored-compact-iframe {
        height: 120px;
    }
    
    .meteored-compact-iframe iframe {
        height: 120px !important;
        max-height: 120px !important;
        transform: scale(0.8);
    }
}

/* === WIDGETS MINI === */

/* Widget Meteored Mini */
.meteored-mini-widget {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 15px;
}

.meteored-mini-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6px 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
}

.meteored-mini-header i {
    font-size: 10px;
}

.meteored-mini-iframe {
    width: 100%;
    height: 100px;
    overflow: hidden;
    position: relative;
    background: white;
}

.meteored-mini-iframe iframe {
    width: 100% !important;
    height: 100px !important;
    max-height: 100px !important;
    border: none !important;
    overflow: hidden !important;
    display: block !important;
    transform: scale(0.75);
    transform-origin: top left;
    margin: 0 !important;
    padding: 0 !important;
}

/* Widget Personalizado Mini */
.custom-mini-widget {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 15px;
}

.custom-mini-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6px 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
}

.custom-mini-header i {
    font-size: 10px;
}

.custom-mini-content {
    padding: 8px 10px;
}

.custom-mini-temp {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
    font-size: 14px;
    font-weight: bold;
    color: #333;
}

.custom-mini-temp i {
    color: #667eea;
    font-size: 12px;
}

.custom-mini-desc {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #666;
}

.custom-mini-desc i {
    color: #667eea;
    font-size: 10px;
}

.custom-mini-footer {
    background: #f8f9fa;
    padding: 4px 10px;
    text-align: center;
    font-size: 9px;
    color: #999;
}

/* Responsive para widgets mini */
@media (max-width: 768px) {
    .meteored-mini-iframe {
        height: 80px;
    }
    
    .meteored-mini-iframe iframe {
        height: 80px !important;
        max-height: 80px !important;
        transform: scale(0.7);
    }
    
    .custom-mini-temp {
        font-size: 12px;
    }
    
    .custom-mini-desc {
        font-size: 10px;
    }
} 