/* Page-specific styles */
.hero {
    padding: clamp(4rem, 10vw, 7rem) 0;
    text-align: center;
    background: linear-gradient(180deg, var(--bg-base) 0%, var(--bg-surface) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(167,139,250,0.08) 0%, transparent 70%);
    pointer-events: none;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero h1 span {
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero .lead {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
}

.stat-value {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--brand-primary);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* Badge */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(167,139,250,0.1);
    border: 1px solid var(--border-medium);
    color: var(--brand-primary);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    margin-bottom: 1.5rem;
}

.badge-dot {
    width: 6px;
    height: 6px;
    background: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--success);
}

/* Section */
.section {
    padding: var(--section-spacing) 0;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 3rem;
}

.section-header h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Live Demo Box */
.demo-box {
    background: var(--bg-surface);
    border: 1px solid var(--border-medium);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.demo-box-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-subtle);
}

.demo-box-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-base);
}

.demo-box-title {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
}

.demo-box-sub {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Tool Call Card */
.tool-call {
    background: var(--bg-base);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    transition: all 0.2s var(--ease-out);
}

.tool-call:hover {
    border-color: var(--border-medium);
    transform: translateX(4px);
}

.tool-call-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.tool-call-num {
    width: 28px;
    height: 28px;
    background: var(--brand-primary);
    color: var(--bg-base);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

.tool-call-name {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}

.tool-call-result {
    font-size: 0.85rem;
    color: var(--success);
    margin-left: auto;
}

/* Palette Display */
.palette-grid {
    display: grid;
    gap: 1.5rem;
    margin-top: 2rem;
}

.palette-row-label {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.palette-row {
    display: flex;
    gap: 3px;
    border-radius: 10px;
    overflow: hidden;
}

.palette-swatch {
    flex: 1;
    height: 56px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 6px;
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: white;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    transition: transform 0.15s var(--ease-out);
    cursor: pointer;
}

.palette-swatch:hover {
    transform: scaleY(1.15);
    z-index: 1;
}

/* Shadow Display */
.shadow-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 1.25rem;
}

.shadow-card {
    background: var(--bg-surface);
    border-radius: 12px;
    padding: 2rem 1rem;
    text-align: center;
    transition: all 0.25s var(--ease-out);
}

.shadow-card:hover {
    transform: translateY(-6px);
}

.shadow-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 1rem;
}

/* Code Block */
.code-block {
    background: var(--bg-base);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-secondary);
    overflow-x: auto;
    max-height: 400px;
    overflow-y: auto;
    line-height: 1.7;
}

.code-block pre {
    margin: 0;
    white-space: pre-wrap;
}

.code-comment { color: var(--text-muted); }
.code-key { color: var(--brand-primary); }
.code-value { color: var(--brand-secondary); }

/* Motion Demo */
.motion-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
}

.motion-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.25rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s var(--ease-out);
}

.motion-card:hover {
    border-color: var(--brand-primary);
}

.motion-dot {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    border-radius: 50%;
    margin: 0 auto 0.75rem;
}

.motion-name {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.motion-value {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-muted);
}

/* Grid Demo */
.grid-demo {
    display: grid;
    gap: 4px;
    margin-bottom: 1.5rem;
}

.grid-col {
    height: 44px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    border-radius: 6px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.grid-col:hover {
    opacity: 1;
}

.grid-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.grid-stat {
    background: var(--bg-base);
    padding: 1.25rem;
    border-radius: 10px;
    text-align: center;
}

.grid-stat-value {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--brand-primary);
}

.grid-stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, rgba(167,139,250,0.08), rgba(217,174,131,0.08));
    border: 1px solid var(--border-medium);
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    margin-top: 3rem;
}

.cta-section h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.cta-section p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-stats { gap: 2rem; }
    .palette-swatch { font-size: 0; }
    .grid-stats { grid-template-columns: 1fr; }
    .cta-section { padding: 2rem 1.5rem; }
}

/* === Utility classes (replacing inline style= attributes) === */

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.icon-sm {
    width: 18px;
    height: 18px;
}

.icon-md {
    width: 24px;
    height: 24px;
}

.section-surface {
    background: var(--bg-surface);
}

.nav-active {
    color: var(--brand-primary);
}
