/**
 * Adaptive Plan System Styles
 * Styling for the adaptive plan adjustment popup and notifications
 */

/* Popup Overlay */
.yrt-adaptive-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 9998;
    backdrop-filter: blur(2px);
}

/* Popup Container */
.yrt-adaptive-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    background: #f1ebe7;
    border-radius: 8px;
    border: 2px solid #d0ee88;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 9999;
    overflow: hidden;
    font-family: 'Rajdhani', sans-serif;
    color: #17131b;
    flex-direction: column;
}

.yrt-adaptive-popup[style*="display: block"],
.yrt-adaptive-popup:not([style*="display: none"]) {
    display: flex !important;
}

/* Popup Header */
.yrt-adaptive-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    background: #d0ee88;
    color: #17131b;
    border-bottom: 2px solid #16361c;
    flex-shrink: 0;
}

.yrt-adaptive-popup-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    font-family: 'League Spartan', 'Rajdhani', sans-serif;
    text-transform: uppercase;
    color: #17131b;
    letter-spacing: 1px;
}

.yrt-popup-close {
    background: none;
    border: 2px solid #17131b;
    color: #17131b;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
    font-weight: bold;
}

.yrt-popup-close:hover {
    background-color: #17131b;
    color: #d0ee88;
    transform: rotate(90deg);
}

/* Popup Content */
.yrt-adaptive-popup-content {
    padding: 24px;
    overflow-y: auto;
    overflow-x: hidden;
    background: #f1ebe7;
    flex: 1;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
}

.yrt-popup-intro {
    font-size: 16px;
    color: #17131b;
    margin-bottom: 20px;
    line-height: 1.6;
    font-weight: 500;
}

/* Missed Distance Summary */
.yrt-missed-distance-summary {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px;
    background: #ffffff;
    border-radius: 8px;
    border: 2px solid #d0ee88;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.yrt-metric {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.yrt-metric-label {
    font-size: 14px;
    color: #17131b;
    font-weight: 600;
}

.yrt-metric-value {
    font-size: 16px;
    color: #16361c;
    font-weight: 700;
}

.yrt-metric:first-child .yrt-metric-value {
    color: #e74c3c;
    font-size: 18px;
    font-weight: 800;
}

/* Adjustments Preview */
.yrt-adjustments-preview {
    margin-top: 24px;
    padding: 16px;
    background: #ffffff;
    border-radius: 8px;
    border: 2px solid #d0ee88;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    max-height: 400px;
    overflow-y: auto;
}

.yrt-adjustments-preview::-webkit-scrollbar {
    width: 8px;
}

.yrt-adjustments-preview::-webkit-scrollbar-track {
    background: #f1ebe7;
    border-radius: 4px;
}

.yrt-adjustments-preview::-webkit-scrollbar-thumb {
    background: #16361c;
    border-radius: 4px;
}

.yrt-adjustments-preview::-webkit-scrollbar-thumb:hover {
    background: #d0ee88;
}

.yrt-adjustments-preview h4 {
    margin: 0 0 16px 0;
    font-size: 18px;
    color: #16361c;
    font-weight: 700;
    font-family: 'League Spartan', 'Rajdhani', sans-serif;
    text-transform: uppercase;
}

.yrt-adjustments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.yrt-adjustment-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
    background: #ffffff;
    border-radius: 6px;
    border-left: 3px solid #16361c;
}

.yrt-adjustment-week-item {
    margin-bottom: 16px;
    padding: 16px;
    background: #ffffff;
    border-radius: 8px;
    border: 2px solid #d0ee88;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.yrt-adjustment-week-item.yrt-excluded-week {
    background: #f8f8f8;
    border-left: 3px solid #95a5a6;
    border: 2px solid #bdc3c7;
    opacity: 0.85;
}

.yrt-week-type-badge {
    display: inline-block;
    padding: 4px 10px;
    background: #95a5a6;
    color: #ffffff;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 8px;
}

.yrt-excluded-message {
    color: #7f8c8d;
    font-style: italic;
    font-weight: 500;
    font-size: 14px;
}

/* Beta Badge */
.yrt-beta-badge {
    display: inline-block;
    background: #f39c12;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 8px;
    vertical-align: middle;
}

/* Pace Warning Icon */
.yrt-pace-warning-icon {
    display: inline-block;
    color: #e67e22;
    font-size: 16px;
    margin-left: 6px;
    cursor: help;
    vertical-align: middle;
}

.yrt-pace-warning-icon:hover {
    color: #d35400;
    transform: scale(1.1);
}

/* Quality Workout Warning in Popup */
.yrt-quality-workout-warning {
    border-left: 3px solid #e67e22;
    background: #fef5e7;
}

.yrt-pace-warning-badge {
    display: inline-block;
    background: #e67e22;
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 12px;
    margin-left: 8px;
    vertical-align: middle;
    cursor: help;
}

.yrt-quality-workout-warning-message {
    margin-top: 8px;
    padding: 10px;
    background: #fef5e7;
    border-left: 3px solid #e67e22;
    border-radius: 4px;
    font-size: 13px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.yrt-warning-icon {
    color: #e67e22;
    font-size: 16px;
    flex-shrink: 0;
}

.yrt-warning-text {
    color: #7f8c8d;
    line-height: 1.5;
}

/* Popup Quality Workout Warning */
.yrt-popup-quality-warning {
    margin: 20px 0;
    padding: 16px;
    background: #fef5e7;
    border: 2px solid #e67e22;
    border-radius: 8px;
}

.yrt-popup-warning-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 16px;
    color: #d35400;
}

.yrt-warning-icon-large {
    font-size: 20px;
}

.yrt-popup-warning-text {
    color: #7f8c8d;
    line-height: 1.6;
    margin: 0;
}

.yrt-adjustment-week-item:last-child {
    margin-bottom: 0;
}

/* Visual feedback for unchecked weeks is handled via JavaScript */

.yrt-week-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 12px;
}

.yrt-week-header-left-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.yrt-week-label {
    font-size: 16px;
    font-weight: 700;
    color: #16361c;
    font-family: 'League Spartan', 'Rajdhani', sans-serif;
}

.yrt-distribution-badge {
    font-size: 13px;
    font-weight: 600;
    color: #17131b;
    background: #d0ee88;
    padding: 4px 10px;
    border-radius: 4px;
    border: 1px solid #16361c;
}

.yrt-strategy-text {
    font-size: 14px;
    font-weight: 600;
    color: #16361c;
    font-style: italic;
}

.yrt-week-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.yrt-week-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #16361c;
}

.yrt-checkbox-text {
    font-size: 14px;
    font-weight: 600;
    color: #17131b;
}

.yrt-week-total-summary {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.yrt-distance-old {
    font-size: 14px;
    color: #999;
    text-decoration: line-through;
}

.yrt-arrow {
    font-size: 16px;
    color: #16361c;
    font-weight: bold;
}

.yrt-distance-new {
    font-size: 15px;
    font-weight: 700;
    color: #16361c;
}

.yrt-adjustment-amount {
    font-size: 13px;
    color: #e74c3c;
    font-weight: 600;
}

.yrt-week-runs-details {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 2px solid #d0ee88;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.yrt-run-adjustment {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: #f1ebe7;
    border-radius: 6px;
    border: 1px solid #d0ee88;
    flex-wrap: wrap;
    gap: 8px;
}

.yrt-run-day {
    font-size: 13px;
    font-weight: 600;
    color: #17131b;
    min-width: 120px;
}

.yrt-run-distance {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.yrt-run-old {
    font-size: 13px;
    color: #999;
    text-decoration: line-through;
}

.yrt-arrow-small {
    font-size: 12px;
    color: #16361c;
    font-weight: bold;
}

.yrt-run-new {
    font-size: 13px;
    font-weight: 700;
    color: #16361c;
}

.yrt-adjustments-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 2px solid #d0ee88;
    flex-wrap: wrap;
}

.yrt-select-all-weeks-btn,
.yrt-deselect-all-weeks-btn {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border: 2px solid #16361c;
    border-radius: 6px;
    background: #ffffff;
    color: #16361c;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Rajdhani', sans-serif;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.yrt-select-all-weeks-btn:hover,
.yrt-deselect-all-weeks-btn:hover {
    background: #16361c;
    color: #f1ebe7;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.yrt-adjustment-details {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

.yrt-popup-explanation {
    margin-top: 24px;
    font-size: 15px;
    color: #17131b;
    line-height: 1.6;
    padding: 16px;
    background: #ffffff;
    border-radius: 8px;
    border: 2px solid #d0ee88;
    font-weight: 500;
}

/* Popup Footer */
.yrt-adaptive-popup-footer {
    display: flex;
    justify-content: stretch;
    gap: 12px;
    padding: 20px 24px;
    background: #f1ebe7;
    border-top: 2px solid #d0ee88;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.yrt-popup-btn {
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 700;
    border: 2px solid;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Rajdhani', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex: 1;
    min-width: 0;
}

.yrt-popup-apply-selected {
    background: #d0ee88;
    border-color: #16361c;
    color: #17131b;
}

.yrt-popup-apply-selected:hover {
    background: #16361c;
    color: #f1ebe7;
}

.yrt-popup-upgrade-plan {
    background: #d0ee88;
    border-color: #16361c;
    color: #17131b;
}

.yrt-popup-upgrade-plan:hover {
    background: #16361c;
    color: #f1ebe7;
}

.yrt-popup-no-changes {
    background: #ffffff;
    border-color: #17131b;
    color: #17131b;
}

.yrt-popup-no-changes:hover {
    background: #17131b;
    color: #f1ebe7;
}

.yrt-popup-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Success Notification */
.yrt-adaptive-success {
    display: none;
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #ffffff;
    padding: 16px 24px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Rajdhani', sans-serif;
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.yrt-success-icon {
    font-size: 24px;
    font-weight: bold;
}

.yrt-success-message {
    font-size: 16px;
    font-weight: 500;
}

/* Complete Week Button */
.yrt-complete-week-btn {
    margin-left: 12px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    border: 2px solid #16361c;
    border-radius: 6px;
    background: #d0ee88;
    color: #17131b;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Rajdhani', sans-serif;
    white-space: nowrap;
}

.yrt-complete-week-btn:hover {
    background: #16361c;
    color: #f1ebe7;
}

.yrt-complete-week-btn:active {
    transform: translateY(0);
}

.yrt-complete-week-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Next Week Button - Prominent Primary Action */
.yrt-next-week-btn {
    margin-left: 12px;
    padding: 12px 24px !important;
    font-size: 18px;
    font-weight: 700;
    background-color: #16361c !important;
    background: #16361c !important;
    color: #d0ee88 !important;
    border: 2px solid #16361c !important;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'League Spartan', 'Rajdhani', sans-serif;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.yrt-next-week-btn:hover {
    background: #1a3f22 !important;
    background-color: #1a3f22 !important;
    color: #e0f098 !important;
    border-color: #1a3f22 !important;
}

.yrt-next-week-btn:active {
    transform: translateY(1px);
}

.yrt-next-week-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #ccc;
    border-color: #999;
    color: #666;
}

/* Completion Message */
.yrt-completion-message {
    display: none;
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #ffffff;
    padding: 16px 24px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10001;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    min-width: 300px;
    max-width: 90%;
    animation: slideDown 0.3s ease-out;
}

/* Week Completion Badge */
.yrt-week-completed-badge {
    margin-left: 12px;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Rajdhani', sans-serif;
    white-space: nowrap;
    min-width: fit-content;
}

/* Unmark Week Button */
.yrt-unmark-week-btn {
    margin-left: 8px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border: 2px solid #e74c3c;
    border-radius: 6px;
    background: #ffffff;
    color: #e74c3c;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Rajdhani', sans-serif;
    white-space: nowrap;
}

.yrt-unmark-week-btn:hover:not(:disabled) {
    background: #e74c3c;
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(231, 76, 60, 0.3);
}

.yrt-unmark-week-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Unmarked Runs Notification */
.yrt-unmarked-runs-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 10001;
    backdrop-filter: blur(2px);
}

.yrt-unmarked-runs-notification {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #f1ebe7;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 10002;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    font-family: 'Rajdhani', sans-serif;
    color: #17131b;
}

.yrt-unmarked-runs-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: linear-gradient(135deg, #d0ee88 0%, #16361c 100%);
    border-radius: 12px 12px 0 0;
    color: #17131b;
}

.yrt-unmarked-runs-header h3 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    font-family: 'League Spartan', 'Rajdhani', sans-serif;
    text-transform: uppercase;
}

.yrt-notification-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #17131b;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.yrt-notification-close:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: rotate(90deg);
}

.yrt-unmarked-runs-content {
    padding: 20px;
}

.yrt-unmarked-runs-content p {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #17131b;
}

.yrt-unmarked-runs-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.yrt-unmarked-run-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    background: #ffffff;
    border: 2px solid #d0ee88;
    border-radius: 8px;
    transition: all 0.2s;
}

.yrt-unmarked-run-item:hover {
    border-color: #16361c;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.yrt-unmarked-run-info {
    flex: 1;
    font-size: 16px;
    color: #17131b;
}

.yrt-unmarked-run-info strong {
    color: #16361c;
    font-weight: 700;
}

.yrt-unmarked-run-actions {
    display: flex;
    gap: 10px;
}

.yrt-mark-done-btn,
.yrt-mark-missed-btn {
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    border: 2px solid;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Rajdhani', sans-serif;
    white-space: nowrap;
}

.yrt-mark-done-btn {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    border-color: #11998e;
    color: #ffffff;
}

.yrt-mark-done-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(17, 153, 142, 0.4);
}

.yrt-mark-missed-btn {
    background: #ffffff;
    border-color: #e74c3c;
    color: #e74c3c;
}

.yrt-mark-missed-btn:hover:not(:disabled) {
    background: #e74c3c;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

.yrt-mark-done-btn:disabled,
.yrt-mark-missed-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Custom Popup System */
.yrt-custom-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    backdrop-filter: blur(2px);
}

.yrt-custom-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 500px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: 10001;
    overflow: hidden;
    font-family: 'Rajdhani', sans-serif;
    animation: popupSlideIn 0.3s ease-out;
}

@keyframes popupSlideIn {
    from {
        transform: translate(-50%, -60%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%);
        opacity: 1;
    }
}

.yrt-custom-popup-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 24px;
    border-bottom: 2px solid #e0e0e0;
}

.yrt-custom-popup-header.yrt-popup-title-confirm {
    background: #d0ee88;
    color: #17131b;
    border-bottom-color: #16361c;
}

.yrt-custom-popup-header.yrt-popup-title-info {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.2);
}

.yrt-custom-popup-header.yrt-popup-title-warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.2);
}

.yrt-custom-popup-header.yrt-popup-title-error {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.2);
}

.yrt-popup-icon {
    font-size: 28px;
    font-weight: bold;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
}

.yrt-custom-popup-header h3 {
    margin: 0;
    flex: 1;
    font-size: 20px;
    font-weight: 600;
}

.yrt-custom-popup-close {
    background: none;
    border: none;
    color: inherit;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
    opacity: 0.8;
}

.yrt-custom-popup-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
    opacity: 1;
}

.yrt-custom-popup-content {
    padding: 24px;
    max-height: 60vh;
    overflow-y: auto;
}

.yrt-custom-popup-message {
    font-size: 15px;
    line-height: 1.6;
    color: #333;
}

.yrt-custom-popup-message p {
    margin: 0 0 12px 0;
}

.yrt-custom-popup-message p:last-child {
    margin-bottom: 0;
}

.yrt-popup-warning-text {
    color: #e67e22;
    font-weight: 600;
    margin: 12px 0 8px 0;
}

.yrt-popup-info-box {
    background: #e8f4f8;
    border-left: 4px solid #11998e;
    padding: 12px 16px;
    margin: 16px 0;
    border-radius: 4px;
    font-size: 14px;
}

.yrt-popup-details {
    background: #fff9e6;
    border: 1px solid #ffc107;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
}

.yrt-popup-list {
    margin: 12px 0;
    padding-left: 20px;
}

.yrt-popup-list li {
    margin: 8px 0;
    line-height: 1.5;
}

.yrt-popup-note {
    font-size: 13px;
    color: #666;
    font-style: italic;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #e0e0e0;
}

.yrt-custom-popup-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 20px 24px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
}

.yrt-custom-popup-btn {
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Rajdhani', sans-serif;
    min-width: 120px;
}

.yrt-custom-popup-cancel {
    background: #e0e0e0;
    color: #333;
}

.yrt-custom-popup-cancel:hover {
    background: #d0d0d0;
    transform: translateY(-1px);
}

.yrt-custom-popup-confirm {
    background: #d0ee88;
    color: #17131b;
    border-color: #16361c;
}

.yrt-custom-popup-confirm:hover {
    background: #16361c;
    color: #f1ebe7;
}

/* Loading Popup */
.yrt-loading-popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10002;
    backdrop-filter: blur(2px);
}

.yrt-loading-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #ffffff;
    border-radius: 12px;
    padding: 32px 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: 10003;
    text-align: center;
    font-family: 'Rajdhani', sans-serif;
}

.yrt-loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #16361c;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

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

.yrt-loading-message {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .yrt-custom-popup {
        width: 95%;
        max-width: none;
    }
    
    .yrt-custom-popup-header {
        padding: 16px 20px;
    }
    
    .yrt-custom-popup-header h3 {
        font-size: 18px;
    }
    
    .yrt-custom-popup-content {
        padding: 20px;
    }
    
    .yrt-custom-popup-footer {
        flex-direction: column;
        padding: 16px 20px;
    }
    
    .yrt-custom-popup-btn {
        width: 100%;
    }
}

@keyframes slideDown {
    from {
        transform: translateX(-50%) translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .yrt-adaptive-popup {
        width: 95%;
        max-height: 95vh;
        top: 50%;
        transform: translate(-50%, -50%);
    }
    
    .yrt-adaptive-popup-header {
        padding: 16px 20px;
        flex-shrink: 0;
    }
    
    .yrt-adaptive-popup-header h3 {
        font-size: 20px;
    }
    
    .yrt-adaptive-popup-content {
        padding: 20px;
        flex: 1;
        min-height: 0;
    }
    
    .yrt-adaptive-popup-footer {
        flex-direction: column;
        padding: 16px 20px;
        gap: 10px;
        flex-shrink: 0;
    }
    
    .yrt-popup-btn {
        width: 100%;
        flex: none;
        padding: 16px 20px;
        font-size: 15px;
    }
    
    .yrt-adjustments-preview {
        max-height: 300px;
    }
    
    .yrt-week-header-row {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .yrt-week-total-summary {
        width: 100%;
        justify-content: flex-start;
    }
    
    .yrt-run-adjustment {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .yrt-adaptive-popup {
        width: 98%;
        max-width: none;
        max-height: 95vh;
        top: 50%;
        transform: translate(-50%, -50%);
    }
    
    .yrt-adaptive-popup-header {
        padding: 14px 16px;
        flex-shrink: 0;
    }
    
    .yrt-adaptive-popup-header h3 {
        font-size: 18px;
    }
    
    .yrt-popup-btn {
        font-size: 14px;
        padding: 14px 16px;
    }
    
    .yrt-adaptive-popup-content {
        padding: 16px;
        flex: 1;
        min-height: 0;
    }
    
    .yrt-adaptive-popup-footer {
        padding: 14px 16px;
        flex-shrink: 0;
    }
    
    .yrt-run-distance {
        width: 100%;
    }
    
    .yrt-adjustments-actions {
        flex-direction: column;
    }
    
    .yrt-select-all-weeks-btn,
    .yrt-deselect-all-weeks-btn {
        width: 100%;
    }
    
    .yrt-missed-distance-summary {
        padding: 12px;
    }
    
    .yrt-metric {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .yrt-adaptive-success {
        right: 10px;
        left: 10px;
        top: 10px;
    }
    
    .yrt-complete-week-btn {
        margin-left: 8px;
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .yrt-completion-message {
        left: 10px;
        right: 10px;
        transform: none;
        min-width: auto;
    }
    
    .yrt-complete-week-btn {
        margin-left: 0;
        margin-top: 8px;
        width: 100%;
        padding: 10px;
    }
    
    .yrt-undo-complete-btn {
        margin-left: 0;
        margin-top: 8px;
        width: 100%;
        padding: 8px;
    }
    
    .yrt-week-completed-badge {
        margin-left: 0;
        margin-top: 8px;
        display: block;
        width: fit-content;
    }
    
    .yrt-week-header-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .yrt-revert-plan-btn {
        margin-right: 0;
        margin-bottom: 8px;
        width: 100%;
        text-align: center;
    }
    
    .yrt-active-plan-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .yrt-active-plan-actions a,
    .yrt-active-plan-actions button {
        width: 100%;
        text-align: center;
    }
}

/* Scrollbar Styling for Popup Content */
.yrt-adaptive-popup-content::-webkit-scrollbar {
    width: 8px;
}

.yrt-adaptive-popup-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.yrt-adaptive-popup-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.yrt-adaptive-popup-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

