:root {
    --bg: #f4f7fb;
    --surface: #ffffff;
    --surface-soft: #f8fafc;
    --text: #101827;
    --muted: #68778b;
    --line: #dbe4ee;
    --blue: #086bd8;
    --blue-hover: #045fca;
    --navy: #0d1728;
    --green: #19a66a;
    --shadow: 0 18px 46px rgba(25, 43, 66, .09);
    --radius: 20px;

    /* Shared layout + typography system. */
    --shell-max: 1120px;
    --content-section-gap: 44px;
    --type-xs: 12px;
    --type-sm: 13px;
    --type-ui: 14px;
    --type-body: 15px;
    --type-copy: 16px;
    --type-lead: 18px;
    --heading-card: 20px;
    --heading-h3: 22px;
    --heading-h2: clamp(28px, 2.6vw, 34px);
    --heading-page: clamp(40px, 4.2vw, 52px);
    --heading-hero: clamp(46px, 4.8vw, 60px);
    --ease-ui: cubic-bezier(.2, .7, .2, 1);
    --transition-fast: 200ms var(--ease-ui);
}

html[data-theme="dark"] {
    --bg: #08111f;
    --surface: #0f1a2a;
    --surface-soft: #101d30;
    --text: #eef4fb;
    --muted: #96a6b9;
    --line: #22354d;
    --navy: #f7fbff;
    --shadow: 0 18px 46px rgba(0, 0, 0, .25);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

/* Shared interaction motion: colour, border and shadow only - no hover movement. */
.nav a,
.mobile-nav a,
.footer-group a,
.footer-meta a,
.tool-link,
.related-links a,
.directory-quick-picks a,
.filter-chip,
.recent-tool-links a,
.release-links a,
.release-link-grid a,
.text-link,
.theme-toggle,
.copy-btn,
.btn,
.mini-copy,
.terminal-text-btn,
.terminal-run,
.endpoint-example button,
.tool-terminal-command .btn-secondary,
.tool-card,
.quick-pick,
.category-overview-card,
.guide-card,
.terminal-example-bar button,
.terminal-feature-examples button,
.text-input,
.select-input,
.textarea-input,
.header-textarea {
    transition:
        color var(--transition-fast),
        background-color var(--transition-fast),
        border-color var(--transition-fast),
        box-shadow var(--transition-fast),
        opacity var(--transition-fast);
}
button, input, select, textarea { font: inherit; }
.shell { width: min(var(--shell-max), calc(100% - 40px)); margin: 0 auto; }

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--surface);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border-bottom: 1px solid var(--line);
}
.header-inner { min-height: 70px; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; margin-right: auto; }
.brand img { width: 190px; height: auto; display: block; }
.brand .logo-dark { display: none; }
html[data-theme="dark"] .brand .logo-light { display: none; }
html[data-theme="dark"] .brand .logo-dark { display: block; }
.nav { display: flex; align-items: center; gap: 24px; color: var(--muted); font-size: var(--type-ui); font-weight: 650; }
.nav a:hover,
.nav a.is-active { color: var(--blue); }
.nav a.is-active, .footer-group a.is-active { font-weight: 750; }
.nav-toggle, .mobile-nav { display: none; }
.nav-toggle {
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text);
    padding: 9px 11px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 800;
}
[hidden] { display: none !important; }
.theme-toggle, .copy-btn {
    border: 0;
    cursor: pointer;
    border-radius: 12px;
}
.theme-toggle {
    min-width: 106px;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--line);
    border-radius: 11px;
    padding: 8px 12px;
    font-weight: 700;
    font-size: 12px;
}
.theme-toggle:hover {
    border-color: color-mix(in srgb, var(--blue) 30%, var(--line));
    background: color-mix(in srgb, var(--blue) 5%, var(--surface));
}

.theme-toggle[data-theme-state="dark"] {
    background: color-mix(in srgb, var(--blue) 14%, var(--surface));
    border-color: color-mix(in srgb, var(--blue) 35%, var(--line));
}

/* Shared button component. Keep size/weight identical across links and buttons. */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    font: inherit;
    font-size: var(--type-sm);
    font-weight: 800;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-hover); }
.btn-secondary { border-color: var(--line); background: var(--surface); color: var(--text); }
.btn-secondary:hover {
    border-color: color-mix(in srgb, var(--blue) 30%, var(--line));
    background: color-mix(in srgb, var(--blue) 5%, var(--surface));
}
.btn-danger {
    border-color: color-mix(in srgb, #d84a4a 30%, var(--line));
    background: var(--surface);
    color: #b63a3a;
}
.btn-danger:hover { background: color-mix(in srgb, #d84a4a 7%, var(--surface)); }
.btn-compact { min-height: 38px; padding: 0 12px; border-radius: 10px; font-size: var(--type-xs); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }

.hero {
    display: grid;
    grid-template-columns: .82fr 1.28fr;
    gap: 54px;
    align-items: center;
    padding: 82px 0 62px;
}
.hero-copy h1 {
    margin: 12px 0 16px;
    color: var(--navy);
    font-size: var(--heading-hero);
    line-height: .98;
    letter-spacing: -.055em;
    white-space: nowrap;
}
.hero-copy p { max-width: 440px; margin: 0; color: var(--muted); font-size: 17px; line-height: 1.7; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; color: var(--blue); font-size: var(--type-xs); font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px color-mix(in srgb, var(--green) 12%, transparent); }

.ip-card {
    padding: 30px;
    background: linear-gradient(135deg, color-mix(in srgb, var(--surface) 98%, var(--blue) 2%) 0%, var(--surface) 78%, color-mix(in srgb, var(--surface) 96%, var(--blue) 4%) 100%);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}
.ip-card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}
.micro-label { display: block; color: var(--muted); font-size: 12px; font-weight: 700; margin-bottom: 8px; }
.ip-value {
    color: var(--navy);
    font-size: clamp(42px, 4.8vw, 60px);
    line-height: 1.02;
    font-weight: 800;
    letter-spacing: -.05em;
    word-break: break-all;
}
.copy-btn {
    align-self: flex-start;
    background: var(--blue);
    color: white;
    padding: 10px 15px;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}
.copy-btn:hover { background: var(--blue-hover); }

.ip-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 26px;
}
.summary-stat {
    min-width: 0;
    padding: 15px 16px;
    border-radius: 14px;
    background: color-mix(in srgb, var(--surface-soft) 88%, transparent);
    border: 1px solid var(--line);
}
.summary-stat span,
.hostname-row span,
.detail-card > span {
    display: block;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .09em;
    margin-bottom: 6px;
}
.summary-stat strong {
    display: block;
    font-size: 18px;
    color: var(--text);
    line-height: 1.25;
}
.hostname-row {
    margin-top: 14px;
    padding: 16px 18px;
    border-radius: 14px;
    background: color-mix(in srgb, var(--surface-soft) 92%, transparent);
    border: 1px solid var(--line);
}
.hostname-row strong {
    display: block;
    color: var(--text);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 14px;
    line-height: 1.6;
    overflow-wrap: anywhere;
    word-break: break-word;
}
.local-db-note { margin-top: 18px; padding: 12px 14px; border: 1px dashed color-mix(in srgb, var(--blue) 35%, var(--line)); border-radius: 12px; color: var(--muted); background: color-mix(in srgb, var(--blue) 5%, var(--surface)); font-size: 12px; }

.details-section, .tools-section, .api-section, .about-section { padding: 50px 0; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 42px; margin-bottom: 24px; }
.section-heading h2, .api-card h2, .about-copy h2 { margin: 8px 0 0; color: var(--navy); font-size: var(--heading-h2); line-height: 1.08; letter-spacing: -.035em; }
.section-heading > p { max-width: 480px; color: var(--muted); margin: 0; font-size: 14px; line-height: 1.65; }
.detail-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.detail-card { min-height: 146px; padding: 21px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.detail-card strong { display: block; margin-top: 16px; color: var(--navy); font-size: 18px; line-height: 1.25; overflow-wrap: anywhere; }
.detail-card small { display: block; margin-top: 7px; color: var(--muted); line-height: 1.45; font-size: 12px; }

.tools-section { padding-top: 72px; }
.tool-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tool-card { min-height: 206px; display: flex; flex-direction: column; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.tool-card:hover { box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--blue) 32%, var(--line)); background: color-mix(in srgb, var(--surface) 97%, var(--blue) 3%); }
.tool-card-top { display: flex; justify-content: space-between; align-items: center; }
.tool-dot { width: 9px; height: 9px; border-radius: 3px; background: var(--blue); box-shadow: 0 0 0 5px color-mix(in srgb, var(--blue) 9%, transparent); }
.tool-tag { border: 1px solid var(--line); color: var(--muted); border-radius: 999px; padding: 4px 8px; font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.tool-card h3 { margin: 30px 0 6px; color: var(--navy); font-size: var(--heading-card); }
.tool-card p { color: var(--muted); margin: 0 0 20px; font-size: 14px; line-height: 1.6; }
.tool-link { margin-top: auto; color: var(--blue); font-size: 12px; font-weight: 800; }

.api-card {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 42px;
    align-items: center;
    padding: 34px;
    color: #eef6ff;
    background: #0b1424;
    border: 1px solid #16243a;
    border-radius: 22px;
    box-shadow: var(--shadow);
}
.api-card .eyebrow { color: #67adf4; }
.api-card h2 { color: white; }
.api-card p { color: #a7b5c8; max-width: 500px; margin-bottom: 0; font-size: 14px; line-height: 1.65; }
.code-box { display: grid; grid-template-columns: auto 1fr auto; gap: 13px; align-items: center; padding: 15px; border: 1px solid #243650; border-radius: 12px; background: #101d30; min-width: 0; }
.code-box span { color: #68d59d; font-weight: 850; font-size: 11px; letter-spacing: .06em; }
.code-box code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #d9e7f8; font-size: 12px; }
.code-box a { color: #72b6ff; font-size: 12px; font-weight: 800; }

.about-section { display: grid; grid-template-columns: 1.05fr .95fr; gap: 60px; padding-bottom: 84px; }
.about-copy p { color: var(--muted); font-size: 16px; line-height: 1.75; max-width: 620px; }
.about-notes { align-self: end; border-left: 1px solid var(--line); padding-left: 30px; }
.about-notes p { margin: 0 0 18px; color: var(--muted); font-size: 14px; line-height: 1.7; }
.about-notes p:last-child { margin-bottom: 0; }
.about-notes strong { color: var(--text); }

.tool-page { padding: 68px 0 90px; }
.tool-page-header { max-width: 760px; margin-bottom: 28px; }
.tool-page-header h1 { margin: 10px 0 12px; color: var(--navy); font-size: var(--heading-page); letter-spacing: -.045em; line-height: 1; }
.tool-page-header p { color: var(--muted); font-size: 16px; }
.tool-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 24px; box-shadow: var(--shadow); }
.form-row { display: flex; gap: 10px; }
.text-input, .select-input, .textarea-input { width: 100%; border: 1px solid var(--line); background: var(--surface); color: var(--text); border-radius: 10px; padding: 13px 14px; outline: none; }
.textarea-input { line-height: 1.6; }
.text-input:focus, .select-input:focus, .textarea-input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 12%, transparent); }
.result-box { margin-top: 20px; border-top: 1px solid var(--line); padding-top: 20px; }
.result-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.result-item { padding: 14px; background: var(--bg); border: 1px solid var(--line); border-radius: 11px; min-width: 0; }
.result-item span { display: block; color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.result-item strong, .result-item code { display: block; margin-top: 5px; color: var(--text); overflow-wrap: anywhere; word-break: normal; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
td { font-size: 14px; word-break: break-word; }
.alert { padding: 13px 15px; border-radius: 11px; background: color-mix(in srgb, var(--blue) 8%, var(--surface)); border: 1px solid color-mix(in srgb, var(--blue) 25%, var(--line)); color: var(--text); }


/* v2.1 utility and content system */
.smart-lookup { margin-top: 30px; max-width: 520px; }
.smart-lookup > label { display: block; margin-bottom: 8px; color: var(--text); font-size: 12px; font-weight: 800; }
.smart-lookup-row { display: flex; gap: 9px; }
.smart-lookup small { display: block; margin-top: 8px; color: var(--muted); font-size: 11px; }

.tool-category-block { margin-top: 34px; }
.tool-category-block:first-of-type { margin-top: 0; }
.tool-category-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; margin-bottom: 14px; }
.tool-category-heading h2, .tool-category-heading h3 { margin: 0; color: var(--navy); font-size: 20px; letter-spacing: -.02em; }
.tool-category-heading > a { color: var(--blue); font-size: 12px; font-weight: 800; }
.tool-category-heading > span { color: var(--muted); font-size: 12px; }
.tool-category { display: block; margin-top: 24px; color: var(--blue); font-size: 11px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.tool-card .tool-category + h3 { margin-top: 7px; }
.tools-section .tool-grid { grid-template-columns: repeat(4, 1fr); }
.tools-section .tool-category-block:last-child .tool-grid { grid-template-columns: repeat(3, 1fr); }

.api-examples { display: grid; gap: 10px; }

.wide-header { max-width: 860px; }
.tools-directory { padding-top: 72px; }
.directory-section { margin-top: var(--content-section-gap); }
.directory-section .tool-grid { grid-template-columns: repeat(3, 1fr); }
.directory-alert { margin-bottom: 28px; }

.result-grid-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.result-wide { grid-column: 1 / -1; }
.compact-results { margin-top: 14px; }
.feature-result strong, .feature-result code { font-size: 16px; }
.compact-select { max-width: 140px; }

.asn-hero-result, .rdap-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.asn-hero-result > div, .rdap-summary > div { padding: 20px; border-radius: 14px; background: color-mix(in srgb, var(--blue) 6%, var(--surface)); border: 1px solid color-mix(in srgb, var(--blue) 18%, var(--line)); }
.asn-hero-result span, .rdap-summary span { display: block; color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 7px; }
.asn-hero-result strong, .rdap-summary strong { display: block; color: var(--navy); font-size: 22px; line-height: 1.3; overflow-wrap: anywhere; }
.source-note { margin-top: 14px; color: var(--muted); font-size: 12px; }
.source-note a { color: var(--blue); font-weight: 700; }

.connection-result { position: relative; padding: 34px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.connection-kicker { display: block; color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.connection-result > strong { display: block; margin: 8px 0 4px; color: var(--navy); font-size: clamp(54px, 8vw, 84px); line-height: .95; letter-spacing: -.05em; }
.connection-result > code { display: block; margin: 12px 0 20px; color: var(--muted); font-size: 15px; overflow-wrap: anywhere; }
.connection-details { margin-top: 14px; box-shadow: none; }

.tool-guide {
    --tool-guide-gap: 24px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: var(--tool-guide-gap);
    row-gap: var(--tool-guide-gap);
    margin-top: var(--content-section-gap);
    padding-top: var(--content-section-gap);
    border-top: 1px solid var(--line);
}
.tool-guide > * { min-width: 0; }
.tool-guide-copy h2, .related-tools h2, .api-notes h2 { margin: 8px 0 16px; color: var(--navy); font-size: var(--heading-h2); line-height: 1.1; letter-spacing: -.035em; }
.tool-guide-copy p { margin: 0 0 14px; color: var(--muted); font-size: var(--type-body); line-height: 1.75; }
.guide-points { display: grid; gap: 10px; }
.guide-points article { padding: 17px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.guide-points strong { color: var(--text); font-size: var(--type-ui); }
.guide-points p { margin: 5px 0 0; color: var(--muted); font-size: var(--type-ui); line-height: 1.55; }
.related-tools { margin-top: var(--content-section-gap); }
.related-links { display: flex; flex-wrap: wrap; gap: 10px; }
.related-links a { display: inline-flex; align-items: center; gap: 8px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); font-size: 12px; font-weight: 750; }
.related-links a:hover { border-color: color-mix(in srgb, var(--blue) 35%, var(--line)); color: var(--blue); }

.api-doc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.endpoint-card { display: flex; flex-direction: column; padding: 22px; border: 1px solid var(--line); background: var(--surface); border-radius: 16px; min-width: 0; }
.endpoint-head { display: flex; align-items: center; gap: 10px; min-width: 0; }
.endpoint-head code { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.method { display: inline-flex; align-items: center; justify-content: center; min-width: 42px; padding: 5px 7px; border-radius: 7px; background: color-mix(in srgb, var(--green) 12%, var(--surface)); color: var(--green); font-size: 11px; font-weight: 900; letter-spacing: .08em; }
.method-text { background: color-mix(in srgb, var(--blue) 10%, var(--surface)); color: var(--blue); }
.endpoint-card h2 { margin: 22px 0 7px; color: var(--navy); font-size: var(--heading-card); letter-spacing: -.02em; }
.endpoint-card p { margin: 0 0 18px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.endpoint-example { display: grid; margin-top: auto; grid-template-columns: 1fr auto; gap: 10px; align-items: center; padding: 12px; background: var(--surface-soft); border: 1px solid var(--line); border-radius: 10px; min-width: 0; }
.endpoint-example code {
    min-width: 0;
    overflow-x: auto;
    color: var(--text);
    font-size: var(--type-xs);
    white-space: nowrap;
    scrollbar-width: none;
}
.endpoint-example code::-webkit-scrollbar { display: none; }
.endpoint-example button { border: 0; background: transparent; color: var(--blue); cursor: pointer; font-size: var(--type-xs); font-weight: 800; }
.api-notes { margin-top: var(--content-section-gap); padding-top: var(--content-section-gap); border-top: 1px solid var(--line); max-width: 780px; }
.api-notes p { color: var(--muted); line-height: 1.7; }

.api-status-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.api-status-row span { display: inline-flex; align-items: center; min-height: 30px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 750; }
.api-doc-section { margin-top: var(--content-section-gap); padding-top: var(--content-section-gap); border-top: 1px solid var(--line); }
.api-section-heading { max-width: 760px; margin-bottom: 20px; }
.api-section-heading h2 { margin: 8px 0 10px; color: var(--navy); font-size: var(--heading-h2); line-height: 1.1; letter-spacing: -.035em; }
.api-section-heading p { margin: 0; color: var(--muted); font-size: var(--type-body); line-height: 1.7; }
.api-section-heading code, .api-info-grid code, .api-error-table code { font-size: .92em; }
.api-code-grid, .api-contract-grid, .api-info-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.api-code-card, .api-response-card, .api-info-grid article { min-width: 0; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); overflow: hidden; }
.api-code-card, .api-response-card { display: flex; flex-direction: column; }
.api-code-head { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; gap: 12px; min-height: 45px; padding: 11px 14px; border-bottom: 1px solid var(--line); background: var(--surface); }
.api-code-head strong { color: var(--text); font-size: 13px; }
.api-code-head button { border: 0; background: transparent; color: var(--blue); cursor: pointer; font: inherit; font-size: 12px; font-weight: 800; }
.api-code-card pre, .api-response-card pre { flex: 1 1 auto; width: 100%; box-sizing: border-box; margin: 0; padding: 16px; min-height: 170px; overflow: auto; background: var(--surface-soft); color: var(--text); font-size: 12px; line-height: 1.65; tab-size: 2; }
.api-card-body { flex: 1 1 auto; margin: 0; padding: 16px; background: var(--surface-soft); color: var(--muted); font-size: var(--type-body); line-height: 1.65; }
.api-code-card code, .api-response-card code { font-family: ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono",monospace; }
.api-response-card pre { min-height: 250px; }
.api-info-grid article { padding: 18px; }
.api-info-grid strong { display: block; margin-bottom: 7px; color: var(--text); font-size: var(--type-ui); }
.api-info-grid p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.api-error-table-wrap { margin-top: 14px; overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.api-error-table { width: 100%; border-collapse: collapse; min-width: 620px; }
.api-error-table th, .api-error-table td { padding: 13px 15px; border-top: 1px solid var(--line); text-align: left; font-size: 13px; vertical-align: top; }
.api-error-table th { border-top: 0; color: var(--muted); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.api-error-table td { color: var(--muted); }
.api-error-table td:first-child { width: 75px; color: var(--text); font-weight: 800; }
.api-error-table td:nth-child(2) { width: 190px; color: var(--text); }

.error-page { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.error-page h1 { margin: 10px 0; color: var(--navy); font-size: var(--heading-page); letter-spacing: -.05em; }
.error-page p { color: var(--muted); }
.error-actions { display: flex; gap: 10px; margin-top: 18px; }


/* v2.1.1 result polish */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--blue) 32%, transparent);
    outline-offset: 2px;
}

.result-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .07em;
    text-transform: uppercase;
}
.result-toolbar-flush { margin-bottom: 10px; }

.value-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-width: 0;
}
.value-row-top { align-items: flex-start; }
.value-row > strong,
.value-row > code,
.table-value > code {
    min-width: 0;
    flex: 1;
    overflow-wrap: anywhere;
    word-break: normal;
}

.mini-copy {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--blue);
    padding: 6px 8px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}
.mini-copy:hover {
        border-color: color-mix(in srgb, var(--blue) 35%, var(--line));
    background: color-mix(in srgb, var(--blue) 5%, var(--surface));
}
.mini-copy:disabled { cursor: default; opacity: .75; transform: none; }

.table-value {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    min-width: 220px;
}
td code { overflow-wrap: anywhere; word-break: normal; }

.result-meta {
    display: block;
    margin-top: 5px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.35;
}

.rdap-status-card { min-width: 0; }
.status-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 2px;
}
.status-chip {
    display: inline-flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    padding: 7px 9px;
    border: 1px solid color-mix(in srgb, var(--blue) 20%, var(--line));
    border-radius: 999px;
    background: color-mix(in srgb, var(--blue) 5%, var(--surface));
    color: var(--text);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    overflow-wrap: anywhere;
}
.nameserver-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    min-width: 0;
}
.nameserver-list code {
    display: inline-flex;
    margin: 0;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text);
    font-size: 12px;
    overflow-wrap: anywhere;
}

@keyframes mobile-nav-in {
    from { opacity: 0; transform: scale(.985); }
    to { opacity: 1; transform: scale(1); }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
    }
}

@media (max-width: 920px) {
    .hero, .api-card, .about-section { grid-template-columns: 1fr; }
    .hero { padding-top: 58px; }
    .detail-grid { grid-template-columns: repeat(2, 1fr); }
    .tool-grid { grid-template-columns: repeat(2, 1fr); }
    .section-heading { align-items: flex-start; flex-direction: column; gap: 12px; }
    .about-notes { border-left: 0; border-top: 1px solid var(--line); padding: 24px 0 0; }
}

@media (max-width: 640px) {
    .hero { gap: 28px; padding: 44px 0 30px; }
    .hero-copy h1 { white-space: normal; }
    .ip-card { padding: 21px; border-radius: 18px; }
    .ip-card-top { flex-direction: column; }
    .copy-btn { width: 100%; }
    .ip-summary { grid-template-columns: 1fr; gap: 10px; }
    .detail-grid, .tool-grid, .result-grid { grid-template-columns: 1fr; }
    .details-section, .tools-section, .api-section, .about-section { padding: 36px 0; }
    .api-card { padding: 22px; }
    .code-box { grid-template-columns: 1fr; }
    .form-row { flex-direction: column; }
}


@media (max-width: 1050px) {
    .tools-section .tool-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 920px) {
    .tool-guide,
    .tool-doc-extra { grid-template-columns: 1fr; }
    .tool-guide { --tool-guide-gap: 20px; }
    .api-doc-grid, .api-code-grid, .api-contract-grid, .api-info-grid { grid-template-columns: 1fr; }
    .directory-section .tool-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .smart-lookup-row { flex-direction: column; }
    .smart-lookup .btn-primary { width: 100%; }
    .tool-category-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
    .tools-section .tool-grid, .tools-section .tool-category-block:last-child .tool-grid, .directory-section .tool-grid { grid-template-columns: 1fr; }
    .result-grid-three, .asn-hero-result, .rdap-summary { grid-template-columns: 1fr; }
    .api-doc-grid { grid-template-columns: 1fr; }
    .endpoint-example {
        position: relative;
        display: block;
        padding: 14px 68px 14px 12px;
    }
    .endpoint-example code {
        display: block;
        overflow-x: visible;
        white-space: pre-wrap;
        overflow-wrap: anywhere;
        word-break: break-word;
        line-height: 1.55;
    }
    .endpoint-example button {
        position: absolute;
        top: 10px;
        right: 10px;
        padding: 4px 6px;
        border-radius: 7px;
    }
}


@media (max-width: 640px) {
    .result-toolbar { align-items: flex-start; }
    .value-row { align-items: flex-start; }
    .value-row > .mini-copy { margin-top: 3px; }
    .table-value { min-width: 260px; }
    .rdap-summary > div { padding: 17px; }
    .status-chip { border-radius: 9px; }
}

/* v2.1.2 mobile polish - compact, app-like layout without changing desktop */
@media (max-width: 640px) {
    .shell { width: min(100% - 24px, var(--shell-max)); }
    .nav { display: none; }
    .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }

    /* Mobile header is intentionally opaque for stronger separation from page content. */
    .site-header {
        overflow: visible;
        background: var(--surface);
        border-bottom-color: var(--line);
        backdrop-filter: none;
    }
    .header-inner {
        min-height: 60px;
        gap: 6px;
    }
    .brand img { width: 150px; }
    .nav-toggle {
        min-height: 36px;
        border-radius: 9px;
        padding: 8px 10px;
        font-size: 11px;
    }
    .nav-toggle {
        gap: 7px;
        font-size: 12px;
    }
    .nav-toggle::before {
        content: "";
        width: 14px;
        height: 10px;
        flex: 0 0 14px;
        background:
            linear-gradient(currentColor, currentColor) 0 0 / 100% 1.5px no-repeat,
            linear-gradient(currentColor, currentColor) 0 50% / 100% 1.5px no-repeat,
            linear-gradient(currentColor, currentColor) 0 100% / 100% 1.5px no-repeat;
    }
    .nav-toggle[aria-expanded="true"] {
        color: var(--blue);
        border-color: color-mix(in srgb, var(--blue) 34%, var(--line));
        background: color-mix(in srgb, var(--blue) 7%, var(--surface));
    }
    .mobile-nav {
        position: absolute;
        top: calc(100% + 8px);
        right: 12px;
        left: auto;
        width: min(240px, calc(100% - 24px));
        margin: 0;
        padding: 7px;
        display: flex;
        flex-direction: column;
        gap: 2px;
        border: 1px solid var(--line);
        border-radius: 12px;
        background: var(--surface);
        box-shadow: 0 14px 34px rgba(16, 38, 68, .14);
    }
    .mobile-nav:not([hidden]) {
        animation: mobile-nav-in 160ms var(--ease-ui);
    }
    .mobile-nav a {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        min-height: 42px;
        padding: 0 12px;
        border: 0;
        border-radius: 8px;
        background: transparent;
        color: var(--muted);
        font-size: var(--type-ui);
        font-weight: 700;
    }
    .mobile-nav a:hover,
    .mobile-nav a.is-active {
        color: var(--blue);
        background: color-mix(in srgb, var(--blue) 7%, var(--surface));
    }

    /* Hero: still bold, but no longer consumes most of the first screen. */
    .hero {
        gap: 22px;
        padding: 34px 0 28px;
    }
    .hero-copy h1 {
        margin: 9px 0 12px;
        line-height: .97;
    }
    .hero-copy p {
        font-size: 16px;
        line-height: 1.6;
    }
    .smart-lookup {
        margin-top: 24px;
        max-width: none;
    }
    .smart-lookup-row { gap: 8px; }
    .text-input,
    .select-input,
    .textarea-input { padding: 12px 13px; }

    /* Public-IP card: keep the important summary visible in one compact block. */
    .ip-card {
        padding: 18px;
        border-radius: 18px;
    }
    .ip-card-top {
        flex-direction: row;
        align-items: center;
        gap: 12px;
    }
    .ip-card-top > div {
        min-width: 0;
        flex: 1;
    }
    .micro-label { margin-bottom: 5px; }
    .ip-value {
        font-size: clamp(38px, 10.75vw, 46px);
        line-height: 1;
    }
    .copy-btn {
        width: auto;
        padding: 9px 12px;
        font-size: 11px;
    }
    .ip-summary {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-top: 18px;
    }
    .summary-stat {
        padding: 11px 10px;
        border-radius: 12px;
    }
    .summary-stat span,
    .hostname-row span,
    .detail-card > span {
        margin-bottom: 4px;
        font-size: 11px;
    }
    .summary-stat strong { font-size: 15px; }
    .hostname-row {
        margin-top: 10px;
        padding: 12px 13px;
        border-radius: 12px;
    }
    .hostname-row strong {
        font-size: 12px;
        line-height: 1.45;
    }

    /* Four network facts work much better as a 2x2 dashboard on phones. */
    .detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }
    .detail-card {
        min-height: 0;
        padding: 15px;
        border-radius: 14px;
    }
    .detail-card strong {
        margin-top: 9px;
        font-size: 16px;
    }
    .detail-card small {
        margin-top: 5px;
        font-size: 11px;
    }

    /* Reduce accumulated vertical space across the long homepage. */
    .details-section,
    .tools-section,
    .api-section,
    .about-section {
        padding: 30px 0;
    }
    .tools-section { padding-top: 38px; }
    .section-heading { margin-bottom: 18px; }
    .section-heading h2,
    .api-card h2,
    .about-copy h2 {
    }
    .section-heading > p { font-size: 13px; }

    /* Tool cards remain one-column, but stop feeling like desktop cards stacked
       on top of each other. */
    .tool-category-block { margin-top: 30px; }
    .tool-category-block:first-of-type { margin-top: 0; }
    .tool-grid { gap: 10px; }
    .tool-card {
        min-height: 0;
        padding: 16px;
        border-radius: 14px;
    }
    .tool-card h3 {
        margin: 19px 0 5px;
    }
    .tool-card p {
        margin-bottom: 14px;
        font-size: 13px;
        line-height: 1.5;
    }
    .tool-card-top { min-height: 18px; }
    .tool-category-heading { margin-bottom: 10px; }

    .api-card {
        gap: 20px;
        padding: 19px;
        border-radius: 18px;
    }
    .api-card p { font-size: 13px; }
    .code-box { padding: 12px; }

    .about-section {
        gap: 26px;
        padding-bottom: 50px;
    }
    .about-copy p { font-size: 14px; }
    .about-notes { padding-top: 18px; }
    .about-notes p { font-size: 13px; }

    /* Tool pages get the same compact treatment as the homepage. */
    .tool-page { padding: 42px 0 62px; }
    .tool-page-header { margin-bottom: 22px; }
    .tool-page-header h1 {
        line-height: 1.02;
    }
    .tool-page-header p { font-size: 15px; }
    .tool-panel {
        padding: 18px;
        border-radius: 16px;
    }
    .tool-guide {
        margin-top: 40px;
        padding-top: 32px;
    }
    .related-tools { margin-top: 36px; }

}

/* Tiny phones still get a readable layout without crushing cards. */
@media (max-width: 360px) {
    :root { --heading-hero: 40px; }
    .nav-toggle { padding-inline: 8px; }
    .ip-card-top { align-items: flex-start; }
    .ip-value { font-size: 36px; }
    .copy-btn { padding: 8px 9px; }
    .detail-grid { grid-template-columns: 1fr; }
    .summary-stat { padding-inline: 8px; }
    .summary-stat strong { font-size: 14px; }
}


/* v2.2 domain, mail and TLS tools */
.check-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}
.check-summary-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.check-summary > div {
    min-width: 0;
    padding: 18px;
    border: 1px solid color-mix(in srgb, var(--blue) 18%, var(--line));
    border-radius: 14px;
    background: color-mix(in srgb, var(--blue) 5%, var(--surface));
}
.check-summary span {
    display: block;
    margin-bottom: 6px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.check-summary strong {
    display: block;
    color: var(--navy);
    font-size: 20px;
    line-height: 1.25;
    overflow-wrap: anywhere;
}
.check-summary small {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.45;
}
.health-text.health-good { color: var(--green); }
.health-text.health-warn { color: #a86600; }
.health-text.health-bad { color: #c0392b; }
html[data-theme="dark"] .health-text.health-warn { color: #f2b84b; }
html[data-theme="dark"] .health-text.health-bad { color: #ff8f82; }

.alert-warn {
    background: color-mix(in srgb, #d79000 9%, var(--surface));
    border-color: color-mix(in srgb, #d79000 30%, var(--line));
}

.record-stack { display: grid; gap: 9px; margin-top: 12px; }
.record-line {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    min-width: 0;
    padding: 13px 14px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--bg);
}
.record-line-primary { margin-bottom: 14px; }
.record-line code {
    min-width: 0;
    flex: 1;
    color: var(--text);
    font-size: 12px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.term-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}
.term-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    max-width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-soft);
    color: var(--muted);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 11px;
    line-height: 1.2;
    overflow-wrap: anywhere;
}
.term-chip b {
    color: var(--blue);
    font-family: Inter, ui-sans-serif, system-ui, sans-serif;
    font-size: 11px;
    letter-spacing: .06em;
}

.resolver-consensus {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 14px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
}
.resolver-consensus strong { color: var(--text); font-size: 13px; }
.resolver-consensus span { color: var(--muted); font-size: var(--type-xs); line-height: 1.45; }
.health-panel-good {
    background: color-mix(in srgb, var(--green) 7%, var(--surface));
    border-color: color-mix(in srgb, var(--green) 28%, var(--line));
}
.health-panel-warn {
    background: color-mix(in srgb, #d79000 7%, var(--surface));
    border-color: color-mix(in srgb, #d79000 28%, var(--line));
}

.resolver-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.resolver-card {
    min-width: 0;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--bg);
}
.resolver-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 13px;
}
.resolver-head span:first-child {
    display: block;
    color: var(--text);
    font-size: 13px;
    font-weight: 800;
}
.resolver-head code {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 11px;
}
.health-dot {
    flex: 0 0 auto;
    width: 9px;
    height: 9px;
    margin-top: 4px;
    border-radius: 50%;
}
.health-dot-good { background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 10%, transparent); }
.health-dot-bad { background: #c0392b; box-shadow: 0 0 0 4px color-mix(in srgb, #c0392b 10%, transparent); }
.resolver-values { display: flex; flex-wrap: wrap; gap: 6px; }
.resolver-values code {
    max-width: 100%;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text);
    font-size: 11px;
    overflow-wrap: anywhere;
}
.resolver-card > small {
    display: block;
    margin-top: 11px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}
.resolver-error, .resolver-empty {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}
.resolver-error { color: #b14a3c; }
html[data-theme="dark"] .resolver-error { color: #ff9e92; }

@media (max-width: 640px) {
    .check-summary,
    .check-summary-two,
    .resolver-grid { grid-template-columns: 1fr; }
    .check-summary > div { padding: 15px; }
    .check-summary strong { font-size: 18px; }
    .resolver-consensus { align-items: flex-start; flex-direction: column; gap: 5px; }
    .record-line { padding: 11px 12px; }
    .term-chip { width: 100%; }
}

/* v2.2.1 SSL result polish */
.ssl-san-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 3px 0 10px;
}
.ssl-san-header .result-meta { margin-top: 0; }
.san-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 7px;
}
.ssl-san-list [data-san-extra][hidden] { display: none !important; }

@media (max-width: 620px) {
    .ssl-san-header { align-items: flex-start; }
    .san-actions { flex: 0 0 auto; }
}

@media (max-width: 420px) {
    .ssl-san-header { display: grid; grid-template-columns: 1fr; }
    .san-actions { justify-content: flex-start; }
}

/* v2.3 web, DNS security and IP utilities */
.final-url-card { margin-bottom: 14px; }
.redirect-alert { margin: 14px 0; }
.redirect-chain {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.redirect-hop {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--bg);
}
.hop-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: color-mix(in srgb, var(--blue) 10%, var(--surface));
    color: var(--blue);
    font-size: 11px;
    font-weight: 900;
}
.hop-main { min-width: 0; }
.hop-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}
.hop-head small,
.hop-meta { color: var(--muted); font-size: 12px; }
.hop-main > code {
    display: block;
    color: var(--text);
    font-size: 12px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
.hop-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px 14px;
    margin-top: 8px;
    line-height: 1.45;
}
.status-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 850;
}
.status-good { color: var(--green); background: color-mix(in srgb, var(--green) 7%, var(--surface)); border-color: color-mix(in srgb, var(--green) 25%, var(--line)); }
.status-warn { color: #a86600; background: color-mix(in srgb, #d79000 7%, var(--surface)); border-color: color-mix(in srgb, #d79000 25%, var(--line)); }
.status-bad { color: #c0392b; background: color-mix(in srgb, #c0392b 7%, var(--surface)); border-color: color-mix(in srgb, #c0392b 25%, var(--line)); }
html[data-theme="dark"] .status-warn { color: #f2b84b; }
html[data-theme="dark"] .status-bad { color: #ff8f82; }

.dnssec-section { margin-top: 16px; }
.dnssec-record-copy { min-width: 0; flex: 1; }
.dnssec-record-copy strong { display: block; color: var(--text); font-size: 13px; }
.dnssec-record-copy small { display: block; margin: 4px 0 8px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.dnssec-record-copy code { display: block; max-width: 100%; color: var(--text); font-size: 11px; line-height: 1.5; overflow-wrap: anywhere; }

.caa-main { min-width: 0; flex: 1; }
.caa-main .term-chip { width: fit-content; margin: 0; }
.caa-main small { display: block; margin-top: 7px; color: var(--muted); font-size: 12px; line-height: 1.45; }

.port-number-input { flex: 0 0 130px; max-width: 130px; }

.cidr-blocks-card { margin-top: 14px; }
.cidr-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 5px 0 10px;
}
.cidr-header .result-meta { margin: 0; }
.cidr-list code { font-size: 11px; }

@media (max-width: 640px) {
    .redirect-hop { grid-template-columns: 30px minmax(0, 1fr); padding: 12px; gap: 10px; }
    .hop-head { align-items: flex-start; }
    .hop-meta { display: grid; gap: 4px; }
    .dnssec-record { align-items: flex-start; }
    .port-number-input { flex: 1 1 auto; max-width: none; width: 100%; }
    .cidr-header { align-items: flex-start; }
}

@media (max-width: 420px) {
    .dnssec-record,
    .caa-record { flex-direction: column; }
    .cidr-header { display: grid; grid-template-columns: 1fr; }
    .cidr-header .mini-copy { width: fit-content; }
}

/* v2.4 tool discovery, web security and mail diagnostics */
.tool-directory-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: end;
    margin: -4px 0 34px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    box-shadow: var(--shadow-soft);
}
.tool-directory-search label {
    display: block;
    margin: 0 0 7px;
    color: var(--text);
    font-size: 12px;
    font-weight: 800;
}
.tool-directory-search .text-input {
    width: 100%;
    height: 48px;
    padding-block: 0;
}
.tool-count {
    display: inline-flex;
    align-items: center;
    height: 48px;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-soft);
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}
.directory-no-results { margin: -16px 0 30px; }
.tool-card[hidden], .directory-section[hidden] { display: none !important; }

.security-header-stack { margin-top: 14px; }
.security-header-row { align-items: flex-start; }
.security-header-main { flex: 1; min-width: 0; }
.security-header-title {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 7px;
}
.security-header-title strong { color: var(--text); font-size: 13px; }
.security-header-main code {
    display: block;
    max-width: 100%;
    margin: 4px 0 7px;
    color: var(--text);
    font-size: 11px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
.security-header-main small { display: block; color: var(--muted); font-size: 12px; line-height: 1.55; }
.status-neutral { color: var(--muted); background: var(--surface-soft); }
.disclosure-note code { overflow-wrap: anywhere; }

.robots-sitemaps { margin-top: 14px; }
.chip-list { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 8px; }
.chip-list code {
    max-width: 100%;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface);
    color: var(--text);
    font-size: 11px;
    overflow-wrap: anywhere;
}
.robots-source-card { margin-top: 14px; }
.source-preview {
    max-height: 440px;
    margin: 14px 0 0;
    padding: 15px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--bg);
    white-space: pre-wrap;
    word-break: break-word;
}
.source-preview code { color: var(--text); font-size: var(--type-xs); line-height: 1.55; }

.sitemap-sample { margin-top: 14px; }
.sitemap-entry-main { min-width: 0; flex: 1; }
.sitemap-entry-main code { display: block; color: var(--text); font-size: var(--type-xs); overflow-wrap: anywhere; }
.sitemap-entry-main small { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; line-height: 1.45; }

.dkim-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 300px) auto;
    gap: 10px;
    align-items: end;
}
.dkim-field { min-width: 0; }
.dkim-field label {
    display: block;
    margin: 0 0 7px;
    color: var(--text);
    font-size: 11px;
    font-weight: 800;
}
.dkim-submit { min-height: 44px; }
.form-help {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.55;
}
.form-help code { color: var(--text); font-size: .95em; }
.form-help a { color: var(--blue); font-weight: 800; }

.mta-result-box > .result-item + .result-grid,
.mta-result-box > .result-grid + .result-item {
    margin-top: 12px;
}


.email-header-form > label {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 12px;
    font-weight: 800;
}
.header-textarea {
    width: 100%;
    min-height: 220px;
    resize: vertical;
    padding: 15px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--bg);
    color: var(--text);
    font: 12px/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    outline: none;
}
.header-textarea:focus { border-color: color-mix(in srgb, var(--blue) 55%, var(--line)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 10%, transparent); }
.textarea-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 12px;
}
.textarea-actions small { max-width: 650px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.email-meta-grid { margin-top: 14px; }
.header-analysis-section { margin-top: 18px; }
.email-route { display: grid; gap: 9px; }
.email-hop {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--bg);
}
.email-route-main { flex: 1; min-width: 0; }
.email-route-main strong { display: block; color: var(--text); font-size: 13px; }
.email-route-main code { display: block; color: var(--text); font-size: 12px; line-height: 1.55; overflow-wrap: anywhere; }
.email-route-main small { display: block; margin-top: 6px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.mini-link { text-decoration: none; }

.featured-tools-block {
    padding: 20px;
    border: 1px solid color-mix(in srgb, var(--blue) 18%, var(--line));
    border-radius: 18px;
    background: color-mix(in srgb, var(--blue) 3%, var(--surface));
}

@media (max-width: 760px) {
    .dkim-form { grid-template-columns: 1fr; }
    .dkim-submit { width: 100%; }
}

@media (max-width: 640px) {
    .security-header-row, .sitemap-entry { align-items: flex-start; }
    .textarea-actions { align-items: stretch; flex-direction: column; }
    .textarea-actions .btn-primary { width: 100%; }
    .email-hop { grid-template-columns: 30px minmax(0, 1fr); gap: 10px; }
    .featured-tools-block { padding: 14px; }
}

@media (max-width: 420px) {
    .security-header-row, .sitemap-entry { flex-direction: column; }
    .security-header-title { align-items: flex-start; }
}

/* v2.5 discovery, breadcrumbs and changelog */
.breadcrumb-shell {
    padding-top: 18px;
}
.breadcrumbs {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.4;
}
.breadcrumbs a {
    color: var(--muted);
    text-decoration: none;
    font-weight: 700;
}
.breadcrumbs a:hover { color: var(--blue); }
.breadcrumbs [aria-current="page"] {
    color: var(--text);
    font-weight: 750;
}
.breadcrumb-separator { opacity: .55; }


.home-discovery { padding-top: 10px; padding-bottom: 8px; }
.compact-heading { margin-bottom: 16px; }
.quick-pick-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}
.quick-pick {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas:
        "tag title"
        "tag copy";
    column-gap: 11px;
    row-gap: 3px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    box-shadow: var(--shadow-soft);
}
.quick-pick:hover {
        border-color: color-mix(in srgb, var(--blue) 28%, var(--line));
    box-shadow: var(--shadow);
    background: color-mix(in srgb, var(--surface) 97%, var(--blue) 3%);
}
.quick-pick > span {
    grid-area: tag;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    min-height: 38px;
    padding: 0 8px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--blue) 8%, var(--surface-soft));
    color: var(--blue);
    font-size: 11px;
    font-weight: 900;
}
.quick-pick strong { grid-area: title; font-size: 13px; }
.quick-pick small { grid-area: copy; color: var(--muted); font-size: 12px; line-height: 1.4; }

.release-section { padding-top: 12px; padding-bottom: 18px; }
.release-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    align-items: center;
    padding: 24px;
    border: 1px solid color-mix(in srgb, var(--blue) 20%, var(--line));
    border-radius: 18px;
    background: linear-gradient(135deg, color-mix(in srgb, var(--blue) 5%, var(--surface)), var(--surface));
    box-shadow: var(--shadow-soft);
}
.release-card h2 { margin: 5px 0 8px; max-width: 760px; }
.release-card p { max-width: 790px; margin: 0; color: var(--muted); line-height: 1.6; }
.release-actions { display: flex; gap: 9px; flex-wrap: wrap; justify-content: flex-end; }
.release-actions a { text-decoration: none; white-space: nowrap; }

.directory-quick-picks {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: -4px 0 16px;
}
.directory-quick-picks > span {
    margin-right: 2px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.directory-quick-picks a,
.filter-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 11px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text);
    font-size: 12px;
    font-weight: 750;
    text-decoration: none;
}
.directory-quick-picks a:hover,
.filter-chip:hover,
.filter-chip.is-active {
    border-color: color-mix(in srgb, var(--blue) 30%, var(--line));
    background: color-mix(in srgb, var(--blue) 7%, var(--surface));
    color: var(--blue);
}
.filter-chip { cursor: pointer; }
.tool-filter-chips {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    padding-top: 2px;
}

.directory-recent {
    margin: -4px 0 34px;
    padding: 18px;
    border: 1px solid color-mix(in srgb, var(--blue) 16%, var(--line));
    border-radius: 16px;
    background: color-mix(in srgb, var(--blue) 3%, var(--surface));
}
.directory-recent .tool-category-heading { margin-bottom: 12px; }
.recent-tool-links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}
.recent-tool-links a {
    display: flex;
    align-items: center;
    gap: 9px;
    min-width: 0;
    padding: 11px 12px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
}
.recent-tool-links a:hover { border-color: color-mix(in srgb, var(--blue) 28%, var(--line)); }
.recent-tool-links span {
    flex: 0 0 auto;
    color: var(--blue);
    font-size: 11px;
    font-weight: 900;
}
.recent-tool-links strong {
    min-width: 0;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.changelog-page { padding-top: 34px; }
.release-timeline { display: grid; gap: 14px; }
.release-entry {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 22px;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    box-shadow: var(--shadow-soft);
}
.release-current { border-color: color-mix(in srgb, var(--blue) 30%, var(--line)); }
.release-version {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
}
.release-version > span {
    display: inline-flex;
    padding: 5px 8px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--green) 10%, var(--surface));
    color: var(--green);
    font-size: 11px;
    font-weight: 900;
}
.release-version strong { font-size: 26px; letter-spacing: -0.03em; }
.release-version small { color: var(--muted); font-size: 12px; }
.release-copy-block h2 { margin: 0 0 8px; font-size: 20px; }
.release-copy-block > p { margin: 0; color: var(--muted); line-height: 1.6; }
.release-copy-block ul { margin: 14px 0 0; padding-left: 20px; color: var(--muted); }
.release-copy-block li { margin: 6px 0; line-height: 1.5; }
.release-links,
.release-link-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.release-links a,
.release-link-grid a {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface-soft);
    color: var(--blue);
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
}
.release-links a:hover,
.release-link-grid a:hover { border-color: color-mix(in srgb, var(--blue) 30%, var(--line)); }

@media (max-width: 900px) {
    .quick-pick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .recent-tool-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .release-card { grid-template-columns: 1fr; gap: 18px; }
    .release-actions { justify-content: flex-start; }
}

@media (max-width: 640px) {
    .breadcrumb-shell { padding-top: 12px; }
    .breadcrumbs { font-size: 11px; }
    .quick-pick-grid { grid-template-columns: 1fr; }
    .quick-pick { padding: 12px; }
    .release-card { padding: 18px; }
    .release-actions { display: grid; grid-template-columns: 1fr 1fr; }
    .tools-directory {
        display: flex;
        flex-direction: column;
    }
    .tools-directory > .tool-page-header { order: 0; }
    .tools-directory > .directory-alert { order: 1; }
    .tools-directory > .tool-directory-search {
        order: 2;
        margin: 0 0 14px;
        padding: 14px;
        gap: 10px;
    }
    .tools-directory > .directory-quick-picks {
        order: 3;
        flex-wrap: nowrap;
        gap: 6px;
        margin: 0 0 4px;
        padding: 0 0 4px;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        scrollbar-width: none;
    }
    .tools-directory > .directory-quick-picks::-webkit-scrollbar,
    .tool-filter-chips::-webkit-scrollbar { display: none; }
    .directory-quick-picks > span {
        width: auto;
        flex: 0 0 auto;
    }
    .directory-quick-picks a,
    .filter-chip { flex: 0 0 auto; }
    .tools-directory > .directory-no-results { order: 4; }
    .tools-directory > .directory-section {
        order: 5;
        margin-top: 30px;
    }
    .tools-directory > .directory-recent {
        order: 6;
        padding: 14px;
        margin: 32px 0 0;
    }
    .tool-filter-chips {
        flex-wrap: nowrap;
        gap: 6px;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        scrollbar-width: none;
    }
    .recent-tool-links { grid-template-columns: 1fr; }
    .release-entry { grid-template-columns: 1fr; gap: 12px; padding: 17px; }
    .release-version { flex-direction: row; align-items: center; flex-wrap: wrap; }
    .release-version strong { font-size: 22px; }
}

@media (max-width: 420px) {
    .release-actions { grid-template-columns: 1fr; }
    .release-actions a { width: 100%; }
    .directory-quick-picks a,
    .filter-chip { min-height: 32px; padding: 0 10px; }
}

/* v2.5.1 homepage refinement */
.home-toolbox { padding-top: 54px; }
.homepage-recent {
    margin-top: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}
.home-recent-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.home-recent-grid .tool-card { min-height: 196px; }
.home-category-browser { margin-top: 34px; }
.category-overview-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}
.category-overview-card {
    display: flex;
    min-width: 0;
    min-height: 170px;
    flex-direction: column;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    box-shadow: var(--shadow-soft);
   
}
.category-overview-card:hover {
        border-color: color-mix(in srgb, var(--blue) 28%, var(--line));
    box-shadow: var(--shadow);
    background: color-mix(in srgb, var(--surface) 97%, var(--blue) 3%);
}
.category-overview-tag {
    width: fit-content;
    margin-bottom: 18px;
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
}
.category-overview-card strong {
    color: var(--navy);
    font-size: 17px;
    line-height: 1.25;
}
.category-overview-card small {
    margin-top: 7px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}
.category-overview-link {
    margin-top: auto;
    padding-top: 14px;
    color: var(--blue);
    font-size: 12px;
    font-weight: 800;
}

@media (max-width: 960px) {
    .category-overview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
    .home-toolbox { padding-top: 38px; }
    .home-recent-grid { grid-template-columns: 1fr !important; }
    .home-recent-grid .tool-card { min-height: 0; }
    .category-overview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
    .category-overview-grid { grid-template-columns: 1fr; }
    .category-overview-card { min-height: 0; }
    .category-overview-tag { margin-bottom: 12px; }
}

/* v2.6 browser terminal and embeds */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.terminal-page-header { max-width: 860px; }
.terminal-shell {
    --terminal-bg: #07111f;
    --terminal-panel: #0b1727;
    --terminal-line: #1d3048;
    --terminal-text: #d9e7f8;
    --terminal-muted: #8194aa;
    --terminal-accent: #63aef6;
    --terminal-green: #62d89d;
    --terminal-red: #ff8c80;
    overflow: hidden;
    border: 1px solid var(--terminal-line);
    border-radius: 20px;
    background: var(--terminal-bg);
    box-shadow: 0 22px 60px rgba(0, 0, 0, .18);
    color: var(--terminal-text);
}
html[data-theme="light"] .terminal-shell {
    --terminal-bg: #f7faff;
    --terminal-panel: #edf3fa;
    --terminal-line: #cfdbea;
    --terminal-text: #162236;
    --terminal-muted: #65778c;
    --terminal-accent: #086bd8;
    --terminal-green: #128557;
    --terminal-red: #bd4034;
    box-shadow: 0 22px 60px rgba(25, 43, 66, .12);
}
.terminal-topbar {
    min-height: 52px;
    display: grid;
    grid-template-columns: 90px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    border-bottom: 1px solid var(--terminal-line);
    background: var(--terminal-panel);
}
.terminal-lights { display: flex; gap: 7px; }
.terminal-lights span { width: 10px; height: 10px; border-radius: 50%; background: #ff675e; }
.terminal-lights span:nth-child(2) { background: #f4bc45; }
.terminal-lights span:nth-child(3) { background: #4ecb71; }
.terminal-title { min-width: 0; text-align: center; line-height: 1.1; }
.terminal-title strong { display: block; color: var(--terminal-text); font-size: 13px; letter-spacing: .02em; }
.terminal-title span { display: block; margin-top: 4px; color: var(--terminal-muted); font-size: 12px; }
.terminal-top-actions { display: flex; justify-content: flex-end; gap: 5px; }
.terminal-text-btn {
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--terminal-muted);
    padding: 6px 8px;
    cursor: pointer;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 12px;
}
.terminal-text-btn:hover { color: var(--terminal-text); background: color-mix(in srgb, var(--terminal-accent) 10%, transparent); }
.terminal-output {
    height: 430px;
    overflow: auto;
    padding: 20px;
    background: var(--terminal-bg);
    overscroll-behavior: contain;
    scrollbar-color: color-mix(in srgb, var(--terminal-muted) 45%, transparent) transparent;
}
.terminal-row {
    min-height: 1.5em;
    color: var(--terminal-text);
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 14px;
    line-height: 1.62;
}
.terminal-row + .terminal-row { margin-top: 1px; }
.terminal-row-command { display: flex; gap: 9px; margin-top: 9px; color: var(--terminal-text); }
.terminal-command-prompt { flex: 0 0 auto; color: var(--terminal-green); font-weight: 850; }
.terminal-row-brand { color: var(--terminal-accent); font-weight: 850; }
.terminal-row-muted { color: var(--terminal-muted); }
.terminal-row-error { color: var(--terminal-red); }
.terminal-row-heading { margin-top: 8px; color: var(--terminal-accent); font-weight: 800; }
.terminal-row-links { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 8px; }
.terminal-row-links a { color: var(--terminal-accent); font-size: 13px; font-weight: 750; }
.terminal-row-links a:hover { text-decoration: underline; }
.terminal-input-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-top: 1px solid var(--terminal-line);
    background: var(--terminal-panel);
}
.terminal-prompt {
    color: var(--terminal-green);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 14px;
    font-weight: 900;
}
.terminal-input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--terminal-text);
    caret-color: var(--terminal-green);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 14px;
}
.terminal-input::placeholder { color: color-mix(in srgb, var(--terminal-muted) 75%, transparent); }
.terminal-run {
    border: 1px solid color-mix(in srgb, var(--terminal-accent) 40%, var(--terminal-line));
    border-radius: 8px;
    background: color-mix(in srgb, var(--terminal-accent) 12%, transparent);
    color: var(--terminal-accent);
    padding: 7px 11px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 850;
}
.terminal-run:hover { background: color-mix(in srgb, var(--terminal-accent) 18%, transparent); }
.terminal-branding {
    padding: 8px 14px 10px;
    border-top: 1px solid var(--terminal-line);
    background: var(--terminal-panel);
    color: var(--terminal-muted);
    text-align: right;
    font-size: 12px;
}
.terminal-branding a { color: var(--terminal-accent); font-weight: 800; }
.terminal-example-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}
.terminal-example-bar button {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--muted);
    padding: 7px 10px;
    cursor: pointer;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 12px;
}
.terminal-example-bar button:hover { color: var(--blue); border-color: color-mix(in srgb, var(--blue) 35%, var(--line)); }
.terminal-command-guide { margin-top: 58px; }
.terminal-command-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.terminal-command-grid article {
    display: flex;
    flex-wrap: wrap;
    align-content: flex-start;
    gap: 7px;
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
}
.terminal-command-grid article > span { width: 100%; margin-bottom: 5px; color: var(--navy); font-size: 14px; font-weight: 850; }
.terminal-command-grid code {
    max-width: 100%;
    padding: 6px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-soft);
    color: var(--muted);
    font-size: 12px;
    overflow-wrap: anywhere;
}
.embed-callout {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 30px;
    align-items: center;
    margin-top: 44px;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: color-mix(in srgb, var(--blue) 4%, var(--surface));
}
.embed-callout h2 { margin: 7px 0 7px; color: var(--navy); font-size: 28px; letter-spacing: -.03em; }
.embed-callout p { max-width: 720px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; }

/* Homepage terminal teaser */
.terminal-feature {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 46px;
    align-items: center;
    padding: 54px 0;
}
.terminal-feature-copy h2 { margin: 8px 0 10px; color: var(--navy); font-size: clamp(30px, 4vw, 44px); line-height: 1.06; letter-spacing: -.04em; }
.terminal-feature-copy p { max-width: 560px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.7; }
.terminal-feature-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 20px; }
.terminal-mini-preview {
    overflow: hidden;
    padding: 0 20px 20px;
    border: 1px solid #1d3048;
    border-radius: 18px;
    background: #07111f;
    box-shadow: 0 18px 48px rgba(5, 14, 26, .18);
}
.terminal-mini-top {
    display: flex;
    align-items: center;
    gap: 7px;
    height: 46px;
    margin: 0 -20px 15px;
    padding: 0 16px;
    border-bottom: 1px solid #1d3048;
    background: #0b1727;
}
.terminal-mini-top span { width: 9px; height: 9px; border-radius: 50%; background: #ff675e; }
.terminal-mini-top span:nth-child(2) { background: #f4bc45; }
.terminal-mini-top span:nth-child(3) { background: #4ecb71; }
.terminal-mini-top strong { margin-left: 8px; color: #9fb0c4; font-size: 12px; }
.terminal-mini-preview code { display: block; color: #d9e7f8; font-size: 13px; line-height: 1.75; overflow-wrap: anywhere; }
.terminal-mini-preview code b { color: #62d89d; }
.terminal-mini-preview .terminal-mini-next { margin-top: 7px; color: #8194aa; }

/* Embed builder */
.embed-builder-layout {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}
.embed-controls { display: grid; gap: 18px; box-shadow: none; }
.embed-control label,
.embed-toggle { color: var(--text); font-size: 12px; font-weight: 800; }
.embed-control label { display: block; margin-bottom: 7px; }
.embed-control small { display: block; margin-top: 6px; color: var(--muted); font-size: var(--type-xs); line-height: 1.5; }
.embed-range-row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; }
.embed-range-row input[type="range"] { width: 100%; accent-color: var(--blue); }
.embed-range-row output { min-width: 52px; color: var(--muted); font-size: 12px; font-weight: 800; }
.embed-toggle { display: flex; align-items: center; gap: 9px; cursor: pointer; }
.embed-toggle input { accent-color: var(--blue); width: 17px; height: 17px; }
.embed-note { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-soft); }
.embed-note strong { display: block; color: var(--text); font-size: 12px; }
.embed-note p { margin: 5px 0 0; color: var(--muted); font-size: var(--type-xs); line-height: 1.55; }
.embed-preview-column { min-width: 0; }
.embed-preview-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 2px 8px; color: var(--muted); font-size: var(--type-xs); font-weight: 800; }
.embed-preview-head a { color: var(--blue); }
.embed-preview-frame { display: block; width: 100%; height: 520px; border: 0; border-radius: 20px; background: #07111f; box-shadow: var(--shadow); }
.embed-code-card {
    margin-top: 28px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--surface);
}
.embed-code-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.embed-code-head h2 { margin: 5px 0 0; color: var(--navy); font-size: 28px; letter-spacing: -.03em; }
.embed-code-card pre {
    overflow: auto;
    margin: 0;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-soft);
}
.embed-code-card pre code { color: var(--text); font-size: 12px; white-space: pre-wrap; overflow-wrap: anywhere; }
.embed-code-card > p { margin: 12px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.embed-code-card > p code { color: var(--text); }
.embed-options-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 18px; }
.embed-options-grid article { padding: 17px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.embed-options-grid span { display: block; color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace; font-size: 11px; font-weight: 800; }
.embed-options-grid strong { display: block; margin-top: 7px; color: var(--text); font-size: 13px; }
.embed-options-grid p { margin: 6px 0 0; color: var(--muted); font-size: var(--type-xs); line-height: 1.5; }

/* The iframe version owns the full viewport and intentionally drops the site chrome. */
.terminal-embed-page { min-height: 100vh; padding: 0; background: transparent; }
.terminal-embed-page .terminal-shell-embed { min-height: 100vh; border-radius: 0; border: 0; box-shadow: none; }
.terminal-embed-page .terminal-output { height: calc(100vh - 103px - var(--terminal-branding-height, 0px)); min-height: 220px; }
.terminal-embed-page .terminal-shell-embed:has(.terminal-branding) { --terminal-branding-height: 34px; }

@media (max-width: 860px) {
    .terminal-feature { grid-template-columns: 1fr; gap: 24px; }
    .embed-builder-layout { grid-template-columns: 1fr; }
    .embed-controls { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .embed-note { grid-column: 1 / -1; }
    .embed-options-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
    .terminal-output { height: 390px; padding: 16px; }
    .terminal-topbar { grid-template-columns: 62px 1fr auto; padding-inline: 12px; }
    .terminal-title span { display: none; }
    .terminal-command-grid { grid-template-columns: 1fr; }
    .embed-callout { grid-template-columns: 1fr; gap: 18px; padding: 20px; }
    .terminal-feature { padding: 38px 0; }
    .embed-controls { grid-template-columns: 1fr; }
    .embed-code-head { align-items: flex-start; flex-direction: column; }
    .embed-options-grid { grid-template-columns: 1fr; }
}

@media (max-width: 430px) {
    .terminal-topbar { grid-template-columns: 52px 1fr auto; gap: 5px; }
    .terminal-lights { gap: 5px; }
    .terminal-lights span { width: 8px; height: 8px; }
    .terminal-text-btn { padding: 5px; }
    .terminal-output { height: 360px; padding: 14px 12px; }
    .terminal-row { font-size: 12px; }
    .terminal-input-row { grid-template-columns: auto minmax(0, 1fr); }
    .terminal-run { display: none; }
    .terminal-example-bar { display: grid; grid-template-columns: 1fr; }
    .terminal-example-bar button { text-align: left; }
    .terminal-mini-preview { padding-inline: 14px; }
    .terminal-mini-top { margin-inline: -14px; }
}

/* v2.6.1 terminal/embed alignment polish */
.embed-builder-layout { align-items: stretch; }
.embed-builder-stack { min-width: 0; display: flex; flex-direction: column; }
.embed-column-head,
.embed-preview-head {
    min-height: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 2px 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.embed-preview-head { margin-inline: 2px; }
.embed-controls { flex: 1 1 auto; align-content: start; }
.embed-control label,
.embed-toggle { font-size: 13px; }
.embed-control small { font-size: 12px; line-height: 1.5; }
.embed-range-row output { font-size: 13px; }
.embed-preview-frame { flex: 0 0 auto; }
.embed-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}
.embed-note { padding: 16px; }
.embed-note strong { font-size: 13px; }
.embed-note p { font-size: 12px; line-height: 1.6; }
.embed-code-card pre code { font-size: 13px; line-height: 1.55; }
.embed-code-card > p { font-size: 13px; line-height: 1.65; }
.embed-options-grid span { font-size: 12px; }
.embed-options-grid strong { font-size: 14px; }
.embed-options-grid p { font-size: 12px; line-height: 1.6; }

/* Make the iframe terminal fit its viewport exactly instead of relying on a brittle height calculation. */
html:has(body.terminal-embed-page),
body.terminal-embed-page { height: 100%; min-height: 0; overflow: hidden; }
.terminal-embed-page .terminal-shell-embed {
    height: 100dvh;
    min-height: 0;
    display: flex;
    flex-direction: column;
}
.terminal-embed-page .terminal-topbar,
.terminal-embed-page .terminal-input-row,
.terminal-embed-page .terminal-branding { flex: 0 0 auto; }
.terminal-embed-page .terminal-output {
    flex: 1 1 auto;
    height: auto;
    min-height: 0;
}

@media (max-width: 860px) {
    .embed-builder-stack { min-width: 0; }
    .embed-info-grid { grid-template-columns: 1fr; }
}

@media (max-width: 430px) {
    .terminal-row { font-size: 13px; }
    .terminal-title strong { font-size: 12px; }
    .embed-column-head,
    .embed-preview-head { font-size: 12px; }
}


/* v2.6.2 terminal embed consistency and smooth resize */
/* The terminal itself owns the visible frame everywhere it is embedded. */
.embed-preview-frame {
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}

html:has(body.terminal-embed-page),
body.terminal-embed-page {
    height: 100%;
    min-height: 0;
    overflow: hidden;
    background: transparent;
}

body.terminal-embed-page {
    padding: 0;
}

.terminal-embed-page .terminal-shell-embed {
    width: 100%;
    height: 100%;
    min-height: 0;
    margin: 0;
    border: 0;
    border-radius: 0;
    background: var(--terminal-bg);
    box-shadow: none;
    overflow: hidden;
}

/* Keep the embedded frame visible on both very light and very dark host pages. */
html[data-theme="light"] .terminal-shell-embed {
    --terminal-line: #c8d5e5;
}
html[data-theme="dark"] .terminal-shell-embed {
    --terminal-line: #29405c;
}

/* v2.6.3 homepage terminal spotlight */

/* The Terminal is a signature IPGetter feature, so surface it early and give it
   a distinct showcase treatment instead of making it look like another tool card. */
.terminal-feature {
    margin-top: 18px;
    margin-bottom: 24px;
    padding: 34px;
    border: 1px solid #1d3048;
    border-radius: 24px;
    background: #08111f;
    box-shadow: 0 18px 48px rgba(5, 14, 26, .14);
}
.terminal-feature-copy .eyebrow { color: #4d9cff; }
.terminal-feature-copy h2 { color: #f7fbff; }
.terminal-feature-copy p { color: #a8b8cb; }
.terminal-feature .btn-secondary {
    border-color: #29405c;
    background: #0d1a2c;
    color: #eaf2fb;
}
.terminal-feature .btn-secondary:hover {
    border-color: #3a5574;
    background: #122239;
}
.terminal-feature .terminal-mini-preview {
    border-color: #29405c;
    background: #06101d;
    box-shadow: none;
}
.terminal-feature .terminal-mini-top {
    border-bottom-color: #29405c;
    background: #0b1727;
}


@media (max-width: 640px) {
    .terminal-feature {
        margin-top: 10px;
        margin-bottom: 16px;
        padding: 24px 20px;
        border-radius: 20px;
    }
}


/* v2.7 terminal UX, homepage interaction and tool-to-terminal linking */
.terminal-suggestions {
    display: grid;
    gap: 1px;
    border-top: 1px solid var(--terminal-line);
    background: var(--terminal-line);
}
.terminal-suggestions[hidden] { display: none; }
.terminal-suggestion {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    width: 100%;
    border: 0;
    padding: 10px 14px;
    background: var(--terminal-panel);
    color: var(--terminal-text);
    text-align: left;
    cursor: pointer;
}
.terminal-suggestion:hover,
.terminal-suggestion:focus-visible {
    background: color-mix(in srgb, var(--terminal-accent) 10%, var(--terminal-panel));
    outline: none;
}
.terminal-suggestion strong { color: var(--terminal-accent); font-size: 13px; }
.terminal-suggestion span { color: var(--terminal-muted); font-size: 12px; line-height: 1.45; }

.terminal-feature-demo { min-width: 0; }
.terminal-feature .terminal-shell-compact {
    --terminal-bg: #07111f;
    --terminal-panel: #0b1727;
    --terminal-line: #243750;
    --terminal-text: #d9e7f8;
    --terminal-muted: #8fa2b8;
    --terminal-accent: #63aef6;
    --terminal-green: #62d89d;
    --terminal-red: #ff8c80;
    border-color: var(--terminal-line);
    background: var(--terminal-bg);
    box-shadow: none;
}
.terminal-shell-compact .terminal-output { height: 210px; min-height: 210px; padding: 14px 16px; }
.terminal-shell-compact .terminal-topbar { padding-block: 10px; }
.terminal-shell-compact .terminal-title span { display: none; }
.terminal-shell-compact .terminal-row { font-size: 13px; line-height: 1.55; }
.terminal-shell-compact .terminal-input { font-size: 13px; }
.terminal-shell-compact .terminal-suggestion { background: var(--terminal-panel); }
.terminal-feature-examples {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}
.terminal-feature-examples button {
    border: 1px solid #253a55;
    border-radius: 999px;
    padding: 7px 10px;
    background: rgba(9, 24, 43, .9);
    color: #a8b8cb;
    font: 600 12px/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    cursor: pointer;
}
.terminal-feature-examples button:hover { color: #fff; border-color: #3b5f87; }

/* v2.7.1 terminal shortcut polish */
.tool-terminal-bridge {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, .92fr);
    gap: 20px;
    align-items: center;
    margin-top: 36px;
    margin-bottom: 22px;
    padding: 18px 20px;
    border: 1px solid #243a55;
    border-radius: 18px;
    background: linear-gradient(135deg, #08111f 0%, #0b1727 100%);
    box-shadow: 0 14px 34px rgba(5, 14, 26, .08);
}
.tool-terminal-bridge .eyebrow { color: #63aef6; }
.tool-terminal-bridge h2 {
    margin: 4px 0 5px;
    color: #f7fbff;
    font-size: 21px;
    letter-spacing: -.025em;
}
.tool-terminal-bridge p {
    margin: 0;
    color: #a8b8cb;
    font-size: 14px;
    line-height: 1.55;
}
.tool-terminal-command {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-width: 0;
    padding: 0 0 0 16px;
    border: 0;
    border-left: 1px solid #29405c;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}
.tool-terminal-command code {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #d9e7f8;
    font-size: 13px;
    line-height: 1.5;
    cursor: default;
    user-select: text;
}
.tool-terminal-command .btn-secondary {
    flex: 0 0 auto;
    border-color: #1476df;
    background: #1476df;
    color: #fff;
    box-shadow: none;
}
.tool-terminal-command .btn-secondary:hover {
    border-color: #2788ef;
    background: #2788ef;
    color: #fff;
    }

.directory-section[id] { scroll-margin-top: 96px; }

@media (max-width: 800px) {
    .tool-terminal-bridge { grid-template-columns: 1fr; gap: 16px; }
    .terminal-suggestion { grid-template-columns: 78px minmax(0, 1fr); padding-inline: 12px; }
}
@media (max-width: 520px) {
    .terminal-shell-compact .terminal-output { height: 190px; min-height: 190px; }
    .terminal-feature-examples { display: grid; grid-template-columns: 1fr; }
    .terminal-feature-examples button { text-align: left; }
    .tool-terminal-command { align-items: stretch; flex-direction: column; padding-left: 0; border-left: 0; }
    .tool-terminal-command code { white-space: normal; overflow-wrap: anywhere; }
    .tool-terminal-command .btn-secondary { width: 100%; text-align: center; }
}


/* v2.9 content depth: useful documentation without turning tool pages into articles. */
.tool-doc-extra {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--tool-guide-gap);
    margin-top: 0;
}
.tool-doc-extra article {
    padding: 18px 20px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: color-mix(in srgb, var(--surface) 92%, var(--blue) 8%);
}
.tool-doc-label {
    display: block;
    margin-bottom: 8px;
    color: var(--blue);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.tool-doc-extra p,
.tool-doc-extra li {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}
.tool-doc-extra p { margin: 0; }
.tool-doc-extra ul { margin: 0; padding-left: 18px; }
.tool-doc-extra li + li { margin-top: 5px; }
.tool-guide-link {
    display: inline-flex;
    margin-top: 14px;
    color: var(--blue);
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
}
.tool-guide-link:hover { text-decoration: underline; }

/* About + guide pages. */
.content-page { padding-top: 64px; padding-bottom: 78px; }
.content-hero,
.content-prose {
    width: 100%;
}
.content-hero { margin-bottom: 48px; }
.content-hero h1 {
    margin: 8px 0 14px;
    color: var(--navy);
    font-size: var(--heading-page);
    line-height: .98;
    letter-spacing: -.055em;
}
.content-hero > p {
    margin: 0;
    color: var(--muted);
    font-size: var(--type-lead);
    line-height: 1.65;
}
.content-prose-wide {
    max-width: none;
    margin-inline: 0;
}
.content-section { margin-top: var(--content-section-gap); }
.content-section:first-child { margin-top: 0; }
.content-section h2,
.guide-body h2 {
    margin: 0 0 14px;
    color: var(--navy);
    font-size: var(--heading-h2);
    line-height: 1.08;
    letter-spacing: -.035em;
}
.content-section p,
.guide-body p {
    margin: 0 0 16px;
    color: var(--muted);
    font-size: var(--type-copy);
    line-height: 1.72;
}
.content-section a:not(.btn-primary):not(.btn-secondary),
.guide-body a:not(.btn-primary):not(.btn-secondary) { color: var(--blue); }
.principle-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: var(--content-section-gap);
}
.principle-grid article,
.content-callout {
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--surface);
}
.principle-grid h2 { margin: 8px 0 10px; color: var(--navy); font-size: 24px; letter-spacing: -.025em; }
.principle-grid p,
.content-callout p { margin: 0; color: var(--muted); font-size: var(--type-body); line-height: 1.7; }
.content-split { display: grid; grid-template-columns: 1.15fr .85fr; gap: 44px; align-items: start; }
.content-callout h3 { margin: 8px 0 10px; color: var(--navy); font-size: var(--heading-h3); }
.content-callout p + p { margin-top: 14px; }
.inline-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.text-link { color: var(--blue); font-weight: 750; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.about-more-link { display: inline-flex; margin-top: 12px; }

.guide-topic-section {
    margin-top: calc(var(--content-section-gap) + 8px);
}
.guide-topic-section:first-of-type { margin-top: 0; }
.guide-topic-heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 360px);
    gap: 28px;
    align-items: end;
    margin-bottom: 18px;
}
.guide-topic-heading h2 {
    margin: 7px 0 0;
    color: var(--navy);
    font-size: var(--heading-h2);
    line-height: 1.08;
    letter-spacing: -.035em;
}
.guide-topic-heading p {
    margin: 0;
    color: var(--muted);
    font-size: var(--type-body);
    line-height: 1.65;
}
.guide-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}
.guide-card {
    display: flex;
    flex-direction: column;
    min-height: 250px;
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--surface);
    text-decoration: none;
   
}
.guide-card:hover { border-color: color-mix(in srgb, var(--blue) 55%, var(--line)); box-shadow: 0 16px 36px rgba(18,44,82,.08); background: color-mix(in srgb, var(--surface) 97%, var(--blue) 3%); }
.guide-card-tag { align-self: flex-start; padding: 6px 9px; border-radius: 999px; background: color-mix(in srgb, var(--surface) 82%, var(--blue) 18%); color: var(--blue); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.guide-card h2 { margin: 18px 0 10px; color: var(--navy); font-size: 27px; line-height: 1.08; letter-spacing: -.035em; }
.guide-card p { margin: 0 0 18px; color: var(--muted); font-size: var(--type-body); line-height: 1.7; }
.guide-card > span:last-child { margin-top: auto; color: var(--blue); font-size: 13px; font-weight: 800; }
.guide-hub-note {
    width: 100%;
    padding-top: var(--content-section-gap);
    border-top: 1px solid var(--line);
}

.guide-article .content-hero,
.guide-body,
.guide-article > .related-tools {
    width: 100%;
}
.guide-body > section { margin-top: var(--content-section-gap); }
.guide-body > section:first-child { margin-top: 0; }
.guide-body code {
    padding: .12em .34em;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-soft);
    color: var(--text);
    font-size: .92em;
}
.guide-tool-callout {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 28px;
    align-items: center;
    margin: var(--content-section-gap) 0;
    padding: 24px 26px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: color-mix(in srgb, var(--surface) 92%, var(--blue) 8%);
}
.guide-tool-callout h2 { margin: 7px 0 7px; font-size: 25px; }
.guide-tool-callout p { margin: 0; }
.guide-steps { margin: 10px 0 0; padding-left: 22px; }
.guide-steps li { padding-left: 5px; color: var(--muted); font-size: 15px; line-height: 1.72; }
.guide-steps li + li { margin-top: 10px; }
.guide-steps strong { color: var(--text); }

.home-guides {
    padding-top: 54px;
}
.home-guide-grid .guide-card {
    min-height: 220px;
}
.home-guide-grid .guide-card h2 {
    font-size: 23px;
}
.home-guides-action {
    display: flex;
    justify-content: flex-start;
    margin-top: 16px;
}

@media (max-width: 760px) {
    .principle-grid,
    .guide-card-grid,
    .guide-topic-heading,
    .content-split { grid-template-columns: 1fr; }
    .content-page { padding-top: 42px; padding-bottom: 56px; }
    .content-hero { margin-bottom: 36px; }
    .guide-card { min-height: 0; }
    .home-guides { padding-top: 38px; }
    .home-guide-grid .guide-card { min-height: 0; }
    .guide-tool-callout { grid-template-columns: 1fr; align-items: start; }
}


/* Footer: grouped product/resource/legal navigation with a quiet metadata row. */
.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--line);
    color: var(--muted);
}
.footer-inner {
    display: grid;
    grid-template-columns: minmax(260px, 1.05fr) minmax(0, 1.45fr);
    grid-template-areas:
        "brand groups"
        "bottom bottom";
    column-gap: clamp(44px, 7vw, 92px);
    row-gap: 30px;
    padding: 42px 0 30px;
}
.footer-brand-block {
    grid-area: brand;
    min-width: 0;
}
.footer-brand {
    display: inline-flex;
    align-items: center;
    color: var(--text);
}
.footer-logo {
    display: block;
    width: 156px;
    height: auto;
}
.footer-brand .logo-dark { display: none; }
html[data-theme="dark"] .footer-brand .logo-light { display: none; }
html[data-theme="dark"] .footer-brand .logo-dark { display: block; }
.footer-tagline {
    max-width: 320px;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: var(--type-ui);
    line-height: 1.6;
}
.footer-groups {
    grid-area: groups;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px clamp(24px, 4vw, 48px);
}
.footer-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    min-width: 0;
}
.footer-group-title {
    margin-bottom: 3px;
    color: var(--blue);
    font-size: var(--type-xs);
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.footer-group a {
    color: var(--muted);
    font-size: var(--type-sm);
    font-weight: 650;
}
.footer-group a:hover,
.footer-group a.is-active { color: var(--blue); }
.footer-bottom {
    grid-area: bottom;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
}
.footer-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 18px;
    color: var(--muted);
    font-size: var(--type-xs);
    line-height: 1.5;
}
.footer-meta a:hover { color: var(--text); }

.footer-theme-toggle {
    min-width: 0;
    min-height: 32px;
    padding: 5px 10px;
    border-radius: 9px;
    font-size: var(--type-xs);
    line-height: 1;
}
.footer-meta-copy { justify-content: flex-end; text-align: right; }

@media (max-width: 820px) {
    .footer-inner {
        grid-template-columns: 1fr;
        grid-template-areas:
            "brand"
            "groups"
            "bottom";
        gap: 26px;
        padding-top: 34px;
    }
    .footer-groups {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    :root {
        --content-section-gap: 36px;
        --heading-page: clamp(36px, 10vw, 46px);
        --heading-hero: clamp(40px, 11vw, 52px);
        --heading-h2: clamp(27px, 8vw, 34px);
        --heading-card: 18px;
        --type-lead: 16px;
    }
    .breadcrumbs { font-size: var(--type-xs); }
    .footer-inner {
        gap: 24px;
        padding: 28px 0 26px;
    }
    .footer-logo { width: 150px; }
    .footer-groups {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px 28px;
    }
    .footer-bottom {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
        padding-top: 16px;
    }
    .footer-meta-copy { justify-content: flex-start; text-align: left; }
}

@media (max-width: 390px) {
    .footer-groups { grid-template-columns: 1fr; }
}

/* v2.12 accounts + signed-in terminal */
.account-auth { padding: 72px 0 88px; }
.account-auth-card {
    width: min(560px, 100%);
    margin: 0 auto;
    padding: 32px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 22px;
    box-shadow: var(--shadow);
}
.account-auth-card h1,
.account-page-head h1 { margin: 8px 0 10px; color: var(--navy); letter-spacing: -.045em; line-height: 1.02; }
.account-auth-card h1 { font-size: clamp(34px, 4vw, 46px); }
.account-auth-lead { margin: 0 0 24px; color: var(--muted); font-size: var(--type-body); line-height: 1.7; }
.account-form { display: grid; gap: 16px; }
.account-form label { display: grid; gap: 7px; color: var(--text); font-size: var(--type-ui); font-weight: 750; }
.account-form label small { color: var(--muted); font-size: var(--type-xs); font-weight: 500; line-height: 1.5; }
.account-form .btn-primary { justify-self: start; }
.account-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.account-form-actions a,
.account-switch a,
.account-panel-head a { color: var(--blue); font-weight: 750; }
.account-switch { margin: 22px 0 0; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: var(--type-ui); }
.account-alert { margin-bottom: 18px; padding: 13px 15px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-soft); font-size: var(--type-ui); }
.account-alert-success { border-color: color-mix(in srgb, var(--green) 35%, var(--line)); background: color-mix(in srgb, var(--green) 8%, var(--surface)); }
.account-alert-error { border-color: color-mix(in srgb, #d84a4a 38%, var(--line)); background: color-mix(in srgb, #d84a4a 8%, var(--surface)); }

.account-page { padding: 64px 0 90px; }
.account-page-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.account-page-head h1 { font-size: var(--heading-page); }
.account-page-head p { margin: 0; color: var(--muted); }
.account-stats { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; margin-bottom: 18px; }
.account-stats article { padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.account-stats span { display: block; color: var(--muted); font-size: var(--type-xs); font-weight: 750; margin-bottom: 8px; }
.account-stats strong { display: block; color: var(--navy); font-size: 24px; line-height: 1.2; }
.account-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 18px; }
.account-panel { padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.account-panel > p { color: var(--muted); font-size: var(--type-ui); line-height: 1.65; }
.account-panel-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.account-panel-head h2 { margin: 5px 0 0; color: var(--navy); font-size: var(--heading-card); }
.account-panel-head a { font-size: var(--type-sm); }
.account-inline-form { display: grid; grid-template-columns: 1fr auto; gap: 9px; margin: 18px 0; }
.account-key-list { display: grid; gap: 8px; }
.account-key-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 0; border-top: 1px solid var(--line); }
.account-key-row > div { min-width: 0; }
.account-key-row strong, .account-key-row code, .account-key-row small { display: block; }
.account-key-row code { margin: 4px 0; color: var(--blue); overflow-wrap: anywhere; }
.account-key-row small { color: var(--muted); font-size: var(--type-xs); }
.account-empty { color: var(--muted); font-size: var(--type-ui); }
.account-history-list { display: grid; gap: 0; margin-top: 14px; }
.account-history-list > div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-top: 1px solid var(--line); }
.account-history-list code { color: var(--text); overflow-wrap: anywhere; }
.account-history-list span { color: var(--muted); font-size: var(--type-xs); white-space: nowrap; }
.account-secret { margin: 0 0 18px; padding: 18px; border-radius: 15px; border: 1px solid color-mix(in srgb, var(--blue) 30%, var(--line)); background: color-mix(in srgb, var(--blue) 6%, var(--surface)); }
.account-secret strong, .account-secret code, .account-secret p { display: block; }
.account-secret code { margin: 10px 0; padding: 11px 12px; border-radius: 9px; background: var(--surface); border: 1px solid var(--line); overflow-wrap: anywhere; }
.account-secret p { margin: 10px 0 0; color: var(--muted); font-size: var(--type-xs); }

.terminal-account-bar { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 12px; padding: 14px 16px; border: 1px solid var(--line); background: var(--surface); border-radius: 14px; }
.terminal-account-bar > div { min-width: 0; }
.terminal-account-status { display: inline-flex; color: var(--blue); font-size: 11px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.terminal-account-bar strong { display: block; margin-top: 2px; color: var(--text); font-size: var(--type-ui); overflow-wrap: anywhere; }
.terminal-account-bar small { display: block; margin-top: 2px; color: var(--muted); font-size: var(--type-xs); }

@media (max-width: 820px) {
    .account-stats { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .account-grid { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
    .account-auth { padding: 40px 0 64px; }
    .account-auth-card { padding: 22px; border-radius: 18px; }
    .account-page { padding-top: 42px; }
    .account-page-head { align-items: flex-start; }
    .account-stats { grid-template-columns: 1fr 1fr; }
    .account-inline-form { grid-template-columns: 1fr; }
    .account-inline-form .btn-primary { width: 100%; }
    .account-key-row { align-items: flex-start; }
    .account-history-list > div { display: grid; gap: 4px; }
    .terminal-account-bar { align-items: flex-start; }
}

/* v2.13 product navigation, account polish and privacy pages */
.header-account-actions { display: flex; align-items: center; gap: 22px; }
.header-signin { color: var(--muted); font-size: var(--type-ui); font-weight: 700; }
.header-signin:hover { color: var(--blue); }
.header-signup {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 10px;
    background: var(--blue);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
}
.header-signup:hover { background: var(--blue-hover); }
.account-menu { position: relative; }
.account-menu summary { list-style: none; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-menu-trigger {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 38px;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text);
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    user-select: none;
}
.account-menu-trigger::after { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); }
.account-menu-trigger:hover,
.account-menu-trigger.is-active,
.account-menu[open] .account-menu-trigger { color: var(--blue); border-color: color-mix(in srgb, var(--blue) 32%, var(--line)); background: color-mix(in srgb, var(--blue) 6%, var(--surface)); }
.account-menu-pop {
    position: absolute;
    top: calc(100% + 9px);
    right: 0;
    z-index: 60;
    width: 240px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: var(--surface);
    box-shadow: 0 18px 42px rgba(16, 38, 68, .16);
}
.account-menu-identity { padding: 9px 10px 11px; border-bottom: 1px solid var(--line); margin-bottom: 5px; }
.account-menu-identity span,
.account-menu-identity strong { display: block; }
.account-menu-identity span { color: var(--muted); font-size: 11px; }
.account-menu-identity strong { margin-top: 2px; overflow: hidden; text-overflow: ellipsis; font-size: 12px; }
.account-menu-pop a,
.account-menu-pop button {
    display: flex;
    width: 100%;
    min-height: 39px;
    align-items: center;
    padding: 0 10px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    text-align: left;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
}
.account-menu-pop a:hover,
.account-menu-pop a.is-active,
.account-menu-pop button:hover { color: var(--blue); background: color-mix(in srgb, var(--blue) 7%, var(--surface)); }
.account-menu-pop form { margin: 2px 0 0; padding-top: 4px; border-top: 1px solid var(--line); }
.account-menu-pop form button { color: #b63a3a; }

.account-consent { grid-template-columns: auto 1fr !important; align-items: start; gap: 10px !important; font-weight: 500 !important; line-height: 1.55; }
.account-consent input { width: 17px; height: 17px; margin: 2px 0 0; accent-color: var(--blue); }
.account-consent a,
.account-data-note a { color: var(--blue); font-weight: 750; }
.account-data-note { margin: 18px 0 0; color: var(--muted); font-size: var(--type-xs); line-height: 1.6; }
.account-verification-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin: 0 0 18px;
    padding: 16px 18px;
    border: 1px solid color-mix(in srgb, #d29a20 36%, var(--line));
    border-radius: 15px;
    background: color-mix(in srgb, #f7bd3d 8%, var(--surface));
}
.account-verification-banner strong { display: block; color: var(--text); }
.account-verification-banner p { margin: 3px 0 0; color: var(--muted); font-size: var(--type-sm); }
.account-inline-note,
.account-key-note { color: var(--muted); font-size: var(--type-xs); line-height: 1.55; }
.account-inline-note { margin: 16px 0; padding: 12px 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-soft); }
.account-key-note { margin: -8px 0 14px; }
.account-settings-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 18px; margin-top: 18px; }
.account-settings-panel h2 { margin: 5px 0 10px; color: var(--navy); font-size: var(--heading-card); }
.account-settings-panel > p { color: var(--muted); font-size: var(--type-ui); line-height: 1.65; }
.account-settings-panel a:not(.btn-secondary) { color: var(--blue); font-weight: 750; }
.account-setting-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.account-setting-row strong,
.account-setting-row small { display: block; }
.account-setting-row small { margin-top: 3px; color: var(--muted); font-size: var(--type-xs); }
.account-status-pill { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; }
.account-status-pill.verified { color: #28734f; background: #edf8f2; }
.account-status-pill.pending { color: #8a611b; background: #fff7e8; }
.account-setting-action { margin: 14px 0 0; }
.account-danger-zone { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.account-danger-zone summary { color: #b63a3a; cursor: pointer; font-weight: 800; font-size: var(--type-sm); }
.account-danger-zone > div { margin-top: 12px; padding: 15px; border: 1px solid color-mix(in srgb, #d84a4a 25%, var(--line)); border-radius: 12px; background: color-mix(in srgb, #d84a4a 5%, var(--surface)); }
.account-danger-zone p { margin-top: 0; color: var(--muted); font-size: var(--type-sm); }
.account-delete-form { display: grid; gap: 12px; }
.account-delete-form label { display: grid; gap: 6px; font-size: var(--type-sm); font-weight: 750; }
.account-delete-form .btn-danger { justify-self: start; }

.account-password-form { display: grid; gap: 12px; margin-top: 16px; }
.account-password-form label { display: grid; gap: 6px; color: var(--text); font-size: var(--type-sm); font-weight: 750; }
.account-password-form .btn { justify-self: start; margin-top: 2px; }
.account-password-help { margin: 0; color: var(--muted); font-size: var(--type-xs); line-height: 1.55; }

.account-secret-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; overflow: auto; background: rgba(5, 15, 29, .58); backdrop-filter: blur(5px); }
.account-secret-dialog { width: min(600px, 100%); padding: 28px; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); box-shadow: 0 28px 80px rgba(0,0,0,.28); }
.account-secret-dialog h2 { margin: 7px 0 8px; color: var(--navy); font-size: 28px; letter-spacing: -.03em; }
.account-secret-dialog p { color: var(--muted); line-height: 1.65; }
.account-secret-dialog code { display: block; margin: 18px 0; padding: 14px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface-soft); color: var(--blue); overflow-wrap: anywhere; font-size: 13px; }
.account-secret-dialog small { display: block; margin-top: 13px; color: var(--muted); }
.account-secret-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.legal-page .content-hero { max-width: 850px; }
.legal-updated { display: block; margin-top: 18px; color: var(--muted); font-size: var(--type-xs); }
.legal-prose a { color: var(--blue); font-weight: 700; }
.legal-prose ul { padding-left: 20px; }
.legal-prose li + li { margin-top: 8px; }
.legal-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
.legal-grid article { padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.legal-grid strong { display: block; color: var(--navy); margin-bottom: 6px; }
.legal-grid p { margin: 0; color: var(--muted); font-size: var(--type-ui); line-height: 1.65; }
.privacy-control-card { padding: 22px; border: 1px solid color-mix(in srgb, var(--blue) 22%, var(--line)); border-radius: 18px; background: color-mix(in srgb, var(--blue) 4%, var(--surface)); }
.privacy-control-card h2 { margin: 5px 0 8px; }
.privacy-control-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.storage-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.storage-table { width: 100%; min-width: 720px; border-collapse: collapse; }
.storage-table th,
.storage-table td { padding: 13px 14px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; font-size: var(--type-sm); }
.storage-table thead th { border-top: 0; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.storage-table td { color: var(--muted); line-height: 1.55; }
.storage-table td:first-child { color: var(--text); white-space: nowrap; }

.product-strip { padding: 12px 0 58px; }
.product-strip-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; }
.product-strip-card { display: flex; flex-direction: column; min-height: 196px; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.product-strip-card .eyebrow { color: var(--blue); font-size: 11px; }
.product-strip-card strong { display: block; margin: 14px 0 5px; color: var(--navy); font-size: 19px; }
.product-strip-card p { margin: 0; color: var(--muted); font-size: var(--type-sm); line-height: 1.6; }
.product-strip-card-top { display: flex; align-items: center; gap: 10px; }
.feature-icon { display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center; flex: 0 0 34px; border: 1px solid color-mix(in srgb, var(--blue) 22%, var(--line)); border-radius: 10px; background: color-mix(in srgb, var(--blue) 7%, var(--surface)); color: var(--blue); }
.feature-icon svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.product-strip-card:hover { border-color: color-mix(in srgb, var(--blue) 30%, var(--line)); background: color-mix(in srgb, var(--blue) 4%, var(--surface)); }

@media (max-width: 900px) {
    .nav { gap: 16px; }
    .header-inner { gap: 16px; }
    .header-signup { padding-inline: 11px; }
}
@media (max-width: 760px) {
    .account-settings-grid,
    .legal-grid,
    .product-strip-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .header-account-actions { display: none; }
    .mobile-nav-divider { height: 1px; margin: 5px 6px; background: var(--line); }
    .mobile-nav form { margin: 0; }
    .mobile-signout button {
        display: flex;
        width: 100%;
        min-height: 42px;
        align-items: center;
        padding: 0 12px;
        border: 0;
        border-radius: 8px;
        background: transparent;
        color: #b63a3a;
        cursor: pointer;
        font-size: var(--type-ui);
        font-weight: 700;
    }
    .mobile-signup { color: #fff !important; background: var(--blue) !important; justify-content: center !important; margin-top: 3px; }
    .account-verification-banner { align-items: flex-start; flex-direction: column; }
    .account-verification-banner .btn-secondary { width: 100%; }
    .account-secret-dialog { padding: 22px; }
    .account-secret-actions > * { width: 100%; }
    .account-setting-row { align-items: flex-start; }
    .account-password-form .btn { width: 100%; }
    .privacy-control-actions > * { width: 100%; }
}
.terminal-account-actions,
.api-hero-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.api-hero-actions { margin-top: 16px; }
@media (max-width: 640px) {
    .terminal-account-actions { width: 100%; }
    .terminal-account-actions > * { flex: 1; }
}
.header-signin.is-active { color: var(--blue); }
.header-signup.is-active { box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 16%, transparent); }

/* v2.16.1 contact and support */
.contact-hero { max-width: 860px; }
.contact-channel-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}
.contact-support-grid {
    grid-template-columns: minmax(0, 1.42fr) minmax(300px, .58fr);
    align-items: start;
}
.contact-channel-card {
    display: flex;
    min-height: 360px;
    flex-direction: column;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--surface);
}
.contact-channel-primary {
    border-color: color-mix(in srgb, var(--blue) 30%, var(--line));
    background: color-mix(in srgb, var(--blue) 3%, var(--surface));
}

.contact-form-card { min-height: 0; }
.contact-privacy-card { min-height: 360px; }
.contact-form { display: grid; gap: 16px; margin-top: 24px; }
.contact-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.contact-field { display: grid; gap: 7px; color: var(--text); font-size: var(--type-sm); font-weight: 750; }
.contact-field small { color: var(--muted); font-size: var(--type-xs); font-weight: 500; line-height: 1.5; }
.contact-message { min-height: 180px; resize: vertical; }
.contact-field.is-invalid .text-input,
.contact-field.is-invalid .select-input,
.contact-field.is-invalid .textarea-input {
    border-color: #d84a4a;
    box-shadow: 0 0 0 3px color-mix(in srgb, #d84a4a 10%, transparent);
}
.field-error { color: #b83333 !important; font-size: var(--type-xs) !important; font-weight: 750 !important; }
html[data-theme="dark"] .field-error { color: #ff9e92 !important; }
.contact-form-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-top: 2px; }
.contact-form-footer p { margin: 0; max-width: 560px; color: var(--muted); font-size: var(--type-xs); line-height: 1.55; }
.contact-form-footer a { color: var(--blue); font-weight: 800; }
.contact-form-alert { margin-top: 20px; }
.contact-form-alert strong { display: block; margin-bottom: 3px; }
.contact-form-alert ul { margin: 7px 0 0; padding-left: 18px; }
.contact-form-alert code { font: 700 12px ui-monospace,SFMono-Regular,Menlo,monospace; }
.contact-honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }

.contact-channel-top { display: flex; align-items: center; gap: 11px; }
.contact-channel-card h2 {
    margin: 22px 0 10px;
    color: var(--navy);
    font-size: 28px;
    line-height: 1.08;
    letter-spacing: -.035em;
}
.contact-channel-card > p {
    margin: 0;
    color: var(--muted);
    font-size: var(--type-body);
    line-height: 1.7;
}
.contact-email {
    display: inline-flex;
    align-self: flex-start;
    margin-top: 22px;
    color: var(--blue);
    font-size: 18px;
    font-weight: 800;
    overflow-wrap: anywhere;
}
.contact-email:hover { text-decoration: underline; }
.contact-card-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: auto; padding-top: 28px; }
.contact-help-section {
    margin-top: var(--content-section-gap);
    padding-top: var(--content-section-gap);
    border-top: 1px solid var(--line);
}
.contact-help-heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
    gap: 32px;
    align-items: end;
    margin-bottom: 18px;
}
.contact-help-heading h2 {
    margin: 7px 0 0;
    color: var(--navy);
    font-size: var(--heading-h2);
    line-height: 1.08;
    letter-spacing: -.035em;
}
.contact-help-heading p { margin: 0; color: var(--muted); font-size: var(--type-body); line-height: 1.65; }
.contact-help-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.contact-help-grid > a {
    display: flex;
    min-height: 190px;
    flex-direction: column;
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    text-decoration: none;
}
.contact-help-grid > a:hover {
    border-color: color-mix(in srgb, var(--blue) 50%, var(--line));
    background: color-mix(in srgb, var(--blue) 3%, var(--surface));
    box-shadow: 0 14px 30px rgba(18,44,82,.07);
}
.contact-help-grid strong { color: var(--navy); font-size: 19px; }
.contact-help-grid span { margin-top: 8px; color: var(--muted); font-size: var(--type-ui); line-height: 1.6; }
.contact-help-grid em { margin-top: auto; padding-top: 20px; color: var(--blue); font-size: 13px; font-style: normal; font-weight: 800; }
.contact-note {
    display: grid;
    grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
    gap: 34px;
    margin-top: var(--content-section-gap);
    padding: 26px 28px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--surface-soft);
}
.contact-note h2 { margin: 7px 0 0; color: var(--navy); font-size: 24px; letter-spacing: -.025em; }
.contact-note ul { margin: 0; padding-left: 20px; }
.contact-note li { color: var(--muted); font-size: var(--type-ui); line-height: 1.65; }
.contact-note li + li { margin-top: 7px; }
.api-support-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    align-items: center;
    margin-top: var(--content-section-gap);
    padding: 24px 26px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: color-mix(in srgb, var(--blue) 4%, var(--surface));
}
.api-support-card h2 { margin: 6px 0 7px; color: var(--navy); font-size: 24px; letter-spacing: -.025em; }
.api-support-card p { margin: 0; color: var(--muted); font-size: var(--type-ui); line-height: 1.65; }

@media (max-width: 820px) {
    .contact-channel-grid,
    .contact-support-grid,
    .contact-help-heading,
    .contact-note,
    .api-support-card { grid-template-columns: 1fr; }
    .contact-help-grid { grid-template-columns: 1fr; }
    .contact-channel-card,
    .contact-privacy-card { min-height: 0; }
    .contact-form-row { grid-template-columns: 1fr; }
    .contact-form-footer { align-items: stretch; flex-direction: column; }
    .contact-form-footer .btn { align-self: flex-start; }
    .api-support-card .btn { justify-self: start; }
}

@media (max-width: 620px) {
    .contact-channel-card { padding: 22px; }
    .contact-channel-card h2 { font-size: 24px; }
    .contact-email { font-size: 16px; }
    .contact-card-actions .btn,
    .contact-form-footer .btn,
    .api-support-card .btn { width: 100%; }
    .contact-note { padding: 22px; }
}

/* v2.16.7 homepage hero refinement
   Keep the intro band almost neutral, centre the hero vertically within it,
   and use the same section rhythm immediately below the divider. */
.home-hero-band {
    background: color-mix(in srgb, var(--blue) 0.9%, var(--bg));
    border-bottom: 1px solid color-mix(in srgb, var(--blue) 6%, var(--line));
}
.home-hero-band .hero {
    padding-top: 56px;
    padding-bottom: 56px;
}
.home-primary-flow {
    display: grid;
    gap: 56px;
    padding-top: 56px;
    padding-bottom: 56px;
}
.home-primary-flow .details-section,
.home-primary-flow .product-strip {
    padding: 0;
}

@media (max-width: 920px) {
    .home-hero-band .hero {
        padding-top: 46px;
        padding-bottom: 46px;
    }
    .home-primary-flow {
        gap: 44px;
        padding-top: 44px;
        padding-bottom: 48px;
    }
}

@media (max-width: 640px) {
    .home-hero-band .hero {
        padding-top: 34px;
        padding-bottom: 34px;
    }
    .home-primary-flow {
        gap: 38px;
        padding-top: 38px;
        padding-bottom: 42px;
    }
}

/* v2.17 responsive terminal embed sizing */
.embed-number-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 9px;
    align-items: center;
}
.embed-number-row span {
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}
.embed-preview-head small {
    margin-left: 7px;
    color: color-mix(in srgb, var(--muted) 80%, transparent);
    font-size: 11px;
    font-weight: 700;
}
.embed-preview-stage {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    border: 1px solid #cfdbea;
    border-radius: 20px;
    background: #f7faff;
    overflow: hidden;
    transition: max-width .18s ease, height .18s ease, border-color var(--transition-fast), background-color var(--transition-fast);
}
.embed-preview-stage[data-align="left"] { margin-left: 0; margin-right: auto; }
.embed-preview-stage[data-align="center"] { margin-left: auto; margin-right: auto; }
.embed-preview-stage[data-align="right"] { margin-left: auto; margin-right: 0; }
.embed-preview-frame {
    width: 100%;
    max-width: none;
    height: 100%;
    border: 0;
    border-radius: 0;
    background: transparent;
}
.embed-control select:disabled {
    opacity: .55;
    cursor: not-allowed;
}
.embed-options-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* The iframe viewport is the responsive container. Keep every control usable even
   when the host embeds the terminal in a narrow column or a short dashboard card. */
@media (max-width: 520px) {
    .terminal-embed-page .terminal-topbar {
        min-height: 46px;
        grid-template-columns: 58px minmax(0, 1fr) auto;
        gap: 7px;
        padding-inline: 10px;
    }
    .terminal-embed-page .terminal-title span { display: none; }
    .terminal-embed-page .terminal-output { padding: 14px; }
    .terminal-embed-page .terminal-input-row { gap: 7px; padding: 10px 11px; }
    .terminal-embed-page .terminal-branding { padding: 6px 10px 7px; font-size: 11px; }
}

@media (max-width: 380px) {
    .terminal-embed-page { padding: 0; }
    .terminal-embed-page .terminal-shell-embed { border-radius: 0; }
    .terminal-embed-page .terminal-topbar {
        min-height: 42px;
        grid-template-columns: 42px minmax(0, 1fr) auto;
        gap: 4px;
        padding-inline: 8px;
    }
    .terminal-embed-page .terminal-lights { gap: 4px; }
    .terminal-embed-page .terminal-lights span { width: 7px; height: 7px; }
    .terminal-embed-page .terminal-title strong { font-size: 11px; }
    .terminal-embed-page .terminal-top-actions { gap: 1px; }
    .terminal-embed-page .terminal-text-btn { padding: 4px 5px; font-size: 10px; }
    .terminal-embed-page .terminal-output { padding: 10px; }
    .terminal-embed-page .terminal-row { font-size: 11px; line-height: 1.55; }
    .terminal-embed-page .terminal-row-links a { font-size: 11px; }
    .terminal-embed-page .terminal-input-row { padding: 8px 9px; }
    .terminal-embed-page .terminal-prompt,
    .terminal-embed-page .terminal-input { font-size: 12px; }
    .terminal-embed-page .terminal-run { display: none; }
    .terminal-embed-page .terminal-branding { font-size: 10px; }
}

@media (max-width: 310px) {
    .terminal-embed-page .terminal-title { text-align: left; }
    .terminal-embed-page .terminal-title strong { font-size: 10px; }
    .terminal-embed-page .terminal-top-actions .terminal-text-btn:first-child { display: none; }
}

@media (max-height: 420px) {
    .terminal-embed-page .terminal-topbar { min-height: 42px; }
    .terminal-embed-page .terminal-output { padding-top: 10px; padding-bottom: 10px; }
    .terminal-embed-page .terminal-input-row { padding-top: 8px; padding-bottom: 8px; }
    .terminal-embed-page .terminal-branding { padding-top: 5px; padding-bottom: 5px; }
}

@media (max-width: 860px) {
    .embed-options-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
    .embed-preview-head { align-items: flex-start; }
    .embed-preview-head > span { display: grid; gap: 2px; }
    .embed-preview-head small { margin-left: 0; }
    .embed-options-grid { grid-template-columns: 1fr; }
}
/* v2.17.1 embed builder hotfix and extra narrow-width resilience */
@media (max-width: 380px) {
    .terminal-embed-page .terminal-suggestion {
        grid-template-columns: 1fr;
        gap: 2px;
        padding: 8px 9px;
    }
}

@media (max-width: 260px) {
    .terminal-embed-page .terminal-lights { display: none; }
    .terminal-embed-page .terminal-topbar {
        grid-template-columns: minmax(0, 1fr) auto;
        padding-inline: 7px;
    }
    .terminal-embed-page .terminal-title strong { font-size: 9px; }
    .terminal-embed-page .terminal-text-btn { padding-inline: 4px; }
    .terminal-embed-page .terminal-output { padding-inline: 8px; }
    .terminal-embed-page .terminal-input-row { padding-inline: 7px; }
}


/* v2.17.2 terminal embed frame ownership fix
   The host wrapper owns border/radius/clipping. The iframe document fills it edge-to-edge,
   which prevents transparent square corners from showing through around the rounded terminal. */
