/* Checkout Page Styles */
.checkout-area {
    padding: 60px 0;
    background-color: var(--color-light);
    /* Default light bg */
}

body.active-dark-mode .checkout-area {
    background-color: var(--color-darker);
}

.checkout-card {
    background: var(--color-white);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border: 1px solid var(--color-border);
}

body.active-dark-mode .checkout-card {
    background: var(--color-card-6);
    /* Dark card bg */
    border-color: var(--color-border-2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.checkout-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--color-heading);
}

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    color: var(--color-body);
}

.form-control-custom {
    width: 100%;
    height: 50px;
    padding: 0 20px;
    border-radius: 6px;
    border: 1px solid var(--color-border);
    background: var(--color-white);
    color: var(--color-body);
    transition: border-color 0.3s;
}

body.active-dark-mode .form-control-custom {
    background: #2b303b;
    /* Darker input bg */
    border-color: #3b4252;
    color: #e5e9f0;
}

.form-control-custom:focus {
    border-color: var(--color-primary);
    outline: none;
}

.order-summary {
    background: var(--color-white);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid var(--color-border);
}

body.active-dark-mode .order-summary {
    background: var(--color-card-6);
    border-color: var(--color-border-2);
}

.summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 16px;
    color: var(--color-body);
}

.summary-item.total {
    border-top: 1px solid var(--color-border);
    padding-top: 15px;
    margin-top: 15px;
    font-weight: 800;
    font-size: 20px;
    color: var(--color-heading);
}

.coupon-section {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.apply-btn {
    background: var(--color-primary);
    color: #fff;
    border: none;
    padding: 0 25px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.apply-btn:hover {
    background: var(--color-primary-100);
}

.checkout-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(90deg, var(--color-secondary) 0%, var(--color-primary) 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(249, 141, 31, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
}

.checkout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 141, 31, 0.5);
}

/* Security Badge */
.security-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    font-size: 14px;
    color: var(--color-bodyest-2);
}

body.active-dark-mode .security-badge {
    color: var(--color-gray);
}

/* Course Mini Card in Summary */
.course-mini {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: center;
}

.course-mini img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
}

.course-mini-title {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--color-heading);
}

/* Alerts */
.alert-message {
    padding: 10px;
    border-radius: 6px;
    margin-top: 10px;
    display: none;
    font-size: 14px;
}

.alert-success {
    background: rgba(62, 183, 94, 0.1);
    color: var(--color-success);
    border: 1px solid var(--color-success);
}

.alert-error {
    background: rgba(255, 0, 3, 0.1);
    color: var(--color-danger);
    border: 1px solid var(--color-danger);
}

/* Glassmorphism Effect for Pro feel */
.glass-panel {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

body.active-dark-mode .glass-panel {
    background: rgba(30, 30, 40, 0.6);
}

/* Overriding Gradient Buttons for specific Pro Flat Look */
.rbt-btn.btn-gradient {
    background: var(--color-primary) !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid transparent !important;
    box-shadow: 0 4px 10px rgba(249, 141, 31, 0.25) !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.rbt-btn.btn-gradient::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background: rgba(0, 0, 0, 0.1);
    transition: width 0.3s ease;
    z-index: -1;
}

.rbt-btn.btn-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(249, 141, 31, 0.4) !important;
    color: #ffffff !important;
}

.rbt-btn.btn-gradient:hover::before {
    width: 100%;
}

/* Dark Mode Specific Adjustments */
body.active-dark-mode .rbt-btn.btn-gradient {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3) !important;
}

body.active-dark-mode .rbt-btn.btn-gradient:hover {
    box-shadow: 0 8px 20px rgba(249, 141, 31, 0.2) !important;
}

/* Adjustments for Course Card Progress */
.course-progress-container {
    margin-top: 15px;
    margin-bottom: 15px;
}

.course-progress-info {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--color-body);
}

/* Enrollement Button in Card */
.rbt-card-bottom .rbt-btn-link {
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* Purchased Badge in Course Details */
.btn-purchased {
    background-color: rgba(var(--color-success-rgb), 0.1);
    color: var(--color-success);
    cursor: default;
    border: 1px solid var(--color-success);
}

/* =========================================
   CONTINUE LEARNING PRO CARD
   ========================================= */
/* Continue Learning layout tweaks */
.dashboard-card-section .title {
    color: var(--color-heading);
}

.dashboard-card-section .subtitle {
    color: var(--color-body);
}

/* Badge in Card */
.badge-pro {
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
}

.bg-primary-opacity {
    background: rgba(var(--color-primary-rgb), 0.1);
}

body.active-dark-mode .bg-primary-opacity {
    background: rgba(var(--color-primary-rgb), 0.2);
}

/* Progress bar inside card */
/* =========================================
   PRO FOOTER (Static)
   ========================================= */
.pro-fixed-footer {
    position: relative;
    /* Changed from fixed */
    width: 100%;
    z-index: 10;
    padding: 10px 0;
    /* Increased padding slightly for static look */
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    margin-top: auto;
    /* Push to bottom if flex parent exists */
}

.pro-fixed-footer p {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
    color: var(--color-body);
    letter-spacing: 0.5px;
}

body.active-dark-mode .pro-fixed-footer {
    background: rgba(15, 23, 42, 0.85);
    /* Dark blue match */
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

body.active-dark-mode .pro-fixed-footer p {
    color: rgba(255, 255, 255, 0.7) !important;
    /* Fix for copyright text visibility */
}

body.active-dark-mode .pro-fixed-footer p a {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* Fix for footer link in light mode */
.pro-fixed-footer p a {
    color: var(--color-heading);
    transition: color 0.3s ease;
}

.pro-fixed-footer p a:hover {
    color: var(--color-primary);
}

/* Ensure no unwanted scroll on full-height pages. */
body {
    padding-bottom: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Allow main content to grow to push footer down */
.rbt-header-wrapper+div,
.rbt-main-content,
main,
section,
.rbt-elements-area {
    /* Try to match common content wrappers. 
       Use flex-grow on the direct children of body that aren't script/footer/header if possible.
       Or simpler: just margin-top auto on footer handles it if body is flex column. 
    */
}

/* We set margin-top: auto on .pro-fixed-footer above, which does the work if body is variable height */