/**
 * TutorEase Dashboard Styles
 *
 * @package TutorEase
 * @since 1.0.0
 */

/* ===================================
   Dashboard Menu Styles
   =================================== */

.tutorease-dashboard-menu {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 20px 0;
}

.tutorease-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.tutorease-menu-item {
    margin: 0;
    padding: 0;
}

.tutorease-menu-link {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    color: #333333;
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.tutorease-menu-link:hover {
    background-color: #f5f5f5;
    color: #2196F3;
    border-left-color: #2196F3;
}

.tutorease-menu-link.active {
    background-color: #e3f2fd;
    color: #2196F3;
    border-left-color: #2196F3;
    font-weight: 600;
}

.tutorease-menu-link i,
.tutorease-menu-link svg {
    margin-right: 12px;
    width: 18px;
    text-align: center;
    flex-shrink: 0;
}

.tutorease-menu-label {
    flex: 1;
}

/* ===================================
   Dashboard Router Styles
   =================================== */

.tutorease-dashboard-router {
    min-height: 200px;
}

.tutorease-router-debug {
    background: #f0f0f0;
    padding: 15px;
    margin-bottom: 20px;
    border-left: 4px solid #0073aa;
    border-radius: 4px;
}

.tutorease-router-debug p {
    margin: 5px 0;
    font-size: 14px;
}

.tutorease-router-debug code {
    background: #ffffff;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: monospace;
}

.tutorease-router-content {
    /* Content sections will be added here */
}

/* ===================================
   Section Title Styles
   =================================== */

.tutorease-section-title {
    margin: 0 0 20px 0;
    font-weight: 600;
    line-height: 1.3;
}

/* ===================================
   Header Component Styles
   =================================== */

/* User Avatar */
.tutorease-user-avatar-wrapper {
    display: inline-block;
}

.tutorease-user-avatar {
    display: inline-block;
    line-height: 0;
}

.tutorease-user-avatar img {
    display: block;
    object-fit: cover;
}

.tutorease-user-avatar.tutorease-placeholder svg {
    display: block;
}

/* User Name */
.tutorease-user-name-wrapper {
    display: inline-block;
}

.tutorease-user-name {
    display: inline-block;
    margin: 0;
}

.tutorease-user-name a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.tutorease-user-name a:hover {
    opacity: 0.7;
}

.tutorease-user-name-prefix {
    font-weight: normal;
    opacity: 0.7;
}

.tutorease-user-name-text {
    font-weight: 600;
}

/* User Role Badge */
.tutorease-role-badge-wrapper {
    display: inline-block;
}

.tutorease-role-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
}

.tutorease-role-badge i,
.tutorease-role-badge svg {
    font-size: 14px;
}

/* Instructor Rating */
.tutorease-instructor-rating-wrapper {
    display: inline-block;
}

.tutorease-instructor-rating,
.tutorease-no-rating {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tutorease-rating-icon {
    font-size: 16px;
}

.tutorease-rating-value {
    font-weight: 600;
}

/* Action Button */
.tutorease-action-button-wrapper {
    display: inline-block;
}

.tutorease-action-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.tutorease-action-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ===================================
   Course Grid Styles
   =================================== */

.tutorease-enrolled-courses-wrapper,
.tutorease-instructor-courses-wrapper {
    width: 100%;
}

.tutorease-courses-grid {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.tutorease-course-item {
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.tutorease-course-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-4px);
}

.tutorease-course-thumbnail {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    overflow: hidden;
    background: #f5f5f5;
}

.tutorease-course-thumbnail a,
.tutorease-course-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tutorease-course-thumbnail .tutorease-no-thumbnail {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    font-weight: 600;
}

.tutorease-course-status-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
    z-index: 10;
}

.tutorease-course-status-badge.status-publish {
    background-color: #4caf50;
}

.tutorease-course-status-badge.status-pending {
    background-color: #ff9800;
}

.tutorease-course-status-badge.status-draft {
    background-color: #9e9e9e;
}

.tutorease-course-status-badge.status-private {
    background-color: #607d8b;
}

.tutorease-course-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.tutorease-course-title {
    margin: 0 0 12px 0;
    font-size: 18px;
    line-height: 1.4;
}

.tutorease-course-title a {
    color: #333333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tutorease-course-title a:hover {
    color: #2196F3;
}

.tutorease-course-meta {
    margin-bottom: 16px;
    flex: 1;
}

.tutorease-course-progress,
.tutorease-course-students,
.tutorease-course-rating {
    margin-bottom: 10px;
}

.tutorease-progress-bar {
    width: 100%;
    height: 8px;
    background-color: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 6px;
}

.tutorease-progress-fill {
    height: 100%;
    background-color: #4caf50;
    transition: width 0.5s ease;
    border-radius: 4px;
}

.tutorease-progress-fill.is-complete {
    background-color: #2196F3;
}

.tutorease-progress-text {
    font-size: 13px;
    color: #666666;
}

.tutorease-course-students,
.tutorease-course-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #666666;
}

.tutorease-course-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.tutorease-course-button {
    flex: 1;
    padding: 10px 16px;
    text-align: center;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.tutorease-course-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.tutorease-edit-button {
    background-color: #2196F3;
    color: #ffffff;
}

.tutorease-view-button {
    background-color: #f5f5f5;
    color: #333333;
}

/* ===================================
   Loop Item Widgets
   =================================== */

/* Course Title */
.tutorease-loop-course-title {
    margin: 0;
}

.tutorease-loop-course-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tutorease-loop-course-title a:hover {
    color: #2196F3;
}

/* Course Image */
.tutorease-loop-course-image {
    display: block;
    line-height: 0;
}

.tutorease-loop-course-image img {
    display: block;
    width: 100%;
    height: auto;
}

/* Course Link */
.tutorease-loop-course-link-wrapper {
    display: block;
}

.tutorease-loop-course-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tutorease-loop-course-link:hover {
    opacity: 0.8;
}

/* Course Price */
.tutorease-loop-course-price-wrapper {
    display: block;
}

.tutorease-loop-course-price {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}

.tutorease-loop-course-price.is-free {
    color: #4caf50;
}

/* Course Instructor */
.tutorease-loop-course-instructor {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tutorease-instructor-avatar {
    line-height: 0;
}

.tutorease-instructor-avatar img {
    display: block;
}

.tutorease-instructor-info {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.tutorease-instructor-prefix {
    font-weight: normal;
    opacity: 0.7;
    margin-right: 4px;
}

.tutorease-instructor-name {
    font-weight: 600;
}

.tutorease-instructor-name a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.tutorease-instructor-name a:hover {
    color: #2196F3;
}

/* Course Rating */
.tutorease-loop-course-rating {
    display: inline-block;
}

.tutorease-has-rating,
.tutorease-no-rating {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tutorease-rating-icon {
    color: #f39c12;
}

.tutorease-rating-value {
    font-weight: 600;
}

.tutorease-rating-count {
    opacity: 0.7;
}

/* Course Progress */
.tutorease-loop-course-progress {
    width: 100%;
}

.tutorease-progress-label {
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
}

.tutorease-loop-course-progress .tutorease-progress-bar {
    position: relative;
    margin-bottom: 6px;
}

.tutorease-loop-course-progress .tutorease-progress-fill {
    display: flex;
    align-items: center;
    justify-content: center;
}

.tutorease-progress-percentage {
    font-size: 13px;
    font-weight: 500;
}

.tutorease-progress-fill .tutorease-progress-percentage {
    color: #ffffff;
    font-size: 11px;
}

/* Resume Button */
.tutorease-resume-button-wrapper {
    display: block;
}

.tutorease-resume-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.tutorease-resume-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Status Badge */
.tutorease-status-badge-wrapper {
    display: inline-block;
}

.tutorease-status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

/* Enrolled Count */
.tutorease-enrolled-count {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tutorease-count-icon {
    font-size: 16px;
}

/* Course Duration */
.tutorease-course-duration {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tutorease-duration-icon {
    font-size: 16px;
}

.tutorease-duration-prefix {
    font-weight: normal;
    opacity: 0.7;
}

/* Edit Button */
.tutorease-edit-button-wrapper {
    display: block;
}

.tutorease-edit-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.tutorease-edit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* ===================================
   Empty State Styles
   =================================== */

.tutorease-empty-state {
    text-align: center;
    padding: 60px 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.tutorease-empty-icon {
    margin: 0 auto 20px;
    width: 100px;
    height: 100px;
}

.tutorease-empty-icon svg {
    width: 100%;
    height: 100%;
}

.tutorease-empty-message {
    font-size: 16px;
    color: #666666;
    margin: 0 0 20px 0;
}

.tutorease-browse-button,
.tutorease-create-button {
    display: inline-block;
    padding: 12px 24px;
    background-color: #2196F3;
    color: #ffffff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tutorease-browse-button:hover,
.tutorease-create-button:hover {
    background-color: #1976D2;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

/* ===================================
   Pagination Styles
   =================================== */

.tutorease-pagination {
    margin-top: 30px;
    text-align: center;
}

.tutorease-pagination .page-numbers {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 4px;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    color: #333333;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tutorease-pagination .page-numbers:hover,
.tutorease-pagination .page-numbers.current {
    background-color: #2196F3;
    color: #ffffff;
    border-color: #2196F3;
}

.tutorease-pagination .page-numbers.dots {
    border: none;
    background: transparent;
}

/* ===================================
   Editor Notices
   =================================== */

.tutorease-editor-notice {
    background: #f0f0f0;
    padding: 20px;
    border-left: 4px solid #2196F3;
    border-radius: 4px;
    margin: 20px 0;
}

.tutorease-editor-notice p {
    margin: 10px 0;
    font-size: 14px;
}

.tutorease-editor-notice strong {
    color: #2196F3;
}

/* ===================================
   TutorLMS Not Active Notice
   =================================== */

.tutorease-notice {
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

.tutorease-notice-warning {
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
    color: #856404;
}

.tutorease-notice p {
    margin: 8px 0;
}

.tutorease-notice strong {
    font-weight: 600;
}

/* ===================================
   Responsive Styles
   =================================== */

@media screen and (max-width: 782px) {
    .tutorease-dashboard-menu {
        padding: 10px 0;
    }

    .tutorease-menu-link {
        padding: 10px 16px;
    }

    .tutorease-course-item {
        margin-bottom: 16px;
    }

    .tutorease-course-content {
        padding: 16px;
    }

    .tutorease-course-title {
        font-size: 16px;
    }

    .tutorease-course-actions {
        flex-direction: column;
    }

    .tutorease-empty-state {
        padding: 40px 16px;
    }
}

@media screen and (max-width: 480px) {
    .tutorease-menu-link {
        font-size: 14px;
    }

    .tutorease-menu-link i,
    .tutorease-menu-link svg {
        width: 16px;
        margin-right: 8px;
    }

    .tutorease-course-title {
        font-size: 15px;
    }
}

/* ===================================
   Utility Classes
   =================================== */

.tutorease-hide {
    display: none !important;
}

.tutorease-show {
    display: block !important;
}

.tutorease-text-center {
    text-align: center;
}

.tutorease-text-left {
    text-align: left;
}

.tutorease-text-right {
    text-align: right;
}

/* ===================================
   Accessibility
   =================================== */

.tutorease-screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    width: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
}

/* Focus styles for keyboard navigation */
.tutorease-menu-link:focus,
.tutorease-course-button:focus,
.tutorease-action-button:focus,
.tutorease-resume-button:focus,
.tutorease-edit-button:focus {
    outline: 2px solid #2196F3;
    outline-offset: 2px;
}

/* ===================================
   Print Styles
   =================================== */

@media print {
    .tutorease-dashboard-menu,
    .tutorease-course-actions,
    .tutorease-pagination {
        display: none;
    }

    .tutorease-course-item {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #e0e0e0;
    }
}


/* ===================================
   Notification Styles
   =================================== */

.tutorease-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    z-index: 99999;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
    max-width: 400px;
    font-size: 14px;
}

.tutorease-notification.show {
    opacity: 1;
    transform: translateX(0);
}

.tutorease-notification-info {
    border-left: 4px solid #2196F3;
    color: #333333;
}

.tutorease-notification-success {
    border-left: 4px solid #4caf50;
    color: #333333;
}

.tutorease-notification-error {
    border-left: 4px solid #f44336;
    color: #333333;
}

.tutorease-notification-warning {
    border-left: 4px solid #ff9800;
    color: #333333;
}

@media screen and (max-width: 480px) {
    .tutorease-notification {
        left: 20px;
        right: 20px;
        max-width: none;
    }
}