:root {
  --bg: #E9F1EB;
  --text: #2f241b;
  --accent: #bba676;
  --card-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Mountains of Christmas", serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: clamp(20px, 4vw, 36px) clamp(24px, 4vw, 44px) 48px;
  position: relative;
  overflow-x: hidden;
}

#app {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1500px;
  margin: 0 auto;
  padding: clamp(12px, 2vw, 24px);
}

.screen {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.title {
  font-size: clamp(36px, 4vw, 64px);
  margin: 0 0 6px;
  letter-spacing: 1px;
}

.subtitle {
  font-size: clamp(22px, 2.2vw, 36px);
  margin: 0 0 24px;
  font-weight: 400;
}

.note {
  font-size: clamp(18px, 1.7vw, 26px);
  margin: 6px 0 24px;
  color: #4a3a2c;
}

.grid {
  display: grid;
  /* This forces exactly 6 equal columns, no matter the screen width */
  grid-template-columns: repeat(6, 1fr); 
  gap: 12px; /* Tighter gap to let cards grow on desktop */
  justify-items: center;
  align-items: start;
  width: 100%;
}

.card {
  /* Change width to 100% so it fills the grid column exactly */
  width: 100%; 
  /* max-width stops them from getting huge on giant screens */
  max-width: 260px; 
  
  /* ... keep your other existing styles (background, shadow, etc.) ... */
  background: #fffdf7;
  border-radius: 12px;
  box-shadow: var(--card-shadow);
  transition: transform 150ms ease, box-shadow 150ms ease;
  cursor: pointer;
  aspect-ratio: 2 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.2);
}

.card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
}

.flippable {
  cursor: pointer;
  position: relative;
  perspective: 1200px;
  padding: 0;
  background: var(--bg);
  border-radius: 12px;
}

.flippable .card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.5s ease;
}

.flippable.flipped .card-inner {
  transform: rotateY(180deg);
}

.flippable .card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg);
}

.flippable .card-face.back {
  transform: rotateY(180deg);
}

.flippable .card-face img {
  border-radius: 12px;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.banner {
  margin: 0 auto 20px;
  padding: 20px 28px;
  width: min(540px, 90%);
  background: url("/Images/boarders/Small%20Boarder.svg") center/contain
    no-repeat;
  background-size: 100% 100%;
  color: var(--text);
}

.banner h2 {
  margin: 0 0 12px;
  font-size: clamp(26px, 3vw, 40px);
}

.banner p {
  margin: 0;
  font-size: clamp(18px, 2vw, 26px);
}

.reveal-card {
  display: inline-block;
  margin-top: 16px;
}

.actions {
  margin-top: 18px;
  display: flex;
  gap: 12px;
  justify-content: center;
}

button {
  font-family: "Mountains of Christmas", serif;
  font-size: 20px;
  padding: 10px 18px;
  border: 2px solid var(--accent);
  background: #fffaf0;
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.1);
  transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.15);
  background: #fff5e2;
}

button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.center-card {
  display: inline-block;
  width: min(380px, 80vw);
  max-width: 420px;
}

.spacer {
  height: 12px;
}

@media (max-width: 1000px) {
  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
  }
}

@media (max-width: 700px) {
  .grid {
    /* On small screens, use 2 columns */
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
}

@media (min-width: 1400px) {
  /* When the layout hits its max width on desktop, shrink feature cards to ~75% */
  .center-card {
    width: min(285px, 70vw);
    max-width: 315px;
  }
}
