/* ScaleBridge — shared stylesheet */

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    background: #f3f2f2;
    color: #201e1d;
    font-family: 'Archivo', -apple-system, BlinkMacSystemFont, sans-serif;
    overflow-x: hidden;
}
a { text-decoration: none; }
img { max-width: 100%; }

@keyframes riseIn { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
@keyframes wipeIn { from { opacity: 0; transform: translateX(-16px); } to { opacity: 1; transform: translateX(0); } }
.sb-reveal { animation: riseIn linear both; animation-timeline: view(); animation-range: entry 0% cover 28%; }
.sb-reveal-x { animation: wipeIn linear both; animation-timeline: view(); animation-range: entry 0% cover 28%; }
@supports not (animation-timeline: view()) {
    .sb-reveal, .sb-reveal-x { animation: none; opacity: 1; transform: none; }
}

/* Nav */
.nav {
    position: sticky; top: 0; z-index: 50;
    display: flex; align-items: center; gap: 2rem; flex-wrap: wrap;
    padding: 1rem clamp(1.25rem,5vw,3rem);
    background: #f3f2f2;
    border-bottom: 2px solid rgba(32,30,29,0.4);
}
.nav-logo { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em; color: #201e1d; margin-right: auto; }
.nav-drawer { display: contents; }
.nav-links { display: flex; gap: 1.75rem; flex-wrap: wrap; font-size: 0.85rem; font-weight: 600; }
.navlink { color: #201e1d; transition: color 0.15s ease; }
.navlink:hover, .navlink.active { color: #ec3013; }
.nav-actions { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.nav-underline {
    font-size: 0.82rem; font-weight: 800; color: #201e1d;
    border-bottom: 1px solid #201e1d; padding-bottom: 2px;
    transition: color 0.15s ease, border-color 0.15s ease;
}
.nav-underline:hover { color: #ec3013; border-color: #ec3013; }

/* Mobile nav toggle (checkbox hack — no JS needed) */
.nav-toggle-checkbox { display: none; }
.nav-toggle-btn { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 26px; height: 22px; cursor: pointer; margin-left: auto; order: 2; }
.nav-toggle-btn span { display: block; height: 2px; width: 100%; background: #201e1d; transition: transform 0.2s ease, opacity 0.2s ease; }
.nav-toggle-checkbox:checked ~ .nav-toggle-btn span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle-checkbox:checked ~ .nav-toggle-btn span:nth-child(2) { opacity: 0; }
.nav-toggle-checkbox:checked ~ .nav-toggle-btn span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Buttons */
.btn { display: inline-block; font-weight: 800; font-size: 0.92rem; padding: 0.95rem 1.6rem; cursor: pointer; border: none; transition: background 0.15s ease, color 0.15s ease; }
.btn-sm { font-size: 0.82rem; padding: 0.7rem 1.2rem; }
.btn-primary { background: #ec3013; color: #f3f2f2; }
.btn-primary:hover { background: #dd2b0f; }
.btn-dark { background: #201e1d; color: #f3f2f2; }
.btn-dark:hover { background: #ec3013; }
.btn-outline { border: 1px solid rgba(32,30,29,0.4); color: #201e1d; background: transparent; }
.btn-outline:hover { background: rgba(32,30,29,0.06); }
.btn-outline-dark { border: 1px solid #201e1d; color: #201e1d; background: transparent; }
.btn-outline-dark:hover { background: #201e1d; color: #f3f2f2; }
.btn-white { background: #f3f2f2; color: #201e1d; }
.btn-white:hover { background: #201e1d; color: #f3f2f2; }
.btn:disabled { background: rgba(32,30,29,0.25) !important; color: #f3f2f2 !important; cursor: not-allowed !important; }

/* Links */
.link-accent { font-size: 0.85rem; font-weight: 800; color: #ae1800; transition: color 0.15s ease; }
.link-accent:hover { color: #ec3013; }

/* Card link (What We Do rows) */
.card-link { display: block; color: #201e1d; transition: background 0.15s ease; }
.card-link:hover { background: #eae9e9; }

/* Footer */
.footer { padding: clamp(3rem,5vw,4.5rem) clamp(1.25rem,5vw,3rem) 2rem; background: #201e1d; color: rgba(243,242,242,0.75); }
.footer-inner { max-width: 1280px; margin: 0 auto; display: flex; justify-content: space-between; gap: 3rem; flex-wrap: wrap; padding-bottom: 2.5rem; border-bottom: 2px solid rgba(243,242,242,0.2); }
.footer-brand { max-width: 20rem; }
.footer-brand-name { font-weight: 800; font-size: 1.1rem; color: #f3f2f2; letter-spacing: -0.02em; margin-bottom: 1rem; }
.footer-cols { display: flex; gap: clamp(2.5rem,6vw,5rem); flex-wrap: wrap; }
.footer-col { display: flex; flex-direction: column; gap: 0.65rem; font-size: 0.85rem; }
.footer-col-title { font-weight: 800; color: #f3f2f2; margin-bottom: 0.2rem; }
.footer-link { color: inherit; transition: color 0.15s ease; }
.footer-link:hover { color: #ec3013; }
.footer-bottom { max-width: 1280px; margin: 0 auto; padding-top: 1.4rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: 0.76rem; color: rgba(243,242,242,0.45); }

/* Forms */
.sb-input {
    width: 100%; min-height: 44px; padding: 10px 12px;
    font-family: 'Archivo', sans-serif; font-size: 0.95rem; color: #201e1d;
    background: #eae9e9; border: 1px solid rgba(32,30,29,0.4); border-radius: 0;
}
.sb-input:focus-visible { outline: 2px solid #ec3013; outline-offset: 0; border-color: #ec3013; }
textarea.sb-input { font-family: 'Archivo', sans-serif; }
.sb-seg { display: inline-flex; overflow: hidden; border: 1px solid rgba(32,30,29,0.4); flex-wrap: wrap; }
.sb-seg label { display: inline-flex; align-items: center; padding: 8px 14px; font-size: 0.85rem; cursor: pointer; border-right: 1px solid rgba(32,30,29,0.4); }
.sb-seg label:last-child { border-right: none; }

.sb-seg input { position: absolute; opacity: 0; width: 0; height: 0; }
.sb-seg label:has(input:checked) { background: #ec3013; color: #f3f2f2; font-weight: 700; }
.form-label { display: block; font-size: 0.78rem; font-weight: 700; margin-bottom: 0.4rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

/* Multi-step option rows (Submit an Opportunity) */
.opt-row { padding: 1rem 0.2rem; border-bottom: 1px solid rgba(32,30,29,0.4); font-size: 0.95rem; font-weight: 500; color: #201e1d; cursor: pointer; transition: color 0.1s ease, font-weight 0.1s ease; }
.opt-row:hover { color: #ec3013; }
.opt-row.selected { font-weight: 800; color: #ec3013; }
.step-bar-track { display: flex; gap: 0.4rem; margin-bottom: 0.6rem; }
.step-bar-seg { flex: 1; height: 4px; background: rgba(32,30,29,0.2); }
.step-bar-seg.active { background: #ec3013; }
.file-drop { display: flex; flex-direction: column; align-items: flex-start; gap: 0.8rem; padding: 2rem; border: 1px dashed rgba(32,30,29,0.4); background: #eae9e9; cursor: pointer; position: relative; }
.file-drop input[type="file"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.form-success { padding: 0.9rem 1rem; background: #eae9e9; border-left: 3px solid #ec3013; font-size: 0.9rem; margin-top: 1rem; display: none; }
.form-success.show { display: block; }
.form-error { padding: 0.9rem 1rem; background: #fdeceb; border-left: 3px solid #ec3013; color: #ae1800; font-size: 0.9rem; margin-top: 1rem; display: none; }
.form-error.show { display: block; }

@media (max-width: 760px) {
    .nav { padding: 0.85rem 1.25rem !important; gap: 0 !important; position: relative; }
    .nav-toggle-btn { display: flex !important; }
    .nav-drawer {
          display: block !important;
          position: absolute; top: 100%; left: 0; right: 0;
          background: #f3f2f2;
          border-bottom: 2px solid rgba(32,30,29,0.4);
          max-height: 0; overflow: hidden;
          transition: max-height 0.25s ease;
    }
    .nav-toggle-checkbox:checked ~ .nav-drawer { max-height: 480px; }
    .nav-links { flex-direction: column !important; gap: 0 !important; padding: 0.5rem 1.25rem; }
    .nav-links .navlink { padding: 0.75rem 0; border-bottom: 1px solid rgba(32,30,29,0.15); }
    .nav-actions { flex-direction: column !important; align-items: stretch !important; gap: 0.75rem !important; padding: 1rem 1.25rem 1.25rem; }
    .nav-actions .nav-underline { text-align: center; border-bottom: none; padding: 0.6rem 0; }
    .nav-actions .btn { text-align: center; }
    [style*="grid-template-columns"] { grid-template-columns: 1fr !important; }
    [style*="display:flex"][style*="justify-content:space-between"] { flex-direction: column !important; align-items: flex-start !important; }
    [style*="display: flex"][style*="justify-content: space-between"] { flex-direction: column !important; align-items: flex-start !important; }
    section img { height: auto !important; max-height: 260px; }
    section [style*="height:340px"] { height: auto !important; }
    section [style*="height:100%"] svg { display: none; }
    figure { border-right: none !important; }
    .footer-inner { flex-direction: column !important; gap: 2rem !important; }
    .footer-cols { flex-direction: column !important; gap: 2rem !important; }
    .footer-bottom { flex-direction: column !important; gap: 0.5rem !important; align-items: flex-start !important; }
    section { padding-left: 1.25rem !important; padding-right: 1.25rem !important; }
    h1, h2 { word-break: break-word; }
    #step-bar { flex-wrap: wrap; }
}
