/* Save Slots Dialog */
#save-slots-dialog {
  box-sizing: border-box;
  width: min(760px, 95vw);
  max-height: 92dvh;
  padding: 14px 18px;
  border: 2px solid #8aa89b;
  border-radius: 18px;
  background: #f5efdf;
  color: #213d34;
}
#save-slots-dialog::backdrop,
#anniversary-intro-dialog::backdrop,
#anniversary-shop-dialog::backdrop,
#anniversary-wish-dialog::backdrop {
  background: #142a2ab8;
  backdrop-filter: blur(4px);
}
#save-slots-dialog header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
#save-slots-dialog header > div {
  margin-right: auto;
}
#save-slots-dialog h2 {
  margin: 0;
  font-size: 21px;
}
#save-slots-count {
  display: block;
  font-size: 12px;
  color: #547065;
  margin-top: 2px;
}
.save-slots-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
#save-slots-status {
  margin: 0 0 10px;
  font-size: 12px;
  color: #425f53;
}
#save-slots-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.save-slot-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border-radius: 14px;
  border: 1.5px solid #c5cfb9;
  background: #fffbf0;
}
.save-slot-card.active {
  border-color: #d68b38;
  box-shadow: 0 0 0 2px #f7d68d66;
}
.save-slot-card.empty {
  border-style: dashed;
  background: #f7f3e4;
}
.save-slot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.save-slot-badge {
  padding: 2px 8px;
  border-radius: 999px;
  background: #d97a30;
  color: #fff9e8;
  font-size: 11px;
  font-weight: 700;
}
.save-slot-badge.muted {
  background: #d9ddd2;
  color: #55665d;
}
.save-slot-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.save-slot-meta b {
  font-size: 16px;
  color: #203d34;
}
.save-slot-meta span {
  font-size: 12px;
  color: #3e5b51;
}
.save-slot-meta small,
.save-slot-empty-copy {
  font-size: 11px;
  color: #677d73;
  margin: 0;
  line-height: 1.4;
}
.save-slot-empty-copy {
  flex: 1;
}
.save-slot-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.save-slot-actions button {
  min-height: 30px;
  padding: 4px 10px;
  font-size: 12px;
}

/* Special Map Card & Locked Gray State */
.map-art.anniversary {
  background: linear-gradient(135deg, #c9333f, #f5b95b);
}
.map-card.map-card-locked {
  filter: grayscale(1);
  opacity: 0.62;
  cursor: not-allowed;
}
.map-card.map-card-locked:hover {
  transform: none;
}
.special-map-empty {
  grid-column: 1 / -1;
  padding: 24px 18px;
  border-radius: 16px;
  border: 1.5px dashed #b9c3b1;
  background: #fffaf0;
  color: #4b6157;
  text-align: center;
}
.special-map-empty h3 {
  margin: 0 0 6px;
  color: #2c4a40;
}
.special-map-empty p {
  margin: 0;
  font-size: 13px;
}
#world-special-map {
  background: linear-gradient(135deg, #b8333d, #d97a32);
  color: #fff6d6;
  border-color: #f4cc76;
}

/* Anniversary World HUD */
#anniversary-world-balance {
  position: absolute;
  top: 91px;
  left: 15px;
  margin: 0;
  padding: 7px 12px;
  border-radius: 10px;
  color: #fff4c4;
  background: #7d1f28db;
  border: 1px solid #f7cf79;
  font-size: 12px;
  z-index: 4;
}

/* Anniversary Opening Intro Animation Dialog */
#anniversary-intro-dialog {
  box-sizing: border-box;
  width: min(740px, 95vw);
  max-height: 94dvh;
  padding: 12px 16px;
  border: 2px solid #f2c86b;
  border-radius: 18px;
  background: linear-gradient(160deg, #5e1824, #2f1422);
  color: #fff4d2;
}
#anniversary-intro-dialog header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
#anniversary-intro-dialog h2 {
  margin: 0;
  font-size: 20px;
  color: #ffe694;
}
#anniversary-intro-canvas {
  display: block;
  width: 100%;
  height: clamp(190px, 44dvh, 330px);
  border-radius: 14px;
  border: 1.5px solid #f2c86b88;
  background: #6c1e30;
}
#anniversary-intro-badge {
  margin: 8px 0 0;
  padding: 6px 10px;
  border-radius: 10px;
  background: linear-gradient(90deg, #b82c38, #d98d2b);
  color: #fff8db;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}
#anniversary-intro-caption {
  margin: 8px 0 0;
  font-size: 13px;
  text-align: center;
  color: #ffefc2;
}

/* Anniversary Shop Dialog */
#anniversary-shop-dialog {
  box-sizing: border-box;
  width: min(820px, 95vw);
  max-height: 93dvh;
  overflow: auto;
  padding: 14px 18px;
  background: #faf0dd;
  border: 2px solid #d98245;
  border-radius: 18px;
  color: #3a231c;
}
#anniversary-shop-dialog header {
  display: flex;
  align-items: center;
  gap: 10px;
}
#anniversary-shop-dialog header > div {
  margin-right: auto;
}
#anniversary-shop-dialog h2 {
  margin: 0;
  font-size: 21px;
  color: #9e242c;
}
#anniversary-shop-balance {
  margin: 3px 0 0;
  font-size: 12px;
  color: #7c422c;
}
#anniversary-shop-tabs {
  display: flex;
  gap: 8px;
  margin: 10px 0;
}
#anniversary-shop-tabs button[aria-pressed="true"] {
  background: #b52b36;
  color: #fff2c4;
  border-color: #8f1d26;
}
#anniversary-shop-items {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.anniv-good {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 4px 10px;
  align-items: center;
  border-color: #e4ba82;
  background: #fffaf0;
}
.anniv-item-symbol {
  grid-row: 1 / 5;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #d93b44, #f5b951);
  color: #fff8db;
  font-size: 26px;
}
#anniversary-shop-notice {
  margin: 10px 0 0;
  font-size: 12px;
  color: #7c422c;
}

/* Anniversary Blessing Wall Dialog */
#anniversary-wish-dialog {
  box-sizing: border-box;
  width: min(680px, 95vw);
  max-height: 92dvh;
  padding: 14px 18px;
  border: 2px solid #de8c49;
  border-radius: 18px;
  background: #fbf1df;
  color: #3a231c;
}
#anniversary-wish-dialog header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
#anniversary-wish-dialog h2 {
  margin: 0;
  font-size: 21px;
  color: #9e242c;
}
#anniversary-wish-form {
  display: flex;
  gap: 8px;
  margin: 10px 0 8px;
}
#anniversary-wish-input {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  border: 1.5px solid #d4a674;
  border-radius: 10px;
  background: #fffdf7;
  color: #332018;
  font-size: 14px;
}
#anniversary-wish-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}
.wish-chip {
  min-height: 28px;
  padding: 3px 10px;
  font-size: 11px;
}
#anniversary-wish-status {
  margin: 0 0 8px;
  font-size: 12px;
  color: #7d4530;
}
#anniversary-wish-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 36dvh;
  overflow-y: auto;
  padding-right: 2px;
}
.wish-card {
  padding: 10px;
  border-radius: 12px;
  border: 1px solid #e5c694;
  background: #fff9ec;
}
.wish-card.mine {
  border-color: #d95b43;
  background: linear-gradient(145deg, #fff6df, #ffe9cf);
}
.wish-card strong {
  display: block;
  font-size: 12px;
  color: #a82c34;
  margin-bottom: 4px;
}
.wish-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: #3d281f;
  word-break: break-word;
}

/* Founder Title highlight in Profile */
.profile-title.founder {
  border-color: #d98c36;
  background: linear-gradient(145deg, #fff7df, #ffe7c4);
}
.profile-title.founder strong {
  color: #a82934;
}

/* Responsive & Android Landscape adjustments */
@media (max-width: 720px) {
  #save-slots-grid,
  #anniversary-shop-items,
  #anniversary-wish-list {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (orientation: landscape) and (max-height: 420px) {
  #save-slots-dialog,
  #anniversary-shop-dialog,
  #anniversary-wish-dialog,
  #anniversary-intro-dialog {
    padding: 9px 12px;
  }
  #save-slots-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
  }
  .save-slot-card {
    padding: 8px;
    gap: 5px;
  }
  .save-slot-meta b {
    font-size: 13px;
  }
  .save-slot-actions button {
    min-height: 26px;
    padding: 2px 7px;
    font-size: 11px;
  }
  #anniversary-intro-canvas {
    height: clamp(140px, 52dvh, 210px);
  }
  #anniversary-shop-items,
  #anniversary-wish-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }
  #anniversary-world-balance {
    top: 72px;
    font-size: 11px;
    padding: 5px 9px;
  }
}
