/* NAVIMUKI Group of Companies — site styles (no framework, no JS) */

:root {
  --brand: #f5321a;
  --ink: #16181d;
  --muted: #5b616e;
  --surface: #ffffff;
  --overlay: rgba(10, 12, 16, 0.72);
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --max: 1180px;
  --font-head: "Oswald", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-body);
  color: #fff;
  background:
    linear-gradient(180deg, rgba(8, 10, 14, 0.55), rgba(8, 10, 14, 0.85)),
    url("../images/background.jpg") center / cover fixed no-repeat,
    #111;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

.container {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute; left: 1rem; top: -3rem;
  background: #fff; color: var(--ink);
  padding: .5rem 1rem; border-radius: 8px; z-index: 10;
}
.skip-link:focus { top: 1rem; }

:focus-visible {
  outline: 3px solid #ffd54a;
  outline-offset: 3px;
}

/* ---------- Header ---------- */

.site-header { padding-block: clamp(.75rem, 3vh, 1.75rem) clamp(.5rem, 1.5vh, 1rem); }

.site-header .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  text-decoration: none;
}
.brand img { width: clamp(150px, 22vh, 220px); }
.brand-tagline {
  font-family: var(--font-head);
  font-weight: 300;
  font-size: clamp(.95rem, 2.2vh, 1.25rem);
  letter-spacing: .28em;
  text-transform: uppercase;
  padding-left: .35rem;
}

.portal-nav ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}
.portal-nav a {
  display: inline-block;
  padding: .55rem 1rem;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  backdrop-filter: blur(6px);
  transition: background-color .2s, border-color .2s, color .2s;
}
.portal-nav a:hover {
  background: #fff;
  border-color: #fff;
  color: var(--ink);
}
.portal-nav a.primary {
  background: var(--brand);
  border-color: var(--brand);
}
.portal-nav a.primary:hover { background: #fff; color: var(--brand); }

/* ---------- Companies ---------- */

main {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  padding-block: clamp(.5rem, 2vh, 1.5rem) clamp(.75rem, 3vh, 2rem);
}
main > .container { display: flex; flex-direction: column; }

.section-title {
  font-family: var(--font-head);
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: .04em;
  margin: 0 0 1.5rem;
}

.companies {
  list-style: none;
  margin: 0; padding: 0;
  display: grid;
  flex: 1;
  min-height: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: clamp(.75rem, 2.2vh, 1.5rem);
}
.companies > li { min-height: 0; }
/* On very tall screens keep tiles at a sensible size and centre the grid. */
.companies { max-height: 44rem; margin-block: auto; }

.company {
  --accent: #888;
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  color: var(--ink);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  text-decoration: none;
  border-top: 6px solid var(--accent);
  transition: transform .25s ease, box-shadow .25s ease;
}
.company:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .45);
}

.company-logo {
  position: relative;
  flex: 1 1 auto;
  min-height: 70px;
  background: color-mix(in srgb, var(--accent) 14%, #fff);
}
.company-logo img {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: auto; height: auto;
  max-width: min(220px, calc(100% - 2rem));
  max-height: min(120px, calc(100% - 1.25rem));
  mix-blend-mode: multiply; /* lets logos with a solid white background blend into the tinted panel */
}
.company-logo img.wide { max-height: min(80px, calc(100% - 1.25rem)); }

.company-body {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(.6rem, 1.6vh, 1.1rem) 1.4rem clamp(.7rem, 1.8vh, 1.2rem);
}
.company-name {
  font-family: var(--font-head);
  font-weight: 400;
  font-size: clamp(1rem, 2.1vh, 1.18rem);
  line-height: 1.2;
  margin: 0;
}
.company-desc {
  margin: .25rem 0 0;
  font-size: .9rem;
  color: var(--muted);
}
.company-arrow {
  flex: none;
  width: 2.25rem; height: 2.25rem;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 1.1rem;
  transition: transform .25s ease;
}
.company:hover .company-arrow { transform: translateX(3px); }

.accent-blue   { --accent: #1fb6e6; }
.accent-pink   { --accent: #c35be0; }
.accent-teal   { --accent: #0ea88c; }
.accent-green  { --accent: #6fb52c; }
.accent-grey   { --accent: #8a8580; }
.accent-yellow { --accent: #e2a400; }
.accent-orange { --accent: #f05a0a; }

/* ---------- Clients ---------- */

.clients {
  background: var(--overlay);
  flex: none;
  padding-block: clamp(.6rem, 2vh, 1.5rem);
  border-top: 1px solid rgba(255, 255, 255, .08);
}
.clients .section-title {
  text-align: center;
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: .25em;
  font-size: clamp(.8rem, 1.8vh, 1rem);
  margin-bottom: clamp(.4rem, 1.2vh, .9rem);
}

.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: scroll 45s linear infinite;
}
.marquee:hover .marquee-track,
.marquee:focus-within .marquee-track { animation-play-state: paused; }

.client-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.25rem;
  padding-right: 1.25rem;
}
.client-list li {
  flex: none;
  width: clamp(56px, 10vh, 104px);
  aspect-ratio: 1;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
}
/* Client logos are 250x250 squares with a green frame baked in;
   scaling up slightly lets the rounded chip crop that frame away. */
.client-list img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: scale(1.1);
}

@keyframes scroll {
  to { transform: translateX(-50%); }
}

/* ---------- Footer ---------- */

.site-footer {
  background: rgba(0, 0, 0, .85);
  color: rgba(255, 255, 255, .7);
  font-size: .85rem;
  flex: none;
  padding-block: clamp(.4rem, 1.2vh, .9rem);
  text-align: center;
}
.site-footer p { margin: 0; }

/* ---------- Responsive & preferences ---------- */

@media (max-width: 700px) {
  body { height: auto; min-height: 100dvh; }
  .site-header { padding-block: .9rem .4rem; }
  .site-header .container { flex-direction: column; align-items: flex-start; gap: .6rem; }
  .brand { gap: .15rem; }
  .brand img { width: 140px; }
  .brand-tagline { font-size: .95rem; }
  .portal-nav ul { gap: .35rem; }
  .portal-nav a { padding: .4rem .65rem; font-size: .68rem; }
  main { padding-block: .5rem .75rem; }
  .companies { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; gap: .75rem; }
  .company { border-top-width: 4px; border-radius: 12px; }
  .company-logo { flex: 1 1 auto; height: auto; min-height: 66px; }
  .company-logo img { max-width: calc(100% - 1.25rem); max-height: min(64px, calc(100% - 1rem)); }
  .company-logo img.wide { max-height: min(40px, calc(100% - 1rem)); }
  .company-body { padding: .55rem .75rem .65rem; }
  .company-name { font-size: .95rem; }
  .company-desc { font-size: .72rem; }
  .company-arrow { display: none; }
  .clients { padding-block: .5rem; }
  .clients .section-title { font-size: .75rem; margin-bottom: .35rem; }
  .site-footer { font-size: .68rem; }
  .client-list li { width: 56px; }
  .client-list { gap: .75rem; padding-right: .75rem; }
}

/* Very short landscape screens: fall back to natural height and allow scrolling. */
@media (max-height: 560px) and (min-width: 701px) {
  body { height: auto; min-height: 100dvh; }
  .companies { grid-template-rows: none; }
  .company-logo { flex: none; height: 110px; }
}

@media (hover: none) {
  body { background-attachment: scroll; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
  .marquee { -webkit-mask-image: none; mask-image: none; }
  .marquee-track { animation: none; width: auto; }
  .client-list { flex-wrap: wrap; justify-content: center; padding-right: 0; }
  .client-list[aria-hidden="true"] { display: none; }
}
