* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100%;
  background: #f3f3f3;
  font-family: Arial, Helvetica, sans-serif;
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
}

.viewer {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 16px;
}

.slide-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
  
.slide-wrapper {
  width: 100%;
  max-height: calc(100vh - 120px);
  aspect-ratio: 4 / 5;
  background: #ffffff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
}

.slide-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  user-select: none;
}

.nav-button {
  position: absolute;
  z-index: 2;
  width: 44px;
  height: 64px;
  border: none;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  color: #ffffff;
  font-size: 42px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-button:hover,
.nav-button:focus {
  background: rgba(0, 0, 0, 0.65);
  outline: none;
}

.prev-button {
  left: 10px;
}

.next-button {
  right: 10px;
}

.controls {
  margin-top: 14px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.control-button {
  border: 1px solid #d0d0d0;
  background: #ffffff;
  color: #222222;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 14px;
  cursor: pointer;
}

.control-button:hover,
.control-button:focus {
  background: #eeeeee;
  outline: none;
}

.slide-counter {
  font-size: 14px;
  color: #333333;
  min-width: 110px;
  text-align: center;
}

.dots {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  gap: 7px;
  flex-wrap: wrap;
}

.dot {
  width: 9px;
  height: 9px;
  border: none;
  border-radius: 50%;
  background: #b8b8b8;
  cursor: pointer;
  padding: 0;
}

.dot.active {
  background: #222222;
}

@media (max-width: 600px) {
  .viewer {
    padding: 10px;
  }

  .slide-wrapper {
    max-height: calc(100vh - 135px);
    border-radius: 10px;
  }

  .nav-button {
    width: 36px;
    height: 52px;
    font-size: 34px;
  }

  .control-button {
    font-size: 13px;
    padding: 7px 10px;
  }
  .full-size-link-wrapper {
  margin-top: 28px;
  text-align: center;
}

.full-size-link {
  font-size: 10px;
  color: #222222;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.full-size-link:hover,
.full-size-link:focus {
  color: #000000;
  text-decoration-thickness: 2px;
}