/*
 * HiveRadar CWG Docs theme: Material for MkDocs aligned with www.hiveradar.com.
 * Token values mirror hiveradar-website tailwind.config.ts and
 * app/[locale]/globals.css; keep them in sync when the website palette moves.
 * Material sets html { font-size: 125% }, so 1rem here is 20px.
 */

/* ===== Brand fonts (same files as hiveradar-website public/fonts) ===== */
/* Sansation Regular only, like the website: headings at 700 render faux-bold
   on purpose so both sites look identical. */
@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope/Manrope-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope/Manrope-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Sansation";
  src: url("../fonts/sansation/Sansation-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-mono/IBMPlexMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-mono/IBMPlexMono-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ===== Tokens ===== */
:root {
  --md-text-font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --md-code-font: "IBM Plex Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --hr-heading-font: "Sansation", "Manrope", system-ui, sans-serif;

  /* palette.primary: custom. Material paints the header and active nav with
     the primary colour; the website header is dark, so primary is the page
     background and the brand yellow is the accent. */
  --md-primary-fg-color: #1d1d1e;
  --md-primary-fg-color--light: #343434;
  --md-primary-fg-color--dark: #101011;
  --md-primary-bg-color: #dbdbdb;
  --md-primary-bg-color--light: #b8b8b9;

  /* palette.accent: custom */
  --md-accent-fg-color: #fdb915;
  --md-accent-fg-color--transparent: rgba(253, 185, 21, 0.1);
  --md-accent-bg-color: #1d1d1e;
  --md-accent-bg-color--light: #1d1d1e;
}

[data-md-color-scheme="slate"] {
  --md-default-bg-color: #1d1d1e;
  --md-default-bg-color--light: rgba(29, 29, 30, 0.7);
  --md-default-bg-color--lighter: rgba(29, 29, 30, 0.3);
  --md-default-bg-color--lightest: rgba(29, 29, 30, 0.12);
  --md-default-fg-color: #dbdbdb;
  --md-default-fg-color--light: #b8b8b9;
  --md-default-fg-color--lighter: #939393;
  --md-default-fg-color--lightest: #343434;
  --md-typeset-color: #dbdbdb;
  --md-typeset-a-color: #fdb915;
  --md-code-bg-color: #242425;
  --md-code-fg-color: #dbdbdb;
  --md-footer-bg-color: #1d1d1e;
  --md-footer-bg-color--dark: #1d1d1e;
  --md-footer-fg-color: #dbdbdb;
  --md-footer-fg-color--light: #b8b8b9;
  --md-footer-fg-color--lighter: #939393;
  --md-shadow-z1: 0 2px 8px rgba(0, 0, 0, 0.1);
  --md-shadow-z2: 0 10px 30px rgba(0, 0, 0, 0.2);
  --md-shadow-z3: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ===== Header: website look (64px, blur + hairline once scrolled) ===== */
.md-header {
  background: #1d1d1e;
  border-bottom: 1px solid transparent;
  box-shadow: none;
}

.md-header--shadow {
  background: rgba(29, 29, 30, 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom-color: #343434;
  box-shadow: none;
}

.md-header__inner {
  min-height: 3.2rem; /* 64px */
}

.md-header__button.md-logo {
  padding: 0 0.4rem;
}

.md-header__button.md-logo img,
.md-header__button.md-logo svg {
  height: 1.6rem;
  width: auto;
}

.md-header__topic .md-ellipsis {
  font-family: var(--hr-heading-font);
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #ffffff;
}

/* ===== Typography ===== */
.md-typeset {
  font-size: 0.8rem; /* 16px */
}

.md-typeset h1,
.md-typeset h2,
.md-typeset h3,
.md-typeset h4,
.md-typeset h5,
.md-typeset h6 {
  font-family: var(--hr-heading-font);
  font-weight: 700;
  color: #ffffff;
}

.md-typeset a:hover {
  color: #fdc130;
}

.md-typeset code,
.md-typeset pre {
  border-radius: 0.375rem;
}

/* ===== Sidebar: top-level sections in uppercase Sansation (the nav labels
   used to carry inline <b> tags for this). ===== */
.md-nav--primary > .md-nav__list > .md-nav__item--nested > .md-nav__link {
  font-family: var(--hr-heading-font);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fdb915;
}

.md-nav__link--active {
  color: var(--md-typeset-a-color);
}

/* ===== Click-to-zoom images (docs/javascript/custom.js) ===== */
.zoomable-image,
.zoomable-image-block {
  transition: transform 0.3s ease, filter 0.3s ease;
  cursor: pointer;
}

.zoomable-image.zoomed {
  transform: scale(1.5);
  z-index: 1000;
  position: relative;
}

.zoomable-image-block.zoomed {
  transform: scale(4);
  z-index: 1000;
  position: relative;
}

.hover-text:hover + .zoomable-image + .zoomable-image-block {
  filter: brightness(50%);
}

/* ===== Footer (overrides/partials/footer.html), mirrors the website ===== */
.hr-footer {
  border-top: 1px solid #343434;
  background: #1d1d1e;
  color: #dbdbdb;
}

.hr-footer__inner {
  max-width: 57.6rem; /* 1152px */
  margin: 0 auto;
  padding: 3.5rem 0.8rem;
}

.hr-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}

.hr-footer__brand {
  display: flex;
  flex-direction: column;
}

.hr-footer__logo {
  display: block;
  width: 8rem;
  height: auto;
  margin-bottom: 1.25rem;
}

.hr-footer__desc {
  font-size: 0.7rem;
  line-height: 1.5;
  max-width: 16rem;
  margin: 0 0 1.25rem;
}

.hr-footer__phone {
  align-self: flex-start;
  font-size: 0.7rem;
  color: #dbdbdb;
  margin-bottom: 1.5rem;
  transition: color 0.15s ease;
}

.hr-footer__social {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.hr-footer__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid #343434;
  border-radius: 0.6rem;
  color: #dbdbdb;
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.hr-footer__social a:hover {
  color: #fdb915;
  border-color: rgba(253, 185, 21, 0.4);
  background: rgba(253, 185, 21, 0.05);
}

.hr-footer__social svg {
  width: 0.8rem;
  height: 0.8rem;
  fill: currentColor;
}

.hr-footer__title {
  font-family: var(--hr-heading-font);
  font-size: 0.6rem;
  font-weight: 700;
  color: #fdb915;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 1rem;
}

.hr-footer__links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.hr-footer__links a,
.hr-footer__legal-links a {
  color: #dbdbdb;
  transition: color 0.15s ease;
}

.hr-footer__links a {
  font-size: 0.7rem;
}

.hr-footer__links a:hover,
.hr-footer__legal-links a:hover,
.hr-footer__phone:hover {
  color: #fdb915;
}

.hr-footer__legal {
  border-top: 1px solid #343434;
  padding-top: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
}

.hr-footer__copyright {
  font-size: 0.6rem;
  color: #fdb915;
  margin: 0;
}

.hr-footer__legal-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.hr-footer__legal-links a {
  font-size: 0.6rem;
}

@media (min-width: 40em) {
  .hr-footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .hr-footer__legal {
    flex-direction: row;
    justify-content: space-between;
  }
}

@media (min-width: 60em) {
  .hr-footer__grid {
    grid-template-columns: repeat(6, 1fr);
    gap: 2rem;
  }

  .hr-footer__brand {
    grid-column: span 2;
  }

  .hr-footer__logo {
    width: 9.6rem;
  }
}
