/* Webapp Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0a0a0a;
    color: #ffffff;
    overflow-x: hidden;
}

.webapp-container {
    display: flex;
    min-height: 100vh;
}


/* Sidebar */
.sidebar {
    width: 220px;
    background: linear-gradient(180deg, rgba(26, 26, 26, 0.95) 0%, rgba(15, 15, 15, 0.95) 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 1000;
    backdrop-filter: blur(20px);
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
}

.sidebar-header {
    padding: 1.5rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.7rem;
    font-weight: 800;
    color: #ff6b35;
    position: relative;
    width: 100%;
}

.logo-image {
    height: 50px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

.logo-fallback {
    display: none !important;
}

.nav-menu {
    flex: 1;
    padding: 0.75rem 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.875rem 1.25rem;
    color: #b3b3b3;
    text-decoration: none;
    transition: all 0.3s ease;
    border-radius: 12px;
    margin: 0.25rem 0.75rem;
    font-size: 0.9rem;
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.nav-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    transition: left 0.5s;
}

.nav-item:hover::before {
    left: 100%;
}

.nav-item:hover {
    background: rgba(255, 107, 53, 0.08);
    color: #ffffff;
    transform: translateX(4px);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.15);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.15), rgba(255, 140, 66, 0.1));
    color: #ff6b35;
    border: 1px solid rgba(255, 107, 53, 0.2);
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.2);
}

.nav-item i {
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.nav-item:hover i,
.nav-item.active i {
    transform: scale(1.1);
}

.sidebar-footer {
    padding: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.user-info:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 107, 53, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.1);
}

.user-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.user-details {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.user-name {
    font-weight: 700;
    color: #ffffff;
    font-size: 0.85rem;
}

.user-role {
    font-size: 0.75rem;
    color: #b3b3b3;
    font-weight: 500;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 220px;
    background: #0a0a0a;
    min-height: 100vh;
    width: calc(100% - 220px);
    max-width: calc(100% - 220px);
    box-sizing: border-box;
    overflow-x: auto;
}

.page {
    display: none;
    padding: 1rem;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
}

.page.active {
    display: block;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-header h1 {
    font-size: 1.4rem;
    font-weight: 700;
    background: linear-gradient(135deg, #ffffff, #cccccc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: center;
    min-width: 0;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.1);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.25rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 107, 53, 0.3);
    box-shadow: 0 20px 40px rgba(255, 107, 53, 0.1);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
}

.stat-icon {
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.stat-content h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.stat-content p {
    color: #cccccc;
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}

.stat-change {
    font-size: 0.75rem;
    font-weight: 600;
}

.stat-change.positive {
    color: #4ade80;
}

/* Section */
.section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0.875rem;
    backdrop-filter: blur(10px);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-header h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
}

.section-actions {
    display: flex;
    gap: 0.75rem;
}

/* Larger action buttons for campaign detail */
.section-actions .btn {
    padding: 0.6rem 1.25rem;
    font-size: 0.85rem;
    border-radius: 8px;
    font-weight: 600;
    min-width: 100px;
}

/* Posts Grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 0.75rem;
}

.post-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 0.875rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    position: relative;
    min-height: 200px;
}

.post-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 107, 53, 0.3);
    box-shadow: 0 15px 30px rgba(255, 107, 53, 0.1);
}

.post-card.high-potential {
    border-color: rgba(255, 107, 53, 0.4);
    background: rgba(255, 107, 53, 0.05);
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.post-meta {
    display: flex;
    gap: 0.75rem;
    font-size: 0.8rem;
}

.platform {
    color: #ff6b35;
    font-weight: 600;
}

.time {
    color: #cccccc;
}

.post-score {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #ff6b35;
    font-weight: 600;
    font-size: 0.9rem;
}

.post-content h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.375rem;
    line-height: 1.3;
}

.post-content p {
    color: #cccccc;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    font-size: 0.85rem;
}

.post-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Campaigns Grid */
.campaigns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .campaigns-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.campaign-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.25rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.campaign-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 107, 53, 0.3);
    box-shadow: 0 20px 40px rgba(255, 107, 53, 0.1);
}

.campaign-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
}

.campaign-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.campaign-header h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
}

.campaign-status {
    padding: 0.4rem 0.8rem;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
}

.campaign-status.active {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
    border: 1px solid rgba(74, 222, 128, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.campaign-status.active:hover {
    background: rgba(74, 222, 128, 0.3);
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.4);
    transform: scale(1.05);
}

.campaign-status.inactive {
    background: rgba(107, 114, 128, 0.2);
    color: #6b7280;
    border: 1px solid rgba(107, 114, 128, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.campaign-status.inactive:hover {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.3);
}

.campaign-status.inactive:hover::after {
    content: 'Activate';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
    font-weight: 600;
    font-size: 0.75rem;
}

.campaign-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.stat {
    text-align: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.stat-number {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.7rem;
    color: #cccccc;
}

.campaign-actions {
    display: flex;
    justify-content: center;
    margin-top: 1.25rem;
}

.campaign-actions .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    border-radius: 8px;
    min-width: auto;
    flex: none;
    font-weight: 500;
}

.campaign-actions .btn i {
    font-size: 0.8rem;
    margin-right: 0.5rem;
}

.campaign-content {
    margin-bottom: 1.5rem;
}

.campaign-content p {
    margin-bottom: 1rem;
    line-height: 1.6;
    color: #cccccc;
}

.campaign-keywords {
    margin-top: 0.75rem;
}

/* Campaign Posts Page */
.header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
    min-width: 0;
}

/* Desktop specific fixes */
@media (min-width: 769px) {
    .page-header {
        flex-wrap: nowrap;
    }
    
    .header-actions {
        flex-wrap: nowrap;
        flex-shrink: 0;
    }
    
    .header-actions .btn {
        flex-shrink: 0;
    }
}

.back-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
}

.posts-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.posts-stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.25rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.posts-stat-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 107, 53, 0.3);
    box-shadow: 0 15px 30px rgba(255, 107, 53, 0.1);
}

.posts-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
}

.posts-stat-card .stat-icon {
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.posts-stat-card .stat-content h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.posts-stat-card .stat-content p {
    color: #cccccc;
    font-size: 0.85rem;
    margin: 0;
}

.campaign-posts-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Comment Popup */
.comment-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.comment-popup.active {
    display: flex;
}

/* Reddit Connection Status in Comment Popup */
.reddit-connection-status {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.08), rgba(255, 69, 0, 0.03));
    border: 1px solid rgba(255, 107, 53, 0.15);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 80px;
}

.reddit-connection-status::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.reddit-connection-status.connected::before {
    opacity: 1;
}

.reddit-connection-status:hover {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.12), rgba(255, 69, 0, 0.06));
    border-color: rgba(255, 107, 53, 0.25);
    box-shadow: 0 6px 25px rgba(255, 107, 53, 0.15);
    transform: translateY(-2px);
}

.reddit-connection-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
}

.reddit-status-indicator {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.15), rgba(255, 69, 0, 0.08));
    border-radius: 50%;
    border: 2px solid rgba(255, 107, 53, 0.2);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.15);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.reddit-status-indicator.connected {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(5, 150, 105, 0.1));
    border-color: rgba(16, 185, 129, 0.4);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.25);
}

.reddit-status-indicator.disconnected {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.1));
    border-color: rgba(239, 68, 68, 0.4);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.25);
}

.reddit-status-indicator:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.2);
}

.reddit-status-indicator.connected:hover {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.25);
}

.reddit-status-indicator.disconnected:hover {
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.25);
}

.reddit-status-indicator .status-dot {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #6b7280;
    border: 3px solid rgba(0, 0, 0, 0.9);
    transition: all 0.3s ease;
}

.reddit-status-indicator .status-dot.connected {
    background: #10b981;
    border-color: rgba(0, 0, 0, 0.9);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.6);
}

.reddit-status-indicator .status-dot.disconnected {
    background: #ef4444;
    border-color: rgba(0, 0, 0, 0.9);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.6);
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

@keyframes pulse-green {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

@keyframes pulse-red {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.reddit-status-indicator i {
    font-size: 1.4rem;
    color: #ff6b35;
    text-shadow: 0 2px 4px rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
}

.reddit-status-indicator.connected i {
    color: #10b981;
    text-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.reddit-status-indicator.disconnected i {
    color: #ef4444;
    text-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.reddit-status-indicator:hover i {
    transform: scale(1.1);
    text-shadow: 0 3px 6px rgba(255, 107, 53, 0.4);
}

.reddit-status-indicator.connected:hover i {
    text-shadow: 0 3px 6px rgba(16, 185, 129, 0.4);
}

.reddit-status-indicator.disconnected:hover i {
    text-shadow: 0 3px 6px rgba(239, 68, 68, 0.4);
}

.reddit-status-details {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.reddit-status-text {
    font-weight: 600;
    color: #ffffff;
    font-size: 1.1rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.reddit-status-text.connected {
    color: #10b981;
    text-shadow: 0 1px 2px rgba(16, 185, 129, 0.3);
}

.reddit-status-text.disconnected {
    color: #ef4444;
    text-shadow: 0 1px 2px rgba(239, 68, 68, 0.3);
}

.reddit-status-subtitle {
    font-size: 0.9rem;
    color: #cccccc;
    opacity: 0.9;
    font-weight: 500;
    transition: all 0.3s ease;
}

.reddit-actions {
    display: flex;
    gap: 0.5rem;
}

.reddit-actions .btn {
    padding: 0.6rem 1.25rem;
    font-size: 0.85rem;
    border-radius: 10px;
    transition: all 0.3s ease;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    min-width: 120px;
    position: relative;
    overflow: hidden;
}

.reddit-actions .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.reddit-actions .btn:hover::before {
    left: 100%;
}

.reddit-actions .connect-btn {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #ffffff;
    border: none;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.reddit-actions .connect-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 107, 53, 0.4);
    background: linear-gradient(135deg, #ff8c42, #ffa726);
}

.reddit-actions .disconnect-btn {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: #ffffff;
    border: none;
    box-shadow: 0 4px 15px rgba(107, 114, 128, 0.3);
}

.reddit-actions .disconnect-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(107, 114, 128, 0.4);
    background: linear-gradient(135deg, #4b5563, #374151);
}

/* Responsive Reddit Status */
@media (max-width: 768px) {
    .reddit-connection-status {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .reddit-actions {
        width: 100%;
        justify-content: stretch;
    }
    
    .reddit-actions .btn {
        flex: 1;
        justify-content: center;
    }
}

.popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.popup-content {
    position: relative;
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.5rem;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

/* Long landscape comment popup layout */
.comment-popup .popup-content {
    max-width: 1300px !important;
    width: 95% !important;
    max-height: 85vh !important;
    padding: 0 !important;
    display: grid !important;
    grid-template-columns: 400px 1fr !important;
    gap: 0 !important;
    overflow: hidden !important;
}

.comment-popup .popup-content .popup-header {
    grid-column: 1 / -1 !important;
    padding: 1.5rem !important;
    margin: 0 !important;
}

.comment-popup .popup-content .post-preview {
    grid-column: 1 !important;
    max-height: calc(85vh - 80px) !important;
    margin: 0 !important;
    border-radius: 0 !important;
    border-right: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 1.5rem !important;
    overflow-y: auto !important;
}

.comment-popup .popup-content .comment-form {
    grid-column: 2 !important;
    padding: 1.5rem !important;
    overflow-y: auto !important;
    max-height: calc(85vh - 80px) !important;
}

/* Responsive comment popup */
@media (max-width: 1100px) {
    .comment-popup .popup-content {
        grid-template-columns: 300px 1fr !important;
    }
}

@media (max-width: 768px) {
    .comment-popup .popup-content {
        max-width: 95% !important;
        width: 95% !important;
        grid-template-columns: 1fr !important;
        max-height: 95vh !important;
    }
    
    .comment-popup .popup-content .post-preview {
        grid-column: 1 !important;
        max-height: 200px !important;
        border-right: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    }
    
    .comment-popup .popup-content .comment-form {
        grid-column: 1 !important;
        max-height: calc(95vh - 350px) !important;
    }
}

.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.popup-header h3 {
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 700;
}

.popup-close {
    background: none;
    border: none;
    color: #cccccc;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.popup-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.post-preview {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 1rem;
    max-height: 200px;
    overflow-y: auto;
    flex-shrink: 0;
    position: relative;
}

.post-preview.expanded {
    max-height: none;
}

/* Read more functionality removed */

.post-preview .post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.post-preview .post-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
}

.post-preview .platform {
    color: #ff6b35;
    font-weight: 600;
}

.post-preview .time {
    color: #cccccc;
}

.post-preview .post-score {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #ff6b35;
    font-weight: 600;
    font-size: 0.9rem;
}

.post-preview .post-content h4 {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.post-preview .post-content p {
    color: #cccccc;
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0;
}

/* Post text container with read more functionality */
.post-text-container {
    position: relative;
    overflow: hidden;
}

.post-text {
    color: #cccccc;
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0 0 1.5rem 0;
    transition: all 0.3s ease;
}

/* Read more functionality removed */

/* Rate Limit Warning Styles */
.notification.warning {
    background: linear-gradient(135deg, #ff9800, #f57c00);
    border-left: 4px solid #e65100;
    box-shadow: 0 4px 20px rgba(255, 152, 0, 0.3);
}

.notification.warning .notification-icon {
    background: rgba(255, 255, 255, 0.2);
}

.notification.warning .notification-content {
    color: #fff;
}

.notification.warning .notification-close {
    color: rgba(255, 255, 255, 0.8);
}

.notification.warning .notification-close:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.comment-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    flex: 1;
    overflow-y: auto;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9rem;
}

.form-group textarea {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem;
    color: #ffffff;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    min-height: 100px;
    transition: all 0.3s ease;
}

.form-group textarea:focus {
    outline: none;
    border-color: rgba(255, 107, 53, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.form-group textarea::placeholder {
    color: #888888;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    flex-shrink: 0;
}

/* AI Generate Button Loading State */
.btn-ai-generate {
    position: relative;
    overflow: hidden;
}

.btn-ai-generate.loading {
    pointer-events: none;
    opacity: 0.7;
}

.btn-ai-generate.loading .btn-text {
    opacity: 0;
}

.btn-ai-generate.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Filter Dropdown */
.filter-dropdown {
    position: relative;
    display: inline-block;
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.filter-btn i:last-child {
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}

.filter-btn.active i:last-child {
    transform: rotate(180deg);
}

.filter-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0.5rem 0;
    min-width: 200px;
    backdrop-filter: blur(20px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

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

.filter-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: #cccccc;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.filter-option:hover {
    background: rgba(255, 107, 53, 0.1);
    color: #ffffff;
}

.filter-option.active {
    background: rgba(255, 107, 53, 0.15);
    color: #ff6b35;
}

.filter-option i {
    width: 16px;
    text-align: center;
    font-size: 0.8rem;
}

/* Delete Button */
.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #ffffff;
    border: none;
    padding: 0.875rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.btn-danger::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-danger:hover::before {
    left: 100%;
}

.btn-danger:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 30px rgba(239, 68, 68, 0.4), 0 0 0 4px rgba(239, 68, 68, 0.1);
    background: linear-gradient(135deg, #f87171, #ef4444);
}

.btn-danger:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-danger i {
    margin-right: 0.5rem;
    transition: transform 0.3s ease;
}

.btn-danger:hover i {
    transform: scale(1.2) rotate(5deg);
}

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    text-align: center;
    padding: 2rem;
}

.empty-state i {
    font-size: 3rem;
    color: #666;
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: #cccccc;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    max-width: 300px;
}

/* Modern Campaign Creation */
.modern-campaign-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Modern Progress Indicator */
.modern-progress-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    backdrop-filter: blur(10px);
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.4;
    transition: all 0.3s ease;
}

.progress-step.active {
    opacity: 1;
}

.progress-step.completed {
    opacity: 1;
}

.step-circle {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #ffffff;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.progress-step.active .step-circle {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    border-color: #ff6b35;
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.3);
}

.progress-step.completed .step-circle {
    background: linear-gradient(135deg, #4ade80, #22c55e);
    color: #000000;
    border-color: #4ade80;
}

.step-label {
    font-size: 0.8rem;
    color: #cccccc;
    font-weight: 600;
    text-align: center;
}

.progress-line {
    width: 60px;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0 1rem;
    transition: all 0.3s ease;
}

.progress-step.completed + .progress-line {
    background: linear-gradient(90deg, #4ade80, #22c55e);
}

/* Modern Campaign Form */
.modern-campaign-form {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    min-height: 500px;
    display: flex;
    flex-direction: column;
}

.form-step {
    display: none;
    flex: 1;
    flex-direction: column;
    gap: 1.5rem;
}

.form-step.active {
    display: flex;
}

.step-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.step-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #ffffff, #ff6b35);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.step-header p {
    color: #cccccc;
    font-size: 1rem;
    margin: 0;
}

.form-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Input Groups */
.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.input-group label {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.8rem;
}

.modern-input, .modern-textarea {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.6rem 0.875rem;
    color: #ffffff;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.modern-input:focus, .modern-textarea:focus {
    outline: none;
    border-color: rgba(255, 107, 53, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
    background: rgba(255, 255, 255, 0.08);
}

.modern-textarea {
    min-height: 100px;
    resize: vertical;
    font-family: inherit;
}

.modern-input::placeholder, .modern-textarea::placeholder {
    color: #888888;
}

/* Setup Options */
.setup-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.setup-option {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.setup-option:hover {
    border-color: rgba(255, 107, 53, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.1);
}

.setup-option.selected {
    border-color: #ff6b35;
    background: rgba(255, 107, 53, 0.1);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.2);
}

.option-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.option-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: #000000;
    flex-shrink: 0;
}

.option-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.option-info p {
    color: #cccccc;
    font-size: 0.9rem;
    margin: 0;
}

.option-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.feature-tag {
    background: rgba(255, 107, 53, 0.2);
    color: #ff6b35;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
}

/* Setup Forms */
.setup-form {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 1rem;
}

.form-row {
    display: flex;
    gap: 1rem;
    align-items: end;
}

.form-row .input-group {
    flex: 1;
}

/* Keywords Container */
.keywords-container {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0.75rem;
    min-height: 60px;
}

.keywords-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.keyword-tag {
    background: rgba(255, 107, 53, 0.15);
    color: #ff6b35;
    padding: 0.2rem 0.4rem;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 400;
    display: inline-block;
    margin: 0.2rem 0.2rem 0.2rem 0;
    border: 1px solid rgba(255, 107, 53, 0.2);
}

.keyword-more {
    background: rgba(255, 255, 255, 0.1);
    color: #cccccc;
    padding: 0.2rem 0.4rem;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 400;
    display: inline-block;
    margin: 0.2rem 0.2rem 0.2rem 0;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.keyword-tag .remove-keyword {
    background: none;
    border: none;
    color: #ff6b35;
    cursor: pointer;
    font-size: 0.9rem;
    padding: 0;
    margin-left: 0.25rem;
    transition: color 0.3s ease;
}

.keyword-tag .remove-keyword:hover {
    color: #ffffff;
}

/* Campaign Summary */
.campaign-summary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.summary-item {
    margin-bottom: 1rem;
}

.summary-item:last-child {
    margin-bottom: 0;
}

.summary-label {
    color: #cccccc;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.summary-value {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 500;
}

.summary-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Modern Buttons */
.modern-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.25rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    justify-content: center;
    min-width: 120px;
}

.modern-btn.primary {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.modern-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 53, 0.4);
}

.modern-btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modern-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

/* Loading Animation */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ff6b35;
    animation: spin 1s ease-in-out infinite;
}

.loading-spinner-large {
    width: 80px;
    height: 80px;
    border: 6px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    border-top-color: #ff6b35;
    border-right-color: #ff8c42;
    border-bottom-color: #ffa726;
    border-left-color: #ffb74d;
    animation: spin 1.2s ease-in-out infinite;
    margin: 0 auto 2rem;
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.3);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Loading Pages */
.loading-page-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
}

.loading-page-content h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
}

.loading-page-content p {
    color: #cccccc;
    font-size: 1rem;
    margin-bottom: 2rem;
    line-height: 1.5;
}

.loading-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
}

.loading-step {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.loading-step.active {
    opacity: 1;
    border-color: rgba(255, 107, 53, 0.3);
    background: rgba(255, 107, 53, 0.05);
}

.loading-step i {
    color: #ff6b35;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

.loading-step span {
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Modern Settings */
.modern-settings-container {
    max-width: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modern-settings-section {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 1rem;
    backdrop-filter: blur(20px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.modern-settings-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modern-settings-section:hover {
    border-color: rgba(255, 107, 53, 0.2);
    box-shadow: 0 8px 20px rgba(255, 107, 53, 0.08);
    transform: translateY(-2px);
}

.modern-settings-section:hover::before {
    opacity: 1;
}

.modern-settings-section.danger-zone {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.05);
}

.modern-settings-section.danger-zone:hover {
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.1);
}

.section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    color: #000000;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.header-content h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.125rem;
}

.header-content p {
    color: #b3b3b3;
    font-size: 0.8rem;
    margin: 0;
}

/* Modern Form */
.modern-form {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 1rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9rem;
}

.modern-input, .modern-select {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.6rem 0.875rem;
    color: #ffffff;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.modern-input:focus, .modern-select:focus {
    outline: none;
    border-color: rgba(255, 107, 53, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
    background: rgba(255, 255, 255, 0.08);
}

.modern-select {
    cursor: pointer;
}

.modern-input::placeholder {
    color: #888888;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 0.75rem;
}

/* Subscription Overview */
.subscription-overview {
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.plan-card {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.plan-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    border-color: rgba(255, 107, 53, 0.2);
}

.plan-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ff6b35, #ff8c42);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.plan-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}

.plan-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.plan-name h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.plan-badge {
    background: rgba(255, 107, 53, 0.2);
    color: #ff6b35;
    padding: 0.375rem 1rem;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 600;
    border: 1px solid rgba(255, 107, 53, 0.3);
}

.plan-price {
    text-align: right;
}

.price {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.period {
    color: #cccccc;
    font-size: 1rem;
    margin-left: 0.25rem;
    font-weight: 500;
}

.status-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 24px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.status-badge.active {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.plan-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
}

.feature-item i {
    color: #4ade80;
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.feature-item span {
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
}

.billing-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}

.billing-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.billing-label {
    color: #cccccc;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.billing-value {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.plan-actions {
    display: flex;
    gap: 1.25rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

/* Preferences */
.preferences-grid {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.preference-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.preference-item:hover {
    border-color: rgba(255, 107, 53, 0.3);
    background: rgba(255, 107, 53, 0.05);
}

.preference-info h4 {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.preference-info p {
    color: #cccccc;
    font-size: 0.8rem;
    margin: 0;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.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: rgba(255, 255, 255, 0.1);
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: #ffffff;
    transition: 0.3s;
    border-radius: 50%;
}

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

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

/* Danger Zone */
.danger-actions {
    background: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.danger-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.danger-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

.danger-info {
    flex: 1;
    margin-right: 1rem;
}

.danger-info h4 {
    color: #ef4444;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.danger-info p {
    color: #cccccc;
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.4;
}

.danger-item .modern-btn {
    flex-shrink: 0;
    min-width: 140px;
}

/* Responsive Danger Zone */
@media (max-width: 768px) {
    .danger-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .danger-info {
        margin-right: 0;
        margin-bottom: 0.5rem;
    }
    
    .danger-item .modern-btn {
        width: 100%;
        justify-content: center;
        min-width: auto;
    }
}

.modern-btn.danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.modern-btn.danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
}

.modern-btn.secondary {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(107, 114, 128, 0.3);
}

.modern-btn.secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(107, 114, 128, 0.4);
}

/* Reddit Integration Section */
.reddit-integration {
    background: linear-gradient(135deg, rgba(255, 69, 0, 0.05), rgba(255, 107, 53, 0.05));
    border: 1px solid rgba(255, 69, 0, 0.2);
}

.reddit-connection-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.5rem;
    backdrop-filter: blur(10px);
}

/* Reddit Disconnect Instructions */
.reddit-disconnect-instructions {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.08), rgba(255, 69, 0, 0.03));
    border: 1px solid rgba(255, 107, 53, 0.15);
    border-radius: 12px;
    padding: 1rem;
    margin-top: 1rem;
}

.instruction-content {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.instruction-content i {
    color: #ff6b35;
    font-size: 1.1rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.instruction-text h4 {
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.instruction-text p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    line-height: 1.5;
    margin: 0 0 0.75rem 0;
}

.instruction-text p:last-child {
    margin-bottom: 0;
}

.instruction-text a {
    color: #ff6b35;
    text-decoration: none;
    font-weight: 500;
}

.instruction-text a:hover {
    color: #ff8c42;
    text-decoration: underline;
}

.connection-status {
    margin-bottom: 1.5rem;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #6b7280;
    transition: all 0.3s ease;
}

.status-dot.connected {
    background: #10b981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

.status-dot.disconnected {
    background: #ef4444;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.3);
}

.status-text {
    font-weight: 600;
    color: #ffffff;
    font-size: 1rem;
}

.connection-details {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem;
    margin-top: 1rem;
}

.connection-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #cccccc;
    font-size: 0.9rem;
}

.info-item i {
    color: #ff6b35;
    width: 16px;
    text-align: center;
}

.info-item strong {
    color: #ffffff;
    font-weight: 600;
}

.connection-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.reddit-info {
    margin-top: 1.5rem;
}

.info-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.25rem;
}

.info-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.info-header i {
    color: #ff6b35;
    font-size: 1.1rem;
}

.info-header h4 {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.info-content p {
    color: #cccccc;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.info-content ul {
    color: #cccccc;
    font-size: 0.9rem;
    margin: 0 0 1rem 1.5rem;
    line-height: 1.6;
}

.info-content li {
    margin-bottom: 0.5rem;
}

.privacy-note {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 8px;
    padding: 0.75rem;
    color: #10b981;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.privacy-note i {
    color: #10b981;
}

/* Reddit Integration Responsive */
@media (max-width: 768px) {
    .connection-actions {
        flex-direction: column;
    }
    
    .connection-actions .modern-btn {
        width: 100%;
        justify-content: center;
    }
    
    .info-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

/* Dashboard Post Cards */
.post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.8rem;
    color: #cccccc;
}

.contacted-badge {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #ffffff;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.post-card.contacted {
    border-color: rgba(16, 185, 129, 0.3);
    background: rgba(16, 185, 129, 0.05);
}

.campaign-info {
    color: #ff6b35;
    font-weight: 600;
}

.post-time {
    color: #999999;
}

/* Dashboard High Potential Posts Grid */
#dashboard-high-potential-posts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
}

/* Dashboard Post Cards - Uniform Sizing */
#dashboard-high-potential-posts .post-card {
    height: 280px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    box-sizing: border-box;
    padding: 1rem;
    margin: 0;
}

#dashboard-high-potential-posts .post-header {
    flex-shrink: 0;
    margin-bottom: 0.75rem;
}

#dashboard-high-potential-posts .post-header h3 {
    font-size: 1rem;
    line-height: 1.3;
    margin: 0 0 0.5rem 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    height: 2.6rem; /* 2 lines * 1.3 line-height */
}

#dashboard-high-potential-posts .post-meta {
    flex-shrink: 0;
    margin-bottom: 0.75rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.8rem;
}

#dashboard-high-potential-posts .post-meta span {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    font-size: 0.75rem;
}

#dashboard-high-potential-posts .post-content {
    flex: 1;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

#dashboard-high-potential-posts .post-content p {
    font-size: 0.85rem;
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    height: 3.6rem; /* 3 lines * 1.4 line-height * 0.85 font-size */
    word-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
}

#dashboard-high-potential-posts .post-actions {
    flex-shrink: 0;
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

#dashboard-high-potential-posts .post-actions .btn {
    flex: 1;
    font-size: 0.8rem;
    padding: 0.5rem 0.75rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0; /* Allow buttons to shrink */
}

#dashboard-high-potential-posts .post-actions .btn i {
    margin-right: 0.25rem;
    font-size: 0.75rem;
}

#dashboard-high-potential-posts .post-footer {
    flex-shrink: 0;
    margin-top: auto;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
}

#dashboard-high-potential-posts .campaign-info {
    color: #ff6b35;
    font-weight: 600;
    flex: 1;
    margin-right: 0.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#dashboard-high-potential-posts .post-time {
    color: #999999;
    flex-shrink: 0;
}

@media (max-width: 768px) {
    #dashboard-high-potential-posts {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    #dashboard-high-potential-posts .post-card {
        height: 320px; /* Slightly taller on mobile for better readability */
    }
    
    #dashboard-high-potential-posts .post-actions {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    #dashboard-high-potential-posts .post-actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    #dashboard-high-potential-posts .post-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    #dashboard-high-potential-posts .campaign-info {
        margin-right: 0;
        margin-bottom: 0.25rem;
    }
}

@media (max-width: 480px) {
    #dashboard-high-potential-posts {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    #dashboard-high-potential-posts .post-card {
        height: 300px;
    }
    
    #dashboard-high-potential-posts .post-header h3 {
        font-size: 0.9rem;
        height: 2.34rem; /* 2 lines * 1.3 line-height * 0.9 font-size */
    }
    
    #dashboard-high-potential-posts .post-content p {
        font-size: 0.8rem;
        height: 3.36rem; /* 3 lines * 1.4 line-height * 0.8 font-size */
    }
}

/* Dashboard Loading State */
.dashboard-loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    text-align: center;
    grid-column: 1 / -1;
}

.dashboard-loading-state .loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 107, 53, 0.3);
    border-top: 3px solid #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

.dashboard-loading-state h3 {
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.dashboard-loading-state p {
    color: #cccccc;
    font-size: 0.9rem;
    margin: 0;
}

/* Loading States for Individual Elements */
.loading-placeholder {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
    position: relative;
    overflow: hidden;
}

.loading-placeholder::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    animation: shimmer 2s infinite;
}

.loading-placeholder .loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(255, 107, 53, 0.3);
    border-top: 2px solid #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Navigation Loading State */
.nav-item.loading {
    position: relative;
    overflow: hidden;
}

.nav-item.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    animation: shimmer 2s infinite;
}

.nav-item.loading i {
    animation: pulse 1.5s ease-in-out infinite;
}

/* User Info Loading State */
.user-info.loading {
    position: relative;
    overflow: hidden;
}

.user-info.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    animation: shimmer 2s infinite;
}

.user-info.loading .user-name {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    height: 16px;
    width: 80px;
    animation: pulse 1.5s ease-in-out infinite;
}

.user-info.loading .user-role {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    height: 12px;
    width: 60px;
    animation: pulse 1.5s ease-in-out infinite;
}

/* Full Screen Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.95), rgba(20, 20, 20, 0.98));
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.5s ease-out;
}

.loading-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.loading-overlay .loading-content {
    text-align: center;
    color: #ffffff;
    max-width: 400px;
    padding: 2rem;
}

.loading-overlay .loading-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(255, 107, 53, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

.loading-overlay .loading-logo i {
    font-size: 2rem;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.loading-overlay .loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 107, 53, 0.2);
    border-top: 4px solid #ff6b35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
}

.loading-overlay h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.loading-overlay p {
    font-size: 1rem;
    color: #cccccc;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.loading-overlay .loading-steps {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.loading-overlay .loading-step {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 107, 53, 0.1);
    transition: all 0.3s ease;
}

.loading-overlay .loading-step.active {
    background: rgba(255, 107, 53, 0.1);
    border-color: rgba(255, 107, 53, 0.3);
}

.loading-overlay .loading-step.completed {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
}

.loading-overlay .loading-step i {
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.loading-overlay .loading-step.active i {
    color: #ff6b35;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-overlay .loading-step.completed i {
    color: #10b981;
}

.loading-overlay .loading-step span {
    font-size: 0.9rem;
    color: #ffffff;
}

.loading-overlay .loading-step.completed span {
    color: #10b981;
}

/* Responsive Loading Overlay */
@media (max-width: 768px) {
    .loading-overlay .loading-content {
        max-width: 90%;
        padding: 1.5rem;
    }
    
    .loading-overlay .loading-logo {
        width: 60px;
        height: 60px;
        margin-bottom: 1.5rem;
    }
    
    .loading-overlay .loading-logo i {
        font-size: 1.5rem;
    }
    
    .loading-overlay h2 {
        font-size: 1.5rem;
    }
    
    .loading-overlay p {
        font-size: 0.9rem;
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Enhanced Success Notification */
.notification.enhanced {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #ffffff;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
    z-index: 10001;
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.3s ease;
    max-width: 400px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.notification.enhanced.show {
    transform: translateX(0);
    opacity: 1;
}

.success-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.success-icon {
    font-size: 1.5rem;
    color: #ffffff;
    flex-shrink: 0;
}

.success-text h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
}

.success-text p {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.4;
}

/* Responsive Success Notification */
@media (max-width: 768px) {
    .notification.enhanced {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        transform: translateY(-100px);
    }
    
    .notification.enhanced.show {
        transform: translateY(0);
    }
}

/* Reddit Token Expired Popup */
.reddit-token-expired-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.reddit-token-expired-popup.active {
    display: flex;
}

.reddit-token-expired-popup .popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.reddit-token-expired-popup .popup-content {
    position: relative;
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.5rem;
    max-width: 500px;
    width: 90%;
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

.reddit-token-expired-popup .popup-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.reddit-token-expired-popup .header-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #000000;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
}

.reddit-token-expired-popup .header-content h3 {
    color: #ffffff;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.reddit-token-expired-popup .header-content p {
    color: #cccccc;
    font-size: 0.9rem;
    margin: 0;
}

.reddit-token-expired-popup .popup-close {
    background: none;
    border: none;
    color: #cccccc;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    margin-left: auto;
}

.reddit-token-expired-popup .popup-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.reddit-token-expired-popup .popup-body {
    margin-bottom: 1.5rem;
}

.reddit-token-expired-popup .expired-info,
.reddit-token-expired-popup .solution-info {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.reddit-token-expired-popup .expired-info i {
    color: #f59e0b;
    font-size: 1.2rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.reddit-token-expired-popup .solution-info i {
    color: #10b981;
    font-size: 1.2rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
}

.reddit-token-expired-popup .info-content h4 {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.reddit-token-expired-popup .info-content p {
    color: #cccccc;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.reddit-token-expired-popup .popup-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.reddit-token-expired-popup .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.reddit-token-expired-popup .btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.reddit-token-expired-popup .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.reddit-token-expired-popup .btn-primary {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

.reddit-token-expired-popup .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.5);
}

/* Responsive Reddit Token Expired Popup */
@media (max-width: 768px) {
    .reddit-token-expired-popup .popup-content {
        width: 95%;
        padding: 1.25rem;
    }
    
    .reddit-token-expired-popup .popup-header {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
    
    .reddit-token-expired-popup .popup-close {
        margin-left: 0;
        margin-top: 0.5rem;
    }
    
    .reddit-token-expired-popup .popup-actions {
        flex-direction: column;
    }
    
    .reddit-token-expired-popup .btn {
        width: 100%;
        justify-content: center;
    }
}

/* Settings Footer Styles */
.settings-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.legal-links {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}

.legal-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #ffffff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.legal-link:hover {
    background: rgba(255, 107, 53, 0.1);
    border-color: rgba(255, 107, 53, 0.3);
    color: #ff6b35;
    transform: translateY(-2px);
}

.legal-link i {
    font-size: 1rem;
}

/* Cancel Subscription Button */
.modern-btn.danger {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: #ffffff;
    border: 1px solid rgba(220, 38, 38, 0.3);
}

.modern-btn.danger:hover {
    background: linear-gradient(135deg, #b91c1c, #991b1b);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(220, 38, 38, 0.3);
}

@media (max-width: 768px) {
    .legal-links {
        gap: 1rem;
    }
    
    .legal-link {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
}

/* Keyword Tips Styling */
.keyword-tips {
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(255, 107, 53, 0.05);
    border: 1px solid rgba(255, 107, 53, 0.2);
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.keyword-tips h4 {
    color: #ff6b35;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tips-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.tip-category {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.75rem;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tip-category strong {
    color: #ffffff;
    font-size: 0.8rem;
    display: block;
    margin-bottom: 0.5rem;
}

.tip-category ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tip-category li {
    color: #cccccc;
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
    padding-left: 0.5rem;
    position: relative;
}

.tip-category li::before {
    content: '•';
    color: #ff6b35;
    position: absolute;
    left: 0;
}

/* Responsive keyword tips */
@media (max-width: 768px) {
    .tips-grid {
        grid-template-columns: 1fr;
    }
    
    .tip-category {
        padding: 0.5rem;
    }
    
    .keyword-tips h4 {
        font-size: 0.8rem;
    }
    
    .tip-category strong {
        font-size: 0.75rem;
    }
    
    .tip-category li {
        font-size: 0.7rem;
    }
}

/* End of styles */


/* Responsive Design */
/* Responsive Design for Modern Campaign Creation */
@media (max-width: 1024px) {
    .modern-campaign-container {
        max-width: 100%;
        padding: 0 0.5rem;
    }
    
    .modern-progress-indicator {
        padding: 0.75rem;
        margin-bottom: 1.5rem;
    }
    
    .progress-line {
        width: 40px;
        margin: 0 0.75rem;
    }
    
    .step-circle {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .step-label {
        font-size: 0.75rem;
    }
    
    .modern-campaign-form {
        padding: 1.5rem;
        min-height: 450px;
    }
    
    .step-header h2 {
        font-size: 1.5rem;
    }
    
    .setup-options {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .setup-option {
        padding: 1.25rem;
    }
    
    .option-icon {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .form-row {
        flex-direction: column;
        gap: 1rem;
    }
    
    .form-row .input-group {
        flex: none;
    }
}

@media (max-width: 768px) {
    .modern-campaign-container {
        padding: 0 0.25rem;
    }
    
    .modern-progress-indicator {
        padding: 0.5rem;
        margin-bottom: 1rem;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .progress-line {
        width: 30px;
        margin: 0 0.5rem;
    }
    
    .step-circle {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }
    
    .step-label {
        font-size: 0.7rem;
    }
    
    .modern-campaign-form {
        padding: 1rem;
        min-height: 400px;
        border-radius: 16px;
    }
    
    .step-header h2 {
        font-size: 1.3rem;
    }
    
    .step-header p {
        font-size: 0.9rem;
    }
    
    .setup-option {
        padding: 1rem;
    }
    
    .option-header {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
    
    .option-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .modern-btn {
        padding: 0.6rem 1.25rem;
        font-size: 0.85rem;
        min-width: 120px;
    }
    
    .keywords-container {
        padding: 0.5rem;
    }
    
    .campaign-summary {
        padding: 1rem;
    }
}

@media (max-width: 1024px) {
    .sidebar {
        width: 200px;
    }
    
    .main-content {
        margin-left: 200px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .campaigns-grid {
        grid-template-columns: 1fr;
    }
    
    .campaign-card {
        padding: 1rem;
    }
    
    .posts-stats {
        grid-template-columns: 1fr;
    }
    
    .campaign-posts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .page {
        padding: 0.75rem;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .page-header h1 {
        font-size: 1.5rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .section-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .header-left {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        width: 100%;
    }
    
    .header-actions {
        flex-wrap: wrap;
        gap: 0.5rem;
        width: 100%;
        justify-content: flex-start;
    }
    
.header-actions .btn {
    flex-shrink: 0;
    min-width: 120px;
    justify-content: center;
    white-space: nowrap;
}
    
    .posts-stats {
        grid-template-columns: 1fr;
    }
    
    .posts-stat-card {
        padding: 1rem;
    }
    
    .campaign-posts-grid {
        gap: 0.75rem;
    }
    
    .popup-content {
        width: 98%;
        padding: 1.5rem;
        max-width: none;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .filter-menu {
        right: auto;
        left: 0;
        min-width: 180px;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.4rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-content h3 {
        font-size: 1.5rem;
    }
    
    .post-card {
        padding: 0.75rem;
    }
    
    .campaign-card {
        padding: 1rem;
    }
    
    .campaign-stats {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
}

/* Reddit Connection Status */
.reddit-connection-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(255, 107, 53, 0.1);
    border: 1px solid rgba(255, 107, 53, 0.3);
    border-radius: 8px;
    margin-bottom: 1rem;
}

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

.connection-info i {
    color: #ff6b35;
    font-size: 1.2rem;
}

.connection-info.connected i {
    color: #10b981;
}

.connection-info.error i {
    color: #ef4444;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    border-radius: 6px;
}

/* Post expansion functionality */
.post-text {
    max-height: 4.5em;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.post-card.expanded .post-text {
    max-height: none;
}

/* Tertiary button style */
.btn-tertiary {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #cccccc;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-tertiary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
    transform: translateY(-1px);
}

.btn-tertiary i {
    font-size: 0.8rem;
}

/* AI Button Style */
.btn-ai {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border: 1px solid rgba(102, 126, 234, 0.3);
    color: #ffffff;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-ai:hover {
    background: linear-gradient(135deg, #5a6fd8, #6a4190);
    border-color: rgba(102, 126, 234, 0.5);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn-ai i {
    font-size: 0.8rem;
}

/* AI Style Popup Styles */
.ai-style-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.ai-style-popup.active {
    display: flex;
}

.ai-style-popup .popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.ai-style-popup .popup-content {
    position: relative;
    background: rgba(26, 26, 26, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1.5rem;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

.ai-style-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    flex: 1;
    overflow-y: auto;
}

.form-section {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.25rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.form-section:hover {
    border-color: rgba(255, 107, 53, 0.2);
    background: rgba(255, 255, 255, 0.08);
}

.form-section h3 {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.form-section h3 i {
    color: #ff6b35;
    font-size: 1rem;
}

.form-group {
    margin-bottom: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-group label {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9rem;
}

.form-select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.form-select:focus {
    outline: none;
    border-color: #ff6b35;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.9rem;
    font-family: inherit;
    resize: vertical;
    min-height: 80px;
    transition: all 0.3s ease;
    line-height: 1.5;
}

.form-textarea:focus {
    outline: none;
    border-color: #ff6b35;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.form-textarea::placeholder {
    color: #888888;
}

/* Slider Styles */
.slider-container {
    position: relative;
    margin-top: 0.5rem;
}

.slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b35;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
}

.slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.4);
}

.slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b35;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 6px rgba(255, 107, 53, 0.3);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #888888;
}

/* Checkbox Styles */
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: #cccccc;
    gap: 0.75rem;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    position: relative;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: #ff6b35;
    border-color: #ff6b35;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Popup Actions */
.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    flex-shrink: 0;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.form-actions .btn {
    min-width: 140px;
}

/* AI Generate Button Loading State */
.btn-ai-generate {
    position: relative;
    overflow: hidden;
}

.btn-ai-generate.loading {
    pointer-events: none;
    opacity: 0.7;
}

.btn-ai-generate.loading .btn-text {
    opacity: 0;
}

.btn-ai-generate.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 1s ease-in-out infinite;
}

/* AI Style Info */
.ai-style-info {
    margin: 1rem 0;
    padding: 0.75rem;
    background: rgba(102, 126, 234, 0.1);
    border: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 8px;
}

.ai-style-status {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    color: #cccccc;
    font-size: 0.9rem;
}

.ai-style-status i {
    color: #667eea;
    font-size: 1rem;
    margin-top: 0.2rem;
}

.ai-style-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.ai-style-label {
    font-weight: 500;
    color: #667eea;
    margin-bottom: 0.25rem;
}

.ai-style-preview {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.style-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
}

.style-label {
    color: #999;
    font-weight: 500;
    min-width: 60px;
}

.style-value {
    color: #ddd;
    font-weight: 400;
}

.btn-small {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(102, 126, 234, 0.5);
    color: #667eea;
}

.btn-outline:hover {
    background: rgba(102, 126, 234, 0.1);
    border-color: #667eea;
}

/* Modern Tone Selection */
.tone-selection {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-top: 0.5rem;
}

/* Modern Length Selection */
.length-selection {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.tone-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.tone-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    transition: left 0.5s;
}

.tone-option:hover::before {
    left: 100%;
}

.tone-option:hover {
    border-color: rgba(255, 107, 53, 0.3);
    background: rgba(255, 107, 53, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 53, 0.15);
}

.tone-option.selected {
    border-color: #ff6b35;
    background: rgba(255, 107, 53, 0.1);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.2);
}

.tone-option.selected::before {
    display: none;
}

.tone-icon {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.tone-option.selected .tone-icon {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    transform: scale(1.1);
}

.tone-content {
    flex: 1;
    min-width: 0;
}

.tone-name {
    font-weight: 600;
    color: #ffffff;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.tone-desc {
    color: #cccccc;
    font-size: 0.8rem;
    line-height: 1.3;
}

/* Length Options - verwenden die gleichen Styles wie Tone Options */
.length-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.length-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.1), transparent);
    transition: left 0.5s;
}

.length-option:hover::before {
    left: 100%;
}

.length-option:hover {
    border-color: rgba(255, 107, 53, 0.3);
    background: rgba(255, 107, 53, 0.05);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 53, 0.15);
}

.length-option.selected {
    border-color: #ff6b35;
    background: rgba(255, 107, 53, 0.1);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.2);
}

.length-option.selected::before {
    display: none;
}

.length-icon {
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.length-option.selected .length-icon {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: #000000;
    transform: scale(1.1);
}

.length-content {
    flex: 1;
    min-width: 0;
}

.length-name {
    font-weight: 600;
    color: #ffffff;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.length-desc {
    color: #cccccc;
    font-size: 0.8rem;
    line-height: 1.3;
}

/* Modern Checkbox Group */
.modern-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 0.5rem;
}

.modern-checkbox-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.modern-checkbox-item:hover {
    border-color: rgba(255, 107, 53, 0.2);
    background: rgba(255, 107, 53, 0.05);
    transform: translateY(-1px);
}

.modern-checkbox-label {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    width: 100%;
}

.modern-checkbox-label input[type="checkbox"] {
    display: none;
}

.modern-checkmark {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

.modern-checkbox-label input[type="checkbox"]:checked + .modern-checkmark {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    border-color: #ff6b35;
    color: #000000;
    transform: scale(1.1);
}

.modern-checkbox-label input[type="checkbox"]:checked + .modern-checkmark i {
    opacity: 1;
    transform: scale(1);
}

.modern-checkmark i {
    font-size: 0.8rem;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s ease;
}

.checkbox-content {
    flex: 1;
    min-width: 0;
}

.checkbox-title {
    font-weight: 600;
    color: #ffffff;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.checkbox-desc {
    color: #cccccc;
    font-size: 0.8rem;
    line-height: 1.3;
}

/* Improved Loading Animation */
.btn-ai-generate.loading {
    pointer-events: none;
    opacity: 0.8;
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
}

.btn-ai-generate.loading .btn-text {
    opacity: 0;
}

.btn-ai-generate.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 1s ease-in-out infinite;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ai-style-popup {
        width: 95vw;
        max-height: 90vh;
    }
    
    .form-section {
        padding: 1rem;
    }
    
    .popup-actions {
        flex-direction: column;
    }
    
    .popup-actions .btn {
        width: 100%;
    }
    
    .tone-selection {
        grid-template-columns: 1fr;
    }
    
    .length-selection {
        grid-template-columns: 1fr;
    }
    
    .header-actions .btn {
        flex: 1 1 100%;
        min-width: unset;
        margin-bottom: 0.5rem;
    }
    
    .header-actions .btn:last-child {
        margin-bottom: 0;
    }
    
    .back-btn {
        font-size: 0.7rem;
        padding: 0.3rem 0.6rem;
    }
    
    .page-header h1 {
        font-size: 1.2rem;
    }
    
    .campaign-posts-grid {
        gap: 0.5rem;
    }
    
    .posts-stat-card {
        padding: 0.75rem;
    }
    
    .posts-stat-card h3 {
        font-size: 0.9rem;
    }
    
    .posts-stat-card .stat-number {
        font-size: 1.5rem;
    }
}

/* Delete Confirmation Modal */
.delete-confirmation-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.delete-confirmation-modal.active {
    opacity: 1;
    visibility: visible;
}

.delete-confirmation-modal .modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
}

.delete-modal-content {
    position: relative;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.98), rgba(30, 30, 30, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 480px;
    width: 90%;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(20px);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.delete-confirmation-modal.active .delete-modal-content {
    transform: scale(1) translateY(0);
}

.delete-modal-content .modal-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(220, 38, 38, 0.2));
    border: 2px solid rgba(239, 68, 68, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 2s ease-in-out infinite;
}

.delete-modal-content .modal-icon i {
    font-size: 2.5rem;
    color: #ef4444;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(239, 68, 68, 0);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.delete-modal-content h2 {
    color: #ffffff;
    font-size: 1.75rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ffffff, #cccccc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.delete-modal-content p {
    color: #cccccc;
    font-size: 1rem;
    line-height: 1.6;
    text-align: center;
    margin-bottom: 2rem;
}

.delete-modal-content .modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.delete-modal-content .modal-actions .btn {
    flex: 1;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.delete-modal-content .modal-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.delete-modal-content .modal-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.delete-modal-content .modal-actions .btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.delete-modal-content .modal-actions .btn-danger:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 10px 30px rgba(239, 68, 68, 0.5);
    background: linear-gradient(135deg, #f87171, #ef4444);
}

/* Responsive Delete Modal */
@media (max-width: 768px) {
    .delete-modal-content {
        padding: 2rem 1.5rem;
        max-width: 95%;
    }
    
    .delete-modal-content .modal-icon {
        width: 60px;
        height: 60px;
    }
    
    .delete-modal-content .modal-icon i {
        font-size: 2rem;
    }
    
    .delete-modal-content h2 {
        font-size: 1.5rem;
    }
    
    .delete-modal-content p {
        font-size: 0.9rem;
    }
    
    .delete-modal-content .modal-actions {
        flex-direction: column;
    }
    
    .delete-modal-content .modal-actions .btn {
        width: 100%;
    }
}
