/* everapi.com shared styles */

:root {
    --accent: #2563EB;
    --accent-hover: #1D4ED8;
    --navy: #0B1222;
    --brand-dark: #0033BF;
    --brand-light: #2994FF;
    --text: #111827;
    --muted: #4B5563;
    --border: #E5E7EB;
    --grid: #EEF2F7;
    --tint: #EFF6FF;
    --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: 'Figtree', 'Helvetica Neue', Arial, sans-serif;
    color: var(--text);
    background-color: #fff;
    background-image:
        linear-gradient(var(--grid) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid) 1px, transparent 1px);
    background-size: 48px 48px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.6;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
img { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; color: var(--navy); letter-spacing: -0.025em; line-height: 1.12; font-weight: 800; }
p { margin: 0; }

.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.eyebrow { font-size: 17px; font-weight: 500; font-style: italic; color: var(--accent); }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    min-height: 50px; padding: 13px 28px;
    border-radius: 999px; border: 1.5px solid var(--accent);
    font-size: 16px; font-weight: 600; line-height: 1.2;
    transition: background-color .15s, color .15s, box-shadow .15s;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px -8px rgba(37, 99, 235, .6); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-outline { background: #fff; color: var(--accent); }
.btn-outline:hover { background: var(--tint); }
.btn-sm { min-height: 44px; padding: 10px 20px; font-size: 15px; box-shadow: none; }

/* Nav */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.site-header .container { height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-header nav { display: flex; gap: 32px; }
.site-header nav a { color: var(--text); font-size: 15px; font-weight: 500; }
.site-header nav a:hover { color: var(--accent); }
.header-actions { display: flex; gap: 10px; }

/* Hero */
.hero { padding: 80px 0 88px; }
.hero .container { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; }
.hero-copy { flex: 1 1 460px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.hero h1 { font-size: 54px; line-height: 1.08; letter-spacing: -0.03em; }
.hero-lead { font-size: 19px; line-height: 1.65; color: var(--muted); max-width: 520px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 560px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: rgba(255, 255, 255, .85); }
.stat { padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.stat + .stat { border-left: 1px solid var(--border); }
.stat:first-child { padding-left: 0; }
.stat-label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.stat-value { font-size: 15px; font-weight: 600; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 4px; }

.hero-visual { flex: 1 1 520px; min-width: 0; }
.window { background: #fff; border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 24px 50px -20px rgba(15, 23, 42, .25); overflow: hidden; margin-right: 40px; }
.window-bar { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border); background: #F8FAFC; }
.window-dot { width: 10px; height: 10px; border-radius: 50%; background: #E2E8F0; }
.window-url { margin-left: 10px; flex-grow: 1; background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 4px 10px; font: 12px var(--mono); color: var(--muted); }
.window-body { padding: 22px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.result { border: 1px solid var(--border); border-radius: 10px; padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.result-label { font-size: 12px; color: var(--muted); }
.result-value { font-size: 15px; font-weight: 700; color: var(--navy); display: inline-flex; align-items: center; gap: 6px; }
.result-value.big { font-size: 22px; font-weight: 800; }
.result-value.mid { font-size: 18px; }
.result-source { font-size: 12px; font-weight: 600; color: var(--brand-dark); }

.code-card { position: relative; background: #fff; border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 24px 50px -20px rgba(15, 23, 42, .25); margin: -36px 0 0 56px; padding: 16px 0; font: 13px/1.75 var(--mono); overflow-x: auto; }
.code-card ol { margin: 0; padding: 0 20px 0 52px; color: #94A3B8; }
.code-card li { white-space: pre; color: #1F2937; }
.code-card li::marker { color: #94A3B8; }
.tk-k { color: #7C3AED; } .tk-s { color: #0F766E; } .tk-f { color: #2563EB; } .tk-c { color: #94A3B8; }
.annotation { display: flex; align-items: center; gap: 8px; margin: 14px 0 0 80px; color: var(--muted); font-size: 15px; font-style: italic; }

/* Products */
.section { padding: 40px 0 96px; }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 40px; }
.section-head > div { display: flex; flex-direction: column; gap: 10px; max-width: 620px; }
.section-head h2, .section h2 { font-size: 40px; }
.section-head a { font-size: 16px; font-weight: 600; }

.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.tile { background: #fff; padding: 30px 26px; min-height: 260px; display: flex; flex-direction: column; gap: 16px; color: var(--text); transition: background-color .15s; }
.tile:hover { background: #FAFCFF; color: var(--text); }
.tile-logo { height: 30px; display: flex; align-items: center; }
.tile-logo img { height: 26px; width: auto; }
.tile h3 { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.tile p { font-size: 15px; color: var(--muted); }
.tags { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; font-weight: 600; color: #1E3A8A; background: var(--tint); border-radius: 999px; padding: 4px 10px; }
.wordmark { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 19px; color: var(--navy); letter-spacing: -0.01em; }

.more { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.more a { background: #fff; border: 1px solid var(--border); border-radius: 999px; padding: 12px 20px; min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 10px; transition: border-color .15s; }
.more a:hover { border-color: var(--accent); }
.more-name { display: block; font-size: 15px; font-weight: 700; color: var(--text); }
.more-desc { display: block; font-size: 13px; color: var(--muted); }

/* Agents */
.agents { background: var(--navy); color: #fff; }
.agents .container { padding-top: 96px; padding-bottom: 96px; display: flex; flex-wrap: wrap; gap: 56px; align-items: flex-start; }
.agents-copy { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.agents .eyebrow { color: #93C5FD; }
.agents h2 { color: #fff; font-size: 40px; }
.agents-copy > p { font-size: 18px; line-height: 1.65; color: #CBD5E1; }
.agents a { color: #93C5FD; }
.agents a:hover { color: #BFDBFE; }
.endpoints { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 8px 20px; font: 13px/1.6 var(--mono); }
.endpoints a { color: #CBD5E1; }
.endpoints a:hover { color: #fff; }
.agents-code { flex: 1 1 460px; min-width: 0; margin: 0; background: #111A2E; border: 1px solid #1E293B; border-radius: 12px; padding: 22px 24px; font: 14px/1.8 var(--mono); color: #CBD5E1; overflow-x: auto; }
.agents-code .tk-key { color: #93C5FD; } .agents-code .tk-str { color: #86EFAC; } .agents-code .tk-c { color: #64748B; }

/* Integrations */
.integrations .container { padding-top: 88px; padding-bottom: 88px; display: flex; flex-direction: column; gap: 28px; align-items: center; text-align: center; }
.integrations h2 { font-size: 34px; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 900px; }
.pill { background: #fff; border: 1px solid var(--border); border-radius: 999px; padding: 10px 20px; font-size: 15px; font-weight: 600; color: var(--text); }

/* Contact */
.contact { padding-bottom: 88px; }
.contact-card { background: #fff; border: 1px solid var(--border); border-radius: 20px; padding: 56px 40px; display: flex; flex-wrap: wrap; gap: 28px; align-items: center; justify-content: space-between; box-shadow: 0 24px 50px -30px rgba(15, 23, 42, .25); }
.contact-card > div { display: flex; flex-direction: column; gap: 10px; max-width: 620px; }
.contact-card h2 { font-size: 32px; line-height: 1.2; }
.contact-card p { font-size: 17px; color: var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); background: rgba(255, 255, 255, .95); }
.footer-grid { padding-top: 56px; padding-bottom: 40px; display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 40px; }
.footer-grid h4 { margin: 0 0 12px; font-size: 14px; font-weight: 700; color: var(--navy); }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.footer-grid ul a, .footer-company { color: var(--muted); }
.footer-grid ul a:hover { color: var(--accent); }
.footer-company { font-size: 14px; margin-top: 14px; }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 20px; padding-bottom: 28px; font-size: 13px; color: var(--muted); }

@media (max-width: 1100px) {
    .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .more { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
}
@media (max-width: 900px) {
    .site-header nav { display: none; }
    .hero { padding: 48px 0 64px; }
    .hero h1 { font-size: 40px; }
    .window, .code-card { margin-left: 0; margin-right: 0; }
    .code-card { margin-top: 16px; }
    .annotation { margin-left: 0; }
    .section-head h2, .section h2, .agents h2 { font-size: 32px; }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
    .header-actions .btn-outline { display: none; }
    .hero h1 { font-size: 34px; }
    .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stat:nth-child(3) { padding-left: 0; border-left: 0; border-top: 1px solid var(--border); }
    .stat:nth-child(4) { border-top: 1px solid var(--border); }
    .window-body { grid-template-columns: 1fr; }
    .bento { grid-template-columns: 1fr; }
    .contact-card { padding: 36px 24px; }
    .footer-grid { grid-template-columns: 1fr; }
}

/* ---------- Subpages ---------- */

.breadcrumb { padding-top: 20px; font-size: 14px; color: var(--muted); }
.breadcrumb ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; color: #94A3B8; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb [aria-current] { color: var(--text); font-weight: 600; }

.page-hero { padding: 48px 0 80px; }
.page-hero .container { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; }
.page-hero-copy { flex: 1 1 460px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.page-hero-copy.solo { max-width: 760px; }
.page-hero h1 { font-size: 52px; line-height: 1.08; letter-spacing: -0.03em; }
.page-hero .hero-logo { height: 34px; width: auto; align-self: flex-start; }
.page-hero .wordmark { font-size: 24px; }
.page-hero-visual { flex: 1 1 480px; min-width: 0; }
.resource-links { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 14px; color: var(--muted); }
.resource-links a { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }

/* Code panels (highlight.js github theme underneath) */
.code-panel { background: #fff; border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 24px 50px -24px rgba(15, 23, 42, .22); overflow: hidden; display: flex; flex-direction: column; }
.code-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border); background: #F8FAFC; font-size: 14px; font-weight: 600; color: var(--text); }
.code-panel pre { margin: 0; padding: 18px 20px; overflow-x: auto; font: 13px/1.7 var(--mono); flex-grow: 1; }
.code-panel pre code.hljs { padding: 0; background: transparent; font: inherit; }
.badge { font-size: 12px; font-weight: 600; color: #1E3A8A; background: var(--tint); border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.badge.muted { color: var(--muted); background: #F1F5F9; }

.block { padding: 72px 0; }
.block-head { display: flex; flex-direction: column; gap: 10px; max-width: 680px; margin-bottom: 36px; }
.block-head h2 { font-size: 36px; }
.block-head p { font-size: 18px; color: var(--muted); }

.feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.feature { background: #fff; padding: 28px 26px; display: flex; flex-direction: column; gap: 10px; }
.feature-num { font: 500 13px var(--mono); color: var(--accent); }
.feature h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.01em; }
.feature p { font-size: 15px; color: var(--muted); }

.example-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }

.int-group + .int-group { margin-top: 36px; }
.int-group h3 { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 14px; }
.sdk-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.sdk { background: #fff; padding: 22px 16px; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; color: var(--text); transition: background-color .15s; }
a.sdk:hover { background: #FAFCFF; color: var(--text); }
.sdk svg { width: 36px; height: 36px; }
.sdk-name { font-size: 15px; font-weight: 700; }
.sdk-sub { font-size: 12px; color: var(--muted); }
.pill-row { display: flex; flex-wrap: wrap; gap: 10px; }
a.pill { display: inline-flex; align-items: center; gap: 8px; color: var(--text); transition: border-color .15s; }
a.pill:hover { border-color: var(--accent); color: var(--text); }
span.pill { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.mcp-line { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 16px 20px; }
.mcp-line code { font: 14px var(--mono); color: var(--navy); }
.mcp-line span { font-size: 14px; color: var(--muted); }

.cta-block { padding: 24px 0 88px; }

/* Category pages */
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.product-grid.n1 { grid-template-columns: minmax(0, 1fr); max-width: 520px; }
.product-grid.n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tile .more-link { font-size: 15px; font-weight: 600; color: var(--accent); }

/* Integrations page */
.market-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.market-grid .tile { min-height: 200px; }

/* Prose (imprint) */
.prose-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; }
.prose-card { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 32px; display: flex; flex-direction: column; gap: 22px; }
.prose-card h2 { font-size: 26px; }
.prose-card h3 { font-size: 16px; font-weight: 700; letter-spacing: 0; margin-bottom: 6px; }
.prose-card p { font-size: 15px; color: var(--muted); }

@media (max-width: 1100px) {
    .sdk-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .product-grid, .market-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
    .page-hero { padding: 32px 0 56px; }
    .page-hero h1 { font-size: 38px; }
    .block-head h2 { font-size: 30px; }
    .feature-grid, .example-grid, .prose-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
    .page-hero h1 { font-size: 32px; }
    .sdk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .product-grid, .product-grid.n2, .market-grid { grid-template-columns: minmax(0, 1fr); }
    .prose-card { padding: 24px; }
}

/* Contact form */
.contact-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 56px; align-items: start; }
.contact-aside { display: flex; flex-direction: column; gap: 18px; font-size: 16px; color: var(--muted); }
.contact-aside h2 { font-size: 22px; }
.form-card { background: #fff; border: 1px solid var(--border); border-radius: 20px; padding: 36px; box-shadow: 0 24px 50px -30px rgba(15, 23, 42, .25); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 14px; font-weight: 600; color: var(--text); }
.field .optional { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
    font: inherit; font-size: 16px; color: var(--text);
    background: #fff; border: 1px solid #CBD5E1; border-radius: 10px;
    padding: 12px 14px; min-height: 48px; width: 100%;
    transition: border-color .15s, box-shadow .15s;
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, .18); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-top: 24px; }
.form-note { font-size: 13px; color: var(--muted); }
.hidden-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 900px) {
    .contact-layout { grid-template-columns: minmax(0, 1fr); gap: 32px; }
}
@media (max-width: 560px) {
    .form-card { padding: 24px; }
    .form-grid { grid-template-columns: minmax(0, 1fr); }
}
