/* === Great Vibes font (sertifika önizleme + canvas için) === */
@font-face {
    font-family: 'GreatVibes';
    src: url('great-vibes.ttf') format('truetype');
    font-display: swap;
}

/* === Reset & temel === */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #1a1a1a;
    background: #f5f6f8;
    line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: #2563eb; text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 28px; margin: 0 0 6px; }
h2 { font-size: 20px; margin: 0 0 12px; }
h3 { font-size: 16px; margin: 0 0 8px; }
hr { border: 0; border-top: 1px solid #e5e7eb; margin: 16px 0; }
.muted { color: #6b7280; }
.small { font-size: 12px; }

/* === Layout === */
.topbar { background: #fff; border-bottom: 1px solid #e5e7eb; }
.topbar__inner {
    max-width: 1200px; margin: 0 auto; padding: 12px 24px;
    display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
.topbar__brand {
    font-weight: 700; color: #111; font-size: 16px; text-decoration: none;
    text-transform: uppercase; letter-spacing: 1.5px;
}
.topbar__nav { display: flex; align-items: center; gap: 14px; margin-left: auto; flex-wrap: wrap; }
.topbar__nav a { color: #374151; font-size: 14px; }
.topbar__nav a:hover { color: #111; }
.topbar__nav .btn-admin {
    background: #ede9fe; color: #5b21b6; padding: 4px 10px; border-radius: 6px; font-weight: 600;
}
.topbar__nav .sep { width: 1px; height: 18px; background: #e5e7eb; }
.topbar__user { font-weight: 500; color: #111; text-decoration: none; }
.topbar__nav a.topbar__user:hover { color: #2563eb; text-decoration: none; }

.container { max-width: 1200px; margin: 0 auto; padding: 28px 24px 60px; }
.footer {
    border-top: 1px solid #e5e7eb; background: #fff;
    color: #6b7280; font-size: 12px; padding: 16px 0;
}
.footer .topbar__inner { padding: 0 24px; justify-content: space-between; }
.footer__version {
    color: #9ca3af; font-size: 11px; font-weight: 500;
    margin-left: 4px; letter-spacing: 0.3px;
}

/* === Buttons === */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 14px; font-size: 14px; font-weight: 500;
    border-radius: 6px; border: 1px solid transparent;
    background: #f3f4f6; color: #111; cursor: pointer; text-decoration: none;
    transition: background .12s, border-color .12s, transform .04s;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn--primary { background: #2563eb; color: #fff; border-color: #2563eb; }
.btn--primary:hover { background: #1d4ed8; color: #fff; }
.btn--danger { background: #fef2f2; color: #b91c1c; border-color: #fecaca; }
.btn--danger:hover { background: #fee2e2; color: #991b1b; }
.btn--ghost { background: #fff; border-color: #d1d5db; color: #374151; }
.btn--ghost:hover { background: #f9fafb; }
.btn--ghost.is-active { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }
.btn--lg { padding: 11px 20px; font-size: 15px; }
.btn--sm { padding: 4px 10px; font-size: 12px; }

/* === Form === */
input[type=text], input[type=email], input[type=password], input[type=number],
input[type=date], input[type=search], input[type=color], select, textarea {
    width: 100%;
    padding: 8px 11px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    background: #fff;
}
input[type=color] { padding: 2px; height: 36px; }
input[type=file] {
    width: 100%; padding: 6px 0; font-size: 14px;
}
textarea { resize: vertical; min-height: 80px; }
select { background: #fff; }
input:focus, select:focus, textarea:focus {
    outline: 2px solid #bfdbfe;
    outline-offset: 0;
    border-color: #2563eb;
}
label { display: block; font-size: 13px; color: #374151; margin-bottom: 12px; }
label > input, label > select, label > textarea { margin-top: 4px; }
label.checkbox, .checkbox-row label {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 14px; color: #111;
}
label.checkbox input, .checkbox-row input[type=checkbox] {
    width: auto; margin: 0;
}
.checkbox-row { display: flex; gap: 18px; flex-wrap: wrap; align-items: center; padding: 4px 0; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 720px) {
    .grid-2, .row-2 { grid-template-columns: 1fr; }
}
.form-actions { margin-top: 18px; display: flex; gap: 8px; }

/* === Panel === */
.panel {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    padding: 20px; margin-bottom: 16px;
}
.page-head {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; margin-bottom: 18px; flex-wrap: wrap;
}
.toolbar {
    display: flex; gap: 18px; align-items: center; margin-bottom: 16px; flex-wrap: wrap;
    background: #fff; padding: 10px 14px; border-radius: 8px; border: 1px solid #e5e7eb;
}
.toolbar__group { display: inline-flex; gap: 6px; align-items: center; }
.back-link { font-size: 13px; display: inline-block; margin-bottom: 8px; color: #6b7280; }
.filter-bar {
    display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap;
}
.filter-bar select, .filter-bar input { width: auto; min-width: 220px; }

/* === Flash messages === */
.flash {
    padding: 10px 14px; border-radius: 8px; margin-bottom: 16px;
    font-size: 14px; border: 1px solid transparent;
}
.flash--ok { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.flash--err { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.flash--warn { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.flash--info { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }
label > .required { color: #dc2626; font-weight: 600; margin-left: 2px; }
.error { color: #b91c1c; font-size: 13px; margin: 6px 0 0; }

/* === Tables === */
.table {
    width: 100%; border-collapse: collapse; background: #fff;
    border: 1px solid #e5e7eb; border-radius: 10px; overflow: hidden;
}
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid #f3f4f6; vertical-align: middle; }
.table th { background: #f9fafb; font-weight: 600; font-size: 13px; color: #374151; text-transform: uppercase; letter-spacing: .03em; }
.table tr:last-child td { border-bottom: 0; }
.table tr:hover td { background: #fafafa; }
.table--compact th, .table--compact td { padding: 8px 10px; font-size: 13px; }
.actions {
    text-align: right;
    white-space: nowrap;
    width: 1%;             /* table-layout trick: bu cell sadece içerik kadar olur,
                              kalan alanı diğer cell'ler paylaşır → butonlar sağa yapışır */
}
.actions .btn { margin-left: 4px; }

/* === Badge === */
.badge {
    display: inline-block; padding: 2px 8px; border-radius: 999px;
    font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em;
    background: #f3f4f6; color: #4b5563;
}
.badge--ok { background: #d1fae5; color: #065f46; }
.badge--warn { background: #fef3c7; color: #92400e; }
.badge--pdf { background: #fee2e2; color: #b91c1c; }

/* === Empty state === */
.empty {
    text-align: center; padding: 60px 20px; background: #fff;
    border: 1px dashed #e5e7eb; border-radius: 10px; color: #6b7280;
}
.empty.success { border-color: #6ee7b7; background: #f0fdf4; color: #065f46; }
.empty.success h2 { color: #065f46; }

/* === Auth card === */
.auth-card {
    max-width: 420px; margin: 60px auto; background: #fff; padding: 32px;
    border: 1px solid #e5e7eb; border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.04);
}
.auth-card h1 { margin-bottom: 8px; }

/* === Stats === */
.stats {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px; margin: 20px 0 28px;
}
.stat {
    background: #fff; padding: 18px; border: 1px solid #e5e7eb; border-radius: 10px;
    display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: #111;
    transition: border-color .12s, box-shadow .12s;
}
.stat:hover { border-color: #93c5fd; box-shadow: 0 1px 4px rgba(37,99,235,.1); text-decoration: none; }
.stat__num { font-size: 32px; font-weight: 700; color: #111; line-height: 1; }
.stat__label { font-size: 13px; color: #6b7280; }

/* === Sertifika kartları === */
.cert-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.cert-list { display: flex; flex-direction: column; gap: 12px; }
.cert-card {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    overflow: hidden; transition: box-shadow .15s;
}
.cert-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.06); }
.cert-list .cert-card { display: flex; align-items: center; }
.cert-list .cert-card__thumb { width: 180px; flex-shrink: 0; }
.cert-list .cert-card__body { flex: 1; }
.cert-card__thumb { aspect-ratio: 4 / 3; overflow: hidden; background: #f9fafb; border-bottom: 1px solid #e5e7eb; }
.cert-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.cert-card__body { padding: 14px 16px; }
.cert-card__title { font-size: 16px; margin-bottom: 4px; }
.cert-card__date { color: #6b7280; font-size: 13px; margin: 4px 0; }
.cert-card__name { font-size: 13px; margin: 4px 0 12px; }
.cert-card__actions { display: flex; gap: 6px; }

/* === Şablon edit canvas === */
.canvas-wrap {
    background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 8px;
    padding: 12px; max-height: 700px; overflow: auto;
}
canvas { display: block; max-width: 100%; cursor: crosshair; }

/* === Sertifika ver — kullanıcı seçici === */
.user-pick {
    border: 1px solid #e5e7eb; border-radius: 8px; background: #fff; margin: 12px 0;
}
.user-pick > input[type=search] {
    border: 0; border-bottom: 1px solid #e5e7eb; border-radius: 8px 8px 0 0;
    padding: 12px 14px;
}
.user-pick__head {
    padding: 8px 14px; border-bottom: 1px solid #e5e7eb; background: #f9fafb;
    display: flex; justify-content: space-between; align-items: center;
}
.user-pick__list { max-height: 320px; overflow: auto; }
.user-pick__item {
    display: grid; grid-template-columns: auto 1fr 1fr; gap: 10px;
    align-items: center; padding: 8px 14px; border-bottom: 1px solid #f3f4f6;
    cursor: pointer; margin: 0;
}
.user-pick__item:hover { background: #f9fafb; }
.user-pick__item input { width: auto; }
.user-pick__name { font-size: 14px; }

/* === Anket — kullanıcı tarafı === */
.survey-list {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 14px;
}
.survey-card {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 18px;
    display: flex; flex-direction: column; gap: 10px; min-height: 160px;
}
.survey-card__body { flex: 1; }
.survey-card .meta { display: flex; gap: 10px; align-items: center; font-size: 13px; color: #6b7280; }
.survey-card__actions { margin-top: auto; display: flex; gap: 8px; }

.survey-form fieldset {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    padding: 18px 20px; margin-bottom: 14px;
}
.survey-form fieldset.has-error { border-color: #fca5a5; background: #fef2f2; }
.survey-form legend { font-weight: 600; font-size: 15px; padding: 0 8px; }
.qnum { color: #2563eb; font-weight: 700; margin-right: 4px; }
.required { color: #dc2626; }
.opt { display: flex; align-items: center; gap: 8px; padding: 6px 0; font-size: 14px; }
.opt input { width: auto; }
.rating { display: flex; gap: 6px; }
.rating label {
    border: 1px solid #d1d5db; border-radius: 6px; padding: 8px 14px; cursor: pointer;
    background: #fff; font-size: 14px; font-weight: 500; min-width: 64px; text-align: center;
}
.rating label:has(input:checked) { background: #2563eb; color: #fff; border-color: #2563eb; }
.rating input { display: none; }
.rating__legend { margin-top: 6px; font-size: 12px; }

/* === Anket — admin sonuçlar === */
.results { margin-top: 20px; }
.result {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 10px;
    padding: 18px 22px; margin-bottom: 14px;
}
.result__head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 14px; gap: 12px;
}
.result h3 { font-size: 15px; margin: 0; }
.result__rating { display: flex; align-items: flex-start; gap: 32px; flex-wrap: wrap; }
.big-number { font-size: 46px; font-weight: 700; color: #111; line-height: 1; }
.big-number .muted { font-size: 18px; }
.bars { flex: 1; min-width: 240px; display: flex; flex-direction: column; gap: 8px; }
.bar-row { display: grid; grid-template-columns: 90px 1fr 90px; gap: 10px; align-items: center; font-size: 13px; }
.bar-label { text-align: right; color: #374151; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar { background: #f3f4f6; height: 14px; border-radius: 4px; overflow: hidden; }
.bar__fill { background: #2563eb; height: 100%; border-radius: 4px; transition: width .25s; }
.bar-num { font-size: 13px; color: #374151; }
.answers {
    list-style: none; padding: 0; margin: 0;
    display: flex; flex-direction: column; gap: 8px;
}
.answers li {
    background: #f9fafb; padding: 10px 12px; border-radius: 6px;
    border-left: 3px solid #93c5fd;
}

/* === Anket admin edit === */
.qcard {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 8px;
    padding: 16px; margin-bottom: 12px;
    transition: box-shadow .15s, opacity .15s;
}
.qcard__head {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 10px; gap: 10px;
}
.qcard__head > strong { flex: 1; }
.qcard__drag {
    cursor: grab; user-select: none;
    color: #9ca3af; font-size: 18px; letter-spacing: -3px;
    padding: 4px 6px; border-radius: 4px;
    transition: background .15s, color .15s;
}
.qcard__drag:hover { background: #f3f4f6; color: #374151; }
.qcard__drag:active { cursor: grabbing; }
.qcard--ghost { opacity: 0.4; background: #eff6ff; }
.qcard--chosen { box-shadow: 0 4px 16px rgba(37,99,235,.18); }

.responses { margin-top: 24px; }

.add-user summary {
    display: inline-flex; align-items: center; cursor: pointer;
    list-style: none;
}
.add-user summary::-webkit-details-marker { display: none; }
.inline-form { display: inline-block; }
.inline-popover {
    background: #fff; border: 1px solid #e5e7eb; padding: 8px;
    margin-top: 4px; border-radius: 6px; display: flex; gap: 6px;
}
.inline-popover input { width: 160px; padding: 6px 8px; font-size: 13px; }

.thumb-preview img { max-height: 220px; object-fit: contain; }
.search { display: flex; gap: 6px; }
.search input { width: 240px; }

.section-auth .container { padding-top: 12px; }

/* === Info box === */
.info-box {
    background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af;
    padding: 10px 14px; border-radius: 6px; font-size: 13px; margin: 10px 0;
}
.info-box--soft {
    background: #fafaf9; border-color: #e5e7eb; color: #4b5563;
}

/* === Sertifika başına dropdown'larda overflow === */
.congress-form select { background: #fff; }
.role-row td { vertical-align: middle; }

/* === Email error popover === */
.email-error-popover { display: inline; position: relative; }
.email-error-popover summary { list-style: none; }
.email-error-popover summary::-webkit-details-marker { display: none; }
.email-error-popover[open] .email-error-body {
    position: absolute; top: 100%; right: 0; z-index: 10;
    background: #fff; border: 1px solid #fca5a5;
    color: #991b1b; padding: 8px 12px; border-radius: 6px;
    font-size: 12px; max-width: 320px; min-width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
    word-break: break-word;
}
.email-error-body { display: none; }

/* === Mail gönderim önizleme (send-progress.php) === */
.send-preview {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 16px 0;
}
.send-preview > summary {
    cursor: pointer;
    font-weight: 600;
    color: #111;
    list-style: none;
    padding: 4px 0;
}
.send-preview > summary::-webkit-details-marker { display: none; }
.send-preview > summary::before { content: '▶ '; font-size: 10px; transition: transform .12s; display: inline-block; }
.send-preview[open] > summary::before { transform: rotate(90deg); }
.send-preview__meta {
    background: #fff;
    border-radius: 6px;
    padding: 10px 14px;
    margin: 10px 0;
    font-size: 13px;
    line-height: 1.8;
}
.send-preview__meta code {
    background: #f3f4f6;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 12px;
}
.send-preview__body {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 24px 28px;
    max-height: 360px;
    overflow-y: auto;
}

/* === Send progress sayfası === */
.send-progress {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 12px;
    padding: 24px; max-width: 720px; margin: 24px auto;
}
.send-progress h2 { margin-top: 0; }
.send-progress__bar {
    background: #e5e7eb; height: 14px; border-radius: 7px;
    overflow: hidden; margin: 14px 0;
}
.send-progress__fill {
    background: linear-gradient(90deg, #2563eb, #10b981);
    height: 100%; width: 0; transition: width .3s;
}
.send-progress__stats {
    display: flex; justify-content: space-around;
    text-align: center; padding: 16px 0; border-top: 1px solid #f3f4f6;
}
.send-progress__stat strong { display: block; font-size: 28px; }
.send-progress__stat .label { font-size: 12px; color: #6b7280; }
.send-progress__log {
    max-height: 200px; overflow-y: auto;
    background: #f9fafb; border: 1px solid #e5e7eb;
    border-radius: 6px; padding: 8px 12px;
    font-family: ui-monospace, monospace; font-size: 12px;
    margin-top: 12px;
}
.send-progress__log .ok { color: #065f46; }
.send-progress__log .fail { color: #b91c1c; }

.code-block {
    background: #1f2937; color: #e5e7eb;
    padding: 12px 14px; border-radius: 6px;
    font-family: ui-monospace, monospace; font-size: 12px;
    overflow-x: auto; margin: 8px 0;
}

/* === Arşiv silme onayı (popover) === */
.archive-delete { display: inline-block; position: relative; }
.archive-delete > summary { list-style: none; cursor: pointer; }
.archive-delete > summary::-webkit-details-marker { display: none; }
.archive-delete[open] .archive-delete__form {
    position: absolute; right: 0; top: 100%; z-index: 100;
    background: #fff;
    border: 1px solid #fca5a5;
    box-shadow: 0 8px 24px rgba(0,0,0,.15);
    border-radius: 8px;
    padding: 14px;
    min-width: 320px;
    text-align: left;
}
.archive-delete__form input[type=text] { width: 100%; }

/* === Bölüm başlığı (Yaklaşan / Geçmiş) === */
.section-heading {
    display: flex; align-items: center; gap: 10px;
    font-size: 16px; color: #374151;
    margin: 0 0 12px;
    text-transform: uppercase; letter-spacing: .04em; font-weight: 600;
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot--upcoming { background: #10b981; box-shadow: 0 0 0 3px #d1fae5; }
.dot--past     { background: #9ca3af; box-shadow: 0 0 0 3px #f3f4f6; }

/* === Dashboard kart === */
.dash-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 24px 28px;
    margin: 18px 0;
    box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.dash-card__head { margin-bottom: 18px; }
.dash-card__title { margin: 0 0 4px; font-size: 22px; color: #111; }
.dash-card__sub {
    margin: 0; color: #6b7280; font-size: 13px;
    display: inline-flex; align-items: center; gap: 4px;
}

/* KPI satırı: 3 kart yan yana */
.kpi-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1.4fr;
    gap: 16px;
    margin-bottom: 20px;
}
@media (max-width: 800px) {
    .kpi-row { grid-template-columns: 1fr; }
}
.kpi {
    background: linear-gradient(180deg, #f9fafb, #fff);
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 18px 20px;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    text-align: center;
    min-height: 140px;
}
.kpi--funnel { align-items: stretch; padding: 14px 18px; }
.kpi__big-number {
    font-size: 42px; font-weight: 700;
    background: linear-gradient(135deg, #2563eb 0%, #10b981 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}
.kpi__suffix {
    font-size: 18px; color: #6b7280; font-weight: 500;
    -webkit-text-fill-color: initial; background: none;
}
.kpi__caption {
    font-size: 12px; color: #6b7280; margin-top: 8px;
    text-transform: uppercase; letter-spacing: .04em;
}

/* Yıldızlar */
.stars {
    margin: 6px 0 2px;
    font-size: 22px;
    line-height: 1;
    letter-spacing: 2px;
}
.star { display: inline-block; }
.star--full  { color: #f59e0b; }
.star--half  {
    background: linear-gradient(90deg, #f59e0b 50%, #e5e7eb 50%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}
.star--empty { color: #e5e7eb; }

/* Donut ring */
.ring { width: 110px; height: 110px; }
.ring__pct {
    font-size: 18px; font-weight: 700; fill: #111;
    font-family: system-ui, sans-serif;
}
.ring__sub {
    font-size: 9px; fill: #6b7280;
    font-family: system-ui, sans-serif;
}

/* Mini-funnel (KPI içinde) */
.mini-funnel { display: flex; flex-direction: column; gap: 6px; flex: 1; justify-content: center; }
.mini-funnel__row {
    display: grid; grid-template-columns: 60px 1fr 70px;
    gap: 8px; align-items: center; font-size: 12px;
}
.mini-funnel__label { color: #4b5563; font-weight: 500; }
.mini-funnel__track {
    background: #f3f4f6; height: 8px; border-radius: 4px; overflow: hidden;
}
.mini-funnel__bar {
    height: 100%; border-radius: 4px;
    transition: width .3s; opacity: .85;
}
.mini-funnel__num { text-align: right; color: #111; font-size: 11px; }

/* Rating kart grid */
.rating-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
    margin-top: 8px;
}
.rating-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 14px 16px;
}
.rating-card__q {
    font-size: 13px;
    color: #111;
    font-weight: 500;
    margin-bottom: 10px;
    line-height: 1.4;
    min-height: 36px;
}
.rating-card__row {
    display: flex;
    gap: 14px;
    align-items: center;
}
.rating-card__avg {
    flex-shrink: 0;
    font-size: 28px;
    line-height: 1;
}
.rating-card__avg strong {
    background: linear-gradient(135deg, #2563eb 0%, #10b981 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}
.rating-card__avg .muted { font-size: 14px; color: #9ca3af; }
.rating-card__bars { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.rating-card__bar-row {
    display: grid; grid-template-columns: 24px 1fr 24px;
    gap: 6px; align-items: center; font-size: 10px;
}
.rating-card__star { color: #6b7280; font-size: 10px; }
.rating-card__bar {
    background: #e5e7eb; height: 5px; border-radius: 3px; overflow: hidden;
}
.rating-card__fill {
    background: linear-gradient(90deg, #6366f1, #10b981);
    height: 100%; border-radius: 3px;
}
.rating-card__num { text-align: right; color: #6b7280; font-size: 11px; }

/* === Dashboard funnel === */
.funnel { display: flex; flex-direction: column; gap: 8px; }
.funnel__step {
    display: grid; grid-template-columns: 130px 1fr 110px;
    gap: 12px; align-items: center; font-size: 14px;
}
.funnel__label { color: #374151; font-weight: 500; }
.funnel__bar { background: #f3f4f6; height: 22px; border-radius: 4px; overflow: hidden; }
.funnel__fill { height: 100%; border-radius: 4px; transition: width .3s; }
.funnel__num { color: #111; }
@media (max-width: 600px) {
    .funnel__step { grid-template-columns: 1fr; gap: 4px; }
}

/* === Topbar — admin nav === */
.topbar__nav .btn-admin { padding: 4px 12px; }

/* .btn-test — genel kullanım (kongre kartı modül butonları) + topbar'da kompakt varyant */
.btn-test {
    display: inline-flex; align-items: center; gap: 4px;
    background: #ecfdf5; color: #065f46;
    padding: 8px 14px; font-size: 14px; font-weight: 600;
    border-radius: 6px; border: 1px solid #a7f3d0; text-decoration: none;
}
.btn-test:hover { background: #d1fae5; color: #064e3b; text-decoration: none; }
.topbar__nav .btn-test { padding: 4px 12px; }

/* Inline SVG ikonlar — buton/link içinde */
.icon {
    display: inline-block;
    vertical-align: -3px;
    margin-right: 3px;
    color: currentColor;
    opacity: .7;
    flex-shrink: 0;
}
.topbar__nav a:hover .icon { opacity: 1; }
.topbar__nav a { display: inline-flex; align-items: center; gap: 4px; }
/* Tablo aksiyonlarında ikonlu butonlar */
.btn .icon { margin-right: 4px; }
.actions .btn { display: inline-flex; align-items: center; gap: 2px; }

/* === PUBLIC SAYFA (token tabanlı katılımcı) === */
.section-public { background: #f7f8fa; }
.container--narrow { max-width: 760px; }

.topbar--public .topbar__inner {
    justify-content: space-between;
    padding: 8px 24px;     /* daha ince header */
}
.topbar--public .topbar__brand strong {
    color: #111;
    font-size: 15px;
    font-weight: 700;
}
.participant-greeting {
    display: flex; align-items: baseline; gap: 6px;
    font-size: 14px;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.participant-greeting__hi { color: #6b7280; }
.participant-greeting__name { color: #111; font-weight: 600; }
.participant-greeting__email { color: #9ca3af; font-size: 13px; }

@media (max-width: 600px) {
    .topbar--public .topbar__inner { padding: 8px 14px; gap: 8px; }
    .participant-greeting { font-size: 13px; }
    .participant-greeting__email { display: none; }   /* dar ekranda emaili gizle */
}

/* === WIZARD === */
.wizard { background: transparent; }
.wizard__progress {
    background: #e5e7eb; height: 6px; border-radius: 3px;
    overflow: hidden; margin: 8px 0 18px;
}
.wizard__progress-bar {
    background: linear-gradient(90deg, #2563eb, #3b82f6);
    height: 100%; transition: width .3s ease;
}
.wizard__meta {
    display: flex; justify-content: space-between; align-items: center;
    color: #374151; margin-bottom: 16px; font-size: 14px;
}

.wizard__form { background: transparent; }
.wizard__question {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 28px 24px;
    margin: 0 0 20px;
}
.wizard__question.has-error {
    border-color: #fca5a5;
    background: #fef9f9;
}
.wizard__question legend {
    font-weight: 600; font-size: 18px;
    padding: 0 4px;
    color: #111;
    line-height: 1.4;
}

.wizard__nav {
    display: flex; justify-content: space-between; gap: 12px;
    margin-top: 24px;
}
.wizard__nav .btn--lg { min-width: 140px; }

/* Büyük rating + radyo (mobile-first) */
.rating--big {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px;
    margin-top: 16px;
}
.rating--big label {
    border: 2px solid #d1d5db; border-radius: 10px;
    padding: 18px 0; cursor: pointer;
    background: #fff; font-size: 22px; font-weight: 600; color: #111;
    text-align: center;
    transition: border-color .12s, background .12s, transform .04s;
}
.rating--big label:hover { border-color: #93c5fd; }
.rating--big label:active { transform: translateY(1px); }
.rating--big label:has(input:checked) {
    background: #2563eb; color: #fff; border-color: #2563eb;
}

.opt--big {
    display: flex; gap: 12px; padding: 14px 16px;
    border: 1.5px solid #e5e7eb; border-radius: 10px;
    margin-bottom: 8px; cursor: pointer; background: #fff;
    transition: border-color .12s, background .12s;
    font-size: 15px;
}
.opt--big:hover { border-color: #93c5fd; }
.opt--big:has(input:checked) {
    border-color: #2563eb; background: #eff6ff; color: #1e40af; font-weight: 500;
}
.opt--big input { width: auto; margin-top: 2px; }

.wizard__question textarea,
.wizard__question input[type=text] {
    margin-top: 14px;
    padding: 12px 14px;
    font-size: 15px;
}

/* Review (onay özet) */
.review {
    margin: 16px 0 24px;
    background: #fff; border: 1px solid #e5e7eb; border-radius: 12px;
    overflow: hidden;
}
.review__row {
    display: grid; grid-template-columns: 1fr 1fr 90px;
    gap: 16px; padding: 14px 18px;
    border-bottom: 1px solid #f3f4f6;
    align-items: start;
}
.review__row:last-child { border-bottom: 0; }
.review__q { color: #374151; font-size: 14px; }
.review__a { color: #111; font-size: 14px; word-break: break-word; }
.review__edit { text-align: right; }
@media (max-width: 600px) {
    .review__row { grid-template-columns: 1fr; gap: 6px; }
    .review__edit { text-align: left; }
}

.prose { line-height: 1.7; color: #374151; }
.prose h1, .prose h2, .prose h3 { color: #111; }
.prose ul, .prose ol { padding-left: 22px; }
.prose code { background: #f3f4f6; padding: 1px 6px; border-radius: 4px; font-size: 13px; }

/* === SERTİFİKA SAYFASI === */
.cert-page {
    padding: 12px 0;
}
.cert-success {
    text-align: center;
    padding: 24px 16px;
    background: linear-gradient(180deg, #ecfdf5, #fff);
    border: 1px solid #a7f3d0;
    border-radius: 12px;
    margin-bottom: 20px;
}

/* === Sertifika önizleme kartı (cert.php) === */
.cert-preview {
    position: relative;
    width: 100%;
    max-width: 480px;
    margin: 16px auto 8px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0,0,0,.12);
    background: #f9fafb;
    /* Container queries için zorunlu (cqw birim için) — eksikti, bazı tarayıcılarda
       overlay font 0px oluyordu */
    container-type: inline-size;
    container-type: inline-size;
}
.cert-preview img {
    width: 100%;
    /* aspect-ratio destekleyen tarayıcılarda inline style ile parent yüksekliği
       belirlenir, image cover ile kaplar. Desteklemeyen eski tarayıcılarda
       (Safari < 15.4 vs.) parent 0 yüksekliğinde kalmasın diye image'in kendi
       natural oranıyla yer kaplaması sağlanır. */
    height: auto;
    display: block;
}
@supports (aspect-ratio: 1) {
    .cert-preview img {
        height: 100%;
        object-fit: cover;
    }
}
.cert-preview__name {
    position: absolute;
    transform: translateX(-50%);
    font-family: 'GreatVibes', cursive;
    white-space: nowrap;
    line-height: 1;
    pointer-events: none;
    /* top, left, font-size, color inline style ile gelir (PHP hesaplar) */
}
.cert-success__icon {
    width: 56px; height: 56px;
    background: #10b981; color: #fff;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 28px; font-weight: 700;
    margin: 0 auto 12px;
    box-shadow: 0 4px 12px rgba(16,185,129,.3);
}
.cert-success h1 { color: #065f46; margin-bottom: 6px; }

.cert-detail {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 12px;
    padding: 20px 24px;
    margin: 16px 0;
}
.cert-detail__row {
    display: flex; justify-content: space-between;
    padding: 10px 0; border-bottom: 1px solid #f3f4f6;
    font-size: 14px;
}
.cert-detail__row:last-child { border-bottom: 0; }
.cert-detail__label { color: #6b7280; }
.cert-detail code {
    background: #f3f4f6; padding: 3px 10px; border-radius: 6px;
    font-size: 13px; letter-spacing: .05em;
}

.cert-actions {
    display: flex; gap: 10px; flex-wrap: wrap; justify-content: center;
    margin: 24px 0 12px;
}
.cert-actions .btn { min-width: 200px; }

.back-link {
    font-size: 13px; display: inline-block; margin-bottom: 8px; color: #6b7280;
}
