.factory-updates-list-section {
  background: #f6f3ec;
}

.factory-updates-shell {
  padding-block: 72px 84px;
}

.factory-updates-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(300px, 1.1fr);
  gap: 48px;
  align-items: end;
  margin-bottom: 32px;
}

.factory-updates-heading .eyebrow {
  margin: 0 0 10px;
}

.factory-updates-heading h2 {
  max-width: 640px;
  margin: 0;
  color: #1f2f29;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.05;
}

.factory-updates-heading > p {
  max-width: 620px;
  margin: 0;
  color: #625e55;
  font-size: 1rem;
  line-height: 1.7;
}

.factory-update-filters {
  display: flex;
  gap: 8px;
  margin: 0 0 30px;
  padding: 0 0 2px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.factory-update-filter {
  min-height: 42px;
  flex: 0 0 auto;
  padding: 9px 15px;
  border: 1px solid #d7c9b1;
  border-radius: 6px;
  background: #fffdf8;
  color: #31423b;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 650;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.factory-update-filter:hover,
.factory-update-filter:focus-visible {
  border-color: #b7965c;
  background: #f0e8d8;
}

.factory-update-filter[aria-pressed="true"] {
  border-color: #24483b;
  background: #24483b;
  color: #fff;
}

.factory-updates-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.factory-update-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #d8cbb7;
  border-radius: 8px;
  background: #fffdf8;
  box-shadow: 0 12px 34px rgb(31 47 41 / 8%);
}

.factory-update-card[hidden] {
  display: none;
}

.factory-update-card.is-linked {
  outline: 2px solid #b89555;
  outline-offset: 3px;
}

.factory-update-poster {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 0;
  background: #1b211e;
  cursor: pointer;
}

.factory-update-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 240ms ease;
}

.factory-update-poster:hover img,
.factory-update-poster:focus-visible img {
  transform: scale(1.018);
}

.factory-update-play {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 76%);
  border-radius: 50%;
  background: rgb(31 47 41 / 88%);
  color: #fff;
  transform: translate(-50%, -50%);
  box-shadow: 0 10px 28px rgb(0 0 0 / 30%);
}

.factory-update-play svg {
  width: 21px;
  height: 21px;
  margin-inline-start: 3px;
  fill: currentColor;
}

.factory-update-duration {
  position: absolute;
  inset: auto 12px 12px auto;
  padding: 5px 8px;
  border-radius: 4px;
  background: rgb(20 25 23 / 82%);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
}

.factory-update-body {
  display: flex;
  min-height: 330px;
  flex: 1;
  flex-direction: column;
  padding: 22px;
}

.factory-update-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  margin-bottom: 13px;
  color: #756b5d;
  font-size: 0.78rem;
}

.factory-update-category {
  color: #8b642b;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.factory-update-date::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  margin-inline-end: 8px;
  border-radius: 50%;
  background: #b89555;
  vertical-align: middle;
}

.factory-update-title {
  margin: 0 0 12px;
  color: #1f2f29;
  font-size: 1.28rem;
  line-height: 1.22;
}

.factory-update-title a {
  color: inherit;
  text-decoration: none;
}

.factory-update-title a:hover,
.factory-update-title a:focus-visible {
  color: #8b642b;
}

.factory-update-description {
  margin: 0;
  color: #5f5a51;
  font-size: 0.93rem;
  line-height: 1.65;
}

.factory-update-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 18px 0 20px;
  padding: 0;
  list-style: none;
}

.factory-update-tags li {
  padding: 6px 9px;
  border: 1px solid #e0d6c5;
  border-radius: 4px;
  background: #f7f2e8;
  color: #514b42;
  font-size: 0.75rem;
  font-weight: 650;
}

.factory-update-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: auto;
}

.factory-update-actions .button {
  min-height: 42px;
  padding-inline: 12px;
  font-size: 0.84rem;
  text-align: center;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease;
}

.factory-update-actions .button-primary {
  border-color: #b28f56;
  background: #c3a56e;
  color: #171b18;
}

.factory-update-actions .button-primary:hover {
  border-color: #94733f;
  background: #ad8a52;
  color: #111512;
}

.factory-update-actions .button-secondary {
  border-color: #a68c65;
  background: #fffdf8;
  color: #1d3a31;
}

.factory-update-actions .button-secondary:hover {
  border-color: #8e744d;
  background: #eee5d6;
  color: #132a23;
}

.factory-update-actions .button:focus-visible {
  outline: 3px solid #1f4b3d;
  outline-offset: 2px;
}

.factory-update-actions .button-primary:focus-visible {
  border-color: #8b6b39;
  background: #b8965d;
  color: #111512;
}

.factory-update-actions .button-secondary:focus-visible {
  border-color: #7d633e;
  background: #f2eadc;
  color: #10251f;
}

.factory-updates-empty-state {
  max-width: 720px;
  margin: 28px auto 0;
  padding: 34px;
  border: 1px dashed #c9b99e;
  border-radius: 8px;
  background: #fffdf8;
  text-align: center;
}

.factory-updates-empty-state[hidden] {
  display: none;
}

.factory-updates-empty-state h3 {
  margin: 0 0 8px;
  color: #1f2f29;
}

.factory-updates-empty-state p {
  margin: 0;
  color: #6a645a;
}

.factory-video-dialog {
  width: min(1000px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100vh - 32px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / 16%);
  border-radius: 8px;
  background: #111613;
  color: #fff;
  box-shadow: 0 30px 80px rgb(0 0 0 / 50%);
}

.factory-video-dialog:not([open]) {
  display: none;
}

.factory-video-dialog::backdrop {
  background: rgb(10 16 13 / 78%);
  backdrop-filter: blur(4px);
}

.factory-video-shell {
  display: grid;
  max-height: calc(100vh - 32px);
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.factory-video-header {
  display: flex;
  min-height: 62px;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px 13px 22px;
  border-bottom: 1px solid rgb(255 255 255 / 12%);
}

.factory-video-header h2 {
  margin: 0;
  color: #fff;
  font-size: 1.05rem;
  line-height: 1.3;
}

.factory-video-close {
  display: grid;
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 26%);
  border-radius: 6px;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.factory-video-close:hover,
.factory-video-close:focus-visible {
  background: rgb(255 255 255 / 11%);
}

.factory-video-stage {
  position: relative;
  display: grid;
  min-height: 300px;
  place-items: center;
  overflow: hidden;
  background: #050806;
}

.factory-video-stage.is-portrait {
  min-height: min(70vh, 760px);
}

.factory-video {
  display: block;
  width: 100%;
  height: 100%;
  max-height: calc(100vh - 180px);
  object-fit: contain;
  background: #050806;
}

.factory-video-stage.is-portrait .factory-video {
  width: auto;
  max-width: 100%;
}

.factory-video-error {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: end center;
  padding: 28px;
  background-position: center;
  background-size: contain;
  background-repeat: no-repeat;
}

.factory-video-error[hidden] {
  display: none;
}

.factory-video-error p {
  max-width: 640px;
  margin: 0;
  padding: 12px 16px;
  border-radius: 6px;
  background: rgb(17 22 19 / 92%);
  color: #fff;
  text-align: center;
}

.factory-video-caption {
  margin: 0;
  padding: 14px 22px 18px;
  color: #d8dbd9;
  font-size: 0.9rem;
  line-height: 1.55;
}

body.factory-video-open {
  overflow: hidden;
}

html[dir="rtl"] .factory-update-duration {
  inset: auto auto 12px 12px;
}

@media (max-width: 1040px) {
  .factory-updates-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .factory-updates-shell {
    padding-block: 52px 64px;
  }

  .factory-updates-heading {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .factory-updates-grid {
    grid-template-columns: 1fr;
  }

  .factory-update-body {
    min-height: 0;
  }

  .factory-video-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
  }

  .factory-video-shell {
    max-height: calc(100vh - 20px);
  }

  .factory-video-stage {
    min-height: 240px;
  }

  .factory-video-stage.is-portrait {
    min-height: min(68vh, 680px);
  }
}

@media (max-width: 440px) {
  .factory-updates-shell {
    padding-block: 44px 56px;
  }

  .factory-update-body {
    padding: 19px;
  }

  .factory-update-actions {
    grid-template-columns: 1fr;
  }

  .factory-video-header {
    padding-inline-start: 16px;
  }

  .factory-video-caption {
    padding-inline: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .factory-update-poster img,
  .factory-update-filter {
    transition: none;
  }
}
