:root {
    --bg-primary: #0a0e27;
    --bg-secondary: #111633;
    --bg-tertiary: #1a1f3a;
    --bg-card: #141937;
    --text-primary: #ffffff;
    --text-secondary: #a0aec0;
    --accent-blue: #4299e1;
    --accent-green: #48bb78;
    --accent-purple: #9f7aea;
    --accent-pink: #ed64a6;
    --accent-orange: #ed8936;
    --accent-teal: #38b2ac;
    --accent-yellow: #ecc94b;
    --accent-red: #f56565;
    --border-color: #2d3748;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.5);
    --gradient-blue: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-green: linear-gradient(135deg, #48bb78 0%, #38b2ac 100%);
    --gradient-orange: linear-gradient(135deg, #ed8936 0%, #f56565 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

/* Login Page */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #0a0e27 0%, #1a1f3a 100%);
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    color: var(--accent-blue);
}

.logo svg {
    width: 32px;
    height: 32px;
}

.login-header h1 {
    font-size: 28px;
    margin-bottom: 10px;
}

.login-header h2 {
    font-size: 24px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.login-header p {
    color: var(--text-secondary);
    font-size: 14px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.input-group label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.input-group input {
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.3s;
}

.input-group input:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

.error-message {
    color: var(--accent-red);
    font-size: 12px;
    margin-top: 4px;
    display: none;
}

.error-message.show {
    display: block;
}

/* Navigation */
.navbar {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    padding: 16px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-left .logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 20px;
    font-weight: 600;
    color: var(--accent-blue);
}

.nav-center {
    display: flex;
    gap: 8px;
    flex: 1;
    justify-content: center;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    font-size: 14px;
}

.nav-link:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.nav-link.active {
    background: var(--gradient-blue);
    color: var(--text-primary);
}

.nav-right {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* Buttons */
.btn-primary {
    background: var(--gradient-blue);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: var(--bg-tertiary);
}

.icon-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.icon-btn:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* Main Content */
.main-content {
    padding: 32px;
    max-width: 1600px;
    margin: 0 auto;
}

.page-header {
    margin-bottom: 32px;
}

.page-header h1 {
    font-size: 32px;
    margin-bottom: 8px;
    font-weight: 700;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 16px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.stat-header h3 {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.team-icon {
    background: rgba(72, 187, 120, 0.1);
    color: var(--accent-green);
}

.task-icon {
    background: rgba(66, 153, 225, 0.1);
    color: var(--accent-blue);
}

.workload-icon {
    background: rgba(159, 122, 234, 0.1);
    color: var(--accent-purple);
}

.priority-icon {
    background: rgba(237, 137, 54, 0.1);
    color: var(--accent-orange);
}

.stat-value {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 4px;
}

.stat-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.dashboard-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
}

.card-header {
    margin-bottom: 20px;
}

.card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 600;
}

.chart-container {
    height: 250px;
    position: relative;
}

/* Activity List */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.activity-item {
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.activity-item:hover {
    border-color: var(--accent-blue);
}

.activity-item h4 {
    font-size: 14px;
    margin-bottom: 6px;
}

.activity-item p {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.activity-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.priority-badge, .status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.priority-low {
    background: rgba(66, 153, 225, 0.2);
    color: var(--accent-blue);
}

.priority-medium {
    background: rgba(236, 201, 75, 0.2);
    color: var(--accent-yellow);
}

.priority-high {
    background: rgba(237, 137, 54, 0.2);
    color: var(--accent-orange);
}

.priority-critical {
    background: rgba(245, 101, 101, 0.2);
    color: var(--accent-red);
}

.status-backlog {
    background: rgba(160, 174, 192, 0.2);
    color: var(--text-secondary);
}

.status-in-progress {
    background: rgba(66, 153, 225, 0.2);
    color: var(--accent-blue);
}

.status-review {
    background: rgba(236, 201, 75, 0.2);
    color: var(--accent-yellow);
}

.status-completed {
    background: rgba(72, 187, 120, 0.2);
    color: var(--accent-green);
}

/* Workload List */
.workload-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.workload-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.workload-info {
    flex: 1;
}

.workload-info h4 {
    font-size: 14px;
    margin-bottom: 4px;
}

.workload-info p {
    font-size: 12px;
    color: var(--text-secondary);
}

.workload-bar-container {
    width: 100px;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.workload-bar {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s;
}

.workload-percentage {
    font-size: 12px;
    font-weight: 600;
    margin-left: 12px;
    min-width: 40px;
}

/* Filter Tabs */
.filter-tabs {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.filter-tab {
    padding: 10px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.filter-tab:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.filter-tab.active {
    background: var(--accent-blue);
    color: white;
    border-color: var(--accent-blue);
}

/* Tasks Grid */
.tasks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.task-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.task-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-blue);
    opacity: 0;
    transition: opacity 0.3s;
}

.task-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-blue);
}

.task-card:hover::before {
    opacity: 1;
}

.task-card h3 {
    font-size: 16px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.task-card .task-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.task-meta {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.task-status-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.task-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.tag {
    padding: 4px 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    font-size: 11px;
    color: var(--text-secondary);
}

.task-assignee {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 8px;
}

.task-due {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Team Grid */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.member-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s;
}

.member-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-blue);
}

.member-header {
    margin-bottom: 20px;
}

.member-name {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
}

.member-email {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.role-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.role-designer {
    background: rgba(159, 122, 234, 0.2);
    color: var(--accent-purple);
}

.role-content-creator {
    background: rgba(66, 153, 225, 0.2);
    color: var(--accent-blue);
}

.role-data-analyst {
    background: rgba(56, 178, 172, 0.2);
    color: var(--accent-teal);
}

.role-seo-specialist {
    background: rgba(72, 187, 120, 0.2);
    color: var(--accent-green);
}

.role-marketing-manager {
    background: rgba(159, 122, 234, 0.2);
    color: var(--accent-purple);
}

.role-copywriter {
    background: rgba(237, 137, 54, 0.2);
    color: var(--accent-orange);
}

.member-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.stat-item {
    flex: 1;
}

.stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-number {
    font-size: 20px;
    font-weight: 700;
}

.workload-container {
    margin-top: 8px;
}

.workload-container .workload-bar-container {
    width: 100%;
    margin-top: 6px;
}

.skills-section {
    margin-top: 20px;
}

.skills-title {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.skills-chart-container {
    height: 200px;
}

/* Integrations Grid */
.integrations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
}

.integration-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s;
    overflow: hidden;
    position: relative;
}

.integration-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-blue);
    opacity: 0;
    transition: opacity 0.3s;
}

.integration-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-blue);
}

.integration-card:hover::before {
    opacity: 1;
}

.integration-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.integration-image::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(66, 153, 225, 0.15) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
}

.gradient-workflow {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-server {
    background: linear-gradient(135deg, #48bb78 0%, #38b2ac 100%);
}

.gradient-database {
    background: linear-gradient(135deg, #f56565 0%, #ed8936 100%);
}

.gradient-globe {
    background: linear-gradient(135deg, #9f7aea 0%, #ed64a6 100%);
}

.gradient-cloud {
    background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%);
}

.gradient-spreadsheet {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
}

.gradient-brain {
    background: linear-gradient(135deg, #ed8936 0%, #dd6b20 100%);
}

.gradient-default {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
}

.integration-image svg {
    width: 90px;
    height: 90px;
    opacity: 0.8;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 0 10px rgba(66, 153, 225, 0.3));
    transition: transform 0.3s;
}

.integration-card:hover .integration-image svg {
    transform: scale(1.1);
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

.integration-content {
    padding: 24px;
}

.integration-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
}

.integration-description {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.integration-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.status-connected {
    background: rgba(72, 187, 120, 0.2);
    color: var(--accent-green);
}

.status-disconnected {
    background: rgba(160, 174, 192, 0.2);
    color: var(--text-secondary);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 32px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.modal-content.large {
    max-width: 800px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.modal-header h2 {
    font-size: 24px;
    font-weight: 600;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.skills-input-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.skill-input {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.skill-input label {
    font-size: 12px;
    color: var(--text-secondary);
}

.skill-input input {
    padding: 8px;
    font-size: 13px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

/* Integration Detail Form */
.integration-detail-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.credential-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.credential-field label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.credential-field input {
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
}

.action-buttons {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}

.action-buttons a {
    flex: 1;
    text-align: center;
    padding: 12px;
    background: var(--accent-blue);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s;
}

.action-buttons a:hover {
    background: var(--accent-purple);
    transform: translateY(-2px);
}

/* Responsive */
@media (max-width: 768px) {
    .main-content {
        padding: 20px;
    }

    .stats-grid,
    .dashboard-grid,
    .tasks-grid,
    .team-grid,
    .integrations-grid {
        grid-template-columns: 1fr;
    }

    .nav-center {
        flex-wrap: wrap;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .skills-input-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

