/* =========================================
   LCM Front-End: MODERN ACADEMIC LIST VIEW
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,600;1,600&display=swap');

:root {
    /* --- Palette: Academic Trust & Clarity --- */
    --lcm-primary: #0f172a;
    /* Midnight Navy (Text/Headers) */

    /* Educational Accent (Bright Royal Blue -> Cyan) */
    --lcm-accent: #2563eb;
    --lcm-accent-gradient: linear-gradient(135deg, #2563eb 0%, #06b6d4 100%);

    --lcm-surface-glass: #ffffff;
    --lcm-bg-gradient: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 100%);
    /* Light Sky tint */
    --lcm-border-soft: #e2e8f0;

    /* Fonts */
    --lcm-font-main: 'Tajawal', sans-serif;
    --lcm-font-serif: 'Playfair Display', serif;

    /* Effects */
    --lcm-shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --lcm-shadow-hover: 0 10px 25px -5px rgba(0, 0, 0, 0.08);
    --lcm-radius: 16px;
}

.lcm-container {
    font-family: var(--lcm-font-main);
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
    color: var(--lcm-primary);
}

/* =========================================
      1. Layout: Vertical Stack (List View)
      ========================================= */
.lcm-lectures-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 40px;
}

/* =========================================
      2. Card: Horizontal Row Design
      ========================================= */
.lcm-card {
    display: grid;
    /* Grid Layout: Title/Info | Status/Price | Actions */
    grid-template-columns: 2fr 1fr 1fr;
    align-items: center;
    background: var(--lcm-surface-glass);
    border-radius: var(--lcm-radius);
    padding: 25px 30px;
    border: 1px solid var(--lcm-border-soft);
    box-shadow: var(--lcm-shadow-sm);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

/* Decorative Accent Stripe on Left */
.lcm-card::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    /* Right aligned for Arabic RTL */
    width: 4px;
    background: var(--lcm-accent-gradient);
    opacity: 1;
}

.lcm-card:hover {
    transform: translateX(-5px);
    /* Subtle nudge */
    box-shadow: var(--lcm-shadow-hover);
    border-color: #38bdf8;
    /* Light blue border on hover */
}

/* Section A: Title & Meta */
.lcm-card-header {
    padding: 0;
    background: none;
    border: none;
    text-align: right;
}

.lcm-card-title {
    font-family: var(--lcm-font-serif);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--lcm-primary);
    margin-bottom: 5px;
}

.lcm-card-meta {
    font-size: 0.9rem;
    color: #64748b;
}

/* Section B: Status & Info (Middle) */
.lcm-card-body {
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-left: 1px solid #f1f5f9;
    /* Separators */
    border-right: 1px solid #f1f5f9;
}

.lcm-price-tag {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--lcm-accent);
}

.lcm-status-badge {
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    background: #f8fafc;
    color: #475569;
    border: 1px solid #e2e8f0;
}

.lcm-status-badge.paid {
    background: #ecfeff;
    color: #0e7490;
    border-color: #a5f3fc;
}

.lcm-status-badge.not-eligible {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

/* Section C: Actions (Left) */
.lcm-card-actions {
    padding: 0;
    border: none;
    background: none;
    display: flex;
    justify-content: flex-end;
    /* Align buttons to the end */
}

/* =========================================
      3. Modern Buttons
      ========================================= */
.lcm-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none !important;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
    white-space: nowrap;
}

/* Request Button: Educational Blue Gradient */
.lcm-button.request-button {
    background: var(--lcm-accent-gradient);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.2);
}

.lcm-button.request-button:hover {
    filter: brightness(110%);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px -2px rgba(37, 99, 235, 0.3);
}

/* Download: Outline Style */
.lcm-button.download-button {
    background: white;
    border: 1px solid var(--lcm-accent);
    color: var(--lcm-accent);
}

.lcm-button.download-button:hover {
    background: #f0f9ff;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.1);
}

/* PDF: Simple Link Style */
.lcm-button.download-button-pdf {
    background: transparent;
    color: #94a3b8;
    padding: 10px;
}

.lcm-button.download-button-pdf:hover {
    color: var(--lcm-accent);
}

.lcm-download-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* =========================================
      4. Verification Portal: Polished & Seamless
      ========================================= */
.lcm-verify-container {
    background: #ffffff !important;
    border-radius: 20px !important;
    padding: 50px 30px !important;
    /* Force padding */
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #f1f5f9 !important;
    margin-bottom: 60px !important;
    text-align: center !important;
    max-width: 750px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    position: relative !important;
}

.lcm-verify-title {
    font-family: var(--lcm-font-serif) !important;
    font-size: 2.2rem !important;
    margin-bottom: 15px !important;
    color: var(--lcm-primary) !important;
}

.lcm-verify-subtitle {
    font-size: 1rem !important;
    color: #64748b !important;
    margin-bottom: 40px !important;
}

/* Seamless Pill Design */
/* Seamless Pill Design */
.lcm-verify-input-group {
    display: flex !important;
    align-items: stretch !important;
    max-width: 600px !important;
    margin: 0 auto !important;
    background: #fff !important;
    border: 2px solid #e2e8f0 !important;
    border-radius: 100px !important;
    padding: 5px !important;
    /* Slightly increased padding */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02) !important;
}

.lcm-verify-input-group:focus-within {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1) !important;
}

.lcm-verify-input {
    flex: 1 !important;
    padding: 15px 25px !important;
    /* Increased padding */
    border: none !important;
    background: transparent !important;
    font-size: 1.1rem !important;
    color: var(--lcm-primary) !important;
    outline: none !important;
    border-radius: 100px !important;
    margin: 0 !important;
}

/* Button inside the pill */
.lcm-verify-btn {
    padding: 12px 40px !important;
    /* Increased padding */
    background: var(--lcm-accent-gradient) !important;
    color: white !important;
    border-radius: 100px !important;
    border: none !important;
    cursor: pointer !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    transition: transform 0.2s !important;
    margin: 0 !important;
}

.lcm-verify-btn:hover {
    transform: scale(1.02);
    filter: brightness(105%);
}

/* ========================
      RESULT CARD: Official Document Style
      ======================== */
.lcm-result-card {
    margin-top: 30px !important;
    background: #fff !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    text-align: right !important;
    /* Arabic default */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
    border: 1px solid #e2e8f0 !important;
    animation: fadeInUp 0.5s ease !important;
    max-width: 650px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 30px !important;
}

/* Status Header Banner */
.lcm-result-header {
    padding: 20px 30px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

/* Valid State */
.lcm-result-valid .lcm-result-header {
    background: #f0fdf4;
    color: #166534;
}

.lcm-result-valid .lcm-result-header::before {
    content: '✓';
    /* Checkmark */
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 32px;
    height: 32px;
    background: #22c55e;
    color: white;
    border-radius: 50%;
    font-weight: bold;
    font-size: 18px;
}

/* Invalid State */
.lcm-result-invalid .lcm-result-header {
    background: #fef2f2;
    color: #991b1b;
}

.lcm-result-invalid .lcm-result-header::before {
    content: '!';
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 32px;
    height: 32px;
    background: #ef4444;
    color: white;
    border-radius: 50%;
    font-weight: bold;
    font-size: 18px;
}

.lcm-result-status-text {
    font-weight: 800;
    font-size: 1.3rem;
    font-family: var(--lcm-font-serif);
}

.lcm-result-body {
    padding: 30px;
}

.lcm-result-row {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: 1.05rem;
}

.lcm-result-row:last-child {
    border-bottom: none;
}

.lcm-result-label {
    color: #64748b;
    font-weight: 500;
}

.lcm-result-value {
    color: var(--lcm-primary);
    font-weight: 700;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
      5. Mobile Responsive (Stack back to cards)
      ========================================= */
@media (max-width: 768px) {
    .lcm-card {
        grid-template-columns: 1fr;
        /* Stack vertically on phone */
        text-align: center;
        gap: 20px;
        padding: 30px 20px;
    }

    .lcm-card::before {
        width: 100%;
        height: 4px;
        bottom: 0;
        top: auto;
        right: 0;
        background: var(--lcm-accent-gradient);
    }

    .lcm-card-header {
        text-align: center;
    }

    .lcm-card-body {
        border: none;
        border-top: 1px solid #f1f5f9;
        border-bottom: 1px solid #f1f5f9;
        padding: 20px 0;
        width: 100%;
    }

    .lcm-card-actions {
        justify-content: center;
        width: 100%;
    }

    .lcm-download-actions {
        flex-direction: column;
        width: 100%;
    }

    .lcm-button {
        width: 100%;
    }

    .lcm-verify-input-group {
        flex-direction: column;
    }
}