/* company.css -- the shared look of LinuxBusiness.com, LinuxBusiness.org, LinuxBusinessEnterprise.com and
   GoodBusinessSoftware.com.  Each site sets --accent / --accent-dark (company.py) and adds css/site.css. */

:root {
    --ac: var(--accent);
    --bg: #f6f7fb;
    --bg-2: #eef1f7;
    --surface: #ffffff;
    --text: #141826;
    --muted: #586178;
    --border: #dfe3ec;
    --shadow: 0 1px 2px rgba(20, 24, 38, .06), 0 8px 24px rgba(20, 24, 38, .07);
    --shadow-lg: 0 2px 6px rgba(20, 24, 38, .08), 0 22px 48px rgba(20, 24, 38, .14);
    --radius: 16px;
    --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
    color-scheme: light;
}
html.theme-dark {
    --ac: var(--accent-dark);
    --bg: #0d1017;
    --bg-2: #131824;
    --surface: #171c28;
    --text: #e9ecf3;
    --muted: #9aa3b8;
    --border: #2a3142;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
    --shadow-lg: 0 2px 6px rgba(0, 0, 0, .5), 0 22px 48px rgba(0, 0, 0, .5);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 17px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    transition: background-color .25s, color .25s;
}
img { max-width: 100%; height: auto; }
a { color: var(--ac); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5.2vw, 3.4rem); letter-spacing: -0.025em; overflow-wrap: anywhere; }
h2 { font-size: clamp(1.55rem, 3.4vw, 2.3rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding-inline: 20px; }
.muted { color: var(--muted); }

/* -- header ------------------------------------------------------------------------------------ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    backdrop-filter: saturate(1.4);
    border-bottom: 1px solid var(--border);
    padding-top: env(safe-area-inset-top, 0px);
}
.head-row { display: flex; align-items: center; gap: 18px; min-height: 66px; }
.wordmark { font-weight: 800; font-size: 1.32rem; letter-spacing: -0.02em; white-space: nowrap; color: var(--text); }
.wordmark:hover { text-decoration: none; }
.wm-b { color: var(--ac); }
.wm-tld { color: var(--muted); font-weight: 600; font-size: .8em; }
.main-nav { display: flex; gap: 4px; margin-left: auto; flex-wrap: wrap; }
.main-nav a {
    color: var(--text);
    padding: 8px 12px;
    border-radius: 10px;
    font-weight: 600;
    font-size: .95rem;
}
.main-nav a:hover { background: var(--bg-2); text-decoration: none; }
.main-nav a.active { color: var(--ac); background: color-mix(in srgb, var(--ac) 12%, transparent); }
.main-nav a.nav-ext { position: relative; }
/* the address a menu link to another website goes to, shown as a tooltip under it */
.nav-tip {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    z-index: 60;
    padding: 7px 12px;
    border-radius: 9px;
    background: var(--text);
    color: var(--surface);
    font-size: .82rem;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translate(-50%, -4px);
    transition: opacity .15s, transform .15s, visibility .15s;
}
.nav-tip::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    margin-left: -6px;
    border: 6px solid transparent;
    border-bottom-color: var(--text);
}
.nav-tip-go { font-weight: 500; opacity: .7; }
.main-nav a.nav-ext:hover .nav-tip, .main-nav a.nav-ext:focus-visible .nav-tip {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0);
}
/* the last menu item's tooltip lines up with its right edge so it stays on screen */
.main-nav a.nav-ext:last-child .nav-tip { left: auto; right: 0; transform: translateY(-4px); }
.main-nav a.nav-ext:last-child:hover .nav-tip, .main-nav a.nav-ext:last-child:focus-visible .nav-tip { transform: none; }
.main-nav a.nav-ext:last-child .nav-tip::before { left: auto; right: 22px; }
.head-tools { display: flex; align-items: center; gap: 10px; }

/* ☀️ | 🌙 switch */
.theme-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 66px;
    height: 34px;
    padding: 0 7px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--bg-2);
    cursor: pointer;
    font-size: 15px;
    line-height: 1;
}
.theme-switch .ts-knob {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--surface);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
    transition: transform .25s ease;
    transform: translateX(32px);          /* light mode: the knob covers the moon, the sun shows */
}
html.theme-dark .theme-switch .ts-knob { transform: none; }   /* dark mode: it covers the sun, the moon shows */
.theme-switch:focus-visible, .menu-btn:focus-visible, a:focus-visible, button:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--ac) 60%, transparent);
    outline-offset: 2px;
}
.menu-btn { display: none; }

@media (max-width: 860px) {
    .menu-btn {
        display: inline-flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        width: 42px;
        height: 38px;
        padding: 0 10px;
        border: 1px solid var(--border);
        border-radius: 10px;
        background: var(--surface);
        cursor: pointer;
    }
    .menu-btn span { display: block; height: 2px; background: var(--text); border-radius: 2px; }
    .head-tools { margin-left: auto; }
    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        gap: 0;
        padding: 8px 16px 16px;
        background: var(--surface);
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow);
        display: none;
    }
    .main-nav.open { display: flex; }
    .main-nav a { padding: 13px 12px; font-size: 1.05rem; }
    /* on a phone there is no hover: the address shows quietly beside the menu item instead */
    .main-nav a.nav-ext { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 12px; }
    .nav-tip, .main-nav a.nav-ext:last-child .nav-tip,
    .main-nav a.nav-ext:hover .nav-tip, .main-nav a.nav-ext:last-child:hover .nav-tip {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        padding: 0;
        background: none;
        box-shadow: none;
        color: var(--muted);
        font-size: .82rem;
        font-weight: 600;
    }
    .nav-tip::before, .main-nav a.nav-ext:last-child .nav-tip::before { display: none; }
    .nav-tip-go { display: none; }
}

/* -- building blocks --------------------------------------------------------------------------- */
.section { padding-block: clamp(48px, 8vw, 92px); }
.section.alt { background: var(--bg-2); }
.eyebrow {
    display: inline-block;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ac);
    margin-bottom: 10px;
}
.lead { font-size: clamp(1.05rem, 2.1vw, 1.25rem); color: var(--muted); max-width: 46em; }
.section-head { max-width: 760px; margin-bottom: 36px; }
.section-head.center { margin-inline: auto; text-align: center; }
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 22px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform .15s, box-shadow .15s, background-color .15s;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--ac); color: #fff; box-shadow: 0 6px 18px color-mix(in srgb, var(--ac) 35%, transparent); }
html.theme-dark .btn-primary { color: #0d1017; }
.btn-ghost { border-color: var(--border); color: var(--text); background: var(--surface); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
}
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.icon-bubble {
    display: inline-grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    font-size: 26px;
    background: color-mix(in srgb, var(--ac) 13%, transparent);
    margin-bottom: 14px;
}
.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
.ticks li { position: relative; padding-left: 30px; margin-bottom: 8px; }
.ticks li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 1px;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 12px;
    font-weight: 800;
    color: #fff;
    background: var(--ac);
}
html.theme-dark .ticks li::before { color: #0d1017; }
.badge {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--ac) 14%, transparent);
    color: var(--ac);
}
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.shown { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
}

/* -- hero ---------------------------------------------------------------------------------------- */
.hero {
    position: relative;
    overflow: hidden;
    padding-block: clamp(56px, 10vw, 120px);
    background:
        radial-gradient(1000px 500px at 85% -10%, color-mix(in srgb, var(--ac) 22%, transparent), transparent 60%),
        radial-gradient(700px 400px at -10% 110%, color-mix(in srgb, var(--ac) 14%, transparent), transparent 60%),
        var(--bg);
}
.hero h1 .hl { color: var(--ac); }
.hero .lead { margin-top: 18px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 48px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: minmax(0, 1fr); } }

/* -- contact card (the round "i") --------------------------------------------------------------- */
.contact-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    max-width: 440px;
    padding: 20px 22px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 5px solid var(--ac);
    box-shadow: var(--shadow);
}
.contact-i {
    flex: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font: italic 800 21px/1 Georgia, "Times New Roman", serif;
    color: #fff;
    background: var(--ac);
}
html.theme-dark .contact-i { color: #0d1017; }
.contact-head { font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ac); }
.contact-name { font-size: 1.15rem; font-weight: 800; margin: 2px 0 6px; }
.contact-line { display: block; color: var(--text); font-weight: 600; margin-top: 3px; word-break: break-word; }
.contact-band { display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center; }
@media (max-width: 820px) { .contact-band { grid-template-columns: 1fr; } }

/* -- footer: the four sites ---------------------------------------------------------------------- */
.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding-block: 48px calc(28px + env(safe-area-inset-bottom, 0px));
}
.co-title { font-weight: 800; font-size: 1.05rem; margin-bottom: 16px; }
/* the footer runs a little wider than the page so "LinuxBusinessEnterprise.com" fits on one line:
   four across on a wide screen, two by two in between, one column on a phone */
.site-footer .wrap { max-width: 1400px; }
.co-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 1380px) { .co-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .co-grid { grid-template-columns: minmax(0, 1fr); } }
.co-card {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 16px 18px;
    border-radius: 14px;
    border: 1px solid var(--border);
    border-top: 4px solid var(--co);
    background: var(--bg);
    color: var(--text);
    transition: transform .15s, box-shadow .15s;
}
.co-card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow); }
.co-card.is-here { background: color-mix(in srgb, var(--co) 8%, var(--bg)); }
.co-com { --co: #1f5fbf; }
.co-org { --co: #16884a; }
.co-enterprise { --co: #5b3fd1; }
.co-software { --co: #cc2a1e; }
html.theme-dark .co-com { --co: #6ea2ff; }
html.theme-dark .co-org { --co: #4fd08a; }
html.theme-dark .co-enterprise { --co: #a693ff; }
html.theme-dark .co-software { --co: #ff7a6b; }
.co-what { font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--co); }
.co-name { font-weight: 800; word-break: break-word; }
.co-line { font-size: .9rem; color: var(--muted); }
.foot-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 10px;
    margin-top: 28px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
    font-size: .9rem;
    color: var(--muted);
}

@media (max-width: 560px) {
    body { font-size: 16px; }
    .card { padding: 20px; }
    .wordmark { font-size: 1.08rem; }
    .btn { width: 100%; justify-content: center; }
}
@media (max-width: 380px) {
    .wordmark .wm-tld { display: none; }
}
