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

:root {
    --bg: #fafafa;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f0f0f0;
    --text: #1a1a1a;
    --text-muted: #666;
    --border: #e0e0e0;
    --accent: #9333ea;
    --accent-hover: #7c3aed;
    --accent-glow: rgba(147, 51, 234, 0.15);
    --warn: #f59e0b;
    --warn-bg: rgba(245, 158, 11, 0.08);
    --success: #16a34a;
    --error: #ef4444;
    --btn-text: #fff;
}

html, body { min-height: 100vh; }

body {
    font-family: 'JetBrains Mono', monospace;
    background: var(--bg);
    color: var(--text);
    display: flex;
    flex-direction: column;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: var(--bg);
    z-index: 100;
}

.logo {
    color: var(--accent);
    font-size: 22px;
    font-weight: 600;
    text-decoration: none;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Hero */
.hero-section {
    background-image: radial-gradient(circle, rgba(0,0,0,0.08) 1px, transparent 1px);
    background-size: 24px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 140px 40px 100px;
    text-align: center;
}

.hero-center {
    max-width: 720px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

h1 {
    font-size: 64px;
    font-weight: 600;
    line-height: 1.1;
    margin-bottom: 28px;
}

h1 span { color: var(--accent); }

#hero-rotating {
    display: inline-block;
    overflow: hidden;
    vertical-align: bottom;
}

#hero-rotating .slide-in {
    display: block;
    animation: slideUp 0.4s ease forwards;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-sub {
    font-size: 19px;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 36px;
}

/* Platform badges row */
.platform-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 48px;
}

.platform-badge {
    display: inline-block;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 11px;
    padding: 5px 14px;
    border-radius: 20px;
    letter-spacing: 0.3px;
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s;
}

a.platform-badge:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* CTA button */
.cta-btn {
    background: #000;
    color: var(--btn-text);
    border: none;
    padding: 16px 40px;
    font-size: 15px;
    font-family: inherit;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.cta-btn:hover { background: #222; }

/* Demo section */
.demo-section {
    padding: 80px 40px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
}

.demo-heading {
    max-width: 960px;
    margin: 0 auto 40px;
}

.demo-heading h2 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 10px;
}

.demo-heading p {
    font-size: 15px;
    color: var(--text-muted);
}

.demo-wrap {
    max-width: 960px;
    margin: 0 auto;
}

.demo-interface {
    display: flex;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.06);
}

/* Sidebar */
.demo-sidebar {
    width: 190px;
    flex-shrink: 0;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.demo-logo {
    color: var(--accent);
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.demo-sb-label {
    font-size: 10px;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    margin-top: 12px;
    margin-bottom: 6px;
}

.demo-sb-project {
    font-size: 12px;
    color: var(--text);
    padding: 6px 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
}

.demo-sb-chat {
    font-size: 11px;
    color: var(--text-muted);
    padding: 6px 8px;
    border-radius: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: default;
}

.demo-sb-chat--active {
    background: var(--bg-tertiary);
    color: var(--text);
}

/* Main chat */
.demo-main {
    flex: 1;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.demo-msg--user {
    align-self: flex-end;
    background: var(--accent);
    border-radius: 16px 16px 4px 16px;
    padding: 10px 16px;
    font-size: 13px;
    color: #fff;
    max-width: 70%;
    line-height: 1.5;
}

.demo-msg--ai {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 4px 16px 16px 16px;
    padding: 16px 20px;
    font-size: 12px;
}

.demo-msg-name {
    font-size: 11px;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: 0.3px;
}

.demo-msg-text {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 14px;
}

.demo-msg-text strong { color: var(--text); }

/* Table */
.demo-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    margin-bottom: 12px;
}

.demo-table th {
    text-align: left;
    color: var(--text-muted);
    font-weight: 500;
    padding: 5px 8px;
    border-bottom: 1px solid var(--border);
}

.demo-table td {
    padding: 7px 8px;
    color: var(--text);
    border-bottom: 1px solid rgba(0,0,0,0.04);
}

.demo-table-green td { color: var(--success); }
.demo-table-warn td { color: var(--warn); }

/* Finding cards */
.demo-finding {
    border-radius: 6px;
    padding: 12px 14px;
    margin-bottom: 8px;
    border: 1px solid transparent;
}

.demo-finding:last-child { margin-bottom: 0; }

.demo-finding--red {
    background: rgba(239, 68, 68, 0.05);
    border-color: rgba(239, 68, 68, 0.2);
}

.demo-finding--yellow {
    background: rgba(245, 158, 11, 0.05);
    border-color: rgba(245, 158, 11, 0.2);
}

.demo-finding--green {
    background: rgba(22, 163, 74, 0.05);
    border-color: rgba(22, 163, 74, 0.2);
}

.demo-finding-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.demo-finding-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.demo-finding-dot--red { background: var(--error); }
.demo-finding-dot--yellow { background: var(--warn); }
.demo-finding-dot--green { background: var(--success); }

.demo-finding-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text);
}

.demo-finding-rec {
    font-size: 11px;
    line-height: 1.6;
    padding: 8px 12px;
    border-radius: 4px;
}

.demo-rec--red { background: rgba(239,68,68,0.08); color: #b91c1c; border-left: 2px solid var(--error); }
.demo-rec--yellow { background: rgba(245,158,11,0.08); color: #92400e; border-left: 2px solid var(--warn); }
.demo-rec--green { background: rgba(22,163,74,0.08); color: #14532d; border-left: 2px solid var(--success); }

/* Platforms section */
.platforms-section {
    padding: 80px 40px;
    background: var(--bg-secondary);
}

.platforms-inner {
    max-width: 960px;
    margin: 0 auto;
}

.platforms-inner h2 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 40px;
    line-height: 1.2;
}

.platforms-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.platform-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: border-color 0.2s;
}

.platform-card:hover {
    border-color: var(--accent);
}

.platform-card-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
}

.platform-card-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.platform-card-list li {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
    padding-left: 16px;
    position: relative;
}

.platform-card-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--border);
    font-size: 11px;
}

.platform-card-link {
    font-size: 11px;
    color: var(--accent);
    text-decoration: none;
    margin-top: 4px;
    transition: opacity 0.2s;
}

.platform-card-link:hover { opacity: 0.7; }

/* Content sections */
.content-section {
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 40px;
}

.content-section--alt { background: var(--bg-secondary); }

.section-inner {
    max-width: 640px;
    width: 100%;
    margin: 0 auto;
}

.section-label {
    font-size: 11px;
    color: var(--accent);
    letter-spacing: 1px;
    margin-bottom: 16px;
    opacity: 0.7;
}

.content-section h2 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 24px;
    line-height: 1.2;
}

.section-intro {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 28px;
    line-height: 1.6;
}

.section-intro--em {
    color: var(--text);
    font-size: 18px;
}

.check-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 28px;
}

.check-list li {
    display: flex;
    align-items: baseline;
    gap: 14px;
    font-size: 16px;
    color: var(--text);
    line-height: 1.4;
}

.check-icon {
    color: var(--text-muted);
    font-size: 14px;
    flex-shrink: 0;
    width: 16px;
}

.check-icon.accent { color: var(--accent); }

.section-note {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}

/* CTA section */
.cta-section {
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 40px;
}

.cta-inner {
    max-width: 480px;
    width: 100%;
    margin: 0 auto;
    text-align: center;
}

.cta-inner h2 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 12px;
}

.cta-inner p {
    font-size: 15px;
    color: var(--text-muted);
    margin-bottom: 32px;
    line-height: 1.6;
}

/* Modal */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.8);
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-overlay.visible { display: flex; }

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 40px;
    max-width: 420px;
    width: 100%;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 16px; right: 16px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
    transition: color 0.2s;
}

.modal-close:hover { color: var(--text); }

.modal h2 { font-size: 20px; margin-bottom: 12px; }

.modal-desc {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 24px;
    line-height: 1.5;
}

.waitlist-form-modal {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.waitlist-form-modal input {
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 14px 18px;
    font-size: 15px;
    font-family: inherit;
    border-radius: 4px;
    outline: none;
    width: 100%;
    transition: border-color 0.2s;
}

.waitlist-form-modal input:focus { border-color: var(--accent); }
.waitlist-form-modal input::placeholder { color: var(--text-muted); }

.waitlist-form-modal button {
    background: #000;
    color: var(--btn-text);
    border: none;
    padding: 14px 28px;
    font-size: 14px;
    font-family: inherit;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.waitlist-form-modal button:hover { background: #222; }

.waitlist-form-modal button:disabled {
    background: var(--bg-tertiary);
    color: var(--text-muted);
    cursor: not-allowed;
}

.success-message {
    background: var(--accent-glow);
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 16px 24px;
    border-radius: 4px;
    font-size: 14px;
    display: none;
}

.success-message.visible { display: block; }

.error-message {
    background: rgba(255,107,107,0.1);
    border: 1px solid var(--error);
    color: var(--error);
    padding: 12px 16px;
    border-radius: 4px;
    font-size: 13px;
    margin-bottom: 16px;
    display: none;
}

.error-message.visible { display: block; }

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

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

/* Footer */
footer {
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-left { color: var(--text-muted); font-size: 13px; }

.footer-right a {
    color: var(--text-muted);
    font-size: 13px;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-right a:hover { color: var(--accent); }
.footer-sep { color: var(--text-muted); margin: 0 8px; }

/* Tablet */
@media (max-width: 960px) {
    .platforms-grid { grid-template-columns: repeat(2, 1fr); }
    .demo-sidebar { width: 160px; }
}

/* Mobile */
@media (max-width: 720px) {
    .platforms-grid { grid-template-columns: 1fr; }
    .demo-sidebar { display: none; }
}

@media (max-width: 600px) {
    header { padding: 16px 20px; }
    .hero-section { padding: 80px 20px 60px; }
    h1 { font-size: 38px; }
    .hero-sub { font-size: 16px; }
    .demo-section { padding: 48px 20px; }
    .platforms-section { padding: 48px 20px; }
    .content-section { padding: 48px 20px; }
    .cta-section { padding: 48px 20px; }
    footer { padding: 16px 20px; flex-direction: column; text-align: center; }
}
