/* ====================================================
   STANDALONE ISOLATED STYLE: ABOUT PAGE DEFINITIONS
   ==================================================== */

body.about-page-wrapper {
  background-color: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ISOLATED HERO STACK
   Encapsulates ambient lighting perfectly within its boundaries
*/
.about-hero-wrapper {
  position: relative;
  width: 100%;
  padding-top: 140px;
  margin-bottom: clamp(3rem, 8vw, 5rem);
  overflow: hidden;
}

.about-hero-content {
  text-align: center;
  position: relative;
  z-index: 5;
}

/* LAYOUT FORCING STYLES */
.about-section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.about-page-wrapper .section-kicker {
  position: static !important;
  transform: none !important;
  left: auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.55rem !important;
  margin: 0 auto 0.75rem auto !important;
  text-align: center !important;
}
.about-page-wrapper .section-kicker::before {
  content: '';
  display: inline-block;
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 6px var(--accent-soft);
}
.about-page-wrapper .section-title {
  text-align: center !important;
  margin: 0 auto 1.25rem auto !important;
}

.about-page-wrapper .projects-subtitle {
  text-align: center !important;
  margin: 0 auto !important;
  max-width: 620px !important;
}

/* STRUCTURAL LAYOUT GRID */
.story-layout-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: stretch;
  margin-bottom: clamp(4rem, 10vw, 7rem);
}

.story-bio-card {
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.8);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

body.dark-mode .story-bio-card {
  background: rgba(21, 23, 26, 0.75);
}

.story-bio-card p {
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--muted);
}

.story-bio-card p strong { color: var(--text); }

.about-tag-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1rem;
}

.about-tag-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  transition: var(--transition);
}

.about-tag-badge i { color: var(--accent); }
.about-tag-badge:hover {
  color: var(--text);
  border-color: var(--text);
  transform: translateY(-2px);
}

.setup-spec-card {
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow-md);
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

body.dark-mode .setup-spec-card {
  background: rgba(21, 23, 26, 0.75);
}

.setup-image-placeholder {
  width: 100%;
  height: clamp(180px, 24vw, 260px);
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  position: relative;
  margin-bottom: 1.5rem;
}

.setup-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: var(--surface-soft);
}

.setup-image[src=""],
.setup-image:not([src]) {
  display: none;
}

.setup-image-fallback {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  gap: 0.5rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 1rem;
}

.setup-image-fallback i {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
}

.setup-card-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.setup-card-title i { color: var(--accent); }

.setup-data-list {
  list-style: none;
  display: grid;
  gap: 1rem;
}

.setup-list-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.75rem;
  border-bottom: 1px dashed var(--line);
  font-size: 0.95rem;
}
.setup-list-row:last-child { border-bottom: 0; padding-bottom: 0; }
.setup-row-label { color: var(--muted); }
.setup-val { font-weight: 600; color: var(--text); text-align: right; }

/* GALLERY ROW SCROLLER */
.about-gallery-section {
  margin-bottom: clamp(4rem, 10vw, 7rem);
  overflow: visible;
}

.stack-gallery-wrapper {
  position: relative;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 54px;
  align-items: center;
  gap: 1rem;
  width: 100%;
  margin-top: 1.5rem;
  overflow: visible;
}

.stack-gallery-stage {
  position: relative;
  width: min(760px, 100%);
  height: clamp(300px, 48vw, 500px);
  margin: 0 auto;
  perspective: 1200px;
  touch-action: pan-y;
  user-select: none;
  overflow: visible;
  transform-style: preserve-3d;
  isolation: isolate;
}

.stack-photo-card {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  opacity: 0;
  transform: translate3d(0, 0, 0) scale(0.82) rotate(0deg);
  transition:
    transform 420ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 220ms ease,
    filter 220ms ease;
  pointer-events: none;
  will-change: transform, opacity;
  backface-visibility: hidden;
}
.stack-photo-card.active {
  opacity: 1;
  z-index: 5;
  transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
  filter: blur(0);
  pointer-events: auto;
}

.stack-photo-card.prev {
  opacity: 0.36;
  z-index: 3;
  transform: translate3d(-72px, 0, -40px) scale(0.9) rotate(-6deg);
  filter: saturate(0.75) brightness(0.78);
}

.stack-photo-card.next {
  opacity: 0.36;
  z-index: 4;
  transform: translate3d(72px, 0, -40px) scale(0.9) rotate(6deg);
  filter: saturate(0.75) brightness(0.78);
}

.stack-photo-card.far-next {
  opacity: 0.14;
  z-index: 2;
  transform: translate3d(120px, 0, -80px) scale(0.78) rotate(10deg);
  filter: saturate(0.55) brightness(0.65);
}

.stack-photo-card.hidden {
  opacity: 0;
  z-index: 1;
  transform: translate3d(0, 0, -120px) scale(0.72) rotate(0deg);
  filter: brightness(0.6);
}
.stack-photo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.stack-photo-info {
  position: absolute;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 2;
  padding: 1rem 1.1rem;
  border-radius: 20px;
  background: rgba(11, 13, 15, 0.68);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.stack-photo-info h4 {
  color: #ffffff;
  font-size: 1.15rem;
  margin-bottom: 0.25rem;
}

.stack-photo-info span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.8rem;
  font-family: 'Fira Code', monospace;
}

.stack-gallery-btn {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  z-index: 8;
}

.stack-gallery-btn:hover {
  background: var(--text);
  color: var(--surface);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.stack-gallery-dots {
  display: flex;
  justify-content: center;
  gap: 0.55rem;
  margin-top: 1.5rem;
}

.stack-dot {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.22);
  cursor: pointer;
  transition: var(--transition);
}

.stack-dot.active {
  width: 32px;
  background: var(--text);
}

body.dark-mode .stack-dot {
  background: rgba(255, 255, 255, 0.22);
}

body.dark-mode .stack-dot.active {
  background: var(--text);
}

/* POPUP LIGHTBOX SYSTEM */
.about-lightbox-screen {
  position: fixed;
  inset: 0;
  background: rgba(11, 13, 15, 0.96);
  z-index: 2000;
  display: none;
  place-items: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.about-lightbox-screen.active { display: grid; opacity: 1; }

.about-lightbox-image {
  max-width: 85vw;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 8px;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}
.about-lightbox-screen.active .about-lightbox-image { transform: scale(1); }

.about-lightbox-close {
  position: absolute;
  top: 30px;
  right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  opacity: 0.7;
}
.about-lightbox-caption { position: absolute; bottom: 40px; color: #fff; text-align: center; }
.about-lightbox-caption h4 { font-size: 1.25rem; margin-bottom: 0.25rem; }
.about-lightbox-caption span { font-family: 'Fira Code', monospace; color: var(--accent); font-size: 0.85rem; }

/* INTEREST CARDS */
.about-interests-container {
  margin-bottom: clamp(4rem, 10vw, 7rem);
}

.about-interests-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}

.about-interest-card {
  height: 100%;
  min-height: 320px;
  padding: clamp(1.35rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.8);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.about-interest-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(37, 99, 235, 0.28);
}

body.dark-mode .about-interest-card {
  background: rgba(21, 23, 26, 0.75);
}

.about-interest-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
  flex-shrink: 0;
}

.about-interest-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.about-interest-meta {
  display: inline-block;
  font-family: 'Fira Code', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.65rem;
}

.about-interest-info h4 {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.about-interest-info p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 0;
}

/* INTEREST VIEW BUTTON */
.interest-view-btn {
  width: fit-content;
  margin-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 44px;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--text);
  color: var(--surface);
  font-size: 0.9rem;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
}

.interest-view-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

body.dark-mode .interest-view-btn {
  background: var(--text);
  color: #0c0d0f;
}

/* INTEREST POPUP MODAL */
.interest-gallery-modal {
  position: fixed;
  inset: 0;
  z-index: 1800;
  display: none;
  place-items: center;
  padding: clamp(0.9rem, 2vw, 1.5rem);
  background: rgba(11, 13, 15, 0.78);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.interest-gallery-modal.active {
  display: grid;
  animation: interestBackdropIn 260ms ease;
}

.interest-gallery-panel {
  position: relative;
  width: min(1080px, 100%);
  max-height: min(88vh, 820px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  padding: clamp(1.2rem, 3vw, 2rem);
  display: flex;
  flex-direction: column;
  transform-origin: center;
}

.interest-gallery-modal.active .interest-gallery-panel {
  animation: interestPanelIn 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.interest-gallery-modal.active .interest-gallery-close,
.interest-gallery-modal.active .interest-gallery-header,
.interest-gallery-modal.active .interest-gallery-list,
.interest-gallery-modal.active .interest-gallery-detail {
  animation: interestContentIn 520ms cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

.interest-gallery-modal.active .interest-gallery-close {
  animation-delay: 80ms;
}

.interest-gallery-modal.active .interest-gallery-header {
  animation-delay: 100ms;
}

.interest-gallery-modal.active .interest-gallery-list {
  animation-delay: 150ms;
}

.interest-gallery-modal.active .interest-gallery-detail {
  animation-delay: 180ms;
}

.interest-gallery-modal.active .interest-gallery-item {
  animation: interestItemIn 420ms cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

.interest-gallery-modal.active .interest-gallery-item:nth-child(1) {
  animation-delay: 240ms;
}

.interest-gallery-modal.active .interest-gallery-item:nth-child(2) {
  animation-delay: 290ms;
}

.interest-gallery-modal.active .interest-gallery-item:nth-child(3) {
  animation-delay: 340ms;
}

.interest-gallery-modal.active .interest-gallery-item:nth-child(4) {
  animation-delay: 390ms;
}

.interest-gallery-modal.active .interest-gallery-item:nth-child(n + 5) {
  animation-delay: 430ms;
}

.interest-gallery-modal.closing {
  display: grid;
  animation: interestBackdropOut 260ms ease forwards;
}

.interest-gallery-modal.closing .interest-gallery-panel {
  animation: interestPanelOut 320ms cubic-bezier(0.76, 0, 0.24, 1) forwards;
}

.interest-gallery-modal.closing .interest-gallery-close,
.interest-gallery-modal.closing .interest-gallery-header,
.interest-gallery-modal.closing .interest-gallery-list,
.interest-gallery-modal.closing .interest-gallery-detail {
  animation: interestContentOut 220ms ease forwards;
}

@keyframes interestBackdropIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes interestPanelIn {
  from {
    opacity: 0;
    transform: translateY(26px) scale(0.96);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes interestContentIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes interestItemIn {
  from {
    opacity: 0;
    transform: translateX(-14px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes interestBackdropOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

@keyframes interestPanelOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  to {
    opacity: 0;
    transform: translateY(22px) scale(0.96);
  }
}

@keyframes interestContentOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }

  to {
    opacity: 0;
    transform: translateY(10px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .interest-gallery-modal.active,
  .interest-gallery-modal.closing,
  .interest-gallery-modal.active .interest-gallery-panel,
  .interest-gallery-modal.closing .interest-gallery-panel,
  .interest-gallery-modal.active .interest-gallery-close,
  .interest-gallery-modal.closing .interest-gallery-close,
  .interest-gallery-modal.active .interest-gallery-header,
  .interest-gallery-modal.closing .interest-gallery-header,
  .interest-gallery-modal.active .interest-gallery-list,
  .interest-gallery-modal.closing .interest-gallery-list,
  .interest-gallery-modal.active .interest-gallery-detail,
  .interest-gallery-modal.closing .interest-gallery-detail,
  .interest-gallery-modal.active .interest-gallery-item {
    animation: none;
  }
}

body.dark-mode .interest-gallery-panel {
  background: #15171a;
}

.interest-gallery-close {
  position: absolute;
  top: 1.1rem;
  right: 1.1rem;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface-soft);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 4;
  transition: var(--transition);
}

.interest-gallery-close:hover {
  background: var(--text);
  color: var(--surface);
}

.interest-gallery-header {
  max-width: 720px;
  padding-right: 3rem;
  margin-bottom: 1.4rem;
  flex-shrink: 0;
}

.interest-gallery-meta {
  display: inline-block;
  margin-bottom: 0.45rem;
  font-family: 'Fira Code', monospace;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.interest-gallery-header h3 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  margin-bottom: 0.55rem;
}

.interest-gallery-header p {
  margin-bottom: 0;
  max-width: 680px;
}

.interest-gallery-layout {
  display: grid;
  grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
  gap: 1.25rem;
  height: clamp(430px, 55vh, 520px);
  min-height: 0;
}

/* LEFT IMAGE LIST */
.interest-gallery-list {
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  display: grid;
  align-content: start;
  gap: 0.85rem;
  padding: 0.25rem 0.45rem 0.25rem 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(37, 99, 235, 0.55) var(--surface-soft);
  box-sizing: border-box;
}

.interest-gallery-list::-webkit-scrollbar {
  width: 8px;
}

.interest-gallery-list::-webkit-scrollbar-track {
  background: var(--surface-soft);
  border-radius: 999px;
}

.interest-gallery-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.55);
  border: 2px solid var(--surface-soft);
}

.interest-gallery-list::-webkit-scrollbar-thumb:hover {
  background: rgba(37, 99, 235, 0.8);
}

.interest-gallery-item {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 0.85rem;
  align-items: center;
  width: 100%;
  min-height: 92px;
  padding: 0.65rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
  color: inherit;
  text-align: left;
  cursor: pointer;
  transition: var(--transition);
}

.interest-gallery-item:hover,
.interest-gallery-item.active {
  border-color: rgba(37, 99, 235, 0.45);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.interest-gallery-thumb {
  width: 96px;
  height: 74px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
}

.interest-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.interest-gallery-item-text {
  min-width: 0;
}

.interest-gallery-item-text h5 {
  font-size: 0.95rem;
  margin-bottom: 0;
  color: var(--text);
  line-height: 1.35;
  word-break: break-word;
}

/* RIGHT SELECTED IMAGE PANEL */
.interest-gallery-detail {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  background: var(--surface-soft);
}

.interest-detail-preview {
  min-height: 0;
  overflow: hidden;
  background: #0c0d0f;
}

.interest-detail-preview img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  cursor: zoom-in;
}

.interest-detail-text {
  min-height: 104px;
  padding: 1rem 1.25rem;
  background: var(--surface);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "count button"
    "title button";
  align-items: center;
  gap: 0.35rem 1rem;
}

body.dark-mode .interest-detail-text {
  background: #15171a;
}

.interest-detail-count {
  grid-area: count;
  display: inline-block;
  color: var(--accent);
  font-family: 'Fira Code', monospace;
  font-size: 0.78rem;
  font-weight: 800;
}

.interest-detail-text h4 {
  grid-area: title;
  font-size: clamp(1.25rem, 2.2vw, 1.7rem);
  margin-bottom: 0;
  line-height: 1.15;
  min-width: 0;
  word-break: break-word;
}

.interest-open-large-btn {
  grid-area: button;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 42px;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--text);
  color: var(--surface);
  font-size: 0.86rem;
  font-weight: 800;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.interest-open-large-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

body.dark-mode .interest-open-large-btn {
  background: var(--text);
  color: #0c0d0f;
}

/* BREAKPOINTS */
@media (max-width: 992px) {
  .story-layout-grid {
    grid-template-columns: 1fr;
  }

  .about-interests-grid {
    grid-template-columns: 1fr;
  }

  .about-interest-card {
    min-height: 260px;
  }
}

@media (max-width: 900px) {
  .interest-gallery-panel {
    max-height: 90vh;
    overflow-y: auto;
  }

  .interest-gallery-layout {
    grid-template-columns: 1fr;
    height: auto;
  }

  .interest-gallery-list {
    height: auto;
    max-height: 270px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.25rem 0;
  }

  .interest-gallery-item {
    grid-template-columns: 82px minmax(0, 1fr);
    min-height: 82px;
  }

  .interest-gallery-thumb {
    width: 82px;
    height: 64px;
  }

  .interest-gallery-detail {
    height: min(430px, 70vh);
  }
}

@media (max-width: 768px) {
  .stack-gallery-wrapper {
    grid-template-columns: 1fr;
  }

  .stack-gallery-stage {
    width: 100%;
    height: clamp(270px, 72vw, 420px);
    overflow: visible;
  }

  .stack-photo-card.prev {
    transform: translate3d(-32px, 0, -40px) scale(0.88) rotate(-5deg);
  }

  .stack-photo-card.next {
    transform: translate3d(32px, 0, -40px) scale(0.88) rotate(5deg);
  }

  .stack-photo-card.far-next {
    transform: translate3d(58px, 0, -80px) scale(0.76) rotate(8deg);
  }

  .stack-gallery-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
  }

  .stack-gallery-btn.prev {
    left: 8px;
  }

  .stack-gallery-btn.next {
    right: 8px;
  }

  .stack-gallery-btn:hover {
    transform: translateY(-50%);
  }

  .stack-photo-info {
    left: 0.9rem;
    right: 0.9rem;
    bottom: 0.9rem;
    padding: 0.85rem;
    border-radius: 16px;
  }

  .stack-photo-info h4 {
    font-size: 1rem;
  }

  .stack-photo-info span {
    font-size: 0.72rem;
  }
}

@media (max-width: 560px) {
  .setup-image-placeholder {
    aspect-ratio: 4 / 3;
    border-radius: 18px;
    margin-bottom: 1.25rem;
  }

  .about-interest-card {
    min-height: auto;
    padding: 1.25rem;
  }

  .about-interest-icon {
    width: 52px;
    height: 52px;
    margin-bottom: 1.2rem;
  }

  .about-interest-info h4 {
    font-size: 1.2rem;
  }

  .interest-view-btn {
    width: 100%;
  }

  .interest-gallery-modal {
    padding: 0.8rem;
  }

  .interest-gallery-panel {
    border-radius: 24px;
    padding: 1rem;
  }

  .interest-gallery-header {
    padding-right: 2.6rem;
  }

  .interest-gallery-header h3 {
    font-size: 1.65rem;
  }

  .interest-gallery-header p {
    font-size: 0.9rem;
  }

  .interest-gallery-list {
    grid-template-columns: 1fr;
    max-height: 230px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.25rem 0;
  }

  .interest-gallery-item {
    grid-template-columns: 76px minmax(0, 1fr);
    min-height: 76px;
    padding: 0.55rem;
  }

  .interest-gallery-thumb {
    width: 76px;
    height: 58px;
  }

  .interest-gallery-detail {
    height: 360px;
  }

  .interest-detail-text {
    min-height: 118px;
    grid-template-columns: 1fr;
    grid-template-areas:
      "count"
      "title"
      "button";
    align-items: start;
  }

  .interest-open-large-btn {
    width: 100%;
    margin-top: 0.4rem;
  }
}

@media (max-width: 480px) {
  .stack-gallery-stage {
    height: 260px;
  }

  .stack-photo-card {
    border-radius: 24px;
  }

  .stack-photo-card.prev {
    transform: translate3d(-20px, 0, -40px) scale(0.88) rotate(-4deg);
  }

  .stack-photo-card.next {
    transform: translate3d(20px, 0, -40px) scale(0.88) rotate(4deg);
  }

  .stack-photo-card.far-next {
    transform: translate3d(34px, 0, -80px) scale(0.76) rotate(7deg);
  }
}
