/* ==========================================================================
   certificates.css
   Styles specific to certificates.html (full certification archive page:
   page head, search/filter controls, accordion groups).
   ========================================================================== */

  /* This page uses a narrower content column than the rest of the site */
  .wrap{ max-width: 900px; }

  /* Page head */
  .page-head {
    padding: 64px 0 12px;
  }

  .page-head-columns {
    display: grid;
    grid-template-columns: 1.6fr 0.4fr;
    align-items: center;
    gap: 32px;
  }

  @media (max-width: 800px) {
    .page-head-columns {
      grid-template-columns: 1fr;
    }
    .page-head-image {
      order: -1;
      margin-bottom: 8px;
    }
  }

  @media (max-width: 560px) {
    .page-head-image {
      display: none;
    }
  }

  .page-head-image {
    width: 100%;
    max-width: 150px;
    margin-left: auto;
    aspect-ratio: 4 / 5;
    border-radius: var(--radius-md);
    object-fit: cover;
  }

  .page-head h1 {
    font-size: clamp(30px, 4vw, 42px);
    line-height: 1.12;
  }

  .page-head p {
    margin-top: 14px;
    max-width: 560px;
    font-size: 16.5px;
    color: var(--navy-soft);
  }

  /* Archive notice banner */
  .archive-notice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 28px 0 0;
    padding: 16px 18px;
    background: var(--bg-panel);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
  }

  .archive-notice svg {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin-top: 2px;
    stroke: var(--teal);
  }

  .archive-notice p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--navy-soft);
  }

  .archive-notice a {
    color: var(--teal);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid var(--teal-soft);
    transition: border-color 0.15s ease;
  }

  .archive-notice a:hover {
    border-color: var(--teal);
  }

  /* Controls (search + toggle-all) */
  .controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 16px 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--line);
  }

  .search-box {
    position: relative;
    flex: 1 1 220px;
    max-width: 280px;
  }

  .search-box input {
    width: 100%;
    padding: 10px 34px 10px 38px;
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 14.5px;
    color: var(--ink);
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    transition: border-color 0.15s ease;
  }

  .search-box input:focus {
    outline: 2px solid var(--teal);
    outline-offset: 1px;
    border-color: var(--teal);
  }

  .search-box svg {
    position: absolute;
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    stroke: var(--slate);
    pointer-events: none;
  }

  .search-clear {
    display: none;
    position: absolute;
    top: 50%;
    right: 8px;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    background: none;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transform: translateY(-50%);
    transition: background 0.15s ease;
  }

  .search-clear svg {
    position: static;
    width: 12px;
    height: 12px;
    stroke: var(--slate);
    transform: none;
  }

  .search-clear:hover {
    background: var(--bg-panel);
  }

  .search-box.has-value .search-clear {
    display: flex;
  }

  .toggle-all-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 12px;
  }

  .result-count {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    color: var(--slate);
  }

  .toggle-all-links {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .toggle-all-btn {
    padding: 2px;
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: var(--teal);
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.15s ease;
  }

  .toggle-all-btn:hover {
    color: var(--teal-dark);
  }

  .toggle-all-divider {
    font-size: 13px;
    color: var(--line);
  }

  /* Accordion groups */
  .archive {
    padding: 8px 0 100px;
  }

  .group {
    border-bottom: 1px solid var(--line);
  }

  .group-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 16px;
    padding: 22px 2px;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
  }

  .group-trigger-left {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    row-gap: 4px;
    gap: 12px;
    min-width: 0;
  }

  .group-name {
    font-family: 'Fraunces', serif;
    font-size: 19px;
    font-weight: 450;
    line-height: 1.3;
    color: var(--navy);
  }

  .group-count {
    flex-shrink: 0;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    color: var(--slate);
  }

  .group-icon {
    position: relative;
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    transition: transform 0.2s ease;
  }

  .group-icon::before,
  .group-icon::after {
    content: "";
    position: absolute;
    background: var(--navy-soft);
    transition: background 0.2s ease;
  }

  .group-icon::before {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1.5px;
    transform: translateY(-50%);
  }

  .group-icon::after {
    top: 0;
    left: 50%;
    width: 1.5px;
    height: 100%;
    transform: translateX(-50%);
  }

  .group.open .group-icon {
    transform: rotate(135deg);
  }

  .group.open .group-icon::before,
  .group.open .group-icon::after {
    background: var(--teal);
  }

  .group.open .group-name {
    color: var(--teal);
  }

  .group-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }

  .group-panel-inner {
    display: flex;
    flex-direction: column;
    padding: 0 2px 22px;
  }

  .cert-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 14px;
    border-radius: var(--radius-sm);
  }

  .cert-row-left {
    min-width: 0;
  }

  .cert-title {
    font-size: 14.5px;
    font-weight: 500;
    color: var(--ink);
  }

  .cert-meta {
    margin-top: 3px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11.5px;
    color: var(--slate);
  }

  .cert-highlight {
    color: var(--navy);
    background: var(--teal-soft);
    border-radius: 3px;
  }

  .empty-state {
    display: none;
    padding: 60px 2px;
    text-align: center;
    color: var(--slate);
  }

  .empty-state.show {
    display: block;
  }

  .empty-state p {
    margin-top: 6px;
    font-size: 15px;
  }

