/* ============================================
   PushCod - Main Stylesheet
   Modern, Responsive, Conversion-Optimized
   ============================================ */

/* === CSS Variables === */
:root {
    --primary: #667eea;
    --primary-dark: #5568d3;
    --secondary: #764ba2;
    --success: #48bb78;
    --error: #f56565;
    --warning: #ed8936;
    --background: #f7fafc;
    --card-bg: #ffffff;
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --border: #e2e8f0;
    --shadow: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

/* === Reset & Base === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
}

/* === Login Page === */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
}

.login-container {
    width: 100%;
    max-width: 450px;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: var(--shadow-lg);
    animation: fadeInUp 0.5s ease;
}

.logo {
    text-align: center;
    margin-bottom: 30px;
}

.logo h1 {
    font-size: 36px;
    margin-bottom: 5px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* === Dashboard Layout === */
.dashboard {
    display: flex;
    min-height: 100vh;
}

/* === Sidebar === */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h1 {
    font-size: 28px;
    margin: 0;
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 15px 25px;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: var(--transition);
    border-left: 4px solid transparent;
}

.nav-item:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

.nav-item.active {
    background: rgba(255,255,255,0.15);
    color: white;
    border-left-color: white;
}

.nav-item .icon {
    font-size: 20px;
    margin-right: 12px;
}

/* === Main Content === */
.main-content {
    margin-left: 260px;
    flex: 1;
    padding: 30px;
    max-width: 100%;
}

.content-header {
    margin-bottom: 30px;
}

.content-header h2 {
    font-size: 32px;
    margin-bottom: 8px;
}

.content-header p {
    color: var(--text-secondary);
}

/* === Cards === */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background: var(--card-bg);
    padding: 25px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card-icon {
    font-size: 40px;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 12px;
    color: white;
}

.card-content h3 {
    font-size: 32px;
    margin-bottom: 5px;
}

.card-content p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* === Sections === */
.section {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
}

.section h3 {
    font-size: 22px;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.section-header {
    margin-bottom: 20px;
}

.section-header h3 {
    margin-bottom: 8px;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* === Forms === */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    transition: var(--transition);
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}

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

/* === Upload Area === */
.upload-form {
    margin-top: 20px;
}

.upload-area {
    border: 3px dashed var(--border);
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
}

.upload-area:hover {
    border-color: var(--primary);
    background: rgba(102,126,234,0.05);
}

.upload-area.dragover {
    border-color: var(--primary);
    background: rgba(102,126,234,0.1);
}

.upload-icon {
    font-size: 60px;
    margin-bottom: 15px;
}

.upload-area p {
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.upload-area input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

/* === Buttons === */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102,126,234,0.4);
}

.btn-secondary {
    background: var(--text-secondary);
    color: white;
}

.btn-secondary:hover {
    background: var(--text-primary);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    background: #38a169;
}

.btn-block {
    width: 100%;
    display: block;
}

.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

.btn-large {
    padding: 15px 30px;
    font-size: 16px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

/* === Tables === */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.data-table thead {
    background: var(--background);
}

.data-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-bottom: 2px solid var(--border);
}

.data-table td {
    padding: 15px;
    border-bottom: 1px solid var(--border);
}

.data-table tbody tr:hover {
    background: var(--background);
}

/* === Alerts === */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    animation: slideDown 0.3s ease;
}

.alert-success {
    background: #f0fff4;
    color: #22543d;
    border-left: 4px solid var(--success);
}

.alert-error {
    background: #fff5f5;
    color: #742a2a;
    border-left: 4px solid var(--error);
}

.alert-warning {
    background: #fffaf0;
    color: #7c2d12;
    border-left: 4px solid var(--warning);
}

/* === Empty State === */
.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

/* === Marketing Angles Grid === */
.angles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.angle-card {
    padding: 20px;
    background: var(--background);
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

.angle-card h4 {
    margin-bottom: 8px;
    color: var(--text-primary);
}

.angle-card p {
    font-size: 13px;
    color: var(--text-secondary);
}

/* === Animations === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === Responsive Design === */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    
    .main-content {
        margin-left: 0;
        padding: 20px;
    }
    
    .dashboard {
        flex-direction: column;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
}
