/* ===== Root & Theme ===== */
:root {
  --brand-blue: #004289;
  --brand-bronze: #967033;
  --ink: #1b1f23;
  --muted: #6b7785;
  --bg: #f7f9fc;
  --panel: #ffffff;
  --border: #e6eaf0;
  --border-radius: 3rem;
  --focus: color-mix(in srgb, var(--brand-blue) 30%, transparent);
  --radius: 12px;
  --shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 6px 16px rgba(0, 0, 0, .06);
  --font: ui-sans-serif, system-ui, "Segoe UI", Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e9edf2;
    --muted: #aab4c1;
    --bg: #0f141b;
    --panel: #151b23;
    --border: #243042;
    --shadow: none;
    --focus: color-mix(in srgb, var(--brand-blue) 45%, transparent);
  }
}

* {
  box-sizing: border-box
}

html,
body {
  height: 100%
}

body {
  margin: 0;
  font: 16px/1.55 var(--font);
  color: var(--ink);
  background: var(--bg)
}

h1
{
  margin: 0;
  font-size: 30px;
  color: var(--brand-blue);
}

.visually-hidden {
  position: absolute !important;
  clip: rect(1px, 1px, 1px, 1px) !important;
  padding: 0 !important;
  border: 0 !important;
  height: 1px !important;
  width: 1px !important;
  overflow: hidden !important
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: -9999px;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
  background: var(--brand-bronze);
  color: #fff;
  padding: 8px 10px;
  border-radius: var(--border-radius);
  z-index: 9999
}

/* ===== Header ===== */
.site-header {
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px
}

.brand
{
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand__wordmark {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: .2px;
  color: var(--brand-blue)
}

.brand__accent {
  color: var(--brand-bronze)
}

/* Brand logo image */
.brand__logo {
  height: 60px;
  width: auto;
  display: inline;
}

@media (max-width:480px) {
  .brand__logo {
    height: 34px
  }
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(135deg, color-mix(in srgb, var(--brand-blue) 9%, transparent), transparent 60%), linear-gradient(0deg, var(--panel), var(--panel));
  border-bottom: 1px solid var(--border)
}

.hero__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 20px 18px
}

.hero__title {
  margin: 0 0 8px;
  font-weight: 800;
  letter-spacing: .2px
}

.hero__subtitle {
  margin: 0;
  color: var(--muted)
}

.hero__meta {
  margin-top: 10px;
  font-size: .9rem;
  color: var(--muted)
}

/* ===== Main ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 22px 20px 60px
}

/* Controls */
.controls__row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap
}

#search {
  flex: 1 1 420px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  background: var(--panel);
  color: inherit
}

#search::placeholder {
  color: var(--muted)
}

.sort select {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  background: var(--panel)
}

.controls__results {
  margin-top: 10px;
  color: var(--muted)
}

/* Downloads Layout */
#software-list.row-flexbox {
  display: grid;
  gap: 18px
}

/* Bundle (your .software-list-container) */
.software-list-container {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 1rem;
  box-shadow: var(--shadow);
  overflow: hidden
}

.software-list-container>h2 {
  margin: 0;
  padding: 14px 16px;
  color: var(--brand-blue);
  font-weight: 700;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
}

.software-list-container[aria-expanded="false"]>ul {
  display: none
}

/* File list */
.software-list-container>ul {
  list-style: none;
  margin: 0;
  padding: 10px;
  display: grid;
  gap: 10px
}

.software-list-container>ul>li {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--panel)
}

/* Hide Show all / Show less when the group is collapsed */
.software-list-container[aria-expanded="false"] .kla-control-row {
  display: none;
}


/* Platform icon (SVG) */
.kla-file-icon {
  display: grid;
  place-items: center
}

.kla-file-icon svg {
  width: 20px;
  height: 20px;
  fill: var(--brand-blue)
}

/* Filename label (middle column) */
.kla-file-name {
  font-weight: 600
}

/* Right-side "download" button (anchor) */
.software-list-container>ul>li>a {
  justify-self: end;
  appearance: none;
  background: var(--brand-blue);
  color: #fff;
  padding: 8px 12px;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 600;
  text-transform: lowercase;
}

.software-list-container>ul>li>a:hover {
  filter: brightness(1.02)
}

.software-list-container>ul>li>a:active {
  transform: translateY(1px)
}

/* Skeletons */
.skeleton {
  height: 96px;
  background: linear-gradient(90deg, #0000, #0001, #0000);
  background-size: 300% 100%;
  animation: sheen 2s infinite linear;
  border-radius: var(--border-radius);
  border: 1px solid var(--border)
}

@keyframes sheen {
  0% {
    background-position: 200% 0
  }

  100% {
    background-position: -100% 0
  }
}

.skeleton--bundle {
  height: 140px
}

/* Empty state */
.no-results {
  margin-top: 18px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--border-radius);
  padding: 18px;
  text-align: center;
  color: var(--muted)
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--panel)
}

.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 18px 20px
}

.kla-control-row {
  display: flex; justify-content: center; padding: 8px 10px 12px;
}
.kla-show-toggle {
  appearance: none; border: 1px solid var(--border, #e6eaf0);
  background: var(--panel, #fff); color: var(--brand-blue, #004289);
  padding: 8px 12px; border-radius: 10px; cursor: pointer; font-weight: 600;
}
.kla-show-toggle:hover { filter: brightness(1.02); }
.kla-show-toggle:active { transform: translateY(1px); }
