/* Scoped to certificate page only - won't affect header or footer */
@media (max-width: 767px) {
    .certificate-view-dashboard {
        padding-top: 12px !important;
    }
    .certificate-hero-section {
        display: none !important;
    }
    .certificate-hero-section + section {
        margin-top: 0 !important;
    }
    .certificate-preview-header,
    #certificate-view-page section > .flex.items-center.gap-4 {
        margin-bottom: 8px !important;
    }
}

@media (min-width: 768px) {
    .certificate-hero-section {
        display: grid !important;
    }
}
#certificate-view-page .certificate-frame {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-radius: 16px;
    padding: 20px;
    position: relative;
}
#certificate-view-page .certificate-frame::before {
    content: '';
    position: absolute;
    inset: 8px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    pointer-events: none;
}
/* Toast - global but scoped to avoid header conflicts */
.toast-container { position: fixed; top: 80px; right: 20px; z-index: 99999; display: flex; flex-direction: column; gap: 12px; pointer-events: none; }
.toast { background: white; border-radius: 12px; padding: 14px 18px; box-shadow: 0 4px 20px rgba(0,0,0,0.15); display: flex; align-items: center; gap: 10px; animation: slideInToast 0.3s ease; pointer-events: auto; z-index: 99999; }
.toast-icon { width: 22px; height: 22px; background: #10b981; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; }
.toast.toast-error .toast-icon { background: #ef4444; }
.toast-message { font-size: 13px; font-weight: 600; color: #1e293b; }
@keyframes slideInToast { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.toast.hiding { animation: slideOutToast 0.3s ease forwards; }
@keyframes slideOutToast { to { transform: translateX(100%); opacity: 0; } }
#certificate-view-page .premium-card { background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%); }
#certificate-view-page .info-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #f1f5f9; }
#certificate-view-page .info-row:last-child { border-bottom: none; }

/* Verification Modal - global but scoped to avoid header conflicts */
.verification-modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.5); display: none; align-items: center; justify-content: center; z-index: 1060; backdrop-filter: blur(4px); }
.verification-modal { background: #fff; border-radius: 16px; width: 580px; max-width: calc(100% - 32px); max-height: 90vh; box-shadow: 0 20px 60px rgba(0,0,0,.3); overflow: hidden; display: flex; flex-direction: column; }
.verification-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid #e5e7eb; }
.verification-modal-title { font-weight: 700; font-size: 18px; color: #111827; }
.verification-modal-close { background: none; border: 0; font-size: 18px; cursor: pointer; color: #6b7280; width: 32px; height: 32px; border-radius: 8px; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.verification-modal-close:hover { background: #f3f4f6; color: #111827; }
.verification-modal-body { padding: 24px; overflow-y: auto; flex: 1; }
.verification-steps { display: flex; flex-direction: column; gap: 0; position: relative; }
.verification-step { display: flex; gap: 16px; padding: 16px 0; position: relative; opacity: 0.5; transition: opacity 0.3s ease; }
.verification-step.step-pending { opacity: 0.5; }
.verification-step.step-active, .verification-step.step-completed { opacity: 1; }
.verification-step::after { content: ''; position: absolute; left: 19px; top: 56px; bottom: -16px; width: 2px; background: #e5e7eb; z-index: 0; transition: background 0.4s ease; }
.verification-step.step-active::after { background: #0a66c2; }
.verification-step.step-completed::after { background: #10b981; }
.verification-step:last-child::after { display: none; }
.step-icon { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; position: relative; z-index: 1; transition: all 0.4s ease; }
.step-icon.step-pending { background: #e5e7eb; color: #9ca3af; }
.step-icon.step-active { background: #0a66c2; color: #fff; animation: pulseCert 1.5s ease-in-out infinite; }
.step-icon.step-completed { background: #10b981; color: #fff; }
.step-number { font-size: 16px; font-weight: 700; }
.step-icon.step-completed .step-number { display: none; }
.step-icon.step-completed::after { content: '\2713'; font-size: 18px; font-weight: bold; }
@keyframes pulseCert { 0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(10,102,194,0.4); } 50% { transform: scale(1.05); box-shadow: 0 0 0 8px rgba(10,102,194,0); } }
.step-content { flex: 1; padding-top: 2px; }
.step-title { font-weight: 700; font-size: 15px; color: #111827; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.verification-step.step-pending .step-title { color: #9ca3af; }
.verification-step:not(.step-active):not(.step-completed):not(.step-pending) .step-title { color: #9ca3af; }
.step-description { font-size: 13px; color: #6b7280; line-height: 1.6; }
.verification-step.step-pending .step-description { color: #9ca3af; }
.verification-step:not(.step-active):not(.step-completed):not(.step-pending) .step-description { color: #9ca3af; }
.verification-step.step-active .step-description, .verification-step.step-completed .step-description { color: #374151; }
.verification-result { background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%); border: 1px solid #a7f3d0; border-radius: 12px; padding: 20px; margin-top: 20px; display: none; gap: 16px; align-items: flex-start; animation: slideInCert 0.5s ease-out; }
.result-icon { width: 48px; height: 48px; border-radius: 50%; background: #10b981; color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 24px; }
.result-content { flex: 1; }
.result-title { font-size: 17px; font-weight: 700; color: #065f46; margin-bottom: 8px; }
.result-description { font-size: 13px; color: #047857; line-height: 1.6; }
.result-description p { margin: 3px 0; }
@keyframes slideInCert { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* Share Modal - global but scoped to avoid header conflicts */
.share-modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: none; align-items: center; justify-content: center; z-index: 1050; backdrop-filter: blur(4px); }
.share-modal { background: #fff; border-radius: 16px; width: 600px; max-width: calc(100% - 32px); box-shadow: 0 20px 60px rgba(0,0,0,.25); overflow: hidden; }
.share-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid #f1f5f9; }
.share-modal-header span { font-weight: 800; font-size: 16px; color: #1e293b; }
.share-modal-close { background: none; border: 0; font-size: 18px; cursor: pointer; color: #94a3b8; }
.share-modal-body { padding: 20px 24px; }
.share-item { display: flex; align-items: center; padding: 14px; border: 1px solid #e2e8f0; border-radius: 12px; cursor: pointer; text-decoration: none; color: inherit; margin-bottom: 10px; transition: all 0.2s; }
.share-item:hover { background: #f8fafc; border-color: #3b82f6; transform: translateX(4px); }
.share-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; margin-right: 14px; font-size: 18px; }
.share-text-title { font-weight: 700; font-size: 14px; color: #1e293b; }
.share-text-sub { color: #64748b; font-size: 12px; margin-top: 2px; }
.share-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-top: 16px; }
.share-grid .mini { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 14px 8px; border-radius: 12px; border: 1px solid #e2e8f0; color: inherit; text-decoration: none; transition: all 0.2s; }
.share-grid .mini:hover { border-color: #3b82f6; background: #f8fafc; transform: translateY(-2px); }
.share-grid .mini i { font-size: 20px; margin-bottom: 6px; }
.share-grid .mini span { font-size: 10px; font-weight: 600; color: #64748b; }
@media (max-width: 640px) { .share-grid { grid-template-columns: repeat(3, 1fr); } }

.certificate-login-modal-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .58); display: none; align-items: center; justify-content: center; z-index: 1070; padding: 20px; backdrop-filter: blur(5px); }
.certificate-login-modal { width: 430px; max-width: 100%; background: #fff; border-radius: 16px; box-shadow: 0 24px 70px rgba(15, 23, 42, .32); overflow: hidden; }
.certificate-login-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid #e5e7eb; }
.certificate-login-modal-title { font-size: 15px; font-weight: 800; color: #0f172a; }
.certificate-login-modal-close { width: 32px; height: 32px; border: 0; border-radius: 8px; background: #f8fafc; color: #64748b; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.certificate-login-modal-body { padding: 22px 20px 20px; }
.certificate-login-modal-content { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 18px; }
.certificate-login-modal-icon { width: 44px; height: 44px; border-radius: 12px; background: #eff6ff; color: #2563eb; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; font-size: 18px; }
.certificate-login-modal-message { color: #334155; font-size: 13px; line-height: 1.65; padding-top: 1px; }
.certificate-login-modal-actions { display: flex; gap: 10px; justify-content: flex-end; }
.certificate-login-modal-actions a, .certificate-login-modal-actions button { border: 0; border-radius: 10px; padding: 10px 14px; font-size: 12px; font-weight: 800; text-decoration: none; cursor: pointer; }
.certificate-login-modal-actions .secondary { background: #f1f5f9; color: #475569; }
.certificate-login-modal-actions .primary { background: #1d4ed8; color: #fff; }

/* Certificate Language Selector (Sağ Bölüm) */
.certificate-lang-wrapper {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.certificate-lang-label {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    user-select: none;
}

.certificate-lang-pill {
    display: inline-flex;
    align-items: center;
    background: #f1f5f9;
    padding: 2.5px;
    border-radius: 9px;
    border: 1px solid #e2e8f0;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.03);
    gap: 2px;
}

.cert-lang-btn {
    border: none;
    background: transparent;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 3.5px 9px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1.15;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    user-select: none;
}

.cert-lang-btn:hover:not(.active) {
    color: #0f172a;
    background: rgba(255, 255, 255, 0.65);
}

.cert-lang-btn.active {
    background: #ffffff;
    color: #0f172a;
    font-weight: 800;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
}

.cert-lang-btn:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 1px;
}

@media (max-width: 640px) {
    .certificate-lang-label {
        display: none !important;
    }
    .cert-lang-btn {
        padding: 3px 8px;
        font-size: 10px;
        min-width: 28px;
    }
}


/* Eğitim içeriği (zengin metin) */
.training-rich-text p { margin-bottom: 0.5rem; }
.training-rich-text p:last-child { margin-bottom: 0; }
.training-rich-text ul { list-style-type: disc !important; padding-left: 1.25rem; margin-bottom: 0.5rem; }
.training-rich-text ol { list-style-type: decimal !important; padding-left: 1.25rem; margin-bottom: 0.5rem; }
.training-rich-text li[data-list="bullet"] { list-style-type: disc; }
.training-rich-text a { color: #ED1C24; text-decoration: underline; font-weight: 600; }
.training-rich-text a:hover { color: #b91c1c; }
