.company-policies {
  --policy-gold: var(--gold, #d4af37);
  --policy-ink: var(--graphite, #25282b);
  --policy-muted: #626970;
  position: relative;
  overflow: hidden;
  padding: clamp(4.5rem, 8vw, 7.5rem) 0;
  color: var(--policy-ink);
  background: var(--paper, #f4f1e9);
}

.company-policies::before {
  position: absolute;
  top: 0;
  left: max(0px, calc((100vw - 80rem) / 2));
  width: clamp(4rem, 10vw, 9rem);
  height: 0.3rem;
  background: var(--policy-gold);
  content: "";
}

.policies-inner {
  position: relative;
  z-index: 1;
}

.policies-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(17rem, 0.7fr);
  align-items: end;
  gap: clamp(2rem, 6vw, 6rem);
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
  padding-bottom: clamp(1.7rem, 3vw, 2.5rem);
  border-bottom: 1px solid rgba(37, 40, 43, 0.18);
}

.policies-heading small {
  display: block;
  margin-bottom: 1.1rem;
  color: #9e7e1d;
  font: 600 0.68rem/1 var(--font-mono, monospace);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.policies-heading h2 {
  max-width: 48rem;
  margin: 0;
  color: var(--policy-ink);
  font: 600 clamp(2.35rem, 5.3vw, 4.9rem)/0.98 var(--font-display, Inter, sans-serif);
  letter-spacing: -0.075em;
}

.policies-heading h2 span {
  color: #ad8c2b;
}

.policies-heading > p {
  max-width: 34rem;
  margin: 0;
  color: var(--policy-muted);
  font-size: 0.94rem;
  line-height: 1.75;
}

.policies-layout {
  display: grid;
  grid-template-columns: minmax(13rem, 0.52fr) minmax(0, 1.8fr);
  align-items: start;
  gap: clamp(1rem, 2.2vw, 2rem);
}

.policy-tabs {
  display: grid;
  gap: 0.55rem;
}

.policy-tab {
  position: relative;
  display: grid;
  grid-template-columns: 2.2rem minmax(0, 1fr) 1rem;
  align-items: center;
  gap: 0.6rem;
  min-height: 4rem;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(37, 40, 43, 0.13);
  color: var(--policy-ink);
  background: rgba(255, 253, 249, 0.58);
  text-align: left;
  cursor: pointer;
  transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.policy-tab:hover {
  border-color: rgba(173, 140, 43, 0.6);
  transform: translateX(0.15rem);
}

.policy-tab[aria-selected="true"] {
  border-color: var(--policy-ink);
  color: var(--white, #fffdf9);
  background: var(--policy-ink);
}

.policy-tab[aria-selected="true"]::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0.22rem;
  background: var(--policy-gold);
  content: "";
}

.policy-tab > span {
  color: #9e7e1d;
  font: 600 0.68rem/1 var(--font-mono, monospace);
}

.policy-tab[aria-selected="true"] > span,
.policy-tab[aria-selected="true"] > i {
  color: var(--policy-gold);
}

.policy-tab strong {
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.3;
}

.policy-tab > i {
  color: #a1a5a7;
  font-size: 0.9rem;
  font-style: normal;
  transition: transform 180ms ease;
}

.policy-tab[aria-selected="true"] > i {
  transform: rotate(45deg);
}

.policy-tab:focus-visible {
  outline: 2px solid var(--policy-gold);
  outline-offset: 2px;
}

.policy-view {
  min-width: 0;
  border: 1px solid rgba(37, 40, 43, 0.12);
  background: var(--white, #fffdf9);
  box-shadow: 0 1rem 2.7rem rgba(37, 40, 43, 0.08);
}

.policy-panel[hidden] {
  display: none;
}

.policy-panel:not([hidden]) {
  animation: policy-panel-arrive 280ms ease both;
}

@keyframes policy-panel-arrive {
  from { opacity: 0; transform: translateY(0.45rem); }
  to { opacity: 1; transform: translateY(0); }
}

.policy-panel-heading {
  padding: clamp(1.5rem, 3.4vw, 2.8rem) clamp(1.35rem, 3.4vw, 3rem) 1.5rem;
  border-bottom: 1px solid rgba(37, 40, 43, 0.12);
}

.policy-panel-heading > span,
.policy-pledge > span {
  display: block;
  margin-bottom: 0.7rem;
  color: #9e7e1d;
  font: 600 0.65rem/1 var(--font-mono, monospace);
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.policy-panel-heading h3 {
  margin: 0;
  color: var(--policy-ink);
  font: 600 clamp(1.55rem, 3vw, 2.35rem)/1.05 var(--font-display, Inter, sans-serif);
  letter-spacing: -0.045em;
}

.policy-panel-heading > p {
  max-width: 58rem;
  margin: 1rem 0 0;
  color: var(--policy-muted);
  font-size: 0.9rem;
  line-height: 1.75;
}

.policy-commitments {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0 clamp(1.35rem, 3.4vw, 3rem);
  list-style: none;
}

.policy-commitments li {
  position: relative;
  padding: 1.35rem 1.3rem 1.25rem 1.2rem;
  border-bottom: 1px solid rgba(37, 40, 43, 0.1);
}

.policy-commitments li:nth-child(odd) {
  padding-left: 0;
}

.policy-commitments li:nth-child(even) {
  border-left: 1px solid rgba(37, 40, 43, 0.1);
}

.policy-commitments h4 {
  margin: 0;
  color: var(--policy-ink);
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.35;
}

.policy-commitments h4::before {
  display: inline-block;
  width: 0.36rem;
  height: 0.36rem;
  margin: 0 0.55rem 0.12rem 0;
  background: var(--policy-gold);
  content: "";
}

.policy-commitments p {
  margin: 0.55rem 0 0;
  color: var(--policy-muted);
  font-size: 0.78rem;
  line-height: 1.65;
}

.policy-pledge {
  margin: 0 clamp(1.35rem, 3.4vw, 3rem);
  padding: 1.45rem 1.5rem;
  border-left: 0.22rem solid var(--policy-gold);
  background: #f4f1e9;
}

.policy-pledge p {
  margin: 0;
  color: var(--policy-ink);
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1.7;
}

.policy-panel-footer {
  padding: 1rem clamp(1.35rem, 3.4vw, 3rem) 1.2rem;
  color: var(--policy-muted);
  font: 500 0.63rem/1.5 var(--font-mono, monospace);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.policies-note {
  margin: 1.2rem 0 0;
  color: var(--policy-muted);
  font-size: 0.72rem;
  line-height: 1.6;
}

@media (max-width: 900px) {
  .policies-heading {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.3rem;
  }

  .policies-heading > p {
    max-width: 45rem;
  }

  .policies-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .policy-tabs {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .policy-tab {
    grid-template-columns: minmax(0, 1fr) auto;
    align-content: center;
    gap: 0.35rem;
    min-height: 4.2rem;
    padding: 0.7rem;
  }

  .policy-tab > span {
    grid-column: 1 / -1;
  }

  .policy-tab > i {
    display: none;
  }
}

@media (max-width: 620px) {
  .company-policies {
    padding: 4rem 0;
  }

  .policy-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .policy-tab:last-child {
    grid-column: 1 / -1;
  }

  .policy-commitments {
    grid-template-columns: minmax(0, 1fr);
    padding: 0 1.25rem;
  }

  .policy-commitments li,
  .policy-commitments li:nth-child(odd),
  .policy-commitments li:nth-child(even) {
    padding: 1.2rem 0;
    border-left: 0;
  }

  .policy-pledge {
    margin: 0 1.25rem;
    padding: 1.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .policy-panel:not([hidden]),
  .policy-tab,
  .policy-tab > i {
    animation: none;
    transition: none;
  }
}
