/* ===== FONTS — self-hosted variable fonts, Latin subset (wwwroot/fonts) ===== */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    src: url('fonts/inter-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'Source Sans 3';
    font-style: normal;
    font-weight: 400 900;
    font-display: swap;
    src: url('fonts/source-sans-3-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'JetBrains Mono';
    font-style: normal;
    font-weight: 400 500;
    font-display: swap;
    src: url('fonts/jetbrains-mono-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ===== CSS CUSTOM PROPERTIES — Copper & Midnight ===== */
:root {
    /* Backgrounds */
    --bc-bg-deep:     #0e0c0a;
    --bc-bg-primary:  #131110;
    --bc-bg-surface:  #1c1916;
    --bc-bg-elevated: #231f1b;

    /* Borders */
    --bc-border:       #302a23;
    --bc-border-light: rgba(249, 115, 22, 0.08);
    --bc-border-mid:   rgba(249, 115, 22, 0.16);

    /* Text — each clears WCAG AA (4.5:1) on all four backgrounds above */
    --bc-text-primary:   #f5ede0;
    --bc-text-secondary: #a89070;
    --bc-text-muted:     #978b7d;

    /* Copper accent system */
    --bc-accent:          #f97316;
    --bc-accent-light:    #fb923c;
    --bc-accent-deep:     #ea580c;
    --bc-accent-dim:      rgba(249, 115, 22, 0.10);
    --bc-accent-glow:     rgba(249, 115, 22, 0.28);
    --bc-accent-border:   rgba(249, 115, 22, 0.25);
    --bc-on-accent:       #1a120b; /* text on copper fills; white fails AA on this orange */

    /* Gradients */
    --bc-gradient-accent:        linear-gradient(135deg, #fb923c 0%, #ea580c 100%);
    --bc-gradient-accent-subtle: linear-gradient(135deg, rgba(249,115,22,0.15) 0%, rgba(234,88,12,0.08) 100%);
    --bc-gradient-glow:          linear-gradient(135deg, rgba(249,115,22,0.3) 0%, rgba(234,88,12,0.1) 100%);

    /* Typography */
    --bc-font-heading: 'Source Sans 3', 'Inter', sans-serif;
    --bc-font-body:    'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --bc-font-mono:    'JetBrains Mono', 'Fira Code', monospace;

    /* Geometry */
    --bc-radius:    8px;
    --bc-radius-lg: 14px;
    --bc-radius-xl: 20px;
    --bc-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== BASE ===== */
/* No smooth scrolling: it animated every page change, and FocusOnNavigate then
   stopped the animation part-way down the new page. */
html {
    scroll-padding-top: 96px; /* keeps anchor targets clear of the fixed 80px app bar */
}

html, body {
    font-family: var(--bc-font-body);
    background-color: var(--bc-bg-primary);
    color: var(--bc-text-primary);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Programmatic focus targets (FocusOnNavigate, skip link) */
h1:focus,
#main-content:focus {
    outline: none;
}

/* ===== SKIP LINK ===== */
.bc-skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 2000;
    padding: 10px 18px;
    border-radius: var(--bc-radius);
    background: var(--bc-accent-light);
    color: var(--bc-on-accent);
    font-weight: 600;
    text-decoration: none;
    transform: translateY(-200%);
    transition: transform 0.2s ease;
}

.bc-skip-link:focus {
    transform: translateY(0);
}

/* ===== UTILITY ===== */
.bc-muted-text {
    color: var(--bc-text-secondary) !important;
}

/* Hero intro copy sits over the gears at full strength; this lighter tone
   keeps 4.5:1 at the brightest point behind it (secondary measured 3.46:1). */
.bc-lede {
    color: #cbb793 !important;
}

.bc-text-link {
    color: var(--bc-accent) !important;
    text-decoration: none !important;
    font-weight: 500;
    transition: color var(--bc-transition);
}

.bc-text-link:hover {
    color: var(--bc-accent-light) !important;
    text-decoration: underline !important;
}

.bc-text-center {
    text-align: center;
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-color: transparent;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    padding: 0 24px;
}

/* The logo image is the page's h1; the heading element only carries structure */
.bc-hero-heading {
    margin: 0;
}

/* Hero logo (cream/transparent variant) */
.bc-hero-logo {
    display: block;
    width: min(460px, 82%);
    height: auto;
    margin: 8px auto 4px;
}

.hero-cta {
    margin-top: 3rem;
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Hero CTA Buttons */
.bc-hero-btn {
    background: var(--bc-gradient-accent) !important;
    color: var(--bc-on-accent) !important;
    text-transform: none !important;
    font-family: var(--bc-font-heading) !important;
    font-weight: 700 !important;
    letter-spacing: 0.2px !important;
    font-size: 0.98rem !important;
    padding: 14px 40px !important;
    border-radius: var(--bc-radius) !important;
    transition: all var(--bc-transition) !important;
    box-shadow: none !important;
}

.bc-hero-btn:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.4) !important;
    transform: translateY(-1px);
}

.bc-hero-btn-outline {
    background-color: transparent !important;
    color: var(--bc-text-primary) !important;
    border: 1px solid var(--bc-border) !important;
    text-transform: none !important;
    font-family: var(--bc-font-heading) !important;
    font-weight: 600 !important;
    letter-spacing: 0.2px !important;
    font-size: 0.98rem !important;
    padding: 14px 40px !important;
    border-radius: var(--bc-radius) !important;
    transition: all var(--bc-transition) !important;
}

.bc-hero-btn-outline:hover {
    border-color: var(--bc-accent-border) !important;
    color: var(--bc-accent) !important;
    background-color: var(--bc-accent-dim) !important;
}

/* ===== SECTION SPACING ===== */
.section-padding {
    padding: 100px 0;
    position: relative;
    background-color: transparent;
}

/* ===== PAGE HEADER ===== */
.page-header {
    padding: 160px 0 72px;
    text-align: center;
    background-color: transparent;
    position: relative;
}

.page-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--bc-gradient-accent);
    border-radius: 2px;
}

/* ===== FEATURE CARD ICONS ===== */
.bc-about-card-icon {
    color: var(--bc-accent) !important;
    font-size: 2.2rem !important;
    margin-bottom: 16px;
}

/* ===== CAPABILITY SHEETS (Services) ===== */
/* The sheet's background is the border color; the 1px grid gap lets it show
   through as shared hairlines between cells, like a drawing's BOM table. */
.bc-capability-sheet {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1px;
    background-color: var(--bc-border);
    border: 1px solid var(--bc-border);
    border-radius: var(--bc-radius);
    overflow: hidden;
}

@media (min-width: 900px) {
    .bc-capability-sheet {
        grid-template-columns: repeat(2, 1fr);
    }

    /* An odd last cell spans the row, so no empty gap-colored cell shows. */
    .bc-capability:last-child:nth-child(odd) {
        grid-column: 1 / -1;
    }
}

.bc-capability {
    background-color: var(--bc-bg-surface);
    padding: 28px 24px;
    transition: background-color var(--bc-transition);
}

.bc-capability:hover {
    background-color: var(--bc-bg-elevated);
}

.bc-capability-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    font-family: var(--bc-font-mono);
    font-size: 0.62rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--bc-text-muted);
}

.bc-capability-icon {
    color: var(--bc-accent) !important;
    font-size: 1.8rem !important;
}

/* ===== FAQ (native <details>) ===== */
.bc-faq {
    max-width: 1100px;
    margin: 0 auto;
}

.bc-faq-item {
    border-bottom: 1px solid var(--bc-border);
}

.bc-faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 0;
    list-style: none;
    cursor: pointer;
    color: var(--bc-text-primary);
    font-size: 1rem;
    font-weight: 500;
    transition: color var(--bc-transition);
}

.bc-faq-question::-webkit-details-marker {
    display: none;
}

.bc-faq-question::after {
    content: '+';
    flex-shrink: 0;
    font-family: var(--bc-font-mono);
    font-size: 1.2rem;
    color: var(--bc-accent);
    transition: transform var(--bc-transition);
}

.bc-faq-item[open] > .bc-faq-question::after {
    transform: rotate(45deg);
}

.bc-faq-question:hover {
    color: var(--bc-accent-light);
}

.bc-faq-question:focus-visible {
    outline: 2px solid var(--bc-accent-light);
    outline-offset: 4px;
    border-radius: 2px;
}

.bc-faq-answer {
    max-width: 900px;
    padding-bottom: 20px;
}

/* ===== CONTACT FORM ===== */
.bc-contact-form-wrapper {
    background-color: var(--bc-bg-surface) !important;
    border: 1px solid var(--bc-border-light) !important;
    border-radius: var(--bc-radius-lg) !important;
    padding: 48px !important;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.bc-contact-form-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--bc-gradient-accent);
}

.bc-submit-btn {
    background: var(--bc-gradient-accent) !important;
    color: var(--bc-on-accent) !important;
    text-transform: none !important;
    font-family: var(--bc-font-heading) !important;
    font-weight: 700 !important;
    letter-spacing: 0.2px !important;
    font-size: 0.98rem !important;
    border-radius: var(--bc-radius) !important;
    transition: all var(--bc-transition) !important;
    box-shadow: none !important;
}

.bc-submit-btn:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.4) !important;
    transform: translateY(-1px);
}

/* ===== STATS BANNER ===== */
.bc-stats-banner {
    padding: 60px 0;
    background-color: var(--bc-bg-surface);
    border-top: 1px solid var(--bc-border-light);
    border-bottom: 1px solid var(--bc-border-light);
    position: relative;
}

/* ===== INDUSTRY ITEMS ===== */
.bc-industry-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    padding: 24px;
    border-radius: var(--bc-radius-lg);
    border: 1px solid var(--bc-border-light);
    background-color: var(--bc-bg-surface);
    transition: all var(--bc-transition);
    height: 100%;
}

.bc-industry-item:hover {
    border-color: var(--bc-accent-border);
    background-color: var(--bc-bg-elevated);
    transform: translateY(-3px);
    box-shadow: 0 10px 32px rgba(0,0,0,0.35);
}

.bc-industry-icon {
    color: var(--bc-accent) !important;
    font-size: 1.8rem !important;
    flex-shrink: 0;
    margin-top: 2px;
}

/* ===== PROCESS STEPS ===== */
.bc-process-step {
    text-align: center;
    padding: 32px 20px;
}

.bc-process-number {
    font-family: var(--bc-font-heading);
    font-size: 2.8rem;
    font-weight: 900;
    color: var(--bc-accent);
    line-height: 1;
    margin-bottom: 16px;
    opacity: 0.7;
}

/* ===== BOTTOM CTA ===== */
.bc-bottom-cta {
    padding: 100px 0;
    text-align: center;
    position: relative;
    background-color: transparent;
}

.bc-bottom-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--bc-gradient-accent);
    border-radius: 2px;
}

/* ===== CONTACT DETAILS ===== */
.bc-contact-details {
    display: grid;
    gap: 20px;
    margin: 0;
}

.bc-contact-detail {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.bc-contact-detail-icon {
    color: var(--bc-accent) !important;
    font-size: 1.4rem !important;
    margin-top: 2px;
}

.bc-contact-detail dt {
    margin-bottom: 2px;
    font-family: var(--bc-font-mono);
    font-size: 0.62rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--bc-text-muted);
}

.bc-contact-detail dd {
    margin: 0;
    font-size: 0.95rem;
    color: var(--bc-text-primary);
}

/* The form's 48px padding crowds phone-width fields. */
@media (max-width: 599px) {
    .bc-contact-form-wrapper {
        padding: 24px !important;
    }
}

/* ===== TECH CHIPS ===== */
.bc-tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.bc-tech-chip {
    border-color: var(--bc-border) !important;
    color: var(--bc-text-secondary) !important;
    font-size: 0.72rem !important;
    height: 26px !important;
}

/* ===== FOOTER ===== */
.bc-footer-heading {
    font-family: var(--bc-font-heading) !important;
    color: var(--bc-text-primary) !important;
    font-weight: 700 !important;
}

.bc-footer-nav .mud-nav-link {
    color: var(--bc-text-secondary) !important;
    font-size: 0.85rem !important;
    padding: 4px 0 !important;
    min-height: 0 !important;
    transition: color var(--bc-transition) !important;
}

.bc-footer-nav .mud-nav-link:hover {
    color: var(--bc-accent) !important;
    background-color: transparent !important;
}

.bc-footer-nav .mud-nav-link.active {
    color: var(--bc-text-secondary) !important;
    background-color: transparent !important;
    font-weight: 400 !important;
}

.bc-footer-nav .mud-nav-link.active:hover {
    color: var(--bc-accent) !important;
}

.bc-footer-cta-btn {
    border-color: var(--bc-accent-border) !important;
    color: var(--bc-accent) !important;
    text-transform: none !important;
    font-size: 0.82rem !important;
    font-weight: 600 !important;
    transition: all var(--bc-transition) !important;
}

.bc-footer-cta-btn:hover {
    background-color: var(--bc-accent-dim) !important;
    border-color: var(--bc-accent) !important;
}

/* ===== BLAZOR ERROR BOUNDARY ===== */
.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

/* ===== BLUEPRINT PRIMITIVES ===== */

/* Technical annotation label */
.bc-annotation {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--bc-font-mono);
    color: var(--bc-accent-light);
    letter-spacing: 2.5px;
    text-transform: uppercase;
    font-size: 0.72rem;
    font-weight: 500;
}

.bc-annotation::before {
    content: '';
    width: 22px;
    height: 1px;
    background: var(--bc-accent);
    opacity: 0.6;
}

/* Dimension divider: a measured line with arrowheads */
.bc-dimension {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 18px auto 40px;
    max-width: 320px;
}

.bc-dimension-line {
    flex: 1;
    height: 1px;
    background: var(--bc-accent);
    opacity: 0.5;
    position: relative;
}

.bc-dimension-line::before,
.bc-dimension-line::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 6px;
    height: 6px;
    border-top: 1px solid var(--bc-accent);
    border-right: 1px solid var(--bc-accent);
}

.bc-dimension-line::before { left: 0;  transform: translateY(-50%) rotate(-135deg); }
.bc-dimension-line::after  { right: 0; transform: translateY(-50%) rotate(45deg); }

.bc-dimension-measure {
    font-family: var(--bc-font-mono);
    font-size: 0.7rem;
    letter-spacing: 1.5px;
    color: var(--bc-accent);
    white-space: nowrap;
}

/* Spec-sheet card */
.bc-spec-card {
    background-color: var(--bc-bg-surface);
    border: 1px solid var(--bc-border);
    border-radius: var(--bc-radius);
    transition: all var(--bc-transition);
    height: 100%;
    overflow: hidden;
}

.bc-spec-card:hover {
    border-color: var(--bc-accent-border);
    background-color: var(--bc-bg-elevated);
}

.bc-spec-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 16px;
    border-bottom: 1px solid var(--bc-border);
    font-family: var(--bc-font-mono);
    font-size: 0.62rem;
    letter-spacing: 1.5px;
    color: var(--bc-text-muted);
    text-transform: uppercase;
}

.bc-spec-card-body { padding: 24px 20px; }

/* Drawing title block */
.bc-title-block {
    display: grid;
    grid-template-columns: 2fr 1fr;
    border: 1px solid var(--bc-accent-border);
    border-radius: 2px;
    font-family: var(--bc-font-mono);
    max-width: 360px;
}

.bc-title-block-cell {
    padding: 8px 12px;
    border-right: 1px solid var(--bc-accent-border);
}

.bc-title-block-cell:last-child { border-right: none; }

.bc-title-block-label {
    display: block;
    font-size: 0.58rem;
    letter-spacing: 1.5px;
    color: var(--bc-text-muted);
    text-transform: uppercase;
    margin-bottom: 2px;
}

.bc-title-block-value {
    font-size: 0.78rem;
    letter-spacing: 1px;
    color: var(--bc-text-primary);
}

/* BOM / schedule table for capabilities */
.bc-schedule {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--bc-font-body);
}

.bc-schedule th {
    text-align: left;
    font-family: var(--bc-font-mono);
    font-size: 0.62rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--bc-text-muted);
    padding: 12px 16px;
    border-bottom: 1px solid var(--bc-accent-border);
}

.bc-schedule td {
    padding: 16px;
    border-bottom: 1px solid var(--bc-border);
    color: var(--bc-text-secondary);
    font-size: 0.9rem;
    vertical-align: top;
}

.bc-schedule tr:hover td { background-color: rgba(249, 115, 22, 0.03); }

.bc-schedule-part {
    font-family: var(--bc-font-mono);
    color: var(--bc-accent);
    font-size: 0.78rem;
    white-space: nowrap;
}

.bc-schedule-name {
    color: var(--bc-text-primary);
    font-weight: 700;
    font-family: var(--bc-font-heading);
}

/* Proof strip */
.bc-proof-strip {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    padding: 48px 0;
}

.bc-proof-item {
    text-align: center;
    padding: 0 28px;
    border-left: 1px solid var(--bc-border);
}

.bc-proof-item:first-child { border-left: none; }

.bc-proof-measure {
    font-family: var(--bc-font-mono);
    font-size: 0.62rem;
    letter-spacing: 2px;
    color: var(--bc-accent);
    text-transform: uppercase;
    display: block;
    margin-bottom: 6px;
}

.bc-proof-value {
    font-family: var(--bc-font-heading);
    font-weight: 900;
    font-size: 2rem;
    color: var(--bc-text-primary);
    line-height: 1;
}

.bc-proof-label {
    display: block;
    margin-top: 6px;
    font-size: 0.8rem;
    color: var(--bc-text-secondary);
}

/* Dimensioned process line */
.bc-process-line {
    position: relative;
}

@media (min-width: 960px) {
    .bc-process-line::before {
        content: '';
        position: absolute;
        top: 28px;
        left: 12%;
        right: 12%;
        height: 1px;
        background: var(--bc-accent);
        opacity: 0.4;
    }
}

/* ===== LAYOUT: APP BAR & NAV ===== */
.bc-appbar {
    border-bottom: 1px solid rgba(249, 115, 22, 0.12);
}

/* Wordmark — the logo's own Source Sans Black setting */
.bc-brand {
    font-family: var(--bc-font-heading);
    font-weight: 900;
    font-size: 1.45rem;
    line-height: 1;
    letter-spacing: 0.2px;
    color: var(--bc-text-primary);
    text-decoration: none;
    transition: color var(--bc-transition);
}

a.bc-brand:hover {
    color: var(--bc-accent-light);
}

.bc-nav-btn {
    color: var(--bc-text-secondary) !important;
    font-size: 0.92rem !important;
    font-weight: 500 !important;
    letter-spacing: 0.2px !important;
    text-transform: none !important;
    padding: 8px 18px !important;
    border-radius: var(--bc-radius) !important;
    transition: all var(--bc-transition) !important;
}

.bc-nav-btn:hover,
.bc-nav-btn[aria-current="page"] {
    color: var(--bc-text-primary) !important;
    background-color: rgba(249, 115, 22, 0.08) !important;
}

.bc-nav-btn[aria-current="page"] {
    box-shadow: inset 0 -2px 0 var(--bc-accent) !important;
}

.bc-cta-btn {
    background: var(--bc-gradient-accent) !important;
    color: var(--bc-on-accent) !important;
    text-transform: none !important;
    font-weight: 600 !important;
    font-size: 0.88rem !important;
    letter-spacing: 0.2px !important;
    border-radius: var(--bc-radius) !important;
    padding: 8px 22px !important;
    box-shadow: none !important;
    transition: all var(--bc-transition) !important;
}

.bc-cta-btn:hover {
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35) !important;
    transform: translateY(-1px);
}

.bc-menu-btn {
    color: var(--bc-text-primary) !important;
}

.bc-brand:focus-visible,
.bc-nav-btn:focus-visible,
.bc-cta-btn:focus-visible,
.bc-menu-btn:focus-visible {
    outline: 2px solid var(--bc-accent-light) !important;
    outline-offset: 2px;
}

/* ===== LAYOUT: MOBILE NAV (native popover) ===== */
/* Only :popover-open may set display — an author display rule would override
   the UA's hidden-popover display:none and pin the menu open. */
.bc-mobile-nav {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(320px, 86vw);
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    border: none;
    border-left: 1px solid var(--bc-border);
    background: var(--bc-bg-primary);
    color: var(--bc-text-primary);
    flex-direction: column;
    box-shadow: -24px 0 48px rgba(0, 0, 0, 0.5);
    transform: translateX(100%);
    transition: transform 0.25s ease, overlay 0.25s allow-discrete, display 0.25s allow-discrete;
}

.bc-mobile-nav:popover-open {
    display: flex;
    transform: translateX(0);
}

@starting-style {
    .bc-mobile-nav:popover-open {
        transform: translateX(100%);
    }
}

.bc-mobile-nav::backdrop {
    background: rgba(14, 12, 10, 0.6);
}

.bc-mobile-nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 80px;
    padding: 0 12px 0 20px;
    border-bottom: 1px solid var(--bc-border);
}

.bc-nav-menu .mud-nav-link {
    color: var(--bc-text-secondary);
    border-radius: var(--bc-radius);
    transition: all 0.2s ease;
}

.bc-nav-menu .mud-nav-link:hover {
    background-color: rgba(249, 115, 22, 0.08);
    color: var(--bc-text-primary);
}

.bc-nav-menu .mud-nav-link.active {
    color: var(--bc-text-primary);
    background-color: rgba(249, 115, 22, 0.12);
}

/* ===== LAYOUT: MAIN & FOOTER ===== */
.bc-main-content {
    padding-top: 0 !important;
    background-color: transparent !important;
    position: relative;
    z-index: 1;
}

.bc-footer {
    border-top: 1px solid rgba(249, 115, 22, 0.10);
    padding: 56px 0 32px;
    background-color: rgba(14, 12, 10, 0.8);
    margin-top: 40px;
}

.bc-footer-text {
    color: var(--bc-text-muted) !important;
    font-size: 0.85rem !important;
    line-height: 1.7 !important;
}

/* Blazor error UI */
#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

/* ===== POLISH ===== */
:root {
    color-scheme: dark; /* native scrollbars, form controls and autofill match the theme */
}

::selection {
    background-color: rgba(249, 115, 22, 0.35);
    color: var(--bc-text-primary);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
    outline: 2px solid var(--bc-accent-light);
    outline-offset: 2px;
}

.mud-typography-h1, .mud-typography-h2, .mud-typography-h3,
.mud-typography-h4, .mud-typography-h5, .mud-typography-h6 {
    text-wrap: balance;
}

.mud-typography-body1,
.mud-typography-body2 {
    text-wrap: pretty;
}

/* Frosted app bar over the moving machinery */
@supports (backdrop-filter: blur(1px)) {
    .bc-appbar {
        background-color: rgba(19, 17, 16, 0.72) !important;
        backdrop-filter: blur(14px) saturate(140%);
    }
}

/* Draftsman motion: dimension lines draw themselves as they scroll into view.
   Scroll-driven (no JS); browsers without support just show the finished line. */
@keyframes bc-draw-line {
    from { transform: scaleX(0); }
    to   { transform: scaleX(1); }
}

@supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
        .bc-dimension-line,
        .bc-process-line::before {
            animation: bc-draw-line linear both;
            animation-timeline: view();
            animation-range: entry 20% cover 40%;
        }

        /* Lines grow outward from the measurement between them. */
        .bc-dimension-line:first-child { transform-origin: right center; }
        .bc-dimension-line:last-child  { transform-origin: left center; }
        .bc-dimension-line:only-child,
        .bc-process-line::before       { transform-origin: center; }
    }
}

/* FAQ answers slide open where the browser can animate to height: auto */
@supports (interpolate-size: allow-keywords) {
    :root {
        interpolate-size: allow-keywords;
    }

    .bc-faq-item::details-content {
        block-size: 0;
        overflow: hidden;
        transition: block-size 0.3s ease, content-visibility 0.3s allow-discrete;
    }

    .bc-faq-item[open]::details-content {
        block-size: auto;
    }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
