/* ===========================
   STEP FPGA Redesign - Main Stylesheet
   =========================== */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #7c3aed;
    --accent: #f59e0b;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;

    /* Neutrals */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;

    /* Typography */
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans SC', sans-serif;
    --font-mono: 'Fira Code', 'Consolas', monospace;

    /* Borders */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

body {
    font-family: var(--font-sans);
    color: var(--gray-900);
    line-height: 1.6;
    background: #fff;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

/* ===========================
   Navigation
   =========================== */

.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    padding: var(--spacing-md) 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900);
}

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

.nav-menu {
    display: flex;
    gap: var(--spacing-xl);
}

.nav-link {
    color: var(--gray-700);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.lang-selector {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-md);
    background: white;
    cursor: pointer;
    font-size: 0.875rem;
}

/* ===========================
   Buttons
   =========================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border: none;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-outline-white {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-outline-white:hover {
    background: white;
    color: var(--primary);
}

.btn-large {
    padding: 0.875rem 2rem;
    font-size: 1rem;
}

.icon {
    width: 1.25rem;
    height: 1.25rem;
}

/* ===========================
   Hero Section
   =========================== */

.hero {
    padding: var(--spacing-3xl) 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    overflow: hidden;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-3xl);
    align-items: center;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--spacing-lg);
}

.gradient-text {
    display: block;
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: var(--spacing-xl);
}

.hero-actions {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-2xl);
}

.hero-stats {
    display: flex;
    gap: var(--spacing-2xl);
    padding-top: var(--spacing-xl);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
}

.stat-label {
    font-size: 0.875rem;
    opacity: 0.8;
}

.hero-visual {
    position: relative;
}

.ide-preview {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.ide-preview img {
    width: 100%;
    height: auto;
    display: block;
}

/* ===========================
   Features Section
   =========================== */

.features {
    padding: var(--spacing-3xl) 0;
    background: var(--gray-50);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: var(--spacing-md);
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--gray-600);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: var(--spacing-xl);
}

.feature-card {
    background: white;
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    border: 1px solid var(--gray-200);
    transition: all 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

.feature-card.highlight {
    border: 2px solid var(--primary);
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    background: var(--primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--spacing-lg);
}

.feature-icon.ai {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
}

.feature-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-md);
    color: var(--gray-900);
}

.feature-description {
    color: var(--gray-600);
    margin-bottom: var(--spacing-lg);
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: var(--spacing-sm);
    color: var(--gray-700);
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success);
    font-weight: 700;
}

/* ===========================
   Boards Section
   =========================== */

.boards {
    padding: var(--spacing-3xl) 0;
    background: white;
}

.boards-grid {
    display: grid;
    gap: var(--spacing-3xl);
}

.board-category {
    background: var(--gray-50);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
}

.category-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-lg);
    color: var(--gray-900);
}

.board-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--spacing-lg);
}

.board-card {
    background: white;
    border-radius: var(--radius-md);
    padding: var(--spacing-lg);
    text-align: center;
    border: 1px solid var(--gray-200);
    transition: all 0.3s;
}

.board-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}

.board-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    margin-bottom: var(--spacing-md);
}

.board-card h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

.chip-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--primary-light);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
}

/* ===========================
   Workflow Section
   =========================== */

.workflow {
    padding: var(--spacing-3xl) 0;
    background: var(--gray-50);
}

.workflow-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-lg);
    flex-wrap: wrap;
}

.step {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    background: white;
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    max-width: 250px;
}

.step-number {
    width: 3rem;
    height: 3rem;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.step-content p {
    font-size: 0.875rem;
    color: var(--gray-600);
}

.step-arrow {
    font-size: 2rem;
    color: var(--gray-400);
}

/* ===========================
   CTA Section
   =========================== */

.cta {
    padding: var(--spacing-3xl) 0;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-md);
}

.cta-content p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: var(--spacing-xl);
}

.cta-actions {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
}

/* ===========================
   Footer
   =========================== */

.footer {
    background: var(--gray-900);
    color: var(--gray-300);
    padding: var(--spacing-3xl) 0 var(--spacing-xl);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-2xl);
    margin-bottom: var(--spacing-2xl);
}

.footer-column h4 {
    color: white;
    font-weight: 600;
    margin-bottom: var(--spacing-lg);
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: var(--spacing-sm);
}

.footer-column a {
    color: var(--gray-400);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-column a:hover {
    color: white;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--spacing-xl);
    border-top: 1px solid var(--gray-800);
}

.footer-links {
    display: flex;
    gap: var(--spacing-lg);
}

.footer-links a {
    color: var(--gray-400);
    text-decoration: none;
}

.footer-links a:hover {
    color: white;
}

/* ===========================
   Responsive Design
   =========================== */

@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
    }

    .hero-visual {
        order: -1;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hero-title {
        font-size: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .workflow-steps {
        flex-direction: column;
    }

    .step-arrow {
        transform: rotate(90deg);
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--spacing-md);
    }
}