:root {
    --primary-color: #a8dadc;
    --primary-dark: #457b9d;
    --secondary-color: #f1faee;
    --accent-color: #e63946;
    --warning-color: #f4a261;
    --success-color: #2a9d8f;
    --bg-color: #f8f9fa;
    --bg-dark: #1d3557;
    --text-color: #212529;
    --text-light: #6c757d;
    --border-color: #dee2e6;
    --card-shadow: 0 2px 8px rgba(0,0,0,0.1);
    --card-shadow-hover: 0 4px 16px rgba(0,0,0,0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    font-size: 2rem;
}

.logo h1 {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav a:hover {
    color: var(--primary-color);
}

.nav-wip {
    position: relative;
}

.wip-badge {
    display: inline-block;
    background: var(--warning-color);
    color: #000;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 4px;
    text-transform: uppercase;
    vertical-align: middle;
}

.wip-badge-btn {
    display: inline-block;
    background: rgba(255, 212, 59, 0.3);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 4px;
    margin-left: 8px;
    text-transform: uppercase;
    border: 1px solid rgba(255, 212, 59, 0.5);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #a8dadc 0%, #457b9d 100%);
    color: white;
    padding: 6rem 0;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.875rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-block;
}

.btn-primary {
    background: white;
    color: var(--primary-color);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: var(--primary-color);
}

/* Timer Preview */
.timer-preview {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.2);
}

.preview-master {
    background: white;
    color: var(--text-color);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 1.5rem;
}

.preview-label {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.preview-time {
    font-size: 2.5rem;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    margin: 0.5rem 0;
}

.preview-controls {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 1rem;
}

.preview-btn {
    padding: 0.5rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
}

.preview-arrow {
    text-align: center;
    font-size: 2rem;
    margin: 1rem 0;
    color: rgba(255,255,255,0.8);
}

.preview-slaves {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.preview-slave {
    background: white;
    color: var(--text-color);
    padding: 1rem;
    border-radius: 12px;
    text-align: center;
}

.preview-slave .preview-time {
    font-size: 1.5rem;
}

.preview-time.green {
    color: var(--success-color);
}

/* Section Styles */
section {
    padding: 5rem 0;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-color);
}

.section-intro {
    text-align: center;
    font-size: 1.125rem;
    color: var(--text-light);
    margin-bottom: 3rem;
}

/* Features Section */
.features {
    background: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    padding: 2rem;
    border-radius: 12px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--card-shadow-hover);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
}

.feature-card p {
    color: var(--text-light);
}

/* How It Works Section */
.how-it-works {
    background: var(--bg-color);
}

.steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.step {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.step-content p {
    color: var(--text-light);
    font-size: 1.125rem;
}

/* Architecture Section */
.architecture {
    background: white;
}

.architecture-diagram {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.arch-node {
    padding: 2rem;
    border-radius: 12px;
    margin: 1rem 0;
}

.master-node {
    background: linear-gradient(135deg, #a8dadc 0%, #457b9d 100%);
    color: white;
}

.server-node {
    background: var(--primary-dark);
    color: white;
}

.slave-node {
    background: var(--success-color);
    color: white;
}

.node-title {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.node-desc {
    font-size: 0.875rem;
    opacity: 0.9;
}

.arch-arrow {
    font-size: 2rem;
    color: var(--text-light);
    margin: 1rem 0;
}

.arch-slaves {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

/* Use Cases Section */
.use-cases {
    background: var(--bg-color);
}

.use-cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.use-case {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s;
}

.use-case:hover {
    transform: translateY(-4px);
    box-shadow: var(--card-shadow-hover);
}

.use-case-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.use-case h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
}

.use-case p {
    color: var(--text-light);
}

/* Deployment Section */
.deployment {
    background: white;
}

.deployment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.deployment-option {
    background: var(--bg-dark);
    color: white;
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #2a2b3d;
}

.deployment-option h3 {
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

.deployment-option p {
    margin-bottom: 1rem;
    color: rgba(255,255,255,0.7);
}

.deployment-option pre {
    background: rgba(0,0,0,0.3);
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
}

.deployment-option code {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    color: #51cf66;
}

.deployment-cta {
    text-align: center;
    margin-top: 3rem;
    padding: 2rem;
    background: var(--bg-color);
    border-radius: 12px;
}

.deployment-cta p {
    font-size: 1.125rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

/* Demo Section */
.demo {
    background: var(--bg-color);
}

.demo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.demo-steps h3,
.demo-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.numbered-list {
    counter-reset: item;
    list-style: none;
}

.numbered-list > li {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
    position: relative;
}

.numbered-list > li::before {
    content: counter(item);
    counter-increment: item;
    position: absolute;
    left: 0;
    top: 0;
    background: var(--primary-color);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.875rem;
}

.numbered-list pre {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    margin-top: 0.5rem;
    overflow-x: auto;
    border: 1px solid var(--border-color);
}

.numbered-list code {
    font-family: 'Courier New', monospace;
    color: var(--primary-color);
}

.numbered-list ul {
    margin-top: 0.5rem;
    padding-left: 1.5rem;
}

.tech-list {
    list-style: none;
}

.tech-list li {
    padding: 0.75rem 1rem;
    background: white;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    border: 1px solid var(--border-color);
}

.tech-list strong {
    color: var(--primary-color);
}

/* Footer */
.footer {
    background: var(--bg-dark);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.footer-section p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 0.5rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero .container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .nav {
        display: none; /* Simple mobile solution - can add hamburger menu */
    }

    .demo-content {
        grid-template-columns: 1fr;
    }

    .arch-slaves {
        grid-template-columns: 1fr;
    }

    .preview-slaves {
        grid-template-columns: 1fr;
    }

    .section-title {
        font-size: 2rem;
    }
}

/* Code blocks */
pre {
    background: var(--bg-dark);
    color: white;
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
}

code {
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}
