/* --- Design Tokens --- */
:root {
    --brand: #2563eb;        /* primary blue */
    --brand-600: #1d4ed8;
    --brand-50: #eff6ff;
    --ink: #0f172a;          /* slate-900 */
    --muted: #475569;        /* slate-600 */
    --line: #e2e8f0;         /* slate-200 */
    --bg: #f8fafc;           /* slate-50 */
    --surface: #ffffff;
    --accent: linear-gradient(135deg, #1d4ed8, #22d3ee);
}

/* --- Base & Typography --- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, 'Apple Color Emoji', 'Segoe UI Emoji', sans-serif;
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
}
h1, h2, h3 {
    font-family: 'Merriweather', Georgia, 'Times New Roman', serif;
    margin: 0 0 0.5rem 0;
    line-height: 1.25;
}
h1 { font-size: clamp(2rem, 4vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 2.5vw, 2.25rem); }
h3 { font-size: clamp(1.125rem, 2vw, 1.35rem); }
p { margin: 0 0 1rem 0; color: var(--muted); }
a { color: var(--brand-600); text-decoration: none; }
a:hover { text-decoration: underline; }

/* --- Layout Helpers --- */
.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 24px;
}
.section { padding: 72px 0; scroll-margin-top: 96px; }
.section-muted { background: var(--bg); }
.section-accent { background: var(--brand-50); }
.section-title {
    display: inline-block;
    position: relative;
    padding-bottom: 10px;
}
.section-title::after {
    content: '';
    position: absolute;
    left: 0; bottom: 0;
    width: 56px; height: 3px;
    background: var(--accent);
    border-radius: 3px;
}
.section-lead { margin: 12px 0 28px 0; }

/* small uppercase label for context (e.g., Labs, Consulting) */
.eyebrow { display:inline-block; margin-bottom:6px; font-size:.8rem; letter-spacing:.12em; text-transform:uppercase; color: var(--muted); }

/* --- Navigation --- */
.site-nav {
    position: sticky; top: 0; z-index: 50;
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    background: rgba(255,255,255,0.9);
    border-bottom: 1px solid var(--line);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; color: var(--ink); }
.brand-mark { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--accent); color: white; font-size: 14px; }
.brand-text { letter-spacing: 0.2px; }
.nav-links { display: flex; gap: 24px; }
.nav-links a { color: var(--ink); font-weight: 600; opacity: 0.9; }
.nav-links a:hover { opacity: 1; }

/* --- Hero --- */
.hero {
    position: relative;
    min-height: 64vh;
    display: grid; place-items: center; text-align: center;
    color: #fff;
}
.hero-bg {
    position: absolute; inset: 0;
    background:
        linear-gradient(180deg, rgba(15,23,42,.55), rgba(15,23,42,.6)),
        url('../images/pyxisint-hero.png') center/cover no-repeat,
        linear-gradient(135deg, #0f172a, #1e293b);
}
.hero-inner { position: relative; padding: 72px 0; }
.hero p { max-width: 860px; margin: 12px auto 24px auto; color: #e5e7eb; }
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* --- Buttons --- */
.btn {
    display: inline-block; padding: 12px 18px; border-radius: 10px;
    font-weight: 600; letter-spacing: .2px; border: 1px solid transparent;
    transition: transform .05s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 8px 24px rgba(37,99,235,.25); }
.btn-primary:hover { background: var(--brand-600); box-shadow: 0 8px 26px rgba(29,78,216,.35); }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,0.4); }
.btn-ghost:hover { background: color-mix(in oklab, #ffffff 8%, transparent); }

/* --- Cards --- */
.cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: 18px;
}
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 20px 18px;
    transition: transform .12s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(2,6,23,.06); border-color: #bfdbfe; }
.card h3 { margin: 6px 0 6px 0; }
.card p { margin: 0; }
.card-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: var(--brand-50); color: var(--brand-600); font-size: 18px; }

/* --- Two-column grid --- */
.grid-two { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 28px; align-items: start; }
.col { min-width: 0; }

/* --- Feature list --- */
.feature-list { list-style: none; padding: 0; margin: 16px 0 20px 0; display: grid; gap: 10px; }
/*
    Previous implementation used a two-column CSS grid (18px + 1fr)
    assuming a leading marker element. The markup doesn't include that
    marker, so items were placed in the 18px column, forcing words to
    wrap one-per-line. Switch to a single-column flow.
*/
.feature-list li { display: block; }
.feature-mark { display: inline-block; width: 10px; height: 10px; margin-top: 8px; border-radius: 50%; background: var(--accent); }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; }

/* --- Panel (illustrative metrics) --- */
.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 18px;
    box-shadow: 0 8px 24px rgba(2,6,23,.05);
}
.panel-header { font-weight: 700; margin-bottom: 10px; }
.panel-metrics { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px; }
.metric { background: var(--bg); border: 1px dashed var(--line); border-radius: 12px; padding: 12px; text-align: center; }
.metric-value { font-weight: 700; font-size: 1.25rem; color: var(--ink); }
.metric-label { font-size: .85rem; color: var(--muted); }
.panel-note { margin-top: 8px; font-size: .85rem; color: var(--muted); }

/* --- Contact --- */
.contact-grid { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; }

/* --- Footer --- */
.site-footer { border-top: 1px solid var(--line); background: #0b1220; color: #dbeafe; }
.footer-wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 72px; }
.site-footer a { color: #bfdbfe; }
.back-to-top { opacity: .9; }
.back-to-top:hover { opacity: 1; }

/* --- Tiles & Badges (Engagement Models) --- */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 18px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.tile h3 { margin: 6px 0 6px 0; }
.tile p { margin: 0 0 8px 0; }
.badges { display: flex; gap: 8px; flex-wrap: wrap; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); font-size: .8rem; color: var(--muted); }

/* --- Responsiveness --- */
@media (max-width: 1024px) {
    .cards { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .panel-metrics { grid-template-columns: repeat(3, minmax(0,1fr)); }
    .tiles { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 720px) {
    .nav-links { gap: 16px; }
    .cards { grid-template-columns: 1fr; }
    .grid-two { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .tiles { grid-template-columns: 1fr; }
    .btn-ghost { color: #0f172a; border-color: var(--line); }
    .hero-cta .btn-ghost { color: #fff; border-color: rgba(255,255,255,0.4); }
}
