/**
 * Website-specific layout (design-preview only)
 */

.preview-banner {
    position: sticky;
    top: 0;
    z-index: 200;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    padding: 10px 20px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.hero {
    padding: 60px 0 40px;
    border-bottom: 1px solid var(--border);
}

.hero-title {
    font-family: var(--font-mono);
    font-size: clamp(1.75rem, 5vw, 3rem);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 28px;
    letter-spacing: -0.02em;
    max-width: none;
}

.hero-sub {
    color: var(--text-muted);
    max-width: 560px;
    margin-bottom: 28px;
    font-size: 1.05rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 480px);
    gap: 32px 48px;
    align-items: start;
}

.hero-copy { min-width: 0; }

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 0;
}

.hero-terminal {
    width: 100%;
    max-width: 480px;
    justify-self: end;
}

.builder {
    padding: 48px 0;
    border-bottom: 1px solid var(--border);
}

.status-bar { margin-bottom: 24px; }

.builder-stage {
    position: relative;
    margin-bottom: 20px;
}

.agent-row-manager {
    display: flex;
    justify-content: center;
    margin-bottom: 12px;
}

.agent-row-manager .agent-card {
    max-width: 300px;
    width: 100%;
}

.agent-manager.active { border-width: 2px; }

.builder-middle {
    display: grid;
    grid-template-columns: minmax(200px, 1fr) minmax(240px, 300px) minmax(200px, 1fr);
    gap: 16px;
    align-items: stretch;
}

.agent-col-left,
.agent-col-right {
    display: grid;
    grid-template-rows: repeat(3, 1fr);
    gap: 12px;
    align-content: space-between;
    min-height: 100%;
}

.agent-col-left {
    justify-self: end;
    width: 100%;
    max-width: 240px;
}

.agent-col-right {
    justify-self: start;
    width: 100%;
    max-width: 240px;
}

.agent-col .agent-card {
    min-height: 112px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.agent-col .agent-domain {
    min-height: 112px;
}

.agent-col .card-desc { flex: 1; }
.agent-col .domain-picker { margin-top: auto; }

.builder-center-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.semantic-core {
    min-height: 200px;
    flex: 1;
}

.core-labels {
    display: flex;
    gap: 12px;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.semantic-core.running .node {
    animation: nodePulse 1.2s ease-in-out infinite;
}

.semantic-core.running .node-hub {
    animation: hubPulse 0.8s ease-in-out infinite;
}

@keyframes nodePulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; fill: var(--accent-dim); stroke: var(--accent); }
}

@keyframes hubPulse {
    0%, 100% { r: 10; }
    50% { r: 12; }
}

.mcp-layer {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed var(--border);
    position: relative;
    z-index: 5;
}

.flow-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

.flow-path {
    fill: none;
    stroke: var(--flow);
    stroke-width: 1.5;
    stroke-dasharray: 6 4;
    opacity: 0;
}

.flow-path.animate {
    animation: flowDash 1.5s linear infinite, flowFade 3s ease forwards;
}

.flow-path.mcp-flow {
    stroke-dasharray: 3 5;
    opacity: 0.6;
}

@keyframes flowDash {
    to { stroke-dashoffset: -20; }
}

@keyframes flowFade {
    0% { opacity: 0; }
    15% { opacity: 0.8; }
    85% { opacity: 0.8; }
    100% { opacity: 0; }
}

.terminal-log { margin-bottom: 20px; }

.builder-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.about {
    padding: 48px 0;
    border-bottom: 1px solid var(--border);
}

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

.contact {
    padding: 48px 0 64px;
}

.contact-terminal { max-width: none; }

.contact-form.contact-form-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 20px;
    align-items: stretch;
}

.contact-form-main {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

.contact-form-main textarea {
    min-height: 140px;
    resize: vertical;
}

.contact-form-side {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 120px;
}

.contact-send {
    min-height: auto;
    padding: 10px 24px;
}

.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.turnstile-placeholder {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    padding: 10px 12px;
    border: 1px dashed var(--border);
    text-align: center;
}

@media (max-width: 900px) {
    .about-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .hero-terminal {
        max-width: none;
        justify-self: stretch;
    }

    .builder-middle { grid-template-columns: 1fr; }
    .agent-col-left,
    .agent-col-right {
        max-width: none;
        justify-self: stretch;
        grid-template-rows: none;
    }
    .agent-col .agent-card {
        min-height: auto;
        height: auto;
    }
    .builder-center-col { order: -1; }
    .about-grid { grid-template-columns: 1fr 1fr; }
    .contact-terminal { max-width: none; }

    .contact-form.contact-form-split {
        grid-template-columns: 1fr;
    }

    .contact-send {
        min-height: 44px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .about-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    .flow-path.animate,
    .semantic-core.running .node,
    .semantic-core.running .node-hub {
        animation: none !important;
    }
}
