/**
 * Classes Module - Frontend Styles
 */

/* Price Display */
.class-likely-price {
    display: block;
    font-size: 1.5em;
    margin-bottom: 5px;
}

.class-likely-price .price-label {
    font-size: 0.7em;
    color: #666;
    display: block;
}

.class-price-range {
    display: block;
    font-size: 0.9em;
    color: #666;
}

.class-final-price {
    font-size: 1.5em;
    color: #46b450;
    font-weight: bold;
}

.class-price-tbd {
    color: #856404;
    font-style: italic;
}

/* Pricing Info Box */
.class-pricing-info {
    background: #f7f7f7;
    padding: 15px;
    border-radius: 5px;
    margin: 15px 0;
    border-left: 4px solid #0073aa;
}

.class-pricing-info .commitment-status {
    font-size: 1.1em;
    margin-bottom: 10px;
}

.class-pricing-info .commitment-status .separator {
    color: #ccc;
    margin: 0 10px;
}

.class-pricing-info .minimum-notice {
    background: #fff3cd;
    padding: 10px;
    border-radius: 4px;
    margin: 10px 0;
    color: #856404;
}

.class-pricing-info .pricing-explanation {
    font-size: 0.9em;
    color: #666;
    font-style: italic;
}

.class-pricing-info .dashicons {
    vertical-align: middle;
    margin-right: 5px;
}

/* Schedule Display - List Format */
.class-schedule {
    margin: 20px 0;
}

.class-schedule h3 {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #0073aa;
}

/* Schedule section - add right margin for product form spacing */
.class-schedule.class-schedule-list {
    margin-right: 20px;
}

/* Venue + Calendar Subscribe Row */
.class-venue-calendar-row {
    display: flex;
    justify-content: space-between;
    align-items: stretch; /* Match heights */
    gap: 20px;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 5px;
}

/* Venue styling */
.class-venue {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    flex: 1;
    padding-right: 20px;
    border-right: 1px solid #e0e0e0;
}

.class-venue .dashicons-location {
    color: #0073aa;
    margin-top: 2px;
}

.class-venue .venue-details {
    flex: 1;
}

.class-venue .venue-details strong {
    display: block;
    font-size: 1.1em;
    margin-bottom: 5px;
}

.class-venue .venue-address {
    color: #666;
    line-height: 1.5;
}

.class-venue .venue-street,
.class-venue .venue-city-state {
    display: block;
}

/* Calendar subscribe widget - expanded width */
.class-calendar-subscribe {
    flex-shrink: 0;
    min-width: 280px;
    max-width: 320px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-left: 10px;
}

.class-calendar-subscribe h4 {
    margin: 0 0 8px 0;
    font-size: 1em;
}

.class-calendar-subscribe .calendar-subscribe-note {
    margin: 0 0 12px 0;
    font-size: 0.85em;
    color: #666;
    line-height: 1.4;
}

.class-calendar-subscribe .calendar-subscribe-button {
    display: inline-block;
    font-size: 0.9em;
    padding: 10px 20px;
}

.class-calendar-subscribe .calendar-subscribe-links {
    margin-top: 10px;
    font-size: 0.8em;
}

.class-calendar-subscribe .calendar-subscribe-links a {
    margin: 0 8px;
    white-space: nowrap;
}

/* Schedule list - full width */
.class-schedule-list .schedule-list {
    margin: 0;
    padding: 0;
}

/* Full-width description below */
.class-description-full {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.class-description-full h4 {
    margin-bottom: 10px;
}

/* Responsive: Stack on mobile */
@media (max-width: 600px) {
    .class-venue-calendar-row {
        flex-direction: column;
    }
    
    .class-calendar-subscribe {
        max-width: 100%;
        width: 100%;
        margin-top: 15px;
        padding-top: 15px;
        border-top: 1px solid #ddd;
    }
}

.class-schedule .class-venue {
    background: #e8f4fd;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
}

.class-schedule .class-venue .dashicons {
    color: #0073aa;
    margin-right: 5px;
    vertical-align: middle;
}

.class-schedule .class-venue .venue-address {
    margin-left: 25px;
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
    line-height: 1.5;
}

/* Right column - Description and Calendar */
.class-short-description {
    margin-bottom: 25px;
}

.class-short-description h4,
.class-calendar-subscribe h4 {
    margin: 0 0 10px 0;
    font-size: 1.1em;
    color: #333;
}

.class-calendar-subscribe {
    background: #f7f7f7;
    padding: 20px;
    border-radius: 8px;
}

.calendar-subscribe-note {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 15px;
}

.calendar-subscribe-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #0073aa;
    color: #fff !important;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
}

.calendar-subscribe-button:hover {
    background: #005a87;
}

.calendar-subscribe-button .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

.calendar-subscribe-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #ddd;
}

.calendar-subscribe-links a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9em;
    color: #666;
    text-decoration: none;
}

.calendar-subscribe-links a:hover {
    color: #0073aa;
}

.calendar-subscribe-links .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* Hide product type label for Class products */
.single-product.product-type-class .product_meta .posted_in::before {
    content: none;
}

/* Ensure breadcrumbs have enough space */
.woocommerce-breadcrumb {
    padding-top: 10px;
    margin-bottom: 20px;
}

.class-schedule-list .schedule-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.class-schedule-list .schedule-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    gap: 10px;
}

.class-schedule-list .schedule-item:last-child {
    border-bottom: none;
}

.class-schedule-list .schedule-item:hover {
    background: #f9f9f9;
}

.class-schedule-list .session-number {
    background: #0073aa;
    color: #fff;
    padding: 3px 10px;
    border-radius: 3px;
    font-size: 0.85em;
    font-weight: 500;
}

.class-schedule-list .session-number-link {
    display: inline-block;
    background: #0073aa;
    color: #fff;
    padding: 3px 10px;
    border-radius: 3px;
    font-size: 0.85em;
    font-weight: 500;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.class-schedule-list .session-number-link:hover {
    background: #005a87;
    color: #fff;
    text-decoration: none;
}

.class-schedule-list .session-number-link:visited {
    color: #fff;
}

.class-schedule-list .session-date {
    flex: 1;
    font-weight: 500;
}

.class-schedule-list .session-time {
    color: #666;
}

.class-schedule-list .session-status {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.8em;
    font-weight: 500;
}

.class-schedule-list .session-status.cancelled {
    background: #f8d7da;
    color: #721c24;
}

.class-schedule-list .session-status.modified {
    background: #fff3cd;
    color: #856404;
}

.class-schedule-list .schedule-item.cancelled {
    opacity: 0.6;
}

.class-schedule-list .schedule-item.cancelled .session-date,
.class-schedule-list .schedule-item.cancelled .session-time {
    text-decoration: line-through;
}

/* Schedule Display - Table Format */
.class-schedule-table .schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.class-schedule-table .schedule-table th,
.class-schedule-table .schedule-table td {
    padding: 10px 15px;
    text-align: left;
    border: 1px solid #ddd;
}

.class-schedule-table .schedule-table th {
    background: #0073aa;
    color: #fff;
    font-weight: 500;
}

.class-schedule-table .schedule-table tr:nth-child(even) {
    background: #f9f9f9;
}

.class-schedule-table .schedule-table tr:hover {
    background: #e8f4fd;
}

.class-schedule-table .schedule-table tr.cancelled {
    opacity: 0.6;
}

.class-schedule-table .schedule-table tr.cancelled td {
    text-decoration: line-through;
}

.class-schedule-table .status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.85em;
}

.class-schedule-table .status-badge.scheduled {
    background: #d4edda;
    color: #155724;
}

.class-schedule-table .status-badge.cancelled {
    background: #f8d7da;
    color: #721c24;
}

.class-schedule-table .status-badge.modified {
    background: #fff3cd;
    color: #856404;
}

/* Schedule Display - Calendar Format */
.class-schedule-calendar .calendar-months {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.class-schedule-calendar .calendar-month {
    flex: 1;
    min-width: 200px;
    background: #f7f7f7;
    border-radius: 5px;
    padding: 15px;
}

.class-schedule-calendar .calendar-month h4 {
    margin: 0 0 15px 0;
    text-align: center;
    color: #0073aa;
}

.class-schedule-calendar .month-dates {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.class-schedule-calendar .date-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 10px;
    text-align: center;
    min-width: 60px;
}

.class-schedule-calendar .date-item.cancelled {
    opacity: 0.5;
    text-decoration: line-through;
}

.class-schedule-calendar .date-day {
    display: block;
    font-size: 1.5em;
    font-weight: bold;
    color: #0073aa;
}

.class-schedule-calendar .date-weekday {
    display: block;
    font-size: 0.8em;
    color: #666;
}

.class-schedule-calendar .date-time {
    display: block;
    font-size: 0.75em;
    color: #999;
    margin-top: 5px;
}

/* Pricing Widget */
.class-pricing-widget {
    background: #f7f7f7;
    padding: 20px;
    border-radius: 5px;
    margin: 20px 0;
}

.class-pricing-widget .pricing-final {
    text-align: center;
}

.class-pricing-widget .pricing-final .price-label {
    display: block;
    color: #666;
    margin-bottom: 5px;
}

.class-pricing-widget .pricing-final .price-amount {
    font-size: 2em;
    font-weight: bold;
    color: #46b450;
}

.class-pricing-widget .pricing-variable .likely-price {
    text-align: center;
    margin-bottom: 15px;
}

.class-pricing-widget .pricing-variable .likely-price .price-label {
    display: block;
    color: #666;
    margin-bottom: 5px;
}

.class-pricing-widget .pricing-variable .likely-price .price-amount {
    font-size: 2em;
    font-weight: bold;
    color: #0073aa;
}

.class-pricing-widget .price-range {
    text-align: center;
    margin-bottom: 15px;
    padding: 10px;
    background: #fff;
    border-radius: 4px;
}

.class-pricing-widget .price-range .range-label {
    display: block;
    font-size: 0.9em;
    color: #666;
}

.class-pricing-widget .commitment-stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 15px 0;
}

.class-pricing-widget .commitment-stats .stat {
    text-align: center;
}

.class-pricing-widget .commitment-stats .stat-value {
    display: block;
    font-size: 1.5em;
    font-weight: bold;
    color: #0073aa;
}

.class-pricing-widget .commitment-stats .stat-label {
    display: block;
    font-size: 0.85em;
    color: #666;
}

.class-pricing-widget .pricing-note {
    text-align: center;
    font-size: 0.9em;
    color: #666;
    font-style: italic;
    margin: 15px 0 0 0;
}

.class-pricing-widget .pricing-chart {
    text-align: center;
    margin: 15px 0;
}

.class-pricing-widget .pricing-chart-svg {
    max-width: 100%;
    height: auto;
}

/* Responsive */
@media screen and (max-width: 900px) {
    .class-schedule-columns {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .schedule-column-left {
        border-right: none;
        padding-right: 0;
        border-bottom: 1px solid #eee;
        padding-bottom: 20px;
    }
    
    .schedule-column-right {
        padding-left: 0;
    }
}

@media screen and (max-width: 600px) {
    .class-schedule-list .schedule-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .class-schedule-list .session-date {
        width: 100%;
    }
    
    .class-schedule-table .schedule-table {
        font-size: 0.9em;
    }
    
    .class-schedule-table .schedule-table th,
    .class-schedule-table .schedule-table td {
        padding: 8px;
    }
    
    .class-pricing-widget .commitment-stats {
        flex-direction: column;
        gap: 15px;
    }
    
    .calendar-subscribe-links {
        flex-direction: column;
        gap: 10px;
    }
}

