/**
 * Front Page Styles
 * Styles specific to the homepage/front-page.php
 */

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
    text-align: center;
    padding: 6rem 1rem 4rem;
    background: linear-gradient(180deg, var(--slate-50) 0%, var(--white) 100%);
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    color: var(--slate-900);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--slate-600);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.underline-dotted {
    border-bottom: 2px dotted var(--primary-400);
}

.hero-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-btn-primary {
    display: inline-flex;
    align-items: center;
    padding: 0.875rem 2rem;
    background-color: var(--primary-600);
    color: var(--white);
    font-weight: 600;
    border-radius: var(--radius-full);
    transition: all var(--transition);
}

.hero-btn-primary:hover {
    background-color: var(--primary-700);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--white);
}

.hero-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background-color: var(--white);
    color: var(--slate-700);
    font-weight: 600;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-full);
    transition: all var(--transition);
}

.hero-btn-secondary:hover {
    background-color: var(--slate-50);
    border-color: var(--slate-300);
}

.hero-btn-secondary svg {
    width: 1rem;
    height: 1rem;
}

/* ==========================================================================
   Metrics Section
   ========================================================================== */
.metrics-section {
    padding: 3rem 1rem;
    background-color: var(--white);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .metrics-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.metric-item {
    text-align: center;
}

.metric-value {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 800;
    color: var(--slate-900);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.metric-value.highlight {
    color: var(--primary-600);
}

.metric-label {
    font-size: var(--text-sm);
    color: var(--slate-500);
    font-weight: 500;
}

/* ==========================================================================
   Features Bento Section
   ========================================================================== */
.features-section {
    padding: 4rem 1rem;
    background-color: var(--white);
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: var(--container-max);
    margin: 0 auto;
}

@media (min-width: 768px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.feature-card {
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    transition: all var(--transition-slow);
}

.feature-card:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.feature-graphic {
    margin-bottom: 1.5rem;
}

.feature-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--slate-900);
    margin-bottom: 0.75rem;
}

.feature-desc {
    font-size: var(--text-sm);
    color: var(--slate-600);
    line-height: 1.6;
    flex-grow: 1;
}

.feature-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--primary-600);
}

.feature-link:hover {
    color: var(--primary-700);
    gap: 0.75rem;
}

/* Model Logos */
.model-logos {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    max-width: 320px;
}

.model-logo-item {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
}

.model-logo-item svg,
.model-logo-item span {
    width: 20px;
    height: 20px;
}

/* Availability Diagram */
.availability-diagram {
    position: relative;
}

.availability-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 500;
    margin-bottom: 1rem;
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: var(--success);
    border-radius: var(--radius-full);
    animation: pulse 2s infinite;
}

.availability-text {
    color: var(--slate-600);
}

.diagram-endpoints {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1rem;
}

.endpoint {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
}

.endpoint.orange {
    background-color: #fff7ed;
}

.endpoint.dark {
    background-color: var(--slate-900);
}

.endpoint.center {
    background-color: var(--primary-light);
    font-size: 1.5rem;
}

/* Performance Chart */
.performance-chart {
    background-color: var(--slate-50);
    border-radius: var(--radius-lg);
    padding: 1rem;
}

.chart-labels {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.chart-legend {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--text-xs);
    color: var(--slate-600);
}

.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
}

.legend-dot.throughput {
    background-color: var(--success);
}

.legend-dot.latency {
    background-color: #8b5cf6;
}

.chart-svg {
    width: 100%;
    height: auto;
}

.chart-time-labels {
    display: flex;
    justify-content: space-between;
    font-size: var(--text-xs);
    color: var(--slate-400);
    margin-top: 0.5rem;
}

/* Security Icons */
.security-icons {
    position: relative;
    width: 160px;
    height: 120px;
    margin: 0 auto;
}

.security-icon-main {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    color: var(--primary-500);
}

.security-icon-inner {
    position: absolute;
    right: 10px;
    top: 10px;
    width: 32px;
    height: 32px;
    background-color: var(--white);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow);
}

.security-icon-inner svg {
    width: 18px;
    height: 18px;
    color: var(--slate-600);
}

.security-icon-float {
    position: absolute;
    font-size: 1.5rem;
    animation: float 3s ease-in-out infinite;
}

.security-icon-float:first-child {
    left: 0;
    bottom: 10px;
    animation-delay: 0s;
}

.security-icon-float:nth-child(2) {
    right: 20px;
    bottom: 30px;
    color: var(--success);
    animation-delay: 1.5s;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* ==========================================================================
   Models Section
   ========================================================================== */
.models-section {
    padding: 4rem 1rem;
    background-color: var(--slate-50);
}

.models-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: var(--container-max);
    margin: 0 auto;
}

@media (min-width: 768px) {
    .models-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .models-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.model-card {
    display: block;
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-slow);
}

.model-card:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.model-card-inner {
    height: 100%;
}

.model-card-content {
    padding: 1.5rem;
}

.model-header {
    margin-bottom: 1rem;
}

.model-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.model-logo {
    flex-shrink: 0;
}

.model-name-group {
    min-width: 0;
}

.model-name {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.model-name h3 {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--slate-900);
}

.model-badge {
    padding: 0.125rem 0.5rem;
    background-color: #ecfdf5;
    color: #059669;
    font-size: var(--text-xs);
    font-weight: 600;
    border-radius: var(--radius-full);
    border: 1px solid #a7f3d0;
}

.model-provider {
    font-size: var(--text-xs);
    color: var(--slate-500);
    margin-top: 0.25rem;
}

.model-stats {
    margin-top: 1rem;
}

.model-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.model-stat {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.model-stat-label {
    font-size: var(--text-xs);
    color: var(--slate-500);
}

.model-stat-value {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--slate-900);
}

.trend-badge {
    display: inline-flex;
    padding: 0.25rem 0.5rem;
    background-color: var(--slate-100);
    color: var(--slate-600);
    font-size: var(--text-xs);
    font-weight: 600;
    border-radius: var(--radius-full);
}

.trend-badge.down {
    background-color: var(--error-light);
    color: #dc2626;
}

/* ==========================================================================
   Agents Section
   ========================================================================== */
.agents-section {
    padding: 4rem 1rem;
    background-color: var(--white);
}

.agents-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: var(--container-max);
    margin: 0 auto;
}

@media (min-width: 768px) {
    .agents-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.agent-card {
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-slow);
}

.agent-card:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-lg);
}

.agent-preview {
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.agent-preview.replit {
    background: linear-gradient(135deg, #1e1e2e 0%, #2d2d44 100%);
}

.agent-preview.hermes {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.agent-preview.kilo {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
}

.agent-preview-content {
    padding: 1rem;
    width: 100%;
}

.window-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.window-dot {
    width: 10px;
    height: 10px;
    border-radius: var(--radius-full);
}

.window-dot.red { background-color: #ff5f56; }
.window-dot.yellow { background-color: #ffbd2e; }
.window-dot.green { background-color: #27c93f; }

.window-title {
    margin-left: auto;
    font-size: var(--text-xs);
    color: var(--slate-400);
}

.window-badge {
    font-size: var(--text-xs);
    color: var(--primary-400);
    background-color: rgba(99, 102, 241, 0.2);
    padding: 0.125rem 0.5rem;
    border-radius: var(--radius-sm);
}

.agent-preview-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: var(--text-xs);
    font-weight: 500;
}

.agent-preview-text .highlight {
    color: var(--primary-400);
}

.agent-preview-text .dark {
    color: var(--slate-300);
}

.agent-preview-text .indigo {
    color: #a5b4fc;
}

.agent-preview-text .amber {
    color: #fcd34d;
}

.agent-preview-text .cyan {
    color: #67e8f9;
}

.agent-footer {
    margin-top: 1rem;
    font-size: 0.625rem;
    color: var(--slate-500);
}

.hermes-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.hermes-title {
    font-family: monospace;
    font-size: var(--text-sm);
    font-weight: 700;
    color: #fbbf24;
    letter-spacing: 0.1em;
}

.hermes-subtitle {
    font-size: var(--text-xs);
    color: var(--slate-400);
}

.kilo-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.kilo-label {
    font-size: var(--text-xl);
    font-weight: 800;
    color: #60a5fa;
    font-family: monospace;
}

.kilo-text {
    font-size: var(--text-xs);
    color: var(--slate-400);
}

.agent-footer-section {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-top: 1px solid var(--slate-100);
}

.agent-logo {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: var(--text-sm);
    flex-shrink: 0;
}

.agent-logo.replit {
    background-color: #1e1e2e;
    color: var(--white);
}

.agent-logo.hermes {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: var(--slate-900);
}

.agent-logo.kilo {
    background-color: var(--slate-800);
    color: var(--white);
    font-family: monospace;
}

.agent-info h4 {
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--slate-900);
}

.agent-info p {
    font-size: var(--text-xs);
    color: var(--slate-500);
}

/* ==========================================================================
   Onboarding Section
   ========================================================================== */
.onboarding-section {
    padding: 4rem 1rem;
    background-color: var(--slate-50);
}

.onboarding-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .onboarding-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.onboarding-step {
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
}

.step-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.step-number {
    width: 32px;
    height: 32px;
    background-color: var(--primary-600);
    color: var(--white);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: var(--text-sm);
    flex-shrink: 0;
}

.step-title {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--slate-900);
}

.step-description {
    margin-bottom: 1.5rem;
}

.step-description p {
    font-size: var(--text-sm);
    color: var(--slate-600);
    line-height: 1.6;
}

.step-description a {
    color: var(--primary-600);
    font-weight: 500;
}

.step-description a:hover {
    text-decoration: underline;
}

.step-visual {
    background-color: var(--slate-50);
    border-radius: var(--radius-lg);
    padding: 1rem;
}

.visual-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.visual-icon {
    width: 24px;
    height: 24px;
    color: var(--slate-500);
    flex-shrink: 0;
}

.bar-group {
    display: flex;
    gap: 2px;
}

.bar-group div {
    width: 4px;
    height: 20px;
    background-color: var(--primary-300);
    border-radius: 2px;
}

.social-buttons {
    display: flex;
    gap: 0.5rem;
}

.social-btn {
    width: 32px;
    height: 32px;
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.social-btn:hover {
    border-color: var(--primary-300);
    transform: translateY(-2px);
}

.social-btn svg {
    width: 16px;
    height: 16px;
}

.credit-history {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.credit-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.credit-date {
    font-size: var(--text-xs);
    color: var(--slate-500);
    width: 40px;
}

.credit-bars {
    display: flex;
    gap: 2px;
}

.credit-bar {
    width: 4px;
    height: 16px;
    background-color: var(--primary-300);
    border-radius: 2px;
}

.credit-amount {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--slate-700);
    margin-left: auto;
}

.api-key-visual {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.api-key-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.api-key-input {
    flex: 1;
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    padding: 0.5rem 0.75rem;
}

.api-key-text {
    font-family: monospace;
    font-size: var(--text-xs);
    color: var(--slate-600);
}

.api-key-hidden {
    padding-left: 2.25rem;
}

.api-key-dots {
    font-family: monospace;
    font-size: var(--text-xs);
    color: var(--slate-400);
}

/* ==========================================================================
   Blog Section
   ========================================================================== */
.blog-section {
    padding: 4rem 1rem;
    background-color: var(--white);
}

.blog-header {
    max-width: var(--container-max);
    margin: 0 auto;
}

.blog-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.blog-title {
    font-size: var(--text-2xl);
    font-weight: 700;
    color: var(--slate-900);
}

.blog-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--primary-600);
}

.blog-link:hover {
    color: var(--primary-700);
}

.blog-link svg {
    width: 16px;
    height: 16px;
}

.blog-posts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .blog-posts {
        grid-template-columns: repeat(3, 1fr);
    }
}

.blog-post {
    display: block;
    background-color: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-slow);
}

.blog-post:hover {
    border-color: var(--primary-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.blog-article {
    display: flex;
    gap: 1rem;
    padding: 1rem;
}

.blog-thumbnail {
    flex-shrink: 0;
}

.blog-thumbnail-inner {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.blog-thumbnail-inner.indigo {
    background: linear-gradient(135deg, var(--primary-500) 0%, var(--primary-700) 100%);
}

.blog-thumbnail-icon {
    width: 24px;
    height: 24px;
    color: var(--white);
    opacity: 0.8;
}

.blog-content {
    flex: 1;
    min-width: 0;
}

.blog-post-title {
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--slate-900);
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-post-excerpt {
    font-size: var(--text-xs);
    color: var(--slate-600);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.blog-post-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: var(--text-xs);
    color: var(--slate-500);
}

.blog-new-badge {
    padding: 0.125rem 0.5rem;
    background-color: #ecfdf5;
    color: #059669;
    border-radius: var(--radius-full);
    font-weight: 600;
}
