/* openglacier: the site's background behind every page, the content on a translucent card. */
/* The image is blended with the navy once and for all (soft-light, media/background-soft.jpg): a live
   background-blend-mode on a fixed background flickers back to the raw image when the browser recomposites. */
html { min-height: 100%; background: #000731; }
body { min-height: 100vh; background: transparent; }
/* A fixed layer rather than background-attachment: fixed, which repaints on scroll and is ignored on iOS. */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background: #000731 url("../media/background-soft.jpg") center top / cover no-repeat;
    pointer-events: none;
}
.page-wrapper, .page, #mdbook-content, .content { background: transparent; }
.menu-bar, .menu-bar.sticky, #mdbook-menu-bar { background-color: color-mix(in srgb, var(--bg) 70%, transparent); backdrop-filter: blur(6px); }
.content main {
    margin-top: 1.5rem;
    margin-bottom: 3rem;
    padding: 1.5rem 2rem 2rem;
    border-radius: 14px;
    background: color-mix(in srgb, var(--bg) 82%, transparent);
    backdrop-filter: blur(8px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}
.sidebar { background-color: color-mix(in srgb, var(--sidebar-bg) 86%, transparent); backdrop-filter: blur(6px); }

/* The hero of the first page, as on openglacier.org. */
.og-hero {
    margin: -1.5rem -2rem 2rem;
    padding: 4.5rem 2rem 3rem;
    border-radius: 14px 14px 0 0;
    text-align: center;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(0, 7, 49, 0.15), rgba(0, 7, 49, 0.75)), url("../media/background.jpg") center 30% / cover no-repeat;
}
.og-hero-logo {
    width: 128px;
    height: 128px;
    filter: drop-shadow(0 0 18px rgba(159, 208, 255, 0.55));
}
.og-hero-name { margin-top: 1rem; font-size: 4.2rem; font-weight: 700; line-height: 1; text-transform: lowercase; }
.og-hero-line { margin-top: 1rem; font-size: 1.45rem; }
.og-hero-note { margin-top: 1.6rem; font-size: 1rem; opacity: 0.9; }
.og-hero a { color: #9fd0ff; }
/* The page title is the hero itself; the heading stays for the search and the browser tab. */
.og-hero + h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

.og-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 1.5rem 0; }
.og-card {
    display: grid;
    gap: 6px;
    padding: 14px 16px;
    border: 1px solid color-mix(in srgb, var(--fg) 18%, transparent);
    border-radius: 12px;
    background: color-mix(in srgb, var(--bg) 60%, transparent);
    color: var(--fg) !important;
    text-decoration: none !important;
    transition: transform 0.15s ease, border-color 0.15s ease;
}
.og-card:hover { transform: translateY(-2px); border-color: var(--links); }
.og-card strong { color: var(--links); }
.og-card span { font-size: 0.9em; opacity: 0.85; overflow-wrap: anywhere; }

.og-about { display: flex; gap: 1.5rem; align-items: flex-start; }
.og-about img { width: 160px; height: 160px; flex: none; border-radius: 50%; object-fit: cover; }
.og-about > div > p:first-child { margin-top: 0; }

.og-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 10px;
    margin-top: 2.5rem;
    padding-top: 1rem;
    border-top: 1px solid color-mix(in srgb, var(--fg) 20%, transparent);
    font-size: 0.9em;
    opacity: 0.85;
}

@media (max-width: 640px) {
    .content main { padding: 1rem 1rem 1.5rem; }
    .og-hero { margin: -1rem -1rem 1.5rem; padding: 3rem 1rem 2rem; }
    .og-hero-name { font-size: 2.8rem; }
    .og-about { flex-direction: column; align-items: center; }
}

/* The book is always navy: no theme picker. */
#mdbook-theme-toggle, #mdbook-theme-list { display: none !important; }

/* glacierdb page: the product header and the download panel. */
.og-product { display: flex; gap: 1.2rem; align-items: center; margin: 0.5rem 0 1.5rem; }
.og-product > img { width: 84px; height: 84px; flex: none; filter: drop-shadow(0 0 14px rgba(159, 208, 255, 0.5)); }
.og-product p { margin: 0.3rem 0; }
.og-product p img { vertical-align: middle; }
.og-downloads {
    display: grid;
    gap: 12px;
    margin: 1.5rem 0 2.5rem;
    padding: 16px 18px;
    border: 1px solid color-mix(in srgb, var(--links) 40%, transparent);
    border-radius: 12px;
    background: color-mix(in srgb, var(--bg) 60%, transparent);
}
.og-downloads-head { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; }
.og-downloads-head strong { font-size: 1.1em; }
.og-downloads-version { opacity: 0.75; font-size: 0.9em; }
.og-downloads-head a { margin-left: auto; font-size: 0.9em; }
.og-downloads-os { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 10px; align-items: start; }
.og-downloads-system { padding-top: 6px; font-weight: 600; opacity: 0.85; white-space: nowrap; }
.og-downloads-os > div { display: flex; flex-wrap: wrap; gap: 6px; }
.og-download {
    display: inline-flex;
    flex-direction: column;
    padding: 5px 11px;
    border: 1px solid color-mix(in srgb, var(--fg) 18%, transparent);
    border-radius: 9px;
    font-weight: 600;
    text-decoration: none !important;
    line-height: 1.3;
}
.og-download:hover { border-color: var(--links); }
.og-download small { font-weight: 400; font-size: 0.75em; color: var(--fg); opacity: 0.7; }
@media (max-width: 640px) {
    .og-downloads-os { grid-template-columns: 1fr; }
    .og-product { flex-direction: column; text-align: center; }
}
.og-button {
    display: inline-block;
    margin-top: 0.4rem;
    padding: 7px 14px;
    border: 1px solid var(--links);
    border-radius: 999px;
    background: color-mix(in srgb, var(--links) 16%, transparent);
    font-weight: 600;
    text-decoration: none !important;
}
.og-button:hover { background: color-mix(in srgb, var(--links) 28%, transparent); }
