/**
 * Mad Office Hours Widget Styles
 * Professional office hours display with clean layout and no text wrapping
 */

/* Main Widget Container */
.mad-office-hours-widget {
    width: 100%;
    position: relative;
    text-align: center;
}

/* Office Hours Container - Main Card Background */
.mad-office-hours-container {
    position: relative;
    width: 100%;
    padding: 30px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    box-sizing: border-box;
}

/* Icon Frame */
.mad-icon-frame {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto -10px auto;
    transition: transform 0.3s ease;
    z-index: 2;
    position: relative;
}

.mad-icon-frame:hover {
    transform: scale(1.05);
}

/* Icon inside frame */
.mad-icon-frame .siteorigin-widget-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Office Title */
.mad-office-title {
    font-weight: 600;
    letter-spacing: 0.5px;
    line-height: 1.2;
    margin: 0 0 20px 0;
    text-align: center;
    z-index: 1;
    position: relative;
}

/* Hours Card */
.mad-hours-card {
    position: relative;
    width: 100%;
    box-sizing: border-box;
    z-index: 1;
}

/* Hours List Container */
.mad-hours-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
}

/* Individual Hour Row - NO TEXT WRAPPING */
.mad-hours-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 0 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    white-space: nowrap;
    min-height: 24px;
}

.mad-hours-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

/* Day/Label Column - Fixed width, no wrapping */
.mad-hours-day {
    flex: 0 0 auto;
    text-align: left;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
    margin-right: 20px;
}

/* Time Column - Fixed width, no wrapping */
.mad-hours-time {
    flex: 0 0 auto;
    text-align: right;
    font-weight: 400;
    line-height: 1.2;
    white-space: nowrap;
}

/* Footer Notice */
.mad-footer-notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    opacity: 0.9;
    font-weight: 400;
    line-height: 1.3;
}

.mad-footer-icon {
    display: flex;
    align-items: center;
    font-size: 0.9em;
    flex-shrink: 0;
}

.mad-footer-text {
    display: flex;
    align-items: center;
    text-align: center;
}

/* Responsive Design - Optimized for 50% width containers */
@media (max-width: 768px) {
    .mad-office-hours-container {
        padding: 25px 20px;
        gap: 15px;
    }
    
    .mad-icon-frame {
        width: 70px !important;
        height: 70px !important;
        margin-bottom: -8px;
    }
    
    .mad-icon-frame .siteorigin-widget-icon {
        font-size: 32px !important;
    }
    
    .mad-office-title {
        font-size: 22px !important;
        margin-bottom: 15px;
    }
    
    .mad-hours-card {
        padding: 25px 20px !important;
    }
    
    .mad-hours-list {
        gap: 12px;
    }
    
    .mad-hours-row {
        padding-bottom: 10px;
    }
    
    .mad-hours-day {
        margin-right: 15px;
        font-size: 15px !important;
    }
    
    .mad-hours-time {
        font-size: 15px !important;
    }
    
    .mad-footer-notice {
        font-size: 12px !important;
        margin-top: 15px;
    }
}

/* Small screens - still avoid text wrapping */
@media (max-width: 480px) {
    .mad-office-hours-container {
        padding: 20px 15px;
        gap: 12px;
    }
    
    .mad-icon-frame {
        width: 60px !important;
        height: 60px !important;
        margin-bottom: -6px;
    }
    
    .mad-icon-frame .siteorigin-widget-icon {
        font-size: 28px !important;
    }
    
    .mad-office-title {
        font-size: 18px !important;
        margin-bottom: 12px;
    }
    
    .mad-hours-card {
        padding: 20px 15px !important;
    }
    
    .mad-hours-list {
        gap: 10px;
    }
    
    .mad-hours-row {
        padding-bottom: 8px;
        min-height: 20px;
    }
    
    .mad-hours-day {
        margin-right: 12px;
        font-size: 13px !important;
    }
    
    .mad-hours-time {
        font-size: 13px !important;
    }
    
    .mad-footer-notice {
        font-size: 11px !important;
        margin-top: 12px;
        gap: 5px;
    }
    
    .mad-footer-text {
        line-height: 1.2;
    }
}

/* Subtle hover effects */
.mad-office-hours-widget:hover .mad-icon-frame {
    transform: scale(1.05);
}

/* Ensure proper spacing in different contexts */
.panel-grid-cell .mad-office-hours-widget,
.so-panel .mad-office-hours-widget {
    margin: 0;
}

/* Print styles */
@media print {
    .mad-office-hours-widget:hover .mad-icon-frame {
        transform: none;
    }
    
    .mad-office-hours-container {
        background: #f5f5f5 !important;
        color: #333 !important;
    }
    
    .mad-office-title,
    .mad-hours-day,
    .mad-hours-time,
    .mad-footer-notice {
        color: #333 !important;
    }
}

/* Focus states for accessibility */
.mad-office-hours-widget:focus-within .mad-icon-frame {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Smooth transitions */
.mad-icon-frame {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Ensure icons are properly aligned */
.mad-icon-frame .siteorigin-widget-icon,
.mad-footer-icon .siteorigin-widget-icon {
    line-height: 1;
    vertical-align: middle;
}

/* Professional layout - no text wrapping allowed */
.mad-hours-day,
.mad-hours-time {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}