/* ==========================================================================
   Rectangle One — course page components
   --------------------------------------------------------------------------
   Course Overview: a quick-nav row of "link cards" plus designed section
   cards. Reuses the colour/shape/elevation tokens from r1-theme.css so it
   stays on-brand and works in both the light page surface and dark panels.

   Loaded only on the course-details page (see courseDetails.blade.php).
   ========================================================================== */

/* wrapper: nav + stack of cards */
.r1-ov {
    display: grid;
    gap: 1.25rem;
}

/* --------------------------------------------------------------------------
   Quick-nav "link cards" — jump to a section
   -------------------------------------------------------------------------- */
.r1-ov-nav {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(172px, 1fr));
    gap: 0.75rem;
    margin: 0 0 1.5rem;
    padding: 0;
    list-style: none;
}

.r1-ov-navcard {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.8rem 0.95rem;
    background: var(--r1-surface);
    border: var(--r1-hairline);
    border-radius: var(--r1-radius-md);
    box-shadow: var(--r1-shadow-sm);
    color: var(--r1-text);
    font-weight: 600;
    font-size: 0.92rem;
    line-height: 1.25;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.r1-ov-navcard i {
    flex-shrink: 0;
    color: var(--r1-gold);
    font-size: 1.15rem;
}

.r1-ov-navcard:hover {
    transform: translateY(-2px);
    box-shadow: var(--r1-shadow-md);
    border-color: var(--r1-blue);
    color: var(--r1-blue-deep);
}

.r1-ov-navcard:focus-visible {
    outline: 3px solid var(--r1-sky);
    outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   Section cards
   -------------------------------------------------------------------------- */
.r1-ov-card {
    position: relative;
    padding: 1.5rem 1.6rem;
    background: var(--r1-surface);
    border: var(--r1-hairline);
    border-radius: var(--r1-radius-lg);
    box-shadow: var(--r1-shadow-md);
    scroll-margin-top: 120px; /* clears the fixed header when jumping */
}

.r1-ov-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    border-radius: var(--r1-radius-lg) 0 0 var(--r1-radius-lg);
    background: linear-gradient(180deg, var(--r1-blue), var(--r1-gold));
}

.r1-ov-head {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.r1-ov-ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border-radius: var(--r1-radius-base);
    background: rgba(40, 107, 240, 0.08);
    color: var(--r1-blue);
    font-size: 1.3rem;
}

.r1-ov-title {
    margin: 0;
    color: var(--r1-ink);
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
}

.r1-ov-body {
    color: var(--r1-text-variant);
    font-size: 1rem;
    line-height: 1.65;
}

.r1-ov-body > :last-child {
    margin-bottom: 0;
}

.r1-ov-body ul,
.r1-ov-body ol {
    margin: 0;
    padding-left: 1.15rem;
}

.r1-ov-body li {
    margin-bottom: 0.45rem;
}

.r1-ov-body li::marker {
    color: var(--r1-gold);
}

.r1-ov-body strong {
    color: var(--r1-ink);
}

.r1-ov-body a {
    color: var(--r1-blue);
    text-underline-offset: 2px;
}

/* pricing table inside a card */
.r1-ov-body table {
    width: 100%;
    border-collapse: collapse;
}

.r1-ov-body table th {
    padding: 0.6rem 0.75rem;
    border-bottom: var(--r1-hairline);
    color: var(--r1-text-muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-align: left;
}

.r1-ov-body table td {
    padding: 0.7rem 0.75rem;
    border-bottom: var(--r1-hairline);
    vertical-align: top;
}

.r1-ov-body table tr:last-child td {
    border-bottom: 0;
}

.r1-ov-body table tbody tr:hover td {
    background: var(--r1-surface-warm);
}

/* --------------------------------------------------------------------------
   Responsive + motion
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
    .r1-ov-card {
        padding: 1.15rem 1.1rem;
    }

    .r1-ov-card::before {
        width: 3px;
    }

    .r1-ov-title {
        font-size: 1.1rem;
    }

    .r1-ov-ico {
        width: 40px;
        height: 40px;
        font-size: 1.15rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .r1-ov-navcard {
        transition: none;
    }

    .r1-ov-navcard:hover {
        transform: none;
    }
}

/* --------------------------------------------------------------------------
   Course tab nav (Overview / Curriculum / Instructor / Reviews / QA) — pills
   -------------------------------------------------------------------------- */
.course_tabs .lms_tabmenu {
    gap: 0.5rem;
    border-bottom: 0;
}

.course_tabs .lms_tabmenu .nav-link {
    padding: 0.6rem 1.15rem;
    background: var(--r1-surface);
    border: var(--r1-hairline);
    border-radius: var(--r1-radius-full);
    color: var(--r1-text-variant);
    font-weight: 600;
    cursor: pointer;
    transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

.course_tabs .lms_tabmenu .nav-link:hover {
    border-color: var(--r1-blue);
    color: var(--r1-blue-deep);
}

.course_tabs .lms_tabmenu .nav-link.active {
    background: var(--r1-blue);
    border-color: var(--r1-blue);
    color: #fff;
}

.course_tabs .lms_tabmenu .nav-link:focus-visible {
    outline: 3px solid var(--r1-sky);
    outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   Course hero — brand panel (replaces the stock banner image)
   -------------------------------------------------------------------------- */
.breadcrumb_area.r1-chero {
    height: auto !important;
    padding: 2.75rem 0 3rem;
    background: linear-gradient(135deg, var(--r1-blue-deep) 0%, var(--r1-panel) 100%) !important;
    background-image: none !important;
}

.breadcrumb_area.r1-chero::before {
    display: none;
}

.r1-chero-cta .details_content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem 1.25rem;
    margin-top: 0.5rem;
}

.r1-chero-cta h4 {
    margin: 0;
    font-size: 1.6rem;
}

.r1-chero-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 44px;
    padding: 0.7rem 1.5rem;
    background: var(--r1-gold);
    color: var(--r1-ink) !important;
    font-weight: 700;
    border-radius: var(--r1-radius-full);
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.r1-chero-btn:hover {
    background: var(--r1-gold-light);
    color: var(--r1-ink) !important;
    transform: translateY(-1px);
    box-shadow: 0 10px 22px -8px rgba(227, 169, 43, 0.65);
}

.r1-chero-btn:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
}
