.profile-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.75);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1050;
    opacity: 0;
    transition: opacity 0.25s ease;
    backdrop-filter: blur(8px);
}

.profile-modal-overlay.show {
    display: flex;
    opacity: 1;
}

.custom-editor-dialog {
    width: 1140px;
    max-width: 96vw;
    height: 86vh;
    max-height: 800px;
    background: #111214;
    border-radius: 16px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.6);
    display: flex;
    overflow: hidden;
    position: relative;
    color: #dbdee1;
    border: 1px solid #1e1f22;
}

body:not(.dark-mode) .custom-editor-dialog {
    background: #ffffff;
    color: #2e3338;
    border-color: #e3e5e8;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.editor-close-btn {
    position: absolute;
    top: 16px;
    right: 18px;
    background: #1e1f22;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    color: #949ba4;
    cursor: pointer;
    z-index: 50;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s ease;
}

body:not(.dark-mode) .editor-close-btn {
    background: #f2f3f5;
    color: #4e5058;
}

.editor-close-btn:hover {
    color: #f2f3f5;
    background: #2b2d31;
}

body:not(.dark-mode) .editor-close-btn:hover {
    color: #060607;
    background: #e3e5e8;
}

.custom-editor-sidebar {
    width: 310px;
    background: #1e1f22;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    border-right: 1px solid #2b2d31;
    flex-shrink: 0;
}

.custom-editor-sidebar::-webkit-scrollbar {
    width: 5px;
}

.custom-editor-sidebar::-webkit-scrollbar-thumb {
    background: #2b2d31;
    border-radius: 4px;
}

body:not(.dark-mode) .custom-editor-sidebar::-webkit-scrollbar-thumb {
    background: #e3e5e8;
}

body:not(.dark-mode) .custom-editor-sidebar {
    background: #f2f3f5;
    border-color: #e3e5e8;
}

.profile-type-dropdown {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #2b2d31;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 24px;
    cursor: pointer;
    color: #f2f3f5;
}

body:not(.dark-mode) .profile-type-dropdown {
    background: #ffffff;
    color: #060607;
    border: 1px solid #e3e5e8;
}

.custom-config-section {
    margin-bottom: 22px;
}

.section-heading-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.section-heading-label {
    display: block;
    font-size: 11.5px;
    font-weight: 800;
    color: #949ba4;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0;
}

body:not(.dark-mode) .section-heading-label {
    color: #4e5058;
}

.btn-text-danger {
    background: transparent;
    border: none;
    color: #ef4444;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    transition: opacity 0.2s;
}

.btn-text-danger:hover {
    opacity: 0.8;
}

.custom-slots-grid {
    display: flex;
    gap: 12px;
}

.custom-slot-card {
    flex: 1;
    height: 76px;
    background: #2b2d31;
    border-radius: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

body:not(.dark-mode) .custom-slot-card {
    background: #ffffff;
    border-color: #e3e5e8;
}

.custom-slot-card:hover {
    border-color: var(--primary-color);
}

.custom-slot-card img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.slot-badge-action {
    position: absolute;
    bottom: 6px;
    right: 6px;
    width: 22px;
    height: 22px;
    background: #111214;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 11px;
    color: #f2f3f5;
}

body:not(.dark-mode) .slot-badge-action {
    background: #ffffff;
    color: #060607;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.active-frame {
    background: radial-gradient(circle, rgba(0, 191, 165, 0.15) 0%, #2b2d31 75%);
}

.slot-center-icon {
    font-size: 24px;
    color: var(--primary-color);
}

.display-name-styler-box {
    background: #2b2d31;
    border-radius: 8px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
}

body:not(.dark-mode) .display-name-styler-box {
    background: #ffffff;
    border: 1px solid #e3e5e8;
}

.name-styler-input {
    width: 100%;
    background: transparent;
    border: none;
    color: #f2f3f5;
    font-size: 14px;
    font-weight: 700;
    outline: none;
}

body:not(.dark-mode) .name-styler-input {
    color: #060607;
}

.font-selection-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    margin-top: 10px;
}

.font-chip-btn {
    height: 38px;
    background: #2b2d31;
    border: 1.5px solid transparent;
    border-radius: 8px;
    color: #f2f3f5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 4px;
}

body:not(.dark-mode) .font-chip-btn {
    background: #ffffff;
    border-color: #e3e5e8;
    color: #060607;
}

.font-chip-btn:hover {
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.font-chip-btn.active {
    border-color: var(--primary-color);
    background: color-mix(in srgb, var(--primary-color) 18%, transparent);
    color: var(--primary-color);
    box-shadow: 0 0 10px color-mix(in srgb, var(--primary-color) 30%, transparent);
}

.font-clean { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 12.5px; font-weight: 800; }
.font-gothic { font-family: 'UnifrakturMaguntia', cursive; font-size: 17px; }
.font-cyber { font-family: 'Orbitron', sans-serif; font-size: 11.5px; font-weight: 900; letter-spacing: 0.5px; }
.font-nobre { font-family: 'Cinzel Decorative', serif; font-size: 12px; font-weight: 700; }
.font-arcade { font-family: 'Press Start 2P', monospace; font-size: 8.5px; }
.font-marker { font-family: 'Permanent Marker', cursive; font-size: 13px; }
.font-script { font-family: 'Kaushan Script', cursive; font-size: 14px; }
.font-brutal { font-family: 'Bungee', sans-serif; font-size: 10.5px; }
.font-amatic { font-family: 'Amatic SC', cursive; font-size: 18px; font-weight: 700; }
.font-caacupe { font-family: 'Caacupe One', cursive; font-size: 14px; }
.font-cinzel { font-family: 'Cinzel', serif; font-size: 13px; font-weight: 700; }
.font-creepster { font-family: 'Creepster', cursive; font-size: 14px; letter-spacing: 1px; }
.font-dancing { font-family: 'Dancing Script', cursive; font-size: 16px; }
.font-hachi { font-family: 'Hachi Maru Pop', cursive; font-size: 11px; }
.font-philosopher { font-family: 'Philosopher', sans-serif; font-size: 13px; font-weight: 700; }
.font-rocksalt { font-family: 'Rock Salt', cursive; font-size: 10px; }
.font-skranji { font-family: 'Skranji', cursive; font-size: 13px; }
.font-yuyu { font-family: 'Yuyu Short', cursive; font-size: 14px; }

.banner-customizer-box {
    display: flex;
    gap: 10px;
    align-items: center;
}

.banner-color-pickers {
    display: flex;
    gap: 8px;
}

.color-picker-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.color-picker-item input[type="color"] {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    background: transparent;
    padding: 0;
}

.color-picker-item input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.color-picker-item input[type="color"]::-webkit-color-swatch {
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
}

.color-picker-label {
    font-size: 10px;
    font-weight: 700;
    color: #949ba4;
    text-transform: uppercase;
}

.banner-upload-slot {
    flex: 1;
    height: 52px;
    background: #2b2d31;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border: 1px solid transparent;
    transition: border-color 0.2s;
}

body:not(.dark-mode) .banner-upload-slot {
    background: #ffffff;
    border-color: #e3e5e8;
}

.banner-upload-slot:hover {
    border-color: var(--primary-color);
}

.slot-banner-bg {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1e1f22 0%, var(--primary-color) 100%);
}

.bio-editor-textarea {
    width: 100%;
    background: #2b2d31;
    border: 1px solid transparent;
    border-radius: 8px;
    padding: 10px 14px;
    color: #f2f3f5;
    font-size: 13px;
    outline: none;
    font-family: inherit;
    resize: vertical;
}

body:not(.dark-mode) .bio-editor-textarea {
    background: #ffffff;
    border-color: #e3e5e8;
    color: #060607;
}

.bio-editor-textarea:focus {
    border-color: var(--primary-color);
}

.save-customizer-btn {
    width: 100%;
    padding: 12px;
    background: var(--primary-color);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    margin-top: auto;
    transition: opacity 0.2s ease;
}

.save-customizer-btn:hover {
    opacity: 0.9;
}

.custom-preview-column.split-view-mode {
    flex: 1;
    background: #18191c;
    padding: 24px 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
}

body:not(.dark-mode) .custom-preview-column.split-view-mode {
    background: #edeef0;
}

.preview-badge-header {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 9999px;
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: #949ba4;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.preview-badge-header i {
    color: var(--primary-color);
    font-size: 13px;
}

body:not(.dark-mode) .preview-badge-header {
    background: #ffffff;
    border-color: #e3e5e8;
    color: #4e5058;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.split-profile-card {
    display: flex;
    gap: 20px;
    width: 100%;
    max-width: 680px;
    align-items: stretch;
    justify-content: center;
}

.profile-card-left-poster {
    width: 270px;
    min-height: 420px;
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px 20px;
    flex-shrink: 0;
    background: #111214;
}

.profile-card-left-poster img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    z-index: 0;
}

.poster-overlay-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 70%;
    background: linear-gradient(180deg, transparent 20%, rgba(0, 0, 0, 0.9) 100%);
    z-index: 1;
}

.poster-footer-content {
    position: relative;
    z-index: 2;
    color: #ffffff;
}

.poster-footer-content h3 {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 3px;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.poster-footer-content p {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 14px;
    font-weight: 500;
}

.poster-badge-pill {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
}

.profile-card-right-info {
    flex: 1;
    background: #232428;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

body:not(.dark-mode) .profile-card-right-info {
    background: #ffffff;
    border-color: #e3e5e8;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.card-info-banner-wrap {
    width: 100%;
    height: 110px;
    background: linear-gradient(135deg, #1e1f22 0%, var(--primary-color) 100%);
    position: relative;
    overflow: hidden;
}

.card-info-banner-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-info-avatar-overlap {
    padding: 0 20px;
    position: relative;
    height: 32px;
}

.avatar-ring-box {
    position: absolute;
    top: -42px;
    width: 74px;
    height: 74px;
}

.avatar-ring-box img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #232428;
    background: #232428;
}

body:not(.dark-mode) .avatar-ring-box img {
    border-color: #ffffff;
    background: #ffffff;
}

.avatar-online-dot {
    position: absolute;
    bottom: 3px;
    right: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #10b981;
    border: 3px solid #232428;
}

body:not(.dark-mode) .avatar-online-dot {
    border-color: #ffffff;
}

.card-info-body {
    padding: 14px 22px 22px 22px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.card-info-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.card-info-header-row h3 {
    font-size: 20px;
    font-weight: 800;
    color: #f2f3f5;
    margin: 0;
    letter-spacing: -0.01em;
}

body:not(.dark-mode) .card-info-header-row h3 {
    color: #060607;
}

.card-handle-text {
    font-size: 13px;
    color: #949ba4;
}

body:not(.dark-mode) .card-handle-text {
    color: #4e5058;
}

.status-greeting-pill {
    font-size: 11.5px;
    font-weight: 700;
    color: #10b981;
    background: rgba(16, 185, 129, 0.12);
    padding: 4px 10px;
    border-radius: 9999px;
}

.card-bio-paragraph {
    font-size: 13px;
    line-height: 1.5;
    color: #dbdee1;
    margin-bottom: 14px;
    word-break: break-word;
}

body:not(.dark-mode) .card-bio-paragraph {
    color: #2e3338;
}

.card-roles-badges {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.role-badge-chip {
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.08);
    color: #dbdee1;
    display: flex;
    align-items: center;
    gap: 5px;
}

body:not(.dark-mode) .role-badge-chip {
    background: #f2f3f5;
    color: #4e5058;
}

.role-badge-chip.primary {
    background: color-mix(in srgb, var(--primary-color) 15%, transparent);
    color: var(--primary-color);
}

.card-metrics-row {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 12px 14px;
    background: #18191c;
    border-radius: 12px;
    margin-bottom: 18px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

body:not(.dark-mode) .card-metrics-row {
    background: #f8fafc;
    border-color: #e3e5e8;
}

.metric-col {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.metric-col strong {
    font-size: 15px;
    font-weight: 800;
    color: #f2f3f5;
}

body:not(.dark-mode) .metric-col strong {
    color: #060607;
}

.metric-col span {
    font-size: 11px;
    color: #949ba4;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-top: 2px;
}

body:not(.dark-mode) .metric-col span {
    color: #4e5058;
}

.metric-divider {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.08);
}

body:not(.dark-mode) .metric-divider {
    background: #e3e5e8;
}

.card-actions-row {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.card-btn-action-primary {
    flex: 1;
    height: 40px;
    border-radius: 9999px;
    background: var(--primary-color);
    color: #ffffff;
    border: none;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: opacity 0.2s, transform 0.1s;
}

.card-btn-action-primary:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.card-btn-action-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #18191c;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #dbdee1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    text-decoration: none;
    transition: all 0.2s ease;
}

body:not(.dark-mode) .card-btn-action-icon {
    background: #f2f3f5;
    border-color: #e3e5e8;
    color: #4e5058;
}

.card-btn-action-icon:hover {
    color: var(--primary-color);
    transform: translateY(-1px);
}

@media (max-width: 900px) {
    .split-profile-card {
        flex-direction: column;
    }
    .profile-card-left-poster {
        width: 100%;
        min-height: 260px;
    }
}