/*
 * Moonon.uk - Kullanıcı Profili & Kişisel Tercihler & Firma Özelleştirme Önizlemesi
 * Tüm stiller harici dosyada toplanmıştır (sıfır inline style, CLS=0, GPU-güvenli geçişler).
 */

.pr-page {
    padding: 112px 24px 84px;
    background: #ffffff;
    color: #0F2554;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 76vh;
}

.pr-shell {
    max-width: 1240px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ---------- 1. Hero Kapak Bandı (Mimari Halka Deseni + Moon Logosu) ---------- */
.pr-hero-wrap {
    position: relative;
}

.pr-hero {
    position: relative;
    height: 216px;
    border-radius: 20px;
    background: linear-gradient(135deg, #f8fafd 0%, #eef2f9 55%, #f5f7fc 100%);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 26px -14px rgba(15, 37, 84, 0.14);
}

.pr-hero-cover-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.pr-hero-cover-img[hidden] {
    display: none;
}

.pr-hero-rings {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.pr-ring {
    position: absolute;
    border-radius: 50%;
    border: 3px solid rgba(15, 37, 84, 0.065);
}

.pr-ring--1 {
    width: 340px;
    height: 340px;
    left: -90px;
    top: -150px;
}

.pr-ring--2 {
    width: 440px;
    height: 440px;
    left: 24%;
    top: -110px;
    border-width: 6px;
    border-color: rgba(15, 37, 84, 0.055);
}

.pr-ring--3 {
    width: 260px;
    height: 260px;
    left: 46%;
    bottom: -140px;
    border-width: 5px;
    border-color: rgba(15, 37, 84, 0.06);
}

.pr-ring--4 {
    width: 390px;
    height: 390px;
    right: -110px;
    bottom: -230px;
    border-width: 2px;
    border-color: rgba(15, 37, 84, 0.05);
}

.pr-hero-brand {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
}

.pr-hero-logo {
    width: 210px;
    max-width: 56vw;
    height: auto;
    aspect-ratio: 2362 / 617;
    object-fit: contain;
    display: block;
}

.pr-cover-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 34px;
    padding: 0 12px;
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    color: #0F2554;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #dbe2ee;
    border-radius: 999px;
    cursor: pointer;
    backdrop-filter: blur(6px);
    transition: background-color 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

@media (hover: hover) {
    .pr-cover-btn:hover {
        background: #ffffff;
        border-color: #0F2554;
        transform: translateY(-1px);
    }
}

.pr-cover-btn:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

/* ---------- 2. Kimlik Satırı (Örtüşen Avatar + İstatistikler) ---------- */
.pr-identity-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    padding: 0 28px;
    margin-top: -64px;
    position: relative;
    z-index: 4;
}

.pr-identity-left {
    display: flex;
    align-items: flex-end;
    gap: 20px;
    min-width: 0;
}

.pr-avatar-wrap {
    position: relative;
    width: 112px;
    height: 112px;
    flex: 0 0 112px;
    border-radius: 50%;
    background: #ffffff;
    border: 4px solid #ffffff;
    box-shadow: 0 8px 22px rgba(15, 37, 84, 0.14);
}

.pr-avatar-circle {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #eef2fa;
    border: 1px solid #dbe2ee;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0F2554;
}

.pr-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pr-avatar-img[hidden],
.pr-avatar-fallback[hidden] {
    display: none;
}

.pr-avatar-edit {
    position: absolute;
    right: -2px;
    bottom: 2px;
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 50%;
    background: #ffffff;
    color: #0F2554;
    border: 1.5px solid #dbe2ee;
    box-shadow: 0 4px 12px rgba(15, 37, 84, 0.14);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

@media (hover: hover) {
    .pr-avatar-edit:hover {
        background: #0F2554;
        color: #ffffff;
        border-color: #0F2554;
        transform: scale(1.06);
    }
}

.pr-avatar-edit:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

.pr-identity-meta {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding-bottom: 4px;
    min-width: 0;
}

.pr-name-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.pr-name {
    margin: 0;
    font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif;
    font-size: 23px;
    font-weight: 700;
    line-height: 1.2;
    color: #0F2554;
}

.pr-role-pill {
    display: inline-flex;
    align-items: center;
    padding: 3px 9px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #0F2554;
    background: #eef2fa;
    border-radius: 999px;
}

.pr-role-pill--preview {
    color: #475569;
    background: #f1f5f9;
}

.pr-handle {
    margin: 0;
    font-size: 13.5px;
    font-weight: 500;
    color: #64748b;
}

/* Sağ İstatistik Kartı */
.pr-stats-card {
    display: inline-flex;
    align-items: stretch;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    box-shadow: 0 6px 18px -10px rgba(15, 37, 84, 0.12);
    overflow: hidden;
}

.pr-stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-width: 104px;
    padding: 12px 16px;
    text-decoration: none;
    color: inherit;
    position: relative;
    transition: background-color 0.16s ease;
}

.pr-stat-item + .pr-stat-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 16%;
    height: 68%;
    width: 1px;
    background: #e2e8f0;
}

@media (hover: hover) {
    a.pr-stat-item:hover {
        background: #f8fafd;
    }
}

.pr-stat-val {
    font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.1;
    color: #0F2554;
}

.pr-stat-lbl {
    font-size: 11.5px;
    font-weight: 500;
    line-height: 1.25;
    color: #64748b;
    text-align: center;
}

/* ---------- 3. Sekme Çubuğu ---------- */
.pr-tabs-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 12px;
}

.pr-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 4px;
    background: #f1f5f9;
    border-radius: 12px;
}

.pr-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 16px;
    font: inherit;
    font-size: 13.5px;
    font-weight: 600;
    color: #475569;
    background: transparent;
    border: 0;
    border-radius: 9px;
    cursor: pointer;
    transition: background-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

@media (hover: hover) {
    .pr-tab:hover {
        color: #0F2554;
    }
}

.pr-tab.is-active {
    background: #ffffff;
    color: #0F2554;
    box-shadow: 0 2px 8px rgba(15, 37, 84, 0.08);
}

.pr-tab:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

.pr-tab-badge {
    font-size: 10.5px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 999px;
    color: #0F2554;
    background: #e2e9f8;
}

.pr-preview-hint {
    margin: 0;
    font-size: 12.5px;
    font-weight: 500;
    color: #64748b;
}

/* ---------- 4. İçerik Paneli & 2 Sütun Izgara ---------- */
.pr-panel[hidden] {
    display: none;
}

.pr-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(290px, 0.9fr);
    gap: 22px;
    align-items: start;
}

.pr-grid--balanced {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pr-col {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-width: 0;
}

.pr-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 22px 24px;
    box-shadow: 0 6px 20px -14px rgba(15, 37, 84, 0.1);
}

.pr-card--subtle {
    background: #f8fafd;
}

.pr-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.pr-card-head--centered {
    position: relative;
    justify-content: center;
}

.pr-card-head--centered .pr-icon-edit {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

.pr-tag-title {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: #334155;
    background: #e9edf3;
    border-radius: 7px;
}

.pr-card-title {
    margin: 0;
    font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif;
    font-size: 17px;
    font-weight: 700;
    color: #0F2554;
}

.pr-card-sub {
    margin: 4px 0 0;
    font-size: 13px;
    color: #64748b;
}

.pr-icon-edit {
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #475569;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

@media (hover: hover) {
    .pr-icon-edit:hover {
        background: #eef2fa;
        color: #0F2554;
    }
}

.pr-icon-edit:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

.pr-about-text {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #334155;
    min-height: 54px;
    white-space: pre-line;
}

.pr-about-text.is-placeholder {
    color: #64748b;
}

/* Anahtar-Değer Satırları (Kişisel Bilgiler) */
.pr-kv-list {
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 13px;
}

.pr-kv-row {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 12px;
    align-items: baseline;
    font-size: 14px;
}

.pr-kv-row dt {
    font-weight: 600;
    color: #0F2554;
}

.pr-kv-row dd {
    margin: 0;
    color: #475569;
    overflow-wrap: anywhere;
}

/* Satır İçi Düzenleme Formu */
.pr-inline-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pr-inline-form[hidden] {
    display: none;
}

.pr-field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.pr-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pr-field--full {
    grid-column: 1 / -1;
}

.pr-field label {
    font-size: 12.5px;
    font-weight: 600;
    color: #0F2554;
}

.pr-field input,
.pr-field textarea,
.pr-field select {
    width: 100%;
    padding: 10px 13px;
    font: inherit;
    font-size: 13.5px;
    color: #0F2554;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pr-field input:focus,
.pr-field textarea:focus,
.pr-field select:focus {
    outline: none;
    border-color: #0F2554;
    box-shadow: 0 0 0 3px rgba(15, 37, 84, 0.08);
}

.pr-field textarea {
    min-height: 92px;
    resize: vertical;
}

.pr-form-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}

/* Düğmeler */
.pr-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 40px;
    padding: 0 18px;
    font: inherit;
    font-size: 13.5px;
    font-weight: 600;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    box-sizing: border-box;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.pr-btn--primary {
    color: #ffffff;
    background: #0F2554;
    border: 1.5px solid #0F2554;
}

@media (hover: hover) {
    .pr-btn--primary:hover {
        background: #173473;
        border-color: #173473;
        color: #ffffff;
    }
}

.pr-btn--ghost {
    color: #0F2554;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
}

@media (hover: hover) {
    .pr-btn--ghost:hover {
        background: #f8fafc;
        border-color: #0F2554;
    }
}

.pr-btn:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

.pr-btn:active {
    transform: scale(0.98);
}

/* ---------- 5. Tercih Hapları & Toggle Anahtarları ---------- */
.pr-pref-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pr-pref-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pr-pref-label {
    font-size: 13px;
    font-weight: 700;
    color: #0F2554;
}

.pr-pill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pr-pill-opt {
    padding: 8px 14px;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    cursor: pointer;
    box-sizing: border-box;
    transition: border-color 0.14s ease, background-color 0.14s ease, color 0.14s ease;
}

@media (hover: hover) {
    .pr-pill-opt:hover {
        border-color: #94a3b8;
        background: #f8fafc;
    }
}

.pr-pill-opt.is-selected {
    color: #0F2554;
    background: #eef2fb;
    border: 2px solid #0F2554;
    padding: 7.5px 13.5px;
    font-weight: 700;
}

.pr-pill-opt:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

.pr-switch-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.pr-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 14px;
    background: #f8fafd;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.pr-switch-copy {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.pr-switch-title {
    font-size: 13.5px;
    font-weight: 600;
    color: #0F2554;
}

.pr-switch-desc {
    font-size: 12px;
    line-height: 1.4;
    color: #64748b;
}

.pr-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex: 0 0 44px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #cbd5e1;
    cursor: pointer;
    transition: background-color 0.18s ease;
}

.pr-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.2);
    transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);
}

.pr-switch[aria-checked="true"] {
    background: #0F2554;
}

.pr-switch[aria-checked="true"]::after {
    transform: translateX(20px);
}

.pr-switch:focus-visible {
    outline: 2px solid #0F2554;
    outline-offset: 2px;
}

/* ---------- 6. Firma Profili & Kurumsal Kartlar ---------- */
.pr-company-banner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #f4f7fd 0%, #eef2fa 100%);
    border: 1px solid #d5e0f4;
    border-radius: 14px;
    margin-bottom: 20px;
}

.pr-company-banner-title {
    margin: 0 0 3px;
    font-size: 14.5px;
    font-weight: 700;
    color: #0F2554;
}

.pr-company-banner-desc {
    margin: 0;
    font-size: 13px;
    color: #475569;
}

.pr-company-logo-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.pr-company-logo-box {
    width: 76px;
    height: 76px;
    border-radius: 14px;
    background: #ffffff;
    border: 1.5px dashed #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #64748b;
    padding: 6px;
    box-sizing: border-box;
}

.pr-company-logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.pr-company-logo-img[hidden] {
    display: none;
}

/* Bildirim Toast */
.pr-toast {
    position: fixed;
    right: 24px;
    top: 88px;
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    z-index: 10050;
    padding: 11px 18px;
    font-size: 13.5px;
    font-weight: 600;
    color: #ffffff;
    background: #0F2554;
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(15, 37, 84, 0.25);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.pr-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.pr-hidden-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* ---------- 7. Responsive Kırılımlar ---------- */
@media screen and (max-width: 960px) {
    .pr-grid,
    .pr-grid--balanced {
        grid-template-columns: minmax(0, 1fr);
    }

    .pr-identity-row {
        padding: 0 12px;
    }
}

@media screen and (max-width: 640px) {
    .pr-page {
        padding: 88px 14px 68px;
    }

    .pr-hero {
        height: 158px;
        border-radius: 16px;
    }

    .pr-hero-brand {
        padding-bottom: 34px;
    }

    .pr-hero-logo {
        width: 136px;
    }

    .pr-cover-btn {
        top: 10px;
        right: 10px;
        padding: 0 10px;
        height: 30px;
        font-size: 11.5px;
    }

    .pr-identity-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
        padding: 0 8px;
        margin-top: -46px;
    }

    .pr-avatar-wrap {
        width: 92px;
        height: 92px;
        flex: 0 0 92px;
    }

    .pr-name {
        font-size: 20px;
    }

    .pr-stats-card {
        width: 100%;
    }

    .pr-stat-item {
        flex: 1 1 0;
        min-width: 0;
        padding: 10px 8px;
    }

    .pr-tabs {
        width: 100%;
    }

    .pr-tab {
        flex: 1 1 auto;
        justify-content: center;
        padding: 8px 10px;
        font-size: 12.5px;
    }

    .pr-card {
        padding: 18px 16px;
    }

    .pr-kv-row {
        grid-template-columns: minmax(0, 1fr);
        gap: 2px;
    }

    .pr-field-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    .pr-cover-btn,
    .pr-avatar-edit,
    .pr-tab,
    .pr-btn,
    .pr-switch,
    .pr-switch::after,
    .pr-toast {
        transition: none;
    }
}
