/**
 * Profile Settings Styles
 * Extracted from profile.js injectToggleStyles() + inline style="" attributes
 * Used by: profile tab settings sections (region, platforms, triggers, content type)
 */

/* ============================================================
   TOGGLE SWITCHES (previously in injectToggleStyles())
   ============================================================ */

/* Regular Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 28px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(166, 192, 221, 0.3);
    transition: 0.3s;
    border-radius: 28px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background: linear-gradient(135deg, #A6C0DD, #8ba3b8);
}

input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

/* Small Toggle Switch */
.toggle-switch-small {
    position: relative;
    display: inline-block;
    width: 36px;
    height: 20px;
    flex-shrink: 0;
}

.toggle-switch-small input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider-small {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(166, 192, 221, 0.3);
    transition: 0.3s;
    border-radius: 20px;
}

.toggle-slider-small:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .toggle-slider-small {
    background: linear-gradient(135deg, #A6C0DD, #8ba3b8);
}

input:checked + .toggle-slider-small:before {
    transform: translateX(16px);
}

/* Hover effects for toggle items */
.platform-toggle-item:hover,
.trigger-toggle-item:hover {
    background: rgba(166, 192, 221, 0.25);
    border-color: rgba(166, 192, 221, 0.4);
}

/* ============================================================
   REGION SELECT (previously inline styles)
   ============================================================ */

#region-select {
    width: 100%;
    padding: 0.875rem;
    background: rgba(166, 192, 221, 0.2);
    border: 1px solid rgba(166, 192, 221, 0.3);
    border-radius: 0.75rem;
    color: #FDFAB0;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

#region-select:hover {
    background: rgba(166, 192, 221, 0.3);
    border-color: rgba(166, 192, 221, 0.4);
}

#region-select:focus {
    outline: none;
    border-color: #A6C0DD;
    box-shadow: 0 0 0 3px rgba(166, 192, 221, 0.2);
}

#region-select option {
    background: #18183A;
    color: #FDFAB0;
    padding: 0.5rem;
}

/* ============================================================
   FRIENDS LIST (previously inline styles)
   ============================================================ */

#friends-list::-webkit-scrollbar {
    width: 6px;
}

#friends-list::-webkit-scrollbar-track {
    background: rgba(166, 192, 221, 0.1);
    border-radius: 3px;
}

#friends-list::-webkit-scrollbar-thumb {
    background: rgba(166, 192, 221, 0.3);
    border-radius: 3px;
}

#friends-list::-webkit-scrollbar-thumb:hover {
    background: rgba(166, 192, 221, 0.5);
}

/* ============================================================
   SETTINGS SECTIONS (replacing inline style="" attributes)
   ============================================================ */

.pf-settings-section {
    background: linear-gradient(135deg, rgba(166, 192, 221, 0.2), rgba(139, 163, 184, 0.2));
    border: 1px solid rgba(166, 192, 221, 0.3);
    border-radius: 1rem;
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.pf-settings-title {
    font-size: 1rem;
    font-weight: 700;
    color: #FDFAB0;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pf-settings-subtitle {
    color: #A6C0DD;
    font-size: 0.8125rem;
    margin-bottom: 0.75rem;
}

/* Settings grid (platforms, triggers) */
.pf-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
    max-width: 100%;
}

/* Toggle item (platforms + triggers) */
.pf-toggle-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.625rem;
    background: rgba(166, 192, 221, 0.15);
    border: 1px solid rgba(166, 192, 221, 0.2);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    gap: 0.5rem;
    min-height: 42px;
    max-width: 100%;
    box-sizing: border-box;
}

.pf-toggle-item:hover {
    background: rgba(166, 192, 221, 0.25);
    border-color: rgba(166, 192, 221, 0.4);
}

.pf-toggle-item-content {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    flex: 1;
    min-width: 0;
    max-width: calc(100% - 44px);
    overflow: hidden;
}

/* For trigger items (no icon, text only) */
.pf-toggle-item-text {
    flex: 1;
    min-width: 0;
    max-width: calc(100% - 44px);
    overflow: hidden;
}

.pf-toggle-label {
    color: #FDFAB0;
    font-weight: 600;
    font-size: 0.75rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

/* Platform icon/badge */
.pf-platform-icon {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.pf-platform-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    font-size: 0.5rem;
    font-weight: 800;
    flex-shrink: 0;
}

/* ============================================================
   CONTENT TYPE SELECTOR (replacing dynamic inline styles)
   ============================================================ */

.pf-content-type-selector {
    display: flex;
    gap: 0.5rem;
}

.content-type-btn {
    flex: 1;
    padding: 0.625rem 0.25rem;
    border-radius: 0.5rem;
    border: 1.5px solid rgba(166, 192, 221, 0.25);
    background: rgba(166, 192, 221, 0.08);
    color: #A6C0DD;
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.content-type-btn.active {
    border-color: #FDFAB0;
    background: rgba(253, 250, 176, 0.15);
    color: #FDFAB0;
    font-weight: 700;
}

/* ============================================================
   FRIENDS LIST ITEMS (replacing inline styles)
   ============================================================ */

.pf-friend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.625rem;
    background: rgba(166, 192, 221, 0.1);
    border: 1px solid rgba(166, 192, 221, 0.2);
    border-radius: 0.5rem;
    margin-bottom: 0.375rem;
    min-height: 42px;
}

.pf-friend-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pf-friend-avatar {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #A6C0DD, #8ba3b8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #18183A;
}

.pf-friend-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #FDFAB0;
}

.pf-friend-remove-btn {
    padding: 0.3rem 0.625rem;
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 0.375rem;
    color: #ef4444;
    font-size: 0.6875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.pf-friend-remove-btn:hover {
    background: rgba(239, 68, 68, 0.25);
}

/* Empty friends state */
.pf-friends-empty {
    text-align: center;
    padding: 2rem 1rem;
    color: #A6C0DD;
    opacity: 0.6;
}

.pf-friends-empty-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.pf-friends-empty-text {
    font-size: 0.875rem;
    margin: 0;
}

/* ============================================================
   PREMIUM MODAL (replacing inline styles from showPremiumModal)
   ============================================================ */

.pf-premium-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 1rem;
    animation: fadeIn 0.3s ease-out;
}

.pf-premium-card {
    background: linear-gradient(135deg, #1a1f2e 0%, #0f1419 100%);
    border-radius: 1.5rem;
    padding: 2rem;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(176, 212, 227, 0.2);
    position: relative;
}

.pf-premium-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    background: rgba(176, 212, 227, 0.1);
    border: 1px solid rgba(176, 212, 227, 0.2);
    border-radius: 50%;
    color: rgba(176, 212, 227, 0.8);
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pf-premium-header {
    text-align: center;
    margin-bottom: 2rem;
}

.pf-premium-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    margin: 0 auto 1rem;
}

.pf-premium-title {
    color: #FDFAB0;
    font-size: 1.875rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
}

.pf-premium-price {
    color: rgba(176, 212, 227, 0.8);
    font-size: 1rem;
    margin: 0;
}

.pf-premium-features {
    background: rgba(176, 212, 227, 0.08);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.pf-premium-features-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.pf-premium-feature {
    display: flex;
    align-items: start;
    gap: 1rem;
}

.pf-premium-feature-icon {
    font-size: 1.75rem;
}

.pf-premium-feature-title {
    color: #FDFAB0;
    font-weight: 700;
    font-size: 1.0625rem;
    margin-bottom: 0.25rem;
}

.pf-premium-feature-desc {
    color: rgba(176, 212, 227, 0.7);
    font-size: 0.875rem;
}

.pf-premium-cta {
    width: 100%;
    padding: 1.25rem;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #fff;
    border: none;
    border-radius: 0.75rem;
    font-weight: 700;
    font-size: 1.125rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.pf-premium-trial {
    text-align: center;
    color: rgba(176, 212, 227, 0.5);
    font-size: 0.8125rem;
    margin: 1rem 0 0 0;
}

/* ============================================================
   ERROR STATE (replacing inline styles from renderError)
   ============================================================ */

.pf-error-state {
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 1rem;
    padding: 2rem;
    text-align: center;
}

.pf-error-icon {
    font-size: 3rem;
}

.pf-error-title {
    color: #FDFAB0;
    font-weight: 700;
    font-size: 1.25rem;
}

.pf-error-text {
    color: #A6C0DD;
    font-size: 0.875rem;
}

/* ============================================================
   MISC (friend code hint, delete loading spinner)
   ============================================================ */

.pf-hint-text {
    color: #A6C0DD;
    font-size: 0.75rem;
    margin: 0.75rem 0 0 0;
    opacity: 0.8;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
