:root {
  --cream: #fcf485;
  --cream-soft: #fff9cc;
  --orange: #ff692e;
  --orange-deep: #d84f18;
  --beetroot: #8d2b52;
  --chilli-paper: #c91f4b;
  --pumpkin: #f68b1e;
  --lemon: #f9d71c;
  --light-green: #c8e86a;
  --lemon-green: #a8d83d;
  --lettuce: #4caf50;
  --farm-green: #1d6b3a;
  --sky: #a9c4ea;
  --navy: #15208c;
  --text: #1f1d17;
  --border: rgba(141, 43, 82, 0.14);
  --shadow: 0 16px 34px rgba(141, 43, 82, 0.12);
  --font-title: "HonoraBold", "Playfair Display", serif;
  --font-display: "HonoraBold", "Playfair Display", serif;
  --font-content: "DarleySans", Arial, sans-serif;
}

@font-face {
  font-family: "HonoraBold";
  src: url("../../fonts/Boleroesque-Honora-by-Josh-Manh-Nguyen.otf") format("opentype");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DarleySans";
  src: url("../../fonts/DarleySans-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--text);
  font-family: var(--font-content);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.42), transparent 34%),
    linear-gradient(165deg, var(--cream-soft) 0%, #ffe0b3 38%, #ffbe78 72%, var(--orange) 100%);
  position: relative;
  isolation: isolate;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

button,
input,
textarea,
select {
  font: inherit;
}

h1,
h2,
h3 {
  font-family: var(--font-title);
}

p,
span,
li {
  font-family: var(--font-content);
}

.container {
  width: min(1180px, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  position: relative;
  z-index: 10;
  background: #ff692e;
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 28px rgba(255, 105, 46, 0.24);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
}

.site-header h1 {
  margin: 0;
  line-height: 0;
}

.site-header h1 a {
  display: block;
}

.site-logo {
  display: block;
  width: auto;
  height: clamp(34px, 4.8vw, 52px);
  filter:
    drop-shadow(2px 0 0 #fff7d5)
    drop-shadow(-2px 0 0 #fff7d5)
    drop-shadow(0 2px 0 #fff7d5)
    drop-shadow(0 -2px 0 #fff7d5)
    drop-shadow(1.5px 1.5px 0 #fff7d5)
    drop-shadow(-1.5px 1.5px 0 #fff7d5)
    drop-shadow(1.5px -1.5px 0 #fff7d5)
    drop-shadow(-1.5px -1.5px 0 #fff7d5)
    drop-shadow(0 3px 10px rgba(0, 0, 0, 0.24));
  transition: transform 0.2s ease, filter 0.2s ease;
}

.site-header h1:hover .site-logo {
  transform: translateY(-1px) scale(1.02);
  filter:
    drop-shadow(2px 0 0 #ffffff)
    drop-shadow(-2px 0 0 #ffffff)
    drop-shadow(0 2px 0 #ffffff)
    drop-shadow(0 -2px 0 #ffffff)
    drop-shadow(1.5px 1.5px 0 #ffffff)
    drop-shadow(-1.5px 1.5px 0 #ffffff)
    drop-shadow(1.5px -1.5px 0 #ffffff)
    drop-shadow(-1.5px -1.5px 0 #ffffff)
    drop-shadow(0 4px 12px rgba(0, 0, 0, 0.28));
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

.site-nav a {
  padding: 0.55rem 1rem;
  border-radius: 999px;
  color: #fff7d5;
  border: 1px solid rgba(255, 247, 213, 0.18);
  background: rgba(255, 255, 255, 0.04);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  transition: transform 0.2s ease, color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.site-nav a small {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0.92;
}

.home-banner {
  width: 100vw;
  height: auto;
  margin: 0;
  overflow: hidden;
  display: block;
}

.home-banner img {
  width: 100vw;
  height: auto;
  object-fit: contain;
  object-position: center;
}

.site-nav a:hover {
  color: #ffffff;
  border-color: rgba(255, 247, 213, 0.45);
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

.site-nav a.active {
  background: linear-gradient(135deg, var(--orange) 0%, #ff8c42 100%);
  color: #fff7d5;
  box-shadow: 0 8px 18px rgba(255, 105, 46, 0.28);
  border-color: rgba(255, 247, 213, 0.2);
}

.page-main {
  padding: 2.5rem 0 4rem;
  flex: 1 0 auto;
}

.hero,
section {
  background: linear-gradient(180deg, rgba(255, 249, 204, 0.96), rgba(252, 244, 133, 0.82));
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.hero h2,
section h2 {
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: #ff692e;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.05;
}

.hero p,
section p {
  max-width: 68ch;
  margin-bottom: 0;
  font-size: 1.02rem;
  line-height: 1.7;
}

.hero {
  border-left: 10px solid var(--orange);
  background:
    linear-gradient(135deg, rgba(255, 105, 46, 0.14), transparent 35%),
    linear-gradient(180deg, rgba(255, 249, 204, 0.94), rgba(252, 244, 133, 0.82));
}

.hero::after {
  content: "";
  display: block;
  width: min(120px, 18vw);
  height: 10px;
  margin-top: 1rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--lemon), var(--pumpkin), var(--lettuce), var(--farm-green));
}

.section-heading {
  margin-bottom: 1rem;
}

.rules-section h2,
.rule-modal__dialog h3 {
  font-family: var(--font-title);
}

.rules-section p,
.rule-modal__eyebrow,
.rule-modal__dialog p {
  font-family: var(--font-content);
}

.rules-section {
  overflow: visible;
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
}

.rules-carousel {
  margin-top: 1rem;
  position: relative;
  width: 100%;
  overflow: hidden;
  padding-inline: 0.25rem;
}

.rules-carousel.swiper {
  overflow: visible;
}

.rules-carousel .swiper-button-lock {
  display: none !important;
}

.rules-carousel .swiper-wrapper {
  align-items: center;
  padding: 0.15rem 0 0.8rem;
}

.rules-carousel .swiper-slide {
  width: min(440px, 41vw);
  height: auto;
  display: flex;
  opacity: 0.45;
  transform: scale(0.9);
  transition: transform 0.35s ease, opacity 0.35s ease, filter 0.35s ease;
}

.rules-carousel .swiper-slide-active {
  z-index: 2;
  opacity: 1;
  transform: scale(1);
}

.rules-carousel .swiper-slide-active .rule-card {
  transform: scale(1.18);
  box-shadow: 0 28px 58px rgba(141, 43, 82, 0.14);
}

.rule-card {
  width: 100%;
  border: 0;
  border-radius: 28px;
  background: transparent;
  box-shadow: none;
  padding: 0;
  display: block;
  overflow: hidden;
  cursor: pointer;
  outline: none;
  transition: transform 0.35s ease, opacity 0.35s ease, filter 0.35s ease, box-shadow 0.35s ease;
}

.rule-card:focus-visible {
  box-shadow: 0 0 0 3px rgba(255, 105, 46, 0.35), 0 26px 52px rgba(141, 43, 82, 0.18);
}

.rule-image {
  width: 100%;
  height: 400px;
  object-fit: contain;
  background: transparent;
}

.rule-modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1rem;
  z-index: 50;
}

.rule-modal[hidden] {
  display: none;
}

.rule-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(2px);
}

.rule-modal__dialog {
  position: relative;
  z-index: 1;
  width: auto;
  max-height: 92vh;
  overflow: visible;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.rule-modal__eyebrow {
  margin: 0 0 0.5rem;
  color: var(--chilli-paper);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.8rem;
}

.rule-modal__dialog h3 {
  margin: 0 2.2rem 0.75rem 0;
  color: #ff692e;
  font-size: clamp(1.5rem, 3vw, 2rem);
}

.rule-modal__dialog p:last-child {
  margin-bottom: 0;
  line-height: 1.75;
  font-size: 1rem;
}

.rule-modal__media {
  margin: 0;
  perspective: 1300px;
}

.rule-flip {
  position: relative;
  max-width: min(92vw, 760px);
  width: min(92vw, 760px);
  aspect-ratio: 3 / 4;
  max-height: 88vh;
}

.rule-flip__inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.72s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.rule-flip.is-flipped .rule-flip__inner {
  transform: rotateY(180deg);
}

.rule-flip__face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
}

.rule-flip__face--back {
  transform: rotateY(180deg);
}

.rule-flip__face img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 0;
  border: 0;
  box-shadow: none;
  object-fit: contain;
}

.rule-modal__fallback {
  margin-top: 0.9rem;
}

.rule-modal__eyebrow,
.rule-modal__dialog h3,
.rule-modal__fallback,
.rule-modal__close {
  display: none;
}

.rule-modal__close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 2.3rem;
  height: 2.3rem;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--beetroot), var(--chilli-paper));
  color: #fff7d5;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: auto;
  border-top: 1px solid rgba(255, 105, 46, 0.5);
  padding: 1.35rem 0 1.55rem;
  background: #ff692e;
  color: #fff7d5;
  backdrop-filter: blur(10px);
  box-shadow: 0 -14px 30px rgba(255, 105, 46, 0.2);
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 6px;
  background: #ff692e;
}

.site-footer .container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.4rem;
  text-align: left;
}

.site-footer h3 {
  margin: 0;
  font-size: 1.12rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #fff7d5;
}

.site-footer__label {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 247, 213, 0.95);
}

.site-footer__list {
  margin: 0.2rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.28rem;
}

.site-footer__list li {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.35;
}

.site-footer__support-btn {
  margin-top: 0.6rem;
  border: 1px solid rgba(255, 247, 213, 0.7);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff7d5;
  padding: 0.45rem 1.1rem;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.site-footer__support-btn:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.24);
  box-shadow: 0 10px 18px rgba(141, 43, 82, 0.14);
}

.support-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(21, 32, 140, 0.45);
}

.support-modal[hidden] {
  display: none !important;
}

.support-modal__dialog {
  width: min(100%, 620px);
  border-radius: 18px;
  border: 1px solid rgba(141, 43, 82, 0.24);
  background: linear-gradient(180deg, rgba(255, 249, 204, 0.98), rgba(252, 244, 133, 0.95));
  box-shadow: 0 20px 44px rgba(21, 32, 140, 0.25);
  padding: 1.1rem 1.1rem 1.2rem;
  position: relative;
}

.support-modal__close {
  position: absolute;
  top: 0.7rem;
  right: 0.7rem;
  z-index: 2;
  border: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: rgba(141, 43, 82, 0.12);
  color: var(--beetroot);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}

.support-modal__dialog h3 {
  margin: 0;
  color: var(--beetroot);
  font-size: 1.2rem;
}

.support-modal__dialog p {
  margin: 0.55rem 0 0.9rem;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--text);
}

.support-modal__form {
  display: grid;
  gap: 0.45rem;
}

.support-modal__form label {
  font-weight: 700;
  color: var(--beetroot);
}

.support-modal__form input,
.support-modal__form textarea {
  width: 100%;
  border: 1px solid rgba(141, 43, 82, 0.28);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  font: inherit;
  color: var(--text);
  background: rgba(255, 255, 255, 0.85);
}

.support-modal__submit {
  margin-top: 0.35rem;
  justify-self: start;
  border: 0;
  border-radius: 999px;
  background: #ff692e;
  color: #fff7d5;
  font-weight: 700;
  padding: 0.5rem 1.1rem;
  cursor: pointer;
}

.support-modal__success {
  margin: 0.35rem 0 0;
  color: #167c3a;
  font-weight: 700;
}

.rps-section {
  position: relative;
  overflow: hidden;
}

.rps-heading h2 {
  margin-bottom: 0.4rem;
}

.rps-heading p {
  margin-top: 0;
  margin-bottom: 1rem;
  max-width: none;
  white-space: nowrap;
}

.rps-scoreboard {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.2rem;
}

.score-item {
  border: 1px solid rgba(141, 43, 82, 0.2);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.66);
  padding: 0.7rem 0.9rem;
  text-align: center;
}

.score-item span {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--beetroot);
}

.score-item strong {
  display: block;
  margin-top: 0.3rem;
  font-size: 1.5rem;
  color: var(--text);
}

.rps-table {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: stretch;
}

.rps-player-panel h3,
.rps-arena .duel-label {
  margin-top: 0;
  margin-bottom: 0.8rem;
  color: #ff692e;
  font-size: 1.15rem;
}

.card-hand {
  display: grid;
  grid-template-columns: repeat(3, minmax(82px, 110px));
  justify-content: center;
  gap: 0.7rem;
}

.choice-card {
  position: relative;
  border: 2px solid transparent;
  border-radius: 14px;
  padding: 0;
  cursor: pointer;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 10px 24px rgba(141, 43, 82, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.choice-label {
  position: absolute;
  left: 0.6rem;
  bottom: 0.55rem;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: rgba(21, 32, 140, 0.86);
  color: #fff7d5;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.choice-card img,
.duel-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
}

.choice-card:hover:not(:disabled) {
  transform: translateY(-4px);
  border-color: rgba(255, 105, 46, 0.48);
  box-shadow: 0 16px 28px rgba(141, 43, 82, 0.16);
}

.choice-card.is-selected {
  border-color: var(--orange);
  transform: translateY(-3px) scale(1.01);
}

.choice-card:disabled {
  cursor: not-allowed;
  opacity: 0.84;
}

.rps-player-panel,
.rps-arena {
  border: 1px solid rgba(141, 43, 82, 0.18);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.56);
  padding: 0.9rem;
}

.rps-player-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.rps-arena {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.duel-cards {
  width: min(460px, 100%);
  display: grid;
  grid-template-columns: repeat(2, minmax(96px, 145px));
  justify-content: center;
  gap: 0.9rem;
  margin-bottom: 0.85rem;
}

.duel-card {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(141, 43, 82, 0.12);
  border: 1px solid rgba(141, 43, 82, 0.14);
  background: rgba(255, 255, 255, 0.88);
  perspective: 900px;
}

.duel-card img {
  backface-visibility: hidden;
  transform-origin: center;
}

.duel-card.is-flipping img {
  animation: duel-flip 0.42s ease-in-out;
}

.duel-card--user.is-fighting {
  animation: clash-user 0.55s ease;
}

.duel-card--cpu.is-fighting {
  animation: clash-cpu 0.55s ease;
}

.duel-card--cpu.is-thrown {
  animation: throw-cpu 0.52s ease;
}

.round-result {
  margin: 0.2rem 0 0.25rem;
  min-height: 1.6em;
  font-size: 1rem;
  font-weight: 700;
  color: var(--beetroot);
}

.round-note {
  margin-top: 0;
  margin-bottom: 0.85rem;
  font-size: 0.9rem;
}

.rps-restart,
.game-overlay__dialog button {
  border: 0;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  color: #fff8e0;
  font-weight: 700;
  background: linear-gradient(135deg, var(--orange), #ff8642);
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(255, 105, 46, 0.25);
}

.rps-restart:hover,
.game-overlay__dialog button:hover {
  filter: brightness(1.05);
}

.game-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(18, 16, 24, 0.54);
  border-radius: 24px;
}

.game-overlay[hidden] {
  display: none;
}

.game-overlay__dialog {
  width: min(420px, calc(100% - 1.5rem));
  border-radius: 20px;
  padding: 1.2rem;
  background: linear-gradient(180deg, #fff8db, #ffeeb8);
  text-align: center;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.22);
}

.game-overlay__dialog h3 {
  margin: 0 0 0.5rem;
  color: #ff692e;
}

.game-overlay__dialog p {
  margin: 0 0 0.95rem;
}

.folk-page {
  display: grid;
  gap: 1.4rem;
}

.folk-hero,
.timeline-section {
  position: relative;
  overflow: hidden;
}

.folk-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: clamp(1rem, 3vw, 2rem);
  align-items: stretch;
  padding: clamp(1.2rem, 2.5vw, 2rem);
  border-radius: 30px;
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.72), transparent 28%),
    radial-gradient(circle at 82% 22%, rgba(141, 43, 82, 0.1), transparent 20%),
    linear-gradient(135deg, rgba(255, 249, 204, 0.96), rgba(252, 244, 133, 0.84));
}

.folk-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 26px 26px, rgba(141, 43, 82, 0.05) 0 2px, transparent 3px 18px),
    radial-gradient(circle at 75% 15%, rgba(29, 107, 58, 0.06) 0 2px, transparent 3px 18px),
    linear-gradient(90deg, transparent 49.5%, rgba(29, 107, 58, 0.08) 50%, transparent 50.5%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.7), transparent 96%);
}

.folk-hero__copy,
.folk-hero__media {
  position: relative;
  z-index: 1;
}

.folk-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.folk-brand__mark {
  width: 74px;
  height: 74px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(141, 43, 82, 0.98), rgba(255, 105, 46, 0.94));
  color: #fff7d5;
  box-shadow: 0 16px 26px rgba(141, 43, 82, 0.22);
  flex: none;
}

.folk-brand__mark svg {
  width: 44px;
  height: 44px;
}

.folk-brand__eyebrow {
  margin: 0 0 0.25rem;
  color: var(--farm-green);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.folk-hero__copy h2 {
  margin: 0;
  color: #ff692e;
  font-size: clamp(0.98rem, 2.22vw, 1.95rem);
  line-height: 0.96;
}

.folk-hero__copy .folk-brand-title {
  color: #ff692e;
}

.folk-copy-card {
  margin-top: 1rem;
  padding: 1rem 1.1rem;
  border-radius: 22px;
  border: 1px solid rgba(141, 43, 82, 0.14);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 12px 24px rgba(141, 43, 82, 0.08);
  display: grid;
  align-content: start;
  gap: 0.18rem;
}

.folk-copy-card h3 {
  margin: 0 0 0.55rem;
  color: #ff692e;
  font-family: var(--font-title);
  font-size: 1.25rem;
}

.timeline-card__title-image {
  width: min(295px, 100%);
  height: clamp(34px, 3.8vw, 50px);
  overflow: hidden;
  line-height: 0;
}

.folk-copy-card p {
  margin: 0;
  line-height: 1.72;
}

.folk-brand-title {
  margin: 0 0 0.4rem;
  color: #ff692e;
  font-size: clamp(0.86rem, 1.96vw, 1.72rem);
  line-height: 0.96;
}

.folk-copy-card__title {
  margin: 0 0 0.55rem;
  color: #ff692e;
  font-size: 1.25rem;
  line-height: 1.08;
}

.timeline-card__title {
  margin: 0 0 0.55rem;
  color: #ff692e;
  font-size: 1.5rem;
  line-height: 1.08;
}

.folk-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.folk-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.8rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(141, 43, 82, 0.14);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 18px rgba(141, 43, 82, 0.08);
  font-weight: 700;
  transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.folk-pill svg {
  width: 1.1rem;
  height: 1.1rem;
  flex: none;
  color: var(--beetroot);
}

.folk-pill:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 105, 46, 0.42);
  background: linear-gradient(135deg, rgba(255, 105, 46, 0.08), rgba(255, 255, 255, 0.98));
  box-shadow: 0 16px 24px rgba(141, 43, 82, 0.12);
}

.folk-hero__media {
  min-height: 100%;
}

.folk-media-card {
  position: relative;
  margin: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(141, 43, 82, 0.14);
  background: linear-gradient(180deg, rgba(21, 32, 140, 0.08), rgba(255, 255, 255, 0.96));
  box-shadow: var(--shadow);
  isolation: isolate;
}

.folk-media-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(141, 43, 82, 0.05), transparent 35%),
    radial-gradient(circle at 18% 14%, rgba(255, 255, 255, 0.18), transparent 18%);
  z-index: 1;
}

.folk-media-card__badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 2;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(141, 43, 82, 0.92);
  color: #fff7d5;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.16);
}

.folk-media-card__image {
  width: 100%;
  height: 100%;
  min-height: 0;
  aspect-ratio: auto;
  object-fit: cover;
  object-position: center;
  display: block;
  transform: none;
  animation: none;
}

.folk-media-card__overlay {
  position: absolute;
  inset: auto 1rem 1rem;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(15, 15, 15, 0), rgba(15, 15, 15, 0.62));
  color: #fff7d5;
}

.folk-media-card__play {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(252, 244, 133, 0.95);
  color: var(--beetroot);
  font-size: 1.1rem;
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.24);
  flex: none;
}

.folk-media-card__overlay p {
  margin: 0;
  max-width: 16ch;
  font-family: var(--font-title);
  font-size: 1.05rem;
  line-height: 1.25;
}

.folk-hero--origin .folk-copy-card--origin {
  border-left: 4px solid var(--orange);
}

.folk-hero--origin {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1rem, 2.2vw, 1.6rem);
  align-items: stretch;
}

.folk-hero--origin .folk-hero__copy {
  max-width: none;
}

.folk-hero--origin .folk-hero__media {
  display: flex;
  align-items: stretch;
  justify-content: stretch;
}

.timeline-section {
  overflow: visible;
  padding: clamp(0.85rem, 1.8vw, 1.35rem);
  border-radius: 30px;
  background:
    radial-gradient(circle at 8% 8%, rgba(255, 255, 255, 0.62), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(252, 244, 133, 0.82));
}

.section-kicker {
  margin: 0 0 0.6rem;
  color: #ff692e;
  font-family: var(--font-title);
  font-size: clamp(0.98rem, 2.22vw, 1.95rem);
  line-height: 0.96;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}

.section-kicker {
  width: 100%;
  max-width: none;
}

.folk-brand-image,
.text-word-image,
.text-word-image--hero,
.text-word-image--kicker,
.folk-copy-card__title-image,
.timeline-card__title-image {
  display: none;
}

@media (max-width: 900px) {
  .folk-hero--origin {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }

  .folk-hero--origin .folk-hero__media {
    width: min(560px, 100%);
    justify-self: center;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.timeline-section h2 {
  margin-bottom: 0;
}

.timeline-section__title {
  margin: 0 0 1rem;
  color: #ff692e;
  font-family: var(--font-title);
  font-size: clamp(1.4rem, 2.6vw, 2.2rem);
  line-height: 1.08;
}

.folk-timeline {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 320px) minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 2rem);
  align-items: start;
  padding: 0.15rem 0 0.45rem;
}

.folk-timeline__rail {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 6px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--orange), var(--beetroot));
  box-shadow: 0 0 0 12px rgba(255, 105, 46, 0.06);
}

.folk-timeline__center {
  grid-column: 2;
  grid-row: 1 / span 3;
  margin: 0;
  display: grid;
  place-items: center;
  position: sticky;
  top: calc(50vh - 150px);
  align-self: start;
  z-index: 1;
}

.folk-timeline__orb {
  position: relative;
  width: min(100%, 270px);
  aspect-ratio: 1;
  padding: 0.7rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.55) 30%, rgba(252, 244, 133, 0.96) 62%, rgba(255, 105, 46, 0.24) 100%);
  box-shadow: 0 22px 44px rgba(141, 43, 82, 0.14);
  border: 1px solid rgba(141, 43, 82, 0.12);
  overflow: hidden;
}

.folk-timeline__orb::before,
.folk-timeline__orb::after {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  border: 1px dashed rgba(141, 43, 82, 0.15);
}

.folk-timeline__orb::after {
  inset: 22px;
  border-style: solid;
  border-color: rgba(29, 107, 58, 0.18);
}

.folk-timeline__orb-ring {
  position: absolute;
  inset: 14px;
  border-radius: 50%;
  border: 7px solid rgba(255, 255, 255, 0.34);
  mix-blend-mode: screen;
}

.folk-timeline__orb img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  border-radius: 50%;
  filter: drop-shadow(0 18px 20px rgba(141, 43, 82, 0.16));
  transform: none;
  animation: none;
}

.timeline-card {
  position: relative;
  padding: 1.15rem 1.2rem;
  border-radius: 26px;
  border: 1px solid rgba(141, 43, 82, 0.14);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 14px 24px rgba(141, 43, 82, 0.1);
}

.timeline-card::after {
  content: "";
  position: absolute;
  top: 1.35rem;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--cream);
  border: 4px solid var(--orange);
  box-shadow: 0 0 0 8px rgba(255, 105, 46, 0.12);
}

.timeline-card--left {
  grid-column: 1;
  justify-self: end;
  max-width: 520px;
}

.timeline-card--left:not(.timeline-card--final) {
  grid-row: 1;
}

.timeline-card--right {
  grid-column: 3;
  grid-row: 2;
  justify-self: start;
  max-width: 520px;
}

.timeline-card--final {
  grid-column: 1;
  grid-row: 3;
}

.timeline-card--left::after {
  right: -1.45rem;
}

.timeline-card--right::after {
  left: -1.45rem;
}

.timeline-card__tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.65rem;
  padding: 0.34rem 0.68rem;
  border-radius: 999px;
  background: rgba(141, 43, 82, 0.08);
  color: var(--beetroot);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.timeline-card__tag svg {
  width: 0.95rem;
  height: 0.95rem;
  flex: none;
  color: var(--beetroot);
}

.timeline-card h3 {
  margin: 0 0 0.55rem;
  color: #ff692e;
  font-family: var(--font-title);
  font-size: 1.5rem;
}

.timeline-card p {
  margin: 0;
  line-height: 1.82;
}

.timeline-card__example {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px dashed rgba(141, 43, 82, 0.2);
}

.timeline-card--final {
  margin-bottom: 0.2rem;
}

.folk-timeline.is-half-flow .timeline-card--left:not(.timeline-card--final),
.folk-timeline.is-half-flow .timeline-card--right,
.folk-timeline.is-half-flow .timeline-card--final {
  grid-row: 1;
  margin-top: 0;
}

@keyframes folk-float {
  0% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-8px) scale(1.02);
  }

  100% {
    transform: translateY(0) scale(1);
  }
}

@keyframes folk-media-drift {
  0% {
    transform: scale(1.03) translateY(0);
  }

  100% {
    transform: scale(1.07) translateY(-10px);
  }
}

@keyframes clash-user {
  0% {
    transform: translateX(-28px) scale(0.95);
  }

  62% {
    transform: translateX(6px) scale(1.03);
  }

  100% {
    transform: translateX(0) scale(1);
  }
}

@keyframes clash-cpu {
  0% {
    transform: translateX(28px) scale(0.95);
  }

  62% {
    transform: translateX(-6px) scale(1.03);
  }

  100% {
    transform: translateX(0) scale(1);
  }
}

@keyframes throw-cpu {
  0% {
    transform: translateY(-40px) rotate(-9deg) scale(0.84);
    opacity: 0;
  }

  70% {
    transform: translateY(5px) rotate(3deg) scale(1.03);
    opacity: 1;
  }

  100% {
    transform: translateY(0) rotate(0) scale(1);
    opacity: 1;
  }
}

@keyframes duel-flip {
  0% {
    transform: rotateY(0deg);
  }

  50% {
    transform: rotateY(90deg);
  }

  100% {
    transform: rotateY(0deg);
  }
}

@keyframes modal-pop {
  from {
    transform: translateY(14px) scale(0.96);
    opacity: 0;
  }

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

@media (max-width: 640px) {
  .site-header .container {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-nav {
    justify-content: flex-start;
  }

  .site-nav a {
    padding: 0.5rem 0.75rem;
  }

  .hero,
  section {
    border-radius: 20px;
    padding: 1.15rem;
  }

  .rules-carousel {
    padding-inline: 0;
  }

  .rules-carousel .swiper-slide {
    width: min(380px, 94vw);
  }

  .rules-carousel .swiper-slide-active .rule-card {
    transform: scale(1.12);
  }

  .rule-image {
    height: 350px;
  }

  .rules-carousel .swiper-slide:hover {
    transform: scale(0.95);
  }

  .rules-nav {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.4rem;
  }

  .rules-nav--prev {
    left: 0.2rem;
  }

  .rules-nav--next {
    right: 0.2rem;
  }

  .rule-image {
    height: 210px;
  }

  .rule-modal__dialog {
    padding: 0;
    border-radius: 0;
  }

  .site-footer {
    padding: 1.15rem 0 1.25rem;
  }

  .rps-scoreboard {
    grid-template-columns: 1fr;
  }

  .rps-table {
    grid-template-columns: 1fr;
  }

  .rps-heading p {
    white-space: normal;
  }

  .card-hand {
    grid-template-columns: repeat(3, minmax(78px, 1fr));
    gap: 0.55rem;
  }

  .duel-cards {
    width: min(330px, 100%);
    grid-template-columns: repeat(2, minmax(92px, 120px));
    gap: 0.7rem;
  }

  .choice-label {
    left: 0.35rem;
    bottom: 0.35rem;
    padding: 0.12rem 0.45rem;
    font-size: 0.74rem;
  }

  .folk-hero {
    grid-template-columns: 1fr;
    border-radius: 24px;
  }

  .folk-hero--origin {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .folk-hero--origin .folk-hero__media {
    display: block;
  }

  .folk-brand {
    align-items: flex-start;
  }

  .folk-brand__mark {
    width: 62px;
    height: 62px;
    border-radius: 18px;
  }

  .folk-brand__mark svg {
    width: 36px;
    height: 36px;
  }

  .folk-copy-card {
    padding: 0.95rem 1rem;
  }

  .folk-pills {
    gap: 0.55rem;
  }

  .folk-pill {
    width: 100%;
    justify-content: flex-start;
    padding: 0.72rem 0.9rem;
  }

  .folk-media-card__overlay {
    inset: auto 0.75rem 0.75rem;
    padding: 0.85rem;
  }

  .folk-media-card__play {
    width: 52px;
    height: 52px;
  }

  .timeline-section {
    border-radius: 24px;
  }

  .folk-timeline {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding-left: 1.35rem;
  }

  .folk-timeline__rail {
    left: 14px;
    transform: none;
  }

  .folk-timeline__center {
    grid-column: auto;
    grid-row: auto;
    order: 2;
    width: min(100%, 260px);
    justify-self: center;
    position: relative;
    top: auto;
  }

  .timeline-card {
    grid-column: auto;
    max-width: none;
    justify-self: stretch;
  }

  .timeline-card--left,
  .timeline-card--right {
    justify-self: stretch;
  }

  .timeline-card--left:not(.timeline-card--final),
  .timeline-card--right,
  .timeline-card--final {
    grid-row: auto;
  }

  .timeline-card::after {
    left: -1.1rem;
    right: auto;
  }
}

@media (min-width: 481px) and (max-width: 640px) {
  .folk-timeline {
    grid-template-columns: minmax(0, 1fr) minmax(150px, 220px) minmax(0, 1fr);
    gap: 0.8rem;
    padding-left: 0;
  }

  .folk-timeline__rail {
    left: 50%;
    transform: translateX(-50%);
  }

  .folk-timeline__center {
    grid-column: 2;
    grid-row: 1 / span 3;
    order: initial;
    width: min(100%, 190px);
    justify-self: center;
    position: sticky;
    top: calc(50vh - 95px);
  }

  .timeline-card {
    max-width: 100%;
  }

  .timeline-card--left {
    grid-column: 1;
    justify-self: end;
  }

  .timeline-card--left:not(.timeline-card--final) {
    grid-row: 1;
  }

  .timeline-card--right {
    grid-column: 3;
    grid-row: 2;
    justify-self: start;
  }

  .timeline-card--final {
    grid-column: 1;
    grid-row: 3;
  }

  .timeline-card--left::after {
    right: -1.45rem;
    left: auto;
  }

  .timeline-card--right::after {
    left: -1.45rem;
    right: auto;
  }
}

@media (max-width: 900px) {
  .rps-table {
    grid-template-columns: 1fr;
  }
}

.collection-page {
  display: grid;
  gap: 1.2rem;
}

.collection-landing,
.collection-view {
  background:
    radial-gradient(circle at 12% 15%, rgba(255, 255, 255, 0.68), transparent 32%),
    linear-gradient(160deg, #f8edd4 0%, #f1dfbf 52%, #e8ceb0 100%);
  border: 1px solid rgba(130, 78, 45, 0.24);
}

.collection-heading h2 {
  margin: 0;
  font-family: "HonoraBold", serif;
  font-size: 2rem;
  color: #ff692e;
  letter-spacing: 0.01em;
}

.collection-heading p {
  margin: 0.45em 0 0;
  font-family: "DarleySans", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: #5f3a29;
}

.collection-folder-grid {
  margin-top: 1.1em;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65em;
}

.collection-folder-card {
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  border: 0;
  border-radius: 1.1em;
  min-height: clamp(24.5rem, 40.8vw, 28.8rem);
  padding: 0;
  margin: 0;
  overflow: hidden;
  text-align: center;
  cursor: pointer;
  background: transparent;
  box-shadow: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.collection-folder-card:hover {
  transform: translateY(-0.12em);
  box-shadow: 0 1em 1.8em rgba(92, 56, 33, 0.2);
}

.collection-folder-card:focus-visible {
  outline: 3px solid rgba(255, 105, 46, 0.34);
  outline-offset: 0.18em;
}

.collection-folder-card__bg {
  flex: 0 0 auto;
  width: 100%;
  height: clamp(18rem, 30vw, 21rem);
  display: block;
  object-fit: cover;
  object-position: top center;
  opacity: 1;
  filter: none;
}

.collection-folder-card__desc {
  margin: 0;
  padding: 0.75rem 0.9rem 0.95rem;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  line-height: 1.55;
  color: #5f3a29;
  background: transparent;
  border-top: 0;
}

@media (max-width: 820px) {
  .collection-folder-card__desc {
    font-size: 0.92rem;
  }
}

@media (max-width: 560px) {
  .collection-folder-card__desc {
    padding: 0.68rem 0.85rem 0.82rem;
  }
}

.collection-popup {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(29, 18, 12, 0.58);
}

.collection-popup[hidden] {
  display: none !important;
}

.collection-popup__dialog {
  position: relative;
  width: min(100%, 980px);
  max-height: 92vh;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid rgba(130, 78, 45, 0.24);
  background:
    radial-gradient(circle at 12% 15%, rgba(255, 255, 255, 0.7), transparent 32%),
    linear-gradient(160deg, #f8edd4 0%, #f1dfbf 52%, #e8ceb0 100%);
  box-shadow: 0 1.6em 3em rgba(28, 16, 10, 0.36);
  padding: 1.15rem 1.15rem 1.3rem;
}

.collection-popup__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  z-index: 2;
  width: 2.1rem;
  height: 2.1rem;
  border: 0;
  border-radius: 999px;
  background: rgba(139, 47, 39, 0.12);
  color: #8b2f27;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.collection-popup__heading {
  margin-bottom: 0.8rem;
  padding-right: 2.6rem;
}

.collection-popup__heading h3 {
  margin: 0;
  font-family: "HonoraBold", serif;
  font-size: 1.6rem;
  color: #ff692e;
}

.collection-popup__heading p {
  margin: 0.35em 0 0;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  color: #5f3a29;
}

.collection-popup__swiper {
  position: relative;
}

.collection-popup__swiper .swiper-slide {
  display: flex;
  justify-content: center;
}

.collection-popup__card {
  width: min(100%, 860px);
  border-radius: 1em;
  overflow: hidden;
  border: 1px solid rgba(126, 72, 41, 0.22);
  background: rgba(255, 252, 244, 0.92);
  box-shadow: 0 0.8em 1.6em rgba(104, 62, 36, 0.14);
}

.collection-popup__card img {
  width: 100%;
  max-height: 72vh;
  object-fit: contain;
  display: block;
}

.collection-popup__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.7rem;
  height: 2.7rem;
  border: 0;
  border-radius: 999px;
  background: rgba(139, 47, 39, 0.9);
  color: #fff4dc;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 3;
}

.collection-popup__nav--prev {
  left: 0.55rem;
}

.collection-popup__nav--next {
  right: 0.55rem;
}

.collection-popup__nav.swiper-button-disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.collection-back-btn {
  border: 0;
  border-radius: 999px;
  padding: 0.5em 1.05em;
  margin-bottom: 0.8em;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  color: #fff4dc;
  background: linear-gradient(135deg, #8b2f27, #b74f2f);
  cursor: pointer;
}

.collection-carousel {
  margin-top: 1.1em;
  padding: 0.7em 0;
}

.collection-carousel .swiper-slide {
  width: min(22em, 90vw);
  transform: scale(0.9);
  opacity: 0.8;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.collection-carousel .swiper-slide-active {
  transform: scale(1);
  opacity: 1;
}

.collection-item {
  border-radius: 1em;
  border: 1px solid rgba(126, 72, 41, 0.24);
  background: linear-gradient(180deg, rgba(255, 252, 244, 0.95), rgba(242, 225, 197, 0.96));
  padding: 1em;
  margin: 0.2em;
  box-shadow: 0 0.75em 1.4em rgba(104, 62, 36, 0.14);
}

.collection-item__image {
  width: 100%;
  aspect-ratio: 3 / 2;
  border-radius: 0.8em;
  overflow: hidden;
  border: 1px solid rgba(126, 72, 41, 0.25);
  background: rgba(246, 227, 194, 0.65);
}

.collection-item__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.collection-item__image--text {
  display: grid;
  place-items: center;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  color: #7c4f35;
  letter-spacing: 0.02em;
}

.collection-item h3 {
  margin: 0.7em 0 0.35em;
  font-family: "HonoraBold", serif;
  font-size: 1.3rem;
  color: #8b2f27;
}

.collection-item p {
  margin: 0;
  font-family: "DarleySans", sans-serif;
  font-size: 0.98rem;
  line-height: 1.6;
  color: #4f3629;
}

@media (max-width: 820px) {
  .collection-folder-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collection-heading h2 {
    font-size: 1.65rem;
  }
}

@media (max-width: 560px) {
  .collection-folder-grid {
    grid-template-columns: 1fr;
  }
}

.group-gallery {
  background:
    radial-gradient(circle at 12% 15%, rgba(255, 255, 255, 0.68), transparent 32%),
    linear-gradient(160deg, #f8edd4 0%, #f1dfbf 52%, #e8ceb0 100%);
  border: 1px solid rgba(130, 78, 45, 0.24);
  border-radius: 24px;
  padding: 1.5rem;
}

.group-gallery__back {
  display: inline-flex;
  align-items: center;
  margin-bottom: 0.9em;
  border-radius: 999px;
  padding: 0.48em 1em;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  color: #fff4dc;
  background: linear-gradient(135deg, #8b2f27, #b74f2f);
}

.group-gallery__swiper {
  margin-top: 1em;
  padding: 0;
}

.group-gallery__swiper .swiper-slide {
  width: auto;
}

.group-gallery__card {
  margin: 0.2em;
  border-radius: 1em;
  border: 1px solid rgba(126, 72, 41, 0.24);
  background: linear-gradient(180deg, rgba(255, 252, 244, 0.95), rgba(242, 225, 197, 0.96));
  box-shadow: 0 0.75em 1.4em rgba(104, 62, 36, 0.14);
  overflow: hidden;
}

.group-gallery__card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
}

.melody-page {
  display: grid;
  gap: 1.2rem;
}

.melody-flashcard-section {
  padding: 0.5rem 0 1rem;
}

.melody-flashcard-shell {
  width: min(100%, 900px);
  margin: 0 auto;
}

.melody-flashcard-back {
  display: inline-flex;
  align-items: center;
  margin-bottom: 1rem;
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-family: "DarleySans", sans-serif;
  font-size: 0.95rem;
  color: #fff4dc;
  background: linear-gradient(135deg, #8b2f27, #b74f2f);
}

.melody-flashcard-heading {
  text-align: center;
  margin-bottom: 1.5rem;
}

.melody-flashcard-heading h2 {
  margin: 0;
  color: var(--ink, #3a1e12);
  font-family: "HonoraBold", serif;
  font-size: clamp(1.8rem, 4vw, 3rem);
}

.melody-flashcard-intro {
  margin: 0.6rem auto 0;
  max-width: 42rem;
  color: rgba(58, 30, 18, 0.78);
  font-family: "DarleySans", system-ui, sans-serif;
  font-size: 1.02rem;
  line-height: 1.65;
}

.melody-flashcard-stage {
  display: grid;
  place-items: center;
  perspective: 1400px;
  margin: 0 auto;
}

.melody-flashcard {
  appearance: none;
  border: 0;
  padding: 0;
  background: transparent;
  width: min(100%, 293px);
  aspect-ratio: 3 / 4;
  cursor: pointer;
  transform-style: preserve-3d;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.melody-flashcard:focus-visible {
  outline: 3px solid rgba(255, 105, 46, 0.35);
  outline-offset: 8px;
  border-radius: 1.6rem;
}

.melody-flashcard.is-hidden {
  opacity: 0;
  transform: translateY(14px) scale(0.98);
  transition:
    opacity 220ms ease,
    transform 220ms ease;
}

.melody-flashcard__inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 1.6rem;
  transform-style: preserve-3d;
  transition: transform 760ms cubic-bezier(0.2, 0.75, 0.2, 1);
  box-shadow:
    0 24px 54px rgba(58, 30, 18, 0.18),
    0 0 0 1px rgba(255, 255, 255, 0.45) inset;
}

.melody-flashcard.is-flipped .melody-flashcard__inner {
  transform: rotateY(180deg);
}

.melody-flashcard__face {
  position: absolute;
  inset: 0;
  border-radius: 1.6rem;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.melody-flashcard__face--front {
  background: linear-gradient(180deg, #fff9ed 0%, #f8e7c6 100%);
}

.melody-flashcard__face--front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.melody-flashcard__face--back {
  transform: rotateY(180deg);
  background: linear-gradient(180deg, #fff9ed 0%, #f8e7c6 100%);
}

.melody-flashcard__face--back img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.melody-flashcard-nav {
  display: flex;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 1.2rem;
  flex-wrap: wrap;
}

.melody-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 0;
  border-radius: 999px;
  padding: 0.95rem 1.25rem;
  background: #ff692e;
  color: #fff;
  font-family: "DarleySans", system-ui, sans-serif;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 14px 28px rgba(255, 105, 46, 0.24);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    opacity 180ms ease;
}

.melody-nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px rgba(255, 105, 46, 0.3);
}

.melody-nav-btn:active {
  transform: translateY(0);
}

.melody-nav-btn--next {
  background: linear-gradient(135deg, #1d6b3a, #2b8a4d);
}

@media (max-width: 640px) {
  .melody-flashcard {
    width: min(100%, 246px);
  }

  .melody-flashcard__face--back {
    padding: 1rem;
  }

  .melody-nav-btn {
    width: 100%;
    justify-content: center;
  }

  .melody-flashcard-nav {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .melody-flashcard__inner,
  .melody-flashcard.is-hidden,
  .melody-nav-btn {
    transition: none;
  }
}
