.portfolio-page {
  background: var(--bg);
}

.portfolio-hero {
  position: relative;
  overflow: hidden;
  padding: 88px 0 72px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 78% 10%, rgba(137, 41, 229, .24), transparent 34%),
    linear-gradient(180deg, #090a0e, #08090c);
}

.portfolio-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #7020cf, transparent);
}

.portfolio-hero__content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.portfolio-hero h1,
.detail-heading h1,
.detail-not-found h1 {
  margin: 0;
  font-size: clamp(44px, 6vw, 76px);
  line-height: .98;
  letter-spacing: -.052em;
}

.portfolio-hero h1 span {
  color: var(--purple2);
}

.portfolio-hero__lead,
.detail-lead {
  max-width: 690px;
  margin: 22px 0 0;
  color: #b2b7c0;
  font-size: 15px;
  line-height: 1.7;
}

.portfolio-list-section {
  min-height: 580px;
  padding: 60px 0 84px;
  background:
    radial-gradient(circle at 5% 0, rgba(110, 34, 180, .11), transparent 28%),
    #080a0f;
}

.portfolio-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.portfolio-toolbar__copy h2 {
  margin: 0;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.08;
  letter-spacing: -.04em;
}

.portfolio-toolbar__copy p {
  margin: 8px 0 0;
  color: #949aa5;
  font-size: 13px;
}

.portfolio-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.portfolio-filter {
  min-height: 39px;
  padding: 0 14px;
  border: 1px solid #303542;
  border-radius: 999px;
  background: rgba(12, 14, 19, .82);
  color: #adb2bc;
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
  transition: .2s;
}

.portfolio-filter:hover,
.portfolio-filter.is-active {
  border-color: rgba(176, 76, 255, .8);
  background: linear-gradient(135deg, #5d17ad, #8828d8);
  color: #fff;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.portfolio-card {
  display: grid;
  grid-template-columns: 47% 53%;
  min-height: 300px;
  overflow: hidden;
  border: 1px solid #273042;
  border-radius: 9px;
  background: linear-gradient(150deg, #111725, #0d111b);
  box-shadow: var(--shadow);
  transition:
    transform .22s ease,
    border-color .22s ease;
}

.portfolio-card:hover {
  transform: translateY(-3px);
  border-color: rgba(176, 76, 255, .58);
}

.portfolio-card__media {
  position: relative;
  display: block;
  min-width: 0;
  padding: 9px;
  overflow: hidden;
}

.portfolio-card__single,
.portfolio-card__pair {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 280px;
  overflow: hidden;
  border-radius: 5px;
  background: #050608;
}

.portfolio-card__single img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portfolio-card__pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.portfolio-card__pair::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  background: rgba(176, 76, 255, .9);
  transform: translateX(-1px);
}

.portfolio-card__pair img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portfolio-card__before-label,
.portfolio-card__after-label {
  position: absolute;
  bottom: 10px;
  z-index: 2;
  padding: 5px 8px;
  border-radius: 3px;
  background: rgba(0, 0, 0, .72);
  color: #fff;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.portfolio-card__before-label {
  left: 10px;
}

.portfolio-card__after-label {
  right: 10px;
}

.portfolio-card__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 31px 27px;
}

.portfolio-card__category {
  color: #43d6ff;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.portfolio-card__title {
  display: block;
  margin-top: 10px;
  font-size: 24px;
  line-height: 1.15;
}

.portfolio-card__description {
  display: block;
  margin-top: 12px;
  color: #a5aab4;
  font-size: 13px;
  line-height: 1.65;
}

.portfolio-card__link {
  display: block;
  margin-top: 19px;
  color: #dc92ff;
  font-size: 12px;
  font-weight: 900;
}

.portfolio-empty {
  margin: 30px 0 0;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #101318;
  color: var(--muted);
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 28px 0 70px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 84% 20%, rgba(137, 41, 229, .22), transparent 32%),
    linear-gradient(180deg, #090a0e, #08090c);
}

.detail-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  margin-bottom: 34px;
  color: #858b96;
  font-size: 11px;
}

.detail-breadcrumb a:hover {
  color: #fff;
}

.detail-breadcrumb strong {
  color: #bfc3ca;
  font-weight: 700;
}

.detail-hero-grid {
  display: grid;
  grid-template-columns: 43% 57%;
  align-items: center;
  gap: 38px;
}

.detail-heading h1 {
  font-size: clamp(42px, 5vw, 67px);
}

.detail-heading .button {
  margin-top: 27px;
}

.detail-main-visual {
  min-width: 0;
  height: 450px;
  overflow: hidden;
  border: 1px solid #2a3040;
  border-radius: 10px;
  background: #050608;
  box-shadow: var(--shadow);
}

.detail-main-visual .compare,
.detail-static-image {
  width: 100%;
  height: 100%;
}

.detail-static-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-content-section {
  padding: 75px 0;
  background: #0b0d11;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: start;
  gap: 60px;
}

.detail-story {
  display: grid;
  gap: 55px;
}

.detail-story article {
  max-width: 750px;
}

.detail-story h2 {
  margin: 0;
  font-size: clamp(27px, 3vw, 40px);
  line-height: 1.1;
  letter-spacing: -.04em;
}

.detail-story article > p:not(.eyebrow) {
  margin: 17px 0 0;
  color: #a4a9b2;
  font-size: 14px;
  line-height: 1.78;
}

.detail-work-list {
  display: grid;
  gap: 11px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.detail-work-list li {
  position: relative;
  padding: 14px 16px 14px 44px;
  border: 1px solid #252a34;
  border-radius: 5px;
  background: #101318;
  color: #c4c8cf;
  font-size: 13px;
}

.detail-work-list li::before {
  content: "✓";
  position: absolute;
  left: 16px;
  top: 13px;
  color: var(--purple2);
  font-weight: 900;
}

.detail-summary-card {
  position: sticky;
  top: 105px;
  display: grid;
  padding: 27px;
  border: 1px solid #2d3340;
  border-radius: 8px;
  background:
    radial-gradient(circle at 100% 0, rgba(137, 41, 229, .15), transparent 36%),
    #101318;
  box-shadow: var(--shadow);
}

.detail-summary-card span {
  margin-top: 18px;
  color: #7f8691;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.detail-summary-card span:first-child {
  margin-top: 0;
}

.detail-summary-card strong {
  margin-top: 5px;
  color: #eef0f4;
  font-size: 13px;
  line-height: 1.45;
}

.detail-summary-card .button {
  width: 100%;
  margin-top: 25px;
}

.detail-gallery-section {
  background:
    radial-gradient(circle at 10% 0, rgba(110, 34, 180, .12), transparent 30%),
    #080a0f;
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 30px;
}

.detail-gallery a {
  height: 410px;
  overflow: hidden;
  border: 1px solid #292f3b;
  border-radius: 7px;
  background: #050608;
}

.detail-gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}

.detail-gallery a:hover img {
  transform: scale(1.02);
}

.detail-not-found {
  min-height: 600px;
  display: grid;
  align-items: center;
  padding: 80px 0;
  background:
    radial-gradient(circle at 70% 20%, rgba(137, 41, 229, .2), transparent 35%),
    #08090c;
}

.detail-not-found p:not(.eyebrow) {
  max-width: 560px;
  margin: 20px 0 25px;
  color: var(--muted);
}

@media (max-width: 980px) {
  .portfolio-toolbar {
    display: block;
  }

  .portfolio-filters {
    justify-content: flex-start;
    margin-top: 22px;
  }

  .portfolio-card {
    grid-template-columns: 42% 58%;
  }

  .detail-hero-grid {
    grid-template-columns: 1fr;
  }

  .detail-main-visual {
    height: 430px;
  }

  .detail-content-grid {
    grid-template-columns: 1fr;
  }

  .detail-summary-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .portfolio-hero {
    padding: 60px 0 52px;
  }

  .portfolio-list-section {
    padding: 46px 0 60px;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .portfolio-card {
    grid-template-columns: 41% 59%;
    min-height: 270px;
  }

  .portfolio-card__single,
  .portfolio-card__pair {
    min-height: 250px;
  }

  .portfolio-card__body {
    padding: 23px 20px;
  }

  .portfolio-card__title {
    font-size: 20px;
  }

  .detail-hero {
    padding-bottom: 48px;
  }

  .detail-main-visual {
    height: 350px;
  }

  .detail-content-section {
    padding: 55px 0;
  }

  .detail-gallery a {
    height: 300px;
  }
}

@media (max-width: 540px) {
  .portfolio-hero h1,
  .detail-heading h1,
  .detail-not-found h1 {
    font-size: 41px;
  }

  .portfolio-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .portfolio-filter {
    width: 100%;
  }

  .portfolio-card {
    grid-template-columns: 1fr;
  }

  .portfolio-card__media {
    height: 235px;
  }

  .portfolio-card__single,
  .portfolio-card__pair {
    min-height: 0;
  }

  .portfolio-card__description {
    font-size: 12px;
  }

  .detail-breadcrumb {
    margin-bottom: 25px;
  }

  .detail-main-visual {
    height: 290px;
  }

  .detail-gallery {
    grid-template-columns: 1fr;
  }

  .detail-gallery a {
    height: 280px;
  }
}

/* BEGIN WONAFKA PORTFOLIO FILTERS */

.portfolio-toolbar {
  margin: 28px 0 31px;
  padding: 22px;
  border: 1px solid #2c3240;
  border-radius: 9px;
  background:
    radial-gradient(
      circle at 100% 0,
      rgba(137, 41, 229, .13),
      transparent 36%
    ),
    #101318;
}

.portfolio-toolbar__top {
  display: grid;
  grid-template-columns:
    minmax(0, 1fr)
    220px;
  align-items: end;
  gap: 24px;
}

.portfolio-toolbar__label,
.portfolio-sort > span {
  display: block;
  margin-bottom: 11px;
  color: #aeb3be;
  text-transform: uppercase;
  letter-spacing: .15em;
  font-size: 9px;
  font-weight: 900;
}

.portfolio-group-filters,
.portfolio-category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.portfolio-group-filter,
.portfolio-category-filter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 42px;
  padding: 10px 15px;
  border: 1px solid #343a48;
  border-radius: 999px;
  background: #0a0c11;
  color: #c5c9d1;
  cursor: pointer;
  font: inherit;
  font-size: 11px;
  font-weight: 850;
  transition:
    border-color .18s ease,
    background .18s ease,
    color .18s ease,
    transform .18s ease;
}

.portfolio-group-filter:hover,
.portfolio-category-filter:hover {
  border-color: #8f31df;
  color: #fff;
  transform: translateY(-1px);
}

.portfolio-group-filter.is-active {
  border-color: #b24fff;
  background:
    linear-gradient(
      135deg,
      #6c16c2,
      #982be8
    );
  color: #fff;
  box-shadow:
    0 9px 25px
    rgba(126, 29, 211, .24);
}

.portfolio-category-filter.is-active {
  border-color: #9234d9;
  background:
    rgba(128, 37, 202, .17);
  color: #e5b2ff;
}

.portfolio-group-filter small,
.portfolio-category-filter small {
  min-width: 21px;
  padding: 3px 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.09);
  color: inherit;
  font-size: 9px;
  line-height: 1.2;
}

.portfolio-sort select,
.portfolio-category-select-wrap select {
  width: 100%;
  min-height: 45px;
  padding: 0 42px 0 14px;
  border: 1px solid #343a48;
  border-radius: 6px;
  background: #090b10;
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
}

.portfolio-toolbar__categories-block {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid #282e39;
}

.portfolio-category-select-wrap {
  display: none;
}

.portfolio-results-summary {
  margin-top: 18px;
  color: #838995;
  font-size: 11px;
}

.portfolio-grid {
  gap: 17px;
}

.portfolio-card__body {
  padding: 22px;
}

.portfolio-card__description {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.portfolio-load-more {
  display: flex;
  justify-content: center;
  margin: 29px 0 8px;
}

.portfolio-load-more[hidden] {
  display: none;
}

.portfolio-load-more .button {
  min-width: 230px;
}

@media (max-width: 800px) {
  .portfolio-toolbar__top {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .portfolio-sort {
    max-width: 360px;
  }
}

@media (max-width: 650px) {
  body {
    padding-bottom: 80px;
  }

  .portfolio-toolbar {
    margin-top: 24px;
    margin-bottom: 25px;
    padding: 15px;
  }

  .portfolio-toolbar__top {
    gap: 17px;
  }

  .portfolio-group-filters {
    display: grid;
    grid-template-columns:
      repeat(2, minmax(0, 1fr));
    gap: 9px;
  }

  .portfolio-group-filter {
    width: 100%;
    min-height: 47px;
    padding: 10px;
    font-size: 13px;
  }

  .portfolio-category-filters {
    display: none;
  }

  .portfolio-category-select-wrap {
    display: block;
  }

  .portfolio-toolbar__categories-block {
    margin-top: 17px;
    padding-top: 17px;
  }

  .portfolio-sort select,
  .portfolio-category-select-wrap select {
    min-height: 49px;
    font-size: 14px;
  }

  .portfolio-results-summary {
    margin-top: 14px;
    font-size: 12px;
  }

  .portfolio-grid {
    gap: 14px;
  }

  .portfolio-card__body {
    padding: 20px;
  }

  .portfolio-card__title {
    font-size: 27px;
    line-height: 1.16;
  }

  .portfolio-card__description {
    font-size: 15px;
    line-height: 1.55;
  }

  .portfolio-card__link {
    margin-top: 17px;
  }

  .portfolio-load-more {
    margin-top: 23px;
  }

  .portfolio-load-more .button {
    width: 100%;
  }
}

/* END WONAFKA PORTFOLIO FILTERS */

/* BEGIN WONAFKA PORTFOLIO DESKTOP FIX */

@media (min-width: 901px) {

  /*
   * Původní obal měl nadpis a jednoduché filtry vedle sebe.
   * Nový ovládací panel potřebuje celou šířku.
   */
  body *:has(> .portfolio-toolbar) {
    display: block !important;
    grid-template-columns: 1fr !important;
    align-items: initial !important;
  }

  body *:has(> .portfolio-toolbar) > .portfolio-toolbar {
    width: 100%;
    max-width: none;
    margin: 28px 0 0 !important;
  }

  /*
   * Úvodní text zůstane čitelný a nebude natažený
   * přes celou šířku monitoru.
   */
  body *:has(> .portfolio-toolbar) > :not(.portfolio-toolbar) {
    width: 100%;
    max-width: 720px;
  }

  .portfolio-toolbar__top {
    grid-template-columns:
      minmax(0, 1fr)
      220px;
    align-items: end;
    gap: 32px;
  }

  .portfolio-sort {
    width: 100%;
    max-width: 220px;
    justify-self: end;
  }

  .portfolio-toolbar__categories-block {
    width: 100%;
  }

  .portfolio-results-summary {
    width: 100%;
    text-align: right;
  }

  /*
   * Dvě karty na řádku zůstávají.
   */
  .portfolio-grid {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 901px) and (max-width: 1100px) {

  .portfolio-toolbar__top {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .portfolio-sort {
    max-width: 300px;
    justify-self: start;
  }

  .portfolio-results-summary {
    text-align: left;
  }
}

/* END WONAFKA PORTFOLIO DESKTOP FIX */

/* BEGIN WONAFKA PORTFOLIO COMPACT DESKTOP */

@media (min-width: 901px) {

  /*
   * Úvod nad filtry
   */

  body *:has(> .portfolio-toolbar)
  > :not(.portfolio-toolbar) {
    width: 100%;
    max-width: none;
    margin: 0 0 14px !important;
  }

  body *:has(> .portfolio-toolbar)
  > :not(.portfolio-toolbar) h2 {
    margin: 0 0 6px !important;
    font-size: clamp(30px, 3.1vw, 42px) !important;
    line-height: 1.05 !important;
    letter-spacing: -.04em;
  }

  body *:has(> .portfolio-toolbar)
  > :not(.portfolio-toolbar) p {
    max-width: 650px;
    margin: 0 !important;
    font-size: 13px !important;
    line-height: 1.55 !important;
  }


  /*
   * Kompaktnější panel filtrů
   */

  .portfolio-toolbar {
    display: block !important;
    width: 100% !important;
    margin: 14px 0 24px !important;
    padding: 16px 18px !important;
  }

  .portfolio-toolbar__top {
    display: grid !important;
    grid-template-columns:
      minmax(0, 1fr)
      200px !important;
    align-items: end !important;
    gap: 20px !important;
  }

  .portfolio-toolbar__groups-block {
    min-width: 0;
  }

  .portfolio-toolbar__categories-block {
    display: block !important;
    width: 100% !important;
    margin: 14px 0 0 !important;
    padding: 14px 0 0 !important;
    border-top: 1px solid #282e39;
  }

  .portfolio-toolbar__label,
  .portfolio-sort > span {
    margin-bottom: 8px !important;
  }

  .portfolio-group-filters,
  .portfolio-category-filters {
    gap: 7px !important;
  }

  .portfolio-group-filter,
  .portfolio-category-filter {
    min-height: 36px !important;
    padding: 7px 12px !important;
    font-size: 10px !important;
  }

  .portfolio-sort {
    width: 100%;
    max-width: 200px;
    justify-self: end;
  }

  .portfolio-sort select {
    min-height: 40px !important;
  }

  .portfolio-results-summary {
    width: 100% !important;
    margin-top: 11px !important;
    text-align: right !important;
  }


  /*
   * Dvě realizace vedle sebe
   */

  .portfolio-grid {
    display: grid !important;
    grid-template-columns:
      repeat(2, minmax(0, 1fr)) !important;
    gap: 18px !important;
  }


  /*
   * Karta bude vertikální:
   * obrázek nahoře, obsah dole.
   */

  .portfolio-card {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: auto 1fr !important;
    min-width: 0;
    overflow: hidden;
  }

  .portfolio-card__media {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 16 / 10;
    overflow: hidden;
  }

  .portfolio-card__single {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
  }

  .portfolio-card__pair {
    position: relative;
    display: grid !important;
    grid-template-columns:
      repeat(2, minmax(0, 1fr)) !important;
    width: 100% !important;
    height: 100% !important;
  }

  .portfolio-card__single img,
  .portfolio-card__pair img {
    display: block;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
  }

  .portfolio-card__body {
    display: flex !important;
    flex-direction: column;
    align-items: flex-start;
    padding: 18px 20px 20px !important;
  }

  .portfolio-card__category {
    margin-bottom: 9px;
  }

  .portfolio-card__title {
    font-size: 23px !important;
    line-height: 1.14 !important;
  }

  .portfolio-card__description {
    margin-top: 10px !important;
    font-size: 13px !important;
    line-height: 1.55 !important;

    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .portfolio-card__link {
    margin-top: auto !important;
    padding-top: 17px;
  }
}


@media (min-width: 901px) and (max-width: 1080px) {

  .portfolio-card__title {
    font-size: 21px !important;
  }

  .portfolio-card__media {
    aspect-ratio: 4 / 3;
  }

  .portfolio-toolbar__top {
    grid-template-columns:
      minmax(0, 1fr)
      180px !important;
  }

  .portfolio-sort {
    max-width: 180px;
  }
}

/* END WONAFKA PORTFOLIO COMPACT DESKTOP */

/* BEGIN WONAFKA DETAIL GALLERY FLOW */

/*
 * Odkaz pod hlavním sliderem nebo fotografií.
 */
.detail-gallery-jump {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  gap: 9px;
  min-height: 43px;
  margin-top: 13px;
  padding: 0 15px;
  border: 1px solid rgba(176, 76, 255, .34);
  border-radius: 7px;
  background: rgba(122, 35, 205, .10);
  color: #dda0ff;
  font-size: 12px;
  font-weight: 850;
  text-decoration: none;
  transition:
    border-color .2s ease,
    background .2s ease,
    color .2s ease;
}

.detail-gallery-jump:hover {
  border-color: rgba(196, 124, 255, .72);
  background: rgba(122, 35, 205, .20);
  color: #fff;
}

.detail-gallery-jump span {
  font-size: 15px;
}


/*
 * Galerie je nyní součást stejné obsahové mřížky.
 */
.detail-gallery-inline {
  min-width: 0;
  padding: 45px 0 0;
  margin-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, .09);
  scroll-margin-top: 125px;
}

.detail-gallery-inline .section-heading {
  margin-bottom: 24px;
}


/*
 * Desktop:
 * text vlevo, informační karta vpravo,
 * galerie pod oběma částmi.
 */
@media (min-width: 821px) {

  .detail-story {
    grid-column: 1;
    grid-row: 1;
  }

  .detail-summary-card {
    grid-column: 2;
    grid-row: 1;
  }

  .detail-gallery-inline {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}


/*
 * Mobil:
 * 1. popis práce
 * 2. galerie
 * 3. informační karta
 *
 * Pořadí je zajištěno už samotným HTML.
 */
@media (max-width: 820px) {

  .detail-content-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .detail-story,
  .detail-gallery-inline,
  .detail-summary-card {
    grid-column: 1;
    grid-row: auto;
  }

  .detail-gallery-inline {
    padding-top: 36px;
    margin-top: 4px;
  }

  .detail-summary-card {
    position: static !important;
    width: 100%;
    margin-top: 23px;
  }

  .detail-gallery-jump {
    align-self: stretch;
    width: 100%;
  }
}


@media (max-width: 520px) {

  .detail-gallery-inline {
    padding-top: 31px;
  }

  .detail-gallery-inline .section-heading {
    margin-bottom: 19px;
  }

  .detail-gallery-jump {
    min-height: 46px;
    font-size: 13px;
  }
}

/* END WONAFKA DETAIL GALLERY FLOW */

/* BEGIN WONAFKA REALIZACE LIGHTBOX */


/* ======================================================
   SOUHRNNÁ KARTA NA DESKTOPU
   ====================================================== */

/*
 * Karta zůstane v pravém sloupci,
 * ale nebude při rolování překrývat galerii.
 */
@media (min-width: 821px) {
  .detail-summary-card {
    position: static !important;
    top: auto !important;
    align-self: start;
  }
}


/* ======================================================
   ODKAZ NA GALERII
   ====================================================== */

@media (max-width: 820px) {
  .detail-gallery-jump {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 50px;
    margin-top: 15px;
    padding: 0 18px;
    border: 1px solid rgba(196, 111, 255, .70);
    border-radius: 7px;
    background:
      linear-gradient(
        135deg,
        rgba(100, 20, 186, .88),
        rgba(149, 47, 230, .88)
      );
    color: #fff;
    box-shadow:
      0 12px 30px rgba(126, 38, 216, .24);
    font-size: 13px;
    font-weight: 900;
    text-align: center;
    text-decoration: none;
  }

  .detail-gallery-jump span {
    font-size: 17px;
  }
}


/* ======================================================
   LIGHTBOX
   ====================================================== */

.realizace-lightbox[hidden] {
  display: none !important;
}

body.realizace-lightbox-open {
  overflow: hidden;
}

.realizace-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 22px;
}

.realizace-lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .93);
  backdrop-filter: blur(8px);
}

.realizace-lightbox__dialog {
  position: relative;
  z-index: 1;
  width: min(1400px, 96vw);
  max-height: calc(100vh - 44px);
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 10px;
  background: #08090c;
  box-shadow: 0 30px 100px rgba(0, 0, 0, .75);
}

.realizace-lightbox__stage {
  position: relative;
  min-height: 260px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #030405;
}

.realizace-lightbox__image {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 150px);
  width: auto;
  height: auto;
  object-fit: contain;
  cursor: ew-resize;
  user-select: none;
  -webkit-user-drag: none;
}

.realizace-lightbox__close,
.realizace-lightbox__previous,
.realizace-lightbox__next {
  position: absolute;
  z-index: 4;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .23);
  background: rgba(7, 8, 11, .78);
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.realizace-lightbox__close {
  top: 14px;
  right: 14px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  font-size: 30px;
  line-height: 1;
}

.realizace-lightbox__previous,
.realizace-lightbox__next {
  top: 50%;
  width: 52px;
  height: 70px;
  border-radius: 8px;
  transform: translateY(-50%);
  font-size: 34px;
}

.realizace-lightbox__previous {
  left: 15px;
}

.realizace-lightbox__next {
  right: 15px;
}

.realizace-lightbox__close:hover,
.realizace-lightbox__previous:hover,
.realizace-lightbox__next:hover {
  border-color: rgba(190, 103, 255, .82);
  background: rgba(116, 31, 201, .80);
}

.realizace-lightbox__meta {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  min-height: 66px;
  padding: 12px 20px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  background: #0c0e13;
}

.realizace-lightbox__counter {
  min-width: 58px;
  color: #dda3ff;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.realizace-lightbox__caption {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  color: #c5c8cf;
  font-size: 12px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}


/* ======================================================
   LIGHTBOX NA TELEFONU
   ====================================================== */

@media (max-width: 700px) {
  .realizace-lightbox {
    padding: 0;
  }

  .realizace-lightbox__dialog {
    width: 100vw;
    height: 100%;
    max-height: none;
    border: 0;
    border-radius: 0;
  }

  .realizace-lightbox__stage {
    min-height: 0;
  }

  .realizace-lightbox__image {
    max-width: 100vw;
    max-height: calc(100vh - 82px);
  }

  .realizace-lightbox__close {
    top: 12px;
    right: 12px;
    width: 43px;
    height: 43px;
  }

  .realizace-lightbox__previous,
  .realizace-lightbox__next {
    width: 44px;
    height: 62px;
    border: 0;
    background: rgba(0, 0, 0, .48);
    font-size: 29px;
  }

  .realizace-lightbox__previous {
    left: 4px;
  }

  .realizace-lightbox__next {
    right: 4px;
  }

  .realizace-lightbox__meta {
    min-height: 82px;
    grid-template-columns: 1fr;
    gap: 3px;
    padding:
      10px
      18px
      calc(10px + env(safe-area-inset-bottom));
  }

  .realizace-lightbox__counter {
    font-size: 13px;
  }

  .realizace-lightbox__caption {
    font-size: 11px;
    white-space: normal;
  }
}

/* END WONAFKA REALIZACE LIGHTBOX */

/* BEGIN WONAFKA GALLERY JUMP */

.detail-main-visual {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.detail-gallery-jump {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  gap: 9px;
  min-height: 46px;
  margin-top: 14px;
  padding: 0 18px;
  border: 1px solid rgba(190, 98, 255, .58);
  border-radius: 7px;
  background: rgba(124, 35, 210, .14);
  color: #e0a4ff;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
  text-decoration: none;
  transition:
    background .2s ease,
    border-color .2s ease,
    color .2s ease,
    transform .2s ease;
}

.detail-gallery-jump:hover {
  border-color: rgba(213, 145, 255, .92);
  background: rgba(130, 36, 219, .26);
  color: #fff;
  transform: translateY(-1px);
}

.detail-gallery-jump span {
  font-size: 17px;
  line-height: 1;
}

#galerie-realizace {
  scroll-margin-top: 125px;
}

@media (max-width: 820px) {

  .detail-gallery-jump {
    align-self: stretch;
    width: 100%;
    min-height: 51px;
    margin-top: 15px;
    background:
      linear-gradient(
        135deg,
        #6414ba,
        #952fe6
      );
    color: #fff;
    box-shadow:
      0 12px 30px rgba(126, 38, 216, .25);
  }
}

/* END WONAFKA GALLERY JUMP */

/* BEGIN WONAFKA MOBILE GALLERY JUMP VISIBILITY */

@media (max-width: 820px) {

  /*
   * Původní mobilní rozložení drželo hlavní vizuál
   * v omezené výšce a tlačítko pod ním ořízlo.
   */
  .detail-hero-grid .detail-main-visual {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
  }

  .detail-main-visual .detail-compare,
  .detail-main-visual .detail-static-image {
    flex: 0 0 auto !important;
    width: 100% !important;
  }

  .detail-main-visual > .detail-gallery-jump {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;

    position: relative !important;
    inset: auto !important;
    z-index: 10 !important;

    flex: 0 0 auto !important;
    align-items: center !important;
    justify-content: center !important;

    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    min-height: 52px !important;
    max-height: none !important;

    margin: 15px 0 0 !important;
    padding: 0 18px !important;

    overflow: visible !important;
    transform: none !important;
    pointer-events: auto !important;

    border: 1px solid rgba(205, 130, 255, .82) !important;
    border-radius: 7px !important;

    background:
      linear-gradient(
        135deg,
        #6414ba,
        #952fe6
      ) !important;

    color: #fff !important;
    box-shadow:
      0 12px 30px rgba(126, 38, 216, .28) !important;

    font-size: 13px !important;
    font-weight: 900 !important;
    line-height: 1.2 !important;
    text-align: center !important;
    text-decoration: none !important;
  }
}

/* END WONAFKA MOBILE GALLERY JUMP VISIBILITY */

/* BEGIN WONAFKA LOAD MORE BUTTON */

.portfolio-load-more-enhanced {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;

  width: min(100%, 440px) !important;
  min-height: 68px !important;

  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;

  margin: 34px auto 8px !important;
  padding: 12px 17px 12px 22px !important;

  border: 1px solid rgba(202, 118, 255, .78) !important;
  border-radius: 8px !important;

  background:
    linear-gradient(
      135deg,
      #6414ba,
      #952fe6
    ) !important;

  color: #fff !important;

  box-shadow:
    0 15px 38px rgba(126, 38, 216, .28),
    inset 0 1px 0 rgba(255, 255, 255, .10) !important;

  font-family: inherit !important;
  text-align: left !important;
  cursor: pointer !important;

  transition:
    transform .2s ease,
    filter .2s ease,
    border-color .2s ease,
    box-shadow .2s ease !important;
}

.portfolio-load-more-enhanced:hover {
  transform: translateY(-2px) !important;
  filter: brightness(1.08) !important;

  border-color:
    rgba(225, 174, 255, .95) !important;

  box-shadow:
    0 18px 44px rgba(126, 38, 216, .38),
    inset 0 1px 0 rgba(255, 255, 255, .14) !important;
}

.portfolio-load-more-enhanced:active {
  transform: translateY(0) !important;
}

.portfolio-load-more-enhanced:focus-visible {
  outline: 3px solid rgba(210, 143, 255, .48) !important;
  outline-offset: 4px !important;
}

.portfolio-load-more-enhanced__copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
}

.portfolio-load-more-enhanced__copy strong {
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
}

.portfolio-load-more-enhanced__copy small {
  color: rgba(255, 255, 255, .76) !important;
  font-size: 11px !important;
  font-weight: 650 !important;
  line-height: 1.35 !important;
}

.portfolio-load-more-enhanced__icon {
  flex: 0 0 auto;

  width: 41px;
  height: 41px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 50%;

  background: rgba(5, 6, 9, .24);
  color: #fff;

  font-size: 21px;
  font-weight: 800;
  line-height: 1;
}

.portfolio-load-more-enhanced:disabled {
  opacity: .52 !important;
  cursor: default !important;
  transform: none !important;
}


@media (max-width: 820px) {

  .portfolio-load-more-enhanced {
    width: 100% !important;
    min-height: 72px !important;

    margin:
      27px
      0
      7px !important;

    padding:
      13px
      14px
      13px
      18px !important;
  }

  .portfolio-load-more-enhanced__copy strong {
    font-size: 15px !important;
  }

  .portfolio-load-more-enhanced__copy small {
    font-size: 11px !important;
  }

  .portfolio-load-more-enhanced__icon {
    width: 43px;
    height: 43px;
  }
}

/* END WONAFKA LOAD MORE BUTTON */
