/*
 * SheetCRM site-wide styles: header, footer and 404.
 * Landing and privacy pages carry their own inline styles (blank canvas layout).
 */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,600;12..96,800&family=Instrument+Sans:wght@400;500;600&family=IBM+Plex+Mono:wght@400;500&display=swap');

body.codecanvas-theme { background: #f4f7f3 !important; }

/*
 * Blank-canvas pages (landing, privacy) bring their own header, sections and
 * footer, so the theme's reading-column wrappers must not constrain them.
 */
body.codecanvas-blank-layout .cc-main,
body.codecanvas-blank-layout .cc-main > .cc-container,
body.codecanvas-blank-layout .cc-main > .cc-section,
body.codecanvas-blank-layout .cc-main > article,
body.codecanvas-blank-layout .cc-main .cc-prose {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
body.codecanvas-blank-layout .cc-prose > .sc,
body.codecanvas-blank-layout .cc-prose > .sp {
    width: 100%;
    max-width: none;
    margin: 0;
}

/* Keep the in-page sticky nav clear of the WordPress admin bar when logged in. */
.admin-bar .sc .sc-nav,
.admin-bar .sp .sp-nav { top: 32px; }
@media (max-width: 782px) {
    .admin-bar .sc .sc-nav,
    .admin-bar .sp .sp-nav { top: 46px; }
}

.sx-nav, .sx-foot, .sx-404 {
    --ink: #13241b; --ink2: #3d4b43; --mute: #66756b; --paper: #f4f7f3; --line: #d7e0d9;
    --green: #2f6f4f; --greend: #1f4e37; --mint: #e1eee5; --amber-s: #fff4cc;
    font-family: 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    line-height: 1.6;
}
.sx-nav *, .sx-foot *, .sx-404 * { box-sizing: border-box; }
.sx-wrap { width: min(calc(100% - 48px), 1140px); margin-inline: auto; }

/* Buttons */
.sx-nav .sx-btn, .sx-404 .sx-btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 50px; padding: 12px 26px; border: 2px solid var(--green); border-radius: 6px;
    background: var(--green); color: #fff; font-weight: 600; font-size: 16px; text-decoration: none;
    transition: background .15s, border-color .15s;
}
.sx-nav .sx-btn:hover, .sx-404 .sx-btn:hover { background: var(--greend); border-color: var(--greend); color: #fff; }
.sx-nav .sx-btn-sm { min-height: 40px; padding: 8px 18px; font-size: 14.5px; }
.sx-404 .sx-btn-line { background: transparent; color: var(--ink); border-color: var(--ink); }
.sx-404 .sx-btn-line:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.sx-nav :focus-visible, .sx-foot :focus-visible, .sx-404 :focus-visible { outline: 3px solid #7fb996; outline-offset: 2px; }

/* Header */
.sx-nav { position: sticky; top: 0; z-index: 50; background: rgba(244, 247, 243, .94); border-bottom: 1px solid var(--line); backdrop-filter: blur(10px); }
.admin-bar .sx-nav { top: 32px; }
.sx-nav .sx-wrap { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.sx-nav .sx-brand, .sx-foot .sx-brand {
    display: inline-flex; align-items: center; gap: 10px; color: var(--ink);
    font-family: 'Bricolage Grotesque', 'Instrument Sans', sans-serif; font-weight: 800; font-size: 20px;
    letter-spacing: -.03em; text-decoration: none;
}
.sx-nav .sx-brand svg, .sx-foot .sx-brand svg { width: 30px; height: 30px; flex: 0 0 30px; }
.sx-nav .sx-logo img { max-height: 36px; width: auto; }
.sx-nav .sx-links { display: flex; gap: 26px; margin-left: auto; }
.sx-nav .sx-links a { font-size: 15px; font-weight: 500; color: var(--ink2); text-decoration: none; }
.sx-nav .sx-links a:hover { color: var(--green); }
.sx-nav .sx-navcta { display: flex; gap: 10px; align-items: center; }
.sx-nav .sx-navcta .sx-signin { font-size: 15px; font-weight: 500; color: var(--ink); text-decoration: none; padding: 8px 6px; }
.sx-nav .sx-navcta .sx-signin:hover { color: var(--green); }

/* 404 */
.sx-404 {
    position: relative; overflow: hidden; display: flex; align-items: center;
    min-height: min(72vh, 680px); padding-block: clamp(48px, 8vw, 110px);
    background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: 100% 44px, 120px 100%; background-position: 0 -1px, -1px 0;
}
.sx-404:after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(244, 247, 243, .5), var(--paper) 96%); pointer-events: none; }
.sx-404 .sx-wrap { position: relative; z-index: 1; }
.sx-404 .sx-formula {
    display: flex; max-width: 460px; margin: 0 0 14px; overflow: hidden; background: #fff;
    border: 1.5px solid var(--ink); border-radius: 6px;
    font-family: 'IBM Plex Mono', ui-monospace, monospace; font-size: 13px; color: var(--mute);
}
.sx-404 .sx-formula i { font-style: normal; font-weight: 500; color: var(--ink); padding: 8px 14px; background: var(--mint); border-right: 1.5px solid var(--ink); }
.sx-404 .sx-formula span { padding: 8px 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sx-404 .sx-cell {
    position: relative; display: inline-block; margin: 0 0 28px; padding: 10px clamp(20px, 4vw, 38px);
    background: #fff; border: 2.5px solid var(--green);
    font-family: 'IBM Plex Mono', ui-monospace, monospace; font-weight: 500;
    font-size: clamp(54px, 10vw, 104px); line-height: 1.1; letter-spacing: -.03em; color: var(--ink);
}
.sx-404 .sx-cell:after { content: ""; position: absolute; right: -7px; bottom: -7px; width: 12px; height: 12px; background: var(--green); border: 2px solid #fff; }
.sx-404 .sx-404-title {
    margin: 0; font-family: 'Bricolage Grotesque', 'Instrument Sans', sans-serif; font-weight: 800;
    font-size: clamp(34px, 5.2vw, 56px); line-height: 1.05; letter-spacing: -.035em; color: var(--ink);
}
.sx-404 .sx-404-text { margin: 18px 0 28px; max-width: 520px; font-size: 18px; line-height: 1.65; color: var(--ink2); }
.sx-404 .sx-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.sx-404 .sx-404-links { margin: 28px 0 0; font-size: 15px; color: var(--mute); }
.sx-404 .sx-404-links a { margin-left: 14px; color: var(--green); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.sx-404 .sx-404-links a:hover { color: var(--greend); }

/* Footer */
.sx-foot { background: #0f1c15; color: #a9bdb0; padding-block: 44px 28px; font-size: 14.5px; }
.sx-foot .sx-foot-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; }
.sx-foot .sx-brand { color: #fff; }
.sx-foot .sx-foot-brand p { margin: 10px 0 0; max-width: 300px; line-height: 1.55; color: #a9bdb0; }
.sx-foot h4 { margin: 0 0 12px; font-family: 'Instrument Sans', sans-serif; font-size: 13px; font-weight: 600; letter-spacing: .02em; color: #fff; }
.sx-foot .sx-foot-grid a:not(.sx-brand) { display: block; margin-bottom: 8px; color: #b9cbbf; text-decoration: none; }
.sx-foot .sx-foot-grid a:not(.sx-brand):hover { color: #fff; text-decoration: underline; }
.sx-foot .sx-foot-bottom {
    display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px;
    margin-top: 32px; padding-top: 18px; border-top: 1px solid #243a2d; font-size: 13px; color: #8aa194;
}
.sx-foot .sx-attr a { color: #b9cbbf; text-decoration: underline; text-underline-offset: 3px; }
.sx-foot .sx-attr a:hover { color: #fff; }

@media (max-width: 1000px) {
    .sx-foot .sx-foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
    .sx-nav .sx-links { display: none; }
    .sx-nav .sx-navcta { margin-left: auto; }
}
@media (max-width: 782px) {
    .admin-bar .sx-nav { top: 46px; }
}
@media (max-width: 620px) {
    .sx-wrap { width: min(calc(100% - 32px), 1140px); }
    .sx-nav .sx-navcta .sx-signin { display: none; }
    .sx-foot .sx-foot-grid { grid-template-columns: 1fr; }
    .sx-404 .sx-formula span { font-size: 12px; }
}
