/* Gitwick brand layer. Colours come from theme-gitwick-*.css; this file is layout + type. */

/* Self-hosted type (OFFLINE_MODE, no CDN). Space Grotesk: UI, Colophon Foundry, London. JetBrains Mono: headings and code. Both OFL, latin subset. */
@font-face {
  font-family: "Space Grotesk"; font-style: normal; font-weight: 300 700; font-display: swap;
  src: url("../fonts/SpaceGrotesk-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: 100 800; font-display: swap;
  src: url("../fonts/JetBrainsMono-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;
}
:root {
  --fonts-override: "Space Grotesk";                                  /* Forgejo hook: feeds --fonts-regular */
  --fonts-monospace: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace, var(--fonts-emoji);
}

/* ---- platform-wide touches ---- */
:root { --border-radius: 3px; --border-radius-medium: 5px; }   /* sharp corners */
#navbar { position: sticky; top: 0; z-index: 100; color: #d7e0d4; border-bottom: 1px solid #1f2a21; }   /* dark in both themes */
#navbar .item, #navbar summary, #navbar .navbar-wordmark { color: #d7e0d4; }
#navbar .item:hover, #navbar .item.active { background: #1f2a21; color: #39ff7a; }
#navbar .dropdown .content { color: var(--color-text); }

/* repo/org/user lists (explore, dashboard, profile) as cards instead of ruled rows */
.flex-list > .flex-item {
  background: var(--color-card);
  border: 1px solid var(--color-light-border);
  border-radius: var(--border-radius-medium);
  padding: 1rem 1.25rem;
  margin-bottom: 0.75rem;
}
.flex-list > .flex-item.flex-item.flex-item:first-child { padding-top: 1rem; }   /* outranks Forgejo's .divider + .flex-list > .flex-item:first-child */
.flex-list > .flex-item + .flex-item { border-top: 1px solid var(--color-light-border); }
.flex-list > .flex-item:hover { border-color: var(--color-primary-light-3); }
.divider:has(+ .flex-list) { display: none; }                      /* stray rule above the cards */

/* login / register: hedgehog above the form (page grid is a flex row, so the pseudo-element takes a full line) */
.page-content.user.signin > .ui.grid::before,
.page-content.user.signup > .ui.grid::before {
  content: "";
  flex: 0 0 100%;
  height: 96px;
  margin-top: 1rem;
  background: var(--gw-logo) center / contain no-repeat;   /* --gw-logo set per theme */
}
#navbar-logo { gap: 0.5rem; }
.navbar-wordmark { font-family: var(--fonts-monospace); font-weight: 700; font-size: 1.1rem; letter-spacing: -0.02em; }
.page-footer .ui.dropdown.language { display: none !important; }   /* single-language instance */
body:has(.page-content.home) .full.height { padding-bottom: 0; }

/* ---- landing + static pages (src/pages) ---- */
.gw { --gw-max: 1080px; --gw-pad: clamp(1.25rem, 4vw, 2rem); }
.gw section { padding: clamp(3rem, 7vw, 5rem) var(--gw-pad); }
.gw section + section { border-top: 1px solid var(--color-light-border); }
.gw .wrap { max-width: var(--gw-max); margin: 0 auto; }
.gw h1, .gw h2, .gw h3 { font-family: var(--fonts-monospace); color: var(--color-text); letter-spacing: -0.03em; line-height: 1.1; margin: 0; }
.gw h2 { font-size: clamp(1.4rem, 3vw, 1.75rem); margin-bottom: 0.75rem; }
.gw p { color: var(--color-text-light); line-height: 1.65; font-size: 1.05rem; margin: 0 0 1rem; }
.gw p a { color: var(--color-primary); text-decoration: underline; text-underline-offset: 3px; }
.gw .lede { font-size: 1.2rem; max-width: 34em; }
.gw .ui.button { border-radius: var(--border-radius-medium); padding: 0.85rem 1.4rem; font-weight: 600; font-family: var(--fonts-monospace); }

.gw-hero { padding-top: clamp(3rem, 9vw, 7rem) !important; padding-bottom: clamp(3rem, 9vw, 7rem) !important; }
.gw-hero .logo { content: var(--gw-logo); width: 132px; height: 90px; object-fit: contain; margin-bottom: 1.75rem; }   /* swaps the src for the theme's hedgehog */
.gw-hero h1 { font-size: clamp(2.3rem, 5.5vw, 4rem); font-weight: 800; margin-bottom: 1.25rem; }
.gw-hero h1 em { font-style: normal; color: var(--color-primary); }
.gw-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 2rem; }

/* section body: heading column + content column */
.gw-split { display: grid; grid-template-columns: 1fr 1.6fr; gap: 2rem 4rem; align-items: start; }
@media (max-width: 800px) { .gw-split { grid-template-columns: 1fr; } }

.gw-alts { margin: 0; }
.gw-alts div { padding: 1rem 0; border-bottom: 1px solid var(--color-light-border); }
.gw-alts div:first-child { border-top: 1px solid var(--color-light-border); }
.gw-alts dt { font-family: var(--fonts-monospace); font-weight: 600; color: var(--color-text); margin-bottom: 0.35rem; }
.gw-alts dd { margin: 0; color: var(--color-text-light); line-height: 1.65; }

#about .gw-split > :last-child { justify-self: end; align-self: center; }
@media (max-width: 800px) { #about .gw-split > :last-child { justify-self: start; } }
