/* ============================================================================
  Mobile responsive key breakpoints.
   ============================================================================ */

   /* Tablet */
@media (max-width: 768px) {
    .topbar-container {
        flex-direction: column;
        padding: 12px;
    }
    
    .nav-links {
        flex-direction: column;
        width: 100%;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .dashboard-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        display: none; /* Or make it a dropdown */
    }
}

/**
 * Account Settings Styles
 * Complete styling for the settings page with tabs and forms
 */

/* ============================================================================
   SETTINGS CONTAINER
   ============================================================================ */

.settings-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 24px 80px;
}

/* ============================================================================
   SETTINGS HEADER
   ============================================================================ */

.settings-header {
    margin-bottom: 40px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 16px;
    transition: color 0.2s;
}

.back-link:hover {
    color: #333;
}

.settings-header h1 {
    font-size: 36px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 8px 0;
}

.settings-subtitle {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* ============================================================================
   SETTINGS LAYOUT
   ============================================================================ */

.settings-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 32px;
}

/* ============================================================================
   SETTINGS SIDEBAR
   ============================================================================ */

.settings-sidebar {
    position: sticky;
    top: 32px;
    height: fit-content;
}

.settings-nav {
    background: white;
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.settings-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: transparent;
    color: #666;
    font-size: 15px;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
    font-family: 'Inter', sans-serif;
}

.settings-nav-item:hover {
    background: #f5f5f5;
    color: #333;
}

.settings-nav-item.active {
    background: #667eea;
    color: white;
}

.settings-nav-item.danger {
    color: #dc2626;
}

.settings-nav-item.danger:hover {
    background: #fef2f2;
    color: #dc2626;
}

.settings-nav-item svg {
    flex-shrink: 0;
}

/* ============================================================================
   SETTINGS MAIN CONTENT
   ============================================================================ */

.settings-main {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.settings-tab {
    display: none;
}

.settings-tab.active {
    display: block;
}

.settings-section {
    padding: 32px;
    border-bottom: 1px solid #e0e0e0;
}

.settings-section:last-child {
    border-bottom: none;
}

.settings-section h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 8px 0;
}

.section-description {
    font-size: 15px;
    color: #666;
    margin: 0 0 24px 0;
    line-height: 1.5;
}

/* ============================================================================
   FORMS
   ============================================================================ */

.settings-form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-help {
    font-size: 13px;
    color: #666;
    margin: 6px 0 0 0;
}

.form-actions {
    margin-top: 32px;
}

/* ============================================================================
   BUTTONS
   ============================================================================ */

.btn-primary {
    padding: 12px 24px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.btn-primary:hover {
    background: #5568d3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    padding: 12px 24px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-secondary:hover {
    background: #f5f5f5;
}

.btn-secondary-outline {
    padding: 10px 20px;
    background: transparent;
    color: #666;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.btn-secondary-outline:hover {
    border-color: #667eea;
    color: #667eea;
}

.btn-danger {
    padding: 12px 24px;
    background: #dc2626;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.btn-danger:hover {
    background: #b91c1c;
}

/* ============================================================================
   PLAN CARDS
   ============================================================================ */

.plan-card {
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 16px;
    transition: all 0.2s;
}

.plan-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.plan-card.active {
    border-color: #667eea;
    background: #f8f9fe;
}

.plan-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.plan-card h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.plan-price {
    font-size: 32px;
    font-weight: 700;
    color: #667eea;
    margin: 0;
}

.plan-price .price-number {
    font-size: 32px;
    font-weight: 700;
    color: #667eea;
}

.plan-price span {
    font-size: 16px;
    font-weight: 500;
    color: #666;
}

.plan-price .period {
    font-size: 16px;
    font-weight: 500;
    color: #666;
}

.plan-badge {
    padding: 6px 12px;
    background: #e0e0e0;
    color: #666;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

.plan-badge.recommended {
    background: #10B981;
    color: white;
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.plan-features li {
    padding: 8px 0;
    color: #333;
    font-size: 15px;
}

/* ============================================================================
   CONNECTIONS LIST
   ============================================================================ */

.connections-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.connection-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    transition: all 0.2s;
}

.connection-card:hover {
    border-color: #0077b5;
    background: #f8f9fa;
}

.connection-icon {
    font-size: 32px;
}

.connection-info {
    flex: 1;
}

.connection-info h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.connection-info p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.connection-badge {
    padding: 6px 12px;
    background: #10B981;
    color: white;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

/* ============================================================================
   TOGGLE SWITCHES
   ============================================================================ */

.toggle-group {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.toggle-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
}

.toggle-info h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.toggle-info p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

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

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

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    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 input:checked + .toggle-slider {
    background-color: #667eea;
}

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

/* ============================================================================
   SECURITY STATUS
   ============================================================================ */

.security-status {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    margin-bottom: 24px;
}

.security-icon {
    font-size: 32px;
}

.security-status h4 {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.security-status p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

/* ============================================================================
   SESSION LIST
   ============================================================================ */

.session-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.session-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
}

.session-icon {
    font-size: 24px;
}

.session-info {
    flex: 1;
}

.session-info h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.session-info p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.session-badge {
    padding: 6px 12px;
    background: #10B981;
    color: white;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

/* ============================================================================
   DANGER SECTION
   ============================================================================ */

.danger-section {
    background: #fef2f2;
}

.danger-warning {
    display: flex;
    align-items: start;
    gap: 16px;
    padding: 20px;
    background: white;
    border: 2px solid #fca5a5;
    border-radius: 12px;
    margin-bottom: 24px;
}

.danger-warning svg {
    color: #dc2626;
    flex-shrink: 0;
}

.danger-warning h4 {
    font-size: 16px;
    font-weight: 700;
    color: #991b1b;
    margin: 0 0 8px 0;
}

.danger-warning p {
    font-size: 14px;
    color: #666;
    margin: 0 0 8px 0;
}

.danger-warning ul {
    margin: 8px 0 0 20px;
    padding: 0;
    color: #666;
    font-size: 14px;
}

.danger-warning li {
    margin: 4px 0;
}

/* ============================================================================
   EMPTY STATES
   ============================================================================ */

.empty-state-small {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.empty-state-small p {
    margin: 0;
    font-size: 15px;
}

/* ============================================================================
   RESPONSIVE DESIGN
   ============================================================================ */

@media (max-width: 1024px) {
    .settings-content {
        grid-template-columns: 1fr;
    }
    
    .settings-sidebar {
        position: static;
    }
    
    .settings-nav {
        display: flex;
        overflow-x: auto;
        padding: 8px;
    }
    
    .settings-nav-item {
        white-space: nowrap;
        flex-shrink: 0;
    }
}

@media (max-width: 768px) {
    .settings-container {
        padding: 24px 16px 60px;
    }
    
    .settings-header h1 {
        font-size: 28px;
    }
    
    .settings-section {
        padding: 24px 20px;
    }
    
    .toggle-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .connection-card {
        flex-direction: column;
        text-align: center;
    }
    
    .plan-header {
        flex-direction: column;
        gap: 12px;
    }
}
/* ============================================================================
   TOPBAR & NAVIGATION
   ============================================================================ */

.topbar {
    background: #ffffff;
    border-bottom: 1px solid #e0e0e0;
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.topbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: 36px;
    width: auto;
}

/* Navigation Links */
.nav-links {
    display: flex;
    gap: 24px;
    margin-left: auto;
    margin-right: 24px;
}

.nav-link {
    padding: 8px 16px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.2s;
}

.nav-link:hover {
    background: #f3f2ef;
    color: #0a66c2;
}

.nav-link.active {
    background: #e7f3ff;
    color: #0a66c2;
}

/* User Menu */
.user-menu {
    position: relative;
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: transparent;
    border: 1px solid #e0e0e0;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.user-menu-btn:hover {
    background: #f3f2ef;
    border-color: #0a66c2;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #0a66c2;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

/* User Dropdown */
.user-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 280px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
}

.user-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.user-avatar-large {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #0a66c2;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 18px;
}

.user-name-large {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.user-dropdown-divider {
    height: 1px;
    background: #e0e0e0;
    margin: 12px 0;
}

.dropdown-link {
    display: block;
    width: 100%;
    padding: 10px 12px;
    text-align: left;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
    color: #333;
    text-decoration: none;
    font-size: 14px;
}

.dropdown-link:hover {
    background: #f3f2ef;
}

/* Pricing Button */
.btn-pricing-animated {
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s;
}

.btn-pricing-animated:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-pricing-animated.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.7);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(102, 126, 234, 0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .topbar-container {
        padding: 12px 16px;
    }
}