/* ============================================
   ACCOUNT PAGE - TAB SYSTEM
   ============================================ */

.account-view-new {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* User Info Card at Top */
.account-user-info {
    margin-bottom: 2rem;
}

.user-info-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 1rem;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.user-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    flex-shrink: 0;
}

.user-avatar i {
    width: 48px;
    height: 48px;
}

.user-details h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    color: var(--text);
}

.user-details p {
    margin: 0 0 0.75rem 0;
    color: var(--text-light);
    font-size: 1rem;
}

.icloud-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    padding: 0.4rem 0.8rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.icloud-badge i {
    width: 16px;
    height: 16px;
}

/* Tab Navigation */
.account-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border);
    overflow-x: auto;
    scrollbar-width: thin;
}

.account-tabs::-webkit-scrollbar {
    height: 4px;
}

.account-tabs::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

.account-tabs button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--text-light);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.account-tabs button i {
    width: 20px;
    height: 20px;
}

.account-tabs button:hover {
    color: var(--text);
    background: rgba(99, 102, 241, 0.05);
}

.account-tabs button.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

/* Tab Content */
.account-tab-content {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 1rem;
    padding: 2rem;
    min-height: 400px;
}

.tab-panel {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tab-panel h3 {
    margin: 0 0 1.5rem 0;
    font-size: 1.5rem;
    color: var(--text);
}

.tab-panel h4 {
    margin: 2rem 0 1rem 0;
    font-size: 1.2rem;
    color: var(--text);
}

/* Form Styles */
.account-form {
    max-width: 600px;
}

.account-form .form-group {
    margin-bottom: 1.5rem;
}

.account-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text);
}

.account-form input[type="text"],
.account-form input[type="email"],
.account-form input[type="password"],
.account-form select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--bg);
    color: var(--text);
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.account-form input:focus,
.account-form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.btn-primary-account {
    padding: 0.875rem 1.75rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary-account:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary-account:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-primary-account i {
    width: 18px;
    height: 18px;
}

/* iCloud Status Card */
.icloud-status-card {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
    border-radius: 0.75rem;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.status-icon {
    width: 48px;
    height: 48px;
    background: rgba(34, 197, 94, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #22c55e;
}

.status-icon i {
    width: 24px;
    height: 24px;
}

.status-info p {
    margin: 0;
}

.icloud-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-danger-account {
    padding: 0.875rem 1.75rem;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-danger-account:hover {
    background: #dc2626;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.3);
}

.btn-danger-account i {
    width: 18px;
    height: 18px;
}

/* Toggle Switch */
.toggle-setting-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.setting-info h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    color: var(--text);
}

.setting-info p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.9rem;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 28px;
}

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

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--border);
    transition: 0.3s;
    border-radius: 28px;
}

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

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--primary);
}

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

/* Sound Settings */
.sound-settings {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.sound-setting-item {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.sound-setting-item label {
    display: block;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 1rem;
}

.sound-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.sound-controls select {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--card-bg);
    color: var(--text);
    font-size: 1rem;
}

.btn-test-sound {
    padding: 0.75rem 1.25rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.btn-test-sound:hover {
    background: var(--secondary);
    transform: translateY(-2px);
}

.btn-test-sound i {
    width: 18px;
    height: 18px;
}

/* Export Buttons */
.export-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-export-account {
    padding: 1rem 2rem;
    background: var(--card-bg);
    border: 2px solid var(--primary);
    color: var(--primary);
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    transition: all 0.3s ease;
}

.btn-export-account:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.3);
}

.btn-export-account i {
    width: 20px;
    height: 20px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .account-view-new {
        padding: 1rem;
    }

    .user-info-card {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }

    .user-avatar {
        width: 64px;
        height: 64px;
        font-size: 2rem;
    }

    .account-tabs {
        gap: 0.25rem;
    }

    .account-tabs button {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }

    .account-tabs button span {
        display: none;
    }

    .account-tabs button i {
        width: 24px;
        height: 24px;
    }

    .account-tab-content {
        padding: 1.5rem;
    }

    .toggle-setting-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .sound-controls {
        flex-direction: column;
        width: 100%;
    }

    .btn-test-sound {
        width: 100%;
        justify-content: center;
    }

    .icloud-actions {
        flex-direction: column;
    }

    .icloud-actions button {
        width: 100%;
        justify-content: center;
    }

    .export-buttons {
        flex-direction: column;
    }

    .btn-export-account {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .user-avatar {
        width: 56px;
        height: 56px;
        font-size: 1.75rem;
    }

    .user-details h3 {
        font-size: 1.25rem;
    }

    .account-tab-content {
        padding: 1rem;
    }

    .tab-panel h3 {
        font-size: 1.25rem;
    }
}

/* ============================================
   AI MODE SELECTOR
   ============================================ */

.ai-mode-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.ai-mode-card {
    position: relative;
    background: var(--bg);
    border: 2px solid var(--border);
    border-radius: 1rem;
    padding: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ai-mode-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.15);
    border-color: var(--primary);
}

.ai-mode-card.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
    border-color: var(--primary);
    border-width: 3px;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.2);
}

.ai-mode-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 0.5rem;
}

.ai-mode-card h4 {
    margin: 0;
    font-size: 1.3rem;
    color: var(--text);
    text-align: center;
}

.ai-mode-card p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.95rem;
    text-align: center;
    line-height: 1.5;
}

.ai-features {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ai-features li {
    color: var(--text);
    font-size: 0.9rem;
    padding-left: 0.25rem;
}

.ai-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-box {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 0.75rem;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.info-box i {
    width: 24px;
    height: 24px;
    color: #3b82f6;
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.info-box p {
    margin: 0;
    color: var(--text);
    font-size: 0.95rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .ai-mode-selector {
        grid-template-columns: 1fr;
    }

    .ai-mode-card {
        padding: 1.5rem;
    }

    .ai-mode-icon {
        font-size: 2.5rem;
    }
}
