/* ==========================================================================
   ULTIMATE LUXURY PARCHMENT & WARM GOLDEN SUNBEAM DESIGN SYSTEM
   (WITH SLEEPING CAT RESTING ON LETTER TOPIC SELECT)
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Itim&family=Playfair+Display:ital,wght@0,600;0,700;1,400;1,600&family=Cormorant+Garamond:ital,wght@0,600;0,700;1,400;1,600&family=Sour+Gummy:ital,wght@0,100..900;1,100..900&family=Plus+Jakarta+Sans:wght@400;600;700;800&display=swap");

:root {
  --bg-parchment: #fbf7f0;
  --card-parchment: #fcf9f2;
  --burgundy-primary: #7d1c1c;
  --burgundy-hover: #962424;
  --accent-gold: #c49a6c;
  --accent-gold-light: rgba(196, 154, 108, 0.15);
  --text-dark: #2c221e;
  --text-muted: #6e5d4f;
  --font-serif: var(--font-body);
  --font-cursive: 'Dancing Script', cursive, serif;
  --font-sans: 'Plus Jakarta Sans', sans-serif;
  --envelope-x: 320px;
  --envelope-y: 210px;
  --envelope-bg: #f5e6d3;
  --envelope-shadow: #c49a6c;
  --letter-x: 270px;
  --letter-y: calc(270px - 1rem - 10px);
  --letter-bg: #fffbf5;
  --letter-shadow: #d4b58e;
  --letter-text: #2c1d11;
  --letter-font: 'Itim', 'Sour Gummy', cursive, sans-serif;
  --letter-button-text: #8c1d1d;
  --heart-bg: #7d1c1c;
  --heart-text: #ffffff;
  --warm-gold-glow: rgba(198, 156, 94, 0.35);
}

@media (min-width: 650px) {
  :root {
    --envelope-x: 540px;
    --envelope-y: 350px;
    --letter-x: 440px;
    --letter-y: calc(350px - 1rem - 10px);
  }
}

body {
  background-color: var(--bg-parchment);
  color: var(--text-dark);
  font-family: var(--font-sans);
}

/* Base Page Background with Sunbeam Glow & Soft Warmth */
.parchment-page-wrapper {
  background:
    radial-gradient(ellipse at 82% 18%, rgba(255, 235, 195, 0.75) 0%, rgba(245, 215, 165, 0.35) 30%, transparent 65%),
    radial-gradient(circle at 12% 15%, rgba(198, 156, 94, 0.1) 0%, transparent 40%),
    radial-gradient(circle at 85% 85%, rgba(125, 28, 28, 0.05) 0%, transparent 40%),
    #fbf7f0;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Atmospheric Sunbeam Flare behind Envelope */
.sunbeam-flare {
  position: absolute;
  top: -50px;
  right: 5%;
  width: 550px;
  height: 550px;
  background: radial-gradient(circle, rgba(255, 245, 215, 0.9) 0%, rgba(248, 218, 160, 0.4) 40%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 1;
}

/* Drifting Blossom Petals */
.drifting-petal {
  position: absolute;
  pointer-events: none;
  z-index: 3;
  opacity: 0.75;
  filter: drop-shadow(0 4px 8px rgba(180, 100, 80, 0.15));
  animation: floatPetal 8s ease-in-out infinite alternate;
}

.petal-1 {
  top: 120px;
  left: 3%;
  width: 28px;
  transform: rotate(-25deg);
}

.petal-2 {
  top: 80px;
  right: 18%;
  width: 22px;
  transform: rotate(35deg);
  animation-delay: 2s;
}

.petal-3 {
  top: 380px;
  right: 6%;
  width: 32px;
  transform: rotate(-15deg);
  animation-delay: 4s;
}

.petal-4 {
  top: 480px;
  left: 4%;
  width: 24px;
  transform: rotate(45deg);
  animation-delay: 1s;
}

@keyframes floatPetal {
  0% {
    transform: translateY(0px) rotate(0deg);
  }

  50% {
    transform: translateY(-12px) rotate(8deg);
  }

  100% {
    transform: translateY(6px) rotate(-6deg);
  }
}

/* Botanical Leaf Branch Accents */
.botanical-branch-top-right {
  position: absolute;
  top: 0;
  right: -15px;
  width: 320px;
  height: 320px;
  pointer-events: none;
  z-index: 2;
  opacity: 0.85;
}

.botanical-branch-bottom-left {
  position: absolute;
  top: 280px;
  left: -15px;
  width: 240px;
  height: 240px;
  pointer-events: none;
  z-index: 2;
  opacity: 0.75;
}

/* ==========================================================================
   HERO SECTION DESIGN (EXACT MATCH TO DESIGN IMAGE)
   ========================================================================== */

.thu-hero-section {
  padding: 70px 20px 80px 20px;
  position: relative;
  z-index: 3;
}

.thu-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
  max-width: 1160px;
  margin: 0 auto;
}

@media (min-width: 992px) {
  .thu-hero-grid {
    grid-template-columns: 1fr 1fr;
    gap: 60px;
  }
}

/* Hero Left Column */
.thu-hero-left {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.thu-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 18px;
  background: rgba(198, 156, 94, 0.14);
  border: 1.5px solid rgba(198, 156, 94, 0.4);
  border-radius: 30px;
  font-size: 11.5px;
  font-weight: 700;
  color: #8c6328;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  width: fit-content;
}

.thu-hero-title {
  font-family: var(--font-body);
  font-size: 48px;
  font-weight: 700;
  color: #2c221e;
  line-height: 1.15;
  margin: 0;
  letter-spacing: -0.5px;
}

@media (min-width: 768px) {
  .thu-hero-title {
    font-size: 60px;
  }
}

.thu-hero-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--accent-gold);
  width: 140px;
  margin: 2px 0;
}

.thu-hero-divider::before,
.thu-hero-divider::after {
  content: '';
  flex: 1;
  height: 1.5px;
  background: rgba(198, 156, 94, 0.4);
}

.thu-hero-quote {
  font-size: 16px;
  color: #5a4b3d;
  line-height: 1.75;
  font-style: italic;
  margin: 0;
  max-width: 480px;
}

.thu-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  border: 1.5px solid rgba(198, 156, 94, 0.45);
  border-radius: 30px;
  color: #4a3e35 !important;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none !important;
  cursor: pointer;
  width: fit-content;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
  transition: all 0.3s ease;
}

.thu-hero-btn:hover {
  background: #ffffff;
  border-color: var(--burgundy-primary);
  color: var(--burgundy-primary) !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(125, 28, 28, 0.15);
}

/* Hero Right Column: Interactive 3D Envelope Showcase (Tilted at -3.5deg Angle!) */
.thu-hero-right {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  transform: rotate(-3deg);
  transition: transform 0.4s ease;
}

.thu-hero-right:hover {
  transform: rotate(0deg) scale(1.02);
}

.love-letters-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px 0;
}

.cssletter {
  position: relative;
  width: 100%;
  max-width: 600px;
  min-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  -webkit-user-select: none;
}

/* Action Control Bar for Envelope Canvas */
.env-action-bar {
  position: absolute;
  top: -45px;
  right: 10px;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.envelope.active~.env-action-bar {
  opacity: 1;
  pointer-events: auto;
}

.env-btn-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  color: #581d24;
  border: 1.5px solid rgba(198, 156, 94, 0.4);
  border-radius: 25px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 15px var(--warm-gold-glow);
  transition: all 0.25s ease;
}

.env-btn-action:hover {
  transform: translateY(-2px);
  background: #ffffff;
  box-shadow: 0 6px 20px rgba(198, 156, 94, 0.45);
  color: #8c1d1d;
}

/* Auto-Restore Toast Floating Alert */
.auto-restore-alert {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 30;
  padding: 16px 24px;
  background: rgba(255, 251, 245, 0.96);
  backdrop-filter: blur(12px);
  border: 2px solid #c49a6c;
  border-radius: 20px;
  color: #581d24;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 12px 30px var(--warm-gold-glow);
  text-align: center;
  display: none;
}

/* Realistic Parchment 3D Envelope Structure */
.envelope {
  position: relative;
  width: var(--envelope-x);
  height: var(--envelope-y);
  background: #f5e6d3;
  border-radius: 8px;
  box-shadow: inset 0 0 35px -5px #d8be9f, 0 22px 50px -10px rgba(140, 95, 45, 0.28);
  transition: all 0.4s ease;
  z-index: 2;
  border: 1px solid rgba(212, 181, 142, 0.6);
}

.envelope::before {
  content: "˚ʚ❤︎ɞ˚";
  font-size: 4rem;
  color: #ffffff;
  position: absolute;
  left: 50%;
  top: 30%;
  transform: translate(-50%, -50%);
  mix-blend-mode: soft-light;
}

.envelope-flap {
  width: 100%;
  height: 71%;
  position: absolute;
  top: 0;
  z-index: 5;
  overflow: hidden;
  transition: 0.6s cubic-bezier(0.4, 0, 0.2, 1) all;
  transform-origin: top;
  pointer-events: all;
}

.envelope-folds {
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 4;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.envelope-flap::before,
.envelope-left::before,
.envelope-right::before,
.envelope-bottom::before {
  content: "";
  transform: rotate(45deg);
  background: #f5e6d3;
  box-shadow: 0 0 30px -5px #c49a6c;
  width: 100%;
  aspect-ratio: 1;
  display: block;
  position: absolute;
  top: 60%;
}

.envelope-flap::before {
  border-radius: 5rem;
  bottom: 30px;
  top: auto;
}

@media (min-width: 650px) {
  .envelope-flap::before {
    bottom: 90px;
  }
}

.envelope-left::before {
  top: 10%;
  left: -65%;
}

.envelope-right::before {
  top: 10%;
  right: -65%;
}

.envelope-bottom::before {
  top: 60%;
  border-radius: 5rem;
}

/* Embossed Burgundy Red Wax Seal Stamp with Leaf Emblem! */
.heart {
  z-index: 6;
  position: relative;
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.4), 0 8px 25px rgba(125, 28, 28, 0.45);
  border: 2px solid #581111;
  width: 78px;
  aspect-ratio: 1;
  background: radial-gradient(circle at 35% 35%, #9b2828 0%, #7d1c1c 60%, #581111 100%);
  border-radius: 50%;
  left: 50%;
  top: 70%;
  transform: translate(-50%, -50%);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (min-width: 650px) {
  .heart {
    width: 110px;
  }
}

.heart::before {
  content: "🌿";
  font-size: 1.8rem;
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
  color: #f7e8d0;
}

@media (min-width: 650px) {
  .heart::before {
    font-size: 2.5rem;
  }
}

.heart:hover,
.heart:active,
.heart:focus {
  transform: translate(-50%, -50%) scale(1.08);
  box-shadow: inset 0 2px 6px rgba(255, 255, 255, 0.5), 0 12px 30px rgba(125, 28, 28, 0.55);
}

.heart-text {
  display: none;
}

.envelope.active * {
  pointer-events: none;
}

.envelope.active .envelope-flap {
  transform: rotateX(-180deg) translateY(0);
  perspective: 10px;
}

.envelope.active .envelope-flap::before {
  box-shadow: inset 0 0 30px -5px var(--envelope-shadow);
}

.envelope.active .heart {
  display: none;
}

/* Letters Container & Cards */
.letters {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.5s ease 0.1s, visibility 0.5s ease 0.1s;
  z-index: 10;
}

.envelope.active~.letters,
.envelope.active+.letters {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.letter {
  box-sizing: border-box;
  font-family: var(--letter-font);
  font-size: 1.1rem;
  line-height: 1.38;
  background-color: var(--letter-bg);
  color: var(--letter-text);
  width: var(--letter-x);
  height: var(--letter-y);
  user-select: none;
  box-shadow: inset 0 0 20px -5px var(--letter-shadow), 0 12px 30px rgba(198, 156, 94, 0.35);
  padding: 3rem 1.5rem 1.5rem;
  margin: 0;
  cursor: grab;
  position: absolute;
  top: 2rem;
  overflow: auto;
  text-align: center;
  border-radius: 12px;
  border: 1.5px solid rgba(196, 154, 108, 0.45);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.letter:active {
  cursor: grabbing;
  box-shadow: inset 0 0 20px -5px var(--letter-shadow), 0 18px 40px rgba(198, 156, 94, 0.45);
}

.letter.center {
  display: flex;
  align-items: center;
  justify-content: safe center;
  flex-direction: column;
}

.letter cite {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--burgundy-primary);
  margin-top: 1.2rem;
  display: block;
}

.letter:nth-child(even) {
  transform: skew(-1.5deg) translateY(-4px);
}

.letter:nth-child(odd) {
  transform: skew(1.5deg) translateY(4px);
}

/* Special Salvation Letter (Lá Thư Cứu Rỗi Bí Mật) - Refined & Aesthetic */
.letter.special-salvation-letter {
  justify-content: flex-start !important;
  padding: 2.8rem 1.7rem 2rem !important;
  background: linear-gradient(165deg, #fffdf8 0%, #fff9f0 55%, #fdf3e3 100%) !important;
  border: 1.8px solid rgba(217, 119, 6, 0.75) !important;
  border-radius: 16px !important;
  box-shadow: 
    inset 0 0 25px rgba(217, 119, 6, 0.12),
    0 16px 36px rgba(180, 83, 9, 0.22),
    0 0 0 3px rgba(217, 119, 6, 0.08) !important;
  scrollbar-width: thin;
  scrollbar-color: rgba(196, 154, 108, 0.4) transparent;
}

.letter.special-salvation-letter::-webkit-scrollbar {
  width: 5px;
}
.letter.special-salvation-letter::-webkit-scrollbar-track {
  background: transparent;
}
.letter.special-salvation-letter::-webkit-scrollbar-thumb {
  background: rgba(196, 154, 108, 0.45);
  border-radius: 4px;
}

.letter.special-salvation-letter .salvation-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(217, 119, 6, 0.1));
  color: #92400e;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 5px 14px;
  border-radius: 999px;
  border: 1px solid rgba(217, 119, 6, 0.38);
  margin-bottom: 0.9rem;
  text-transform: uppercase;
  box-shadow: 0 2px 6px rgba(217, 119, 6, 0.1);
  flex-shrink: 0;
}

.letter.special-salvation-letter .salvation-content {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 0;
  padding: 0 2px;
}

.letter.special-salvation-letter p {
  font-family: 'Itim', 'Sour Gummy', cursive, sans-serif;
  font-size: 1.06rem;
  line-height: 1.52;
  color: #38271e;
  margin: 0;
  text-align: center;
}

.letter.special-salvation-letter p.highlight-quote {
  font-weight: 700;
  color: #7d1c1c;
  font-style: italic;
  font-size: 1.1rem;
  margin-top: 0.2rem;
}

.letter.special-salvation-letter .salvation-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 1.1rem auto 0 auto;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  color: #92400e;
  text-decoration: none;
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  padding: 6px 16px;
  border-radius: 20px;
  border: 1px solid rgba(217, 119, 6, 0.4);
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.15);
  transition: all 0.25s ease;
  flex-shrink: 0;
}

.letter.special-salvation-letter .salvation-link:hover {
  background: #d97706;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 5px 14px rgba(217, 119, 6, 0.32);
}

.letter.special-salvation-letter cite {
  font-family: 'Itim', cursive, sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #b45309;
  margin-top: 1.25rem;
  display: block;
  flex-shrink: 0;
}

@media (min-width: 650px) {
  .letter {
    font-size: 1.28rem;
  }
}

.closeLetter {
  font-size: 0 !important;
  position: absolute;
  top: 10px;
  right: 12px;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(4px);
  border-radius: 50%;
  border: 1px solid rgba(196, 154, 108, 0.35);
  cursor: pointer;
  z-index: 25;
  transition: all 0.2s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.closeLetter::before {
  content: "✕";
  font-size: 1.2rem !important;
  font-family: sans-serif;
  font-weight: bold;
  color: var(--burgundy-primary);
  text-align: center;
  transition: color 0.2s ease;
}

.closeLetter:hover::before {
  color: #e53e3e;
}

/* ==========================================================================
   SECTION 2: CENTERED QUOTE CARD DESIGN (MODERN & CATCHY DISPLAY)
   ========================================================================== */

.thu-middle-quote-sec {
  padding: 80px 20px 90px 20px;
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Ambient Radial Glow Backdrop */
.thu-middle-quote-backdrop {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 850px;
  height: 280px;
  background: radial-gradient(ellipse at center,
      rgba(200, 149, 71, 0.18) 0%,
      rgba(122, 140, 110, 0.12) 50%,
      transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 1;
  animation: quoteAuraPulse 8s ease-in-out infinite alternate;
}

@keyframes quoteAuraPulse {
  0% {
    transform: translate(-50%, -50%) scale(0.95);
    opacity: 0.7;
  }

  100% {
    transform: translate(-50%, -50%) scale(1.08);
    opacity: 1;
  }
}

.thu-middle-quote-card {
  max-width: 820px;
  width: 100%;
  margin: 0 auto;
  background: rgba(253, 251, 247, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(200, 149, 71, 0.35);
  border-radius: 32px;
  padding: 48px 42px 42px 42px;
  text-align: center;
  position: relative;
  z-index: 2;
  box-shadow:
    0 20px 50px rgba(47, 93, 67, 0.06),
    0 1px 3px rgba(200, 149, 71, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease, border-color 0.4s ease;
  overflow: hidden;
}

/* Corner Botanical Leaf Accents */
.thu-middle-quote-card::before {
  content: "🌿";
  position: absolute;
  top: 18px;
  left: 24px;
  font-size: 20px;
  opacity: 0.4;
  transform: rotate(-35deg);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.thu-middle-quote-card::after {
  content: "🌸";
  position: absolute;
  bottom: 18px;
  right: 24px;
  font-size: 20px;
  opacity: 0.4;
  transform: rotate(15deg);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.thu-middle-quote-card:hover {
  transform: translateY(-4px);
  box-shadow:
    0 28px 60px rgba(47, 93, 67, 0.1),
    0 4px 12px rgba(200, 149, 71, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 1);
  border-color: rgba(200, 149, 71, 0.6);
}

.thu-middle-quote-card:hover::before,
.thu-middle-quote-card:hover::after {
  opacity: 0.85;
  transform: scale(1.15) rotate(0deg);
}

/* Top Pill Badge */
.thu-quote-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Poppins', sans-serif;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-green, #2f5d43);
  background: rgba(47, 93, 67, 0.07);
  border: 1px solid rgba(47, 93, 67, 0.18);
  padding: 5px 16px;
  border-radius: 50px;
  margin-bottom: 24px;
  box-shadow: 0 2px 8px rgba(47, 93, 67, 0.04);
}

.badge-sparkle {
  color: #c89547;
  font-size: 10px;
}

/* Giant Floating Quote Icon & Wind SVG */
.thu-quote-icon-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 16px;
}

.thu-quote-giant-mark {
  font-family: var(--font-body);
  font-size: 64px;
  line-height: 0.8;
  color: #c89547;
  opacity: 0.85;
  display: block;
  text-shadow: 0 4px 15px rgba(200, 149, 71, 0.25);
}

.thu-quote-wind-svg {
  position: absolute;
  top: -10px;
  width: 90px;
  height: 36px;
  opacity: 0.7;
  pointer-events: none;
  animation: windDrift 4s ease-in-out infinite alternate;
}

@keyframes windDrift {
  0% {
    transform: translateX(-8px) translateY(0);
    opacity: 0.5;
  }

  100% {
    transform: translateX(12px) translateY(-3px);
    opacity: 0.85;
  }
}

/* Main Text & Highlight Phrase */
.thu-quote-main-text {
  font-family: var(--font-body);
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  color: #2c3531;
  font-weight: 600;
  line-height: 1.7;
  margin-bottom: 22px;
  letter-spacing: -0.2px;
}

.highlight-phrase {
  background: linear-gradient(135deg, #2f5d43 20%, #c89547 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
  position: relative;
  display: inline-block;
  padding: 0 4px;
}

.highlight-phrase::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, rgba(47, 93, 67, 0.3), rgba(200, 149, 71, 0.4));
  border-radius: 2px;
}

/* Divider with Flower Icon */
.thu-quote-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 20px auto 22px auto;
  max-width: 320px;
}

.thu-quote-divider .line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200, 149, 71, 0.4), transparent);
}

.thu-quote-divider .flower-icon {
  font-size: 16px;
  color: #c89547;
  opacity: 0.8;
  animation: spinFlower 12s linear infinite;
}

@keyframes spinFlower {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* Sub-text */
.thu-quote-sub-text {
  font-family: 'Charm', cursive, 'Poppins', sans-serif;
  font-size: clamp(1.05rem, 1.8vw, 1.25rem);
  color: #5c6b64;
  line-height: 1.75;
  margin-bottom: 28px;
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

/* Action Button at Bottom of Quote Card */
.thu-quote-footer-action {
  margin-top: 10px;
}

.thu-quote-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #2f5d43, #254a35);
  color: #ffffff !important;
  font-family: 'Poppins', sans-serif;
  font-size: 13.5px;
  font-weight: 600;
  padding: 11px 28px;
  border-radius: 50px;
  text-decoration: none !important;
  box-shadow: 0 6px 20px rgba(47, 93, 67, 0.25);
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.thu-quote-btn:hover {
  background: linear-gradient(135deg, #376d4f, #2b563e);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(47, 93, 67, 0.35);
  color: #ffffff !important;
}

@media (max-width: 768px) {
  .thu-middle-quote-sec {
    padding: 50px 16px 60px 16px;
  }

  .thu-middle-quote-card {
    padding: 34px 22px 30px 22px;
    border-radius: 24px;
  }

  .thu-quote-giant-mark {
    font-size: 50px;
  }

  .thu-quote-btn {
    width: 100%;
    max-width: 300px;
    padding: 11px 20px;
  }
}

/* ==========================================================================
   SECTION 3: FORM CARD DESIGN (WITH SLEEPING CAT ON LETTER TOPIC SELECT)
   ========================================================================== */

.send-letter-section {
  padding: 40px 20px 100px 20px;
  position: relative;
  z-index: 3;
}

.send-letter-container {
  max-width: 790px;
  margin: 0 auto;
  background: var(--card-parchment);
  border: 1.5px solid #e5dacb;
  border-radius: 30px;
  padding: 48px 38px;
  box-shadow: 0 20px 50px rgba(140, 100, 50, 0.06);
  position: relative;
}

@media (max-width: 640px) {
  .send-letter-container {
    padding: 32px 22px;
  }
}

.send-letter-header {
  text-align: center;
  margin-bottom: 35px;
}

.send-letter-badge {
  display: inline-block;
  padding: 5px 18px;
  background: rgba(125, 28, 28, 0.08);
  border: 1px solid rgba(125, 28, 28, 0.2);
  border-radius: 30px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--burgundy-primary);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.send-letter-title {
  font-family: var(--font-body);
  font-size: 38px;
  font-weight: 700;
  color: #2c221e;
  line-height: 1.25;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.send-letter-subtitle {
  font-size: 14.5px;
  color: #6e5d4f;
  line-height: 1.6;
}

/* Form Controls */
.send-letter-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.form-row-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

@media (min-width: 640px) {
  .form-row-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 13.5px;
  font-weight: 700;
  color: #3b2e24;
}

/* SLEEPING CAT ON SELECT CONTAINER STYLES */
.relative-select-container {
  position: relative;
  width: 100%;
  margin-top: 6px;
}

.sleeping-cat-on-select {
  position: absolute;
  top: -36px;
  right: 22px;
  width: 62px;
  height: auto;
  z-index: 10;
  pointer-events: none;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.12));
  transition: transform 0.3s ease;
}

.relative-select-container:hover .sleeping-cat-on-select {
  transform: translateY(-3px) scale(1.06);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 13.5px 18px;
  background: #fdfbf7;
  border: 1.5px solid rgba(198, 156, 94, 0.35);
  border-radius: 16px;
  font-family: inherit;
  font-size: 14.5px;
  color: #2c221e;
  outline: none;
  transition: all 0.3s ease;
}

.form-group textarea {
  font-family: var(--font-cursive);
  font-size: 1.3rem;
  line-height: 1.5;
  background: #fdfbf7 url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%23c49a6c" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"><path d="M12 19l7-7 3 3-7 7-3-3z"/><path d="M18 13l-1.5-7.5L2 2l3.5 14.5L13 18l5-5z"/><path d="M2 2l7.5 7.5"/></svg>') no-repeat right 16px bottom 16px;
  background-size: 28px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--burgundy-primary);
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(125, 28, 28, 0.08);
}

/* Stamp / Wax Seal Selector */
.seal-selector-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #3b2e24;
  margin-bottom: 10px;
}

.seal-options-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.seal-pill-opt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  background: #fdfbf7;
  border: 1.5px solid rgba(198, 156, 94, 0.35);
  border-radius: 25px;
  font-size: 13px;
  font-weight: 600;
  color: #5a4b3d;
  cursor: pointer;
  transition: all 0.25s ease;
}

.seal-pill-opt:hover {
  background: #ffffff;
  border-color: var(--burgundy-primary);
  color: var(--burgundy-primary);
}

.seal-pill-opt.active {
  background: var(--burgundy-primary);
  border-color: var(--burgundy-primary);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(125, 28, 28, 0.3);
}

/* Form Action Buttons */
.send-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 10px;
  justify-content: center;
}

.btn-send-letter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 34px;
  background: linear-gradient(135deg, var(--burgundy-primary) 0%, #5e1111 100%);
  color: #ffffff !important;
  font-family: var(--font-sans);
  font-size: 14.5px;
  font-weight: 700;
  border: none;
  border-radius: 30px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(125, 28, 28, 0.35);
  transition: all 0.3s ease;
}

.btn-send-letter:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(125, 28, 28, 0.45);
  background: linear-gradient(135deg, #962424 0%, #751616 100%);
}

.btn-preview-letter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  background: #ffffff;
  color: #5a4b3d !important;
  font-family: var(--font-sans);
  font-size: 14.5px;
  font-weight: 700;
  border: 1.5px solid rgba(198, 156, 94, 0.4);
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-preview-letter:hover {
  transform: translateY(-2px);
  border-color: var(--burgundy-primary);
  color: var(--burgundy-primary) !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

.send-form-footer-note {
  text-align: center;
  font-size: 12.5px;
  color: #8c7868;
  margin-top: 15px;
}

/* Toast / Confirmation Alert */
.send-toast-msg {
  display: none;
  padding: 16px 24px;
  background: #f0fdf4;
  border: 1.5px solid #86efac;
  border-radius: 16px;
  color: #166534;
  font-weight: 600;
  font-size: 14.5px;
  text-align: center;
  margin-top: 15px;
  animation: fadeIn 0.4s ease;
}

/* Letter Preview Modal */
.letter-preview-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.letter-preview-modal.active {
  display: flex;
}

.preview-card-wrap {
  width: 100%;
  max-width: 480px;
  background: #fffbf5;
  border: 2px solid #d4b58e;
  border-radius: 24px;
  padding: 35px 28px;
  box-shadow: inset 0 0 25px -5px #d4b58e, 0 16px 40px var(--warm-gold-glow);
  position: relative;
  font-family: var(--font-cursive);
  text-align: center;
  color: #2c1d11;
}

.preview-card-close {
  position: absolute;
  top: 15px;
  right: 18px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--burgundy-primary);
  cursor: pointer;
}

.preview-card-content {
  font-size: 1.35rem;
  line-height: 1.5;
  margin-bottom: 20px;
}

.preview-card-author {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--burgundy-primary);
}

/* ==========================================================================
   MOUSE DETECTOR CAT SELECT (FROM CAT-FILTER)
   ========================================================================== */

.mouse-detector {
  position: relative;
  width: 100%;
  box-sizing: border-box;
  padding-top: 0;
  margin-top: 6px;
  z-index: 10;
}

.mouse-detector:hover #lefteyelid {
  visibility: hidden;
}

.mouse-detector:hover .sleep-symbol {
  visibility: hidden;
}

.cat {
  position: relative;
  width: 100%;
  box-sizing: border-box;
  z-index: 10;
}

.cat:hover #righteyelid {
  visibility: hidden;
}

.cat select,
.cat ::picker(select) {
  appearance: base-select;
  font-size: 15px;
  font-family: inherit;
}

.cat select.side-select {
  position: relative;
  z-index: 1;
  width: 100%;
  box-sizing: border-box;
  min-height: 54px;
  padding: 13.5px 18px;
  border-radius: 16px;
  background-color: #fdfbf7;
  border: 1.5px solid rgba(198, 156, 94, 0.35);
  color: #2c221e;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: inherit;
}

.cat select.side-select:hover {
  background-color: #fff9ed;
  border-color: var(--burgundy-primary);
}

.cat ::picker(select) {
  border-radius: 0px 0px 16px 16px;
  border: 1.5px solid rgba(198, 156, 94, 0.35);
  border-top: none;
  background-color: #fffbf5;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.cat ::picker-icon,
.cat ::checkmark {
  display: none;
}

.cat [hidden] {
  display: none;
}

.cat option {
  padding: 8px 18px;
  min-height: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #3b2e24;
  cursor: pointer;
  font-family: inherit;
}

.cat option:hover {
  background: #fdf3e3;
  color: var(--burgundy-primary);
}

.cat .sleep-symbol {
  position: absolute;
  right: 160px;
  top: -100%;
  font-weight: 600;
  width: max-content;
  pointer-events: none;
  color: #3b2e24;
  z-index: 0;
}

.cat .sleep-symbol span {
  position: relative;
  display: inline-block;
  opacity: 1;
  transform: scale(1);
  animation: sleep 4s ease-in-out infinite;
}

.cat .sleep-symbol span:nth-child(1) {
  animation-delay: 0s;
}

.cat .sleep-symbol span:nth-child(2) {
  animation-delay: 1s;
  margin-left: -8px;
}

.cat .sleep-symbol span:nth-child(3) {
  animation-delay: 2s;
  margin-left: -8px;
}

.cat .thecat {
  position: absolute;
  z-index: 50;
  right: 55px;
  top: -75px;
  width: max-content;
  pointer-events: none;
  transform: scale(0.7);
  -webkit-transform: scale(0.7);
}

#tail {
  visibility: visible;
}

#longtail {
  visibility: hidden;
}

.thecat #eyesdown {
  visibility: hidden;
}

.cat:has(.side-select:hover) #eyesdown {
  visibility: visible;
}

.cat select:open {
  border-radius: 16px 16px 0px 0px;
}

.cat:has(option:hover) #righteyelid,
.cat:has(option:hover) #lefteyelid,
.cat:has(option:hover) .sleep-symbol {
  visibility: hidden;
}

.cat:has(option:hover) #eyesdown {
  visibility: visible;
}

@keyframes sleep {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  50% {
    opacity: 0.5;
    transform: translate(-5px, -25px) scale(1.2);
  }

  100% {
    opacity: 0;
    transform: translateY(-45px) scale(1.5);
  }
}

/* ==========================================================================
   REPLAY ALL LETTERS CARD & FULLSCREEN DRAGGING STYLES
   ========================================================================== */
.empty-letters-replay-card {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 440px;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.98) 0%, rgba(254, 249, 240, 0.96) 100%);
  backdrop-filter: blur(12px);
  border: 1.8px solid rgba(198, 156, 94, 0.55);
  border-radius: 24px;
  padding: 2.4rem 2rem;
  text-align: center;
  box-shadow: 
    0 20px 45px rgba(125, 28, 28, 0.15),
    0 4px 18px rgba(198, 156, 94, 0.25),
    0 0 0 3px rgba(217, 119, 6, 0.08);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: replayCardPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes replayCardPop {
  0% {
    opacity: 0;
    transform: translate(-50%, -46%) scale(0.9);
  }
  100% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.replay-card-sparkle {
  font-size: 1.8rem;
  margin-bottom: 0.6rem;
  filter: drop-shadow(0 2px 6px rgba(196, 154, 108, 0.3));
}

.replay-card-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: #581d24;
  margin: 0 0 0.65rem 0;
  line-height: 1.3;
}

.replay-card-desc {
  font-family: 'Itim', sans-serif;
  font-size: 1.02rem;
  color: #6e5d4f;
  line-height: 1.5;
  margin: 0 0 1.5rem 0;
}

.btn-replay-all-letters {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #7d1c1c 0%, #a82828 100%);
  color: #ffffff !important;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  padding: 12px 28px;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 6px 20px rgba(125, 28, 28, 0.35);
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-replay-all-letters:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #962424 0%, #bd3131 100%);
  box-shadow: 0 10px 25px rgba(125, 28, 28, 0.45);
}

.btn-replay-all-letters:active {
  transform: translateY(0);
}

/* Free Dragging across entire viewport */
body > .letter {
  box-shadow: inset 0 0 20px -5px var(--letter-shadow), 0 20px 45px rgba(125, 28, 28, 0.25) !important;
  cursor: grabbing !important;
}

body > .letter.dragging {
  cursor: grabbing !important;
  opacity: 0.96;
}


/* Popup Guide for Envelope (Template Trang Chủ) */
.thu-envelope-guide {
  position: absolute;
  top: -20px;
  left: 10px;
  transform: none;
  z-index: 50;
  max-width: 290px;
  background: rgba(253, 248, 242, 0.96) !important;
  border: 1.5px dashed rgba(198, 156, 94, 0.6) !important;
  border-radius: 18px !important;
  box-shadow: 0 12px 30px rgba(125, 28, 28, 0.12), 0 2px 10px rgba(198, 156, 94, 0.2) !important;
  animation: guideFloat 3s ease-in-out infinite alternate;
  cursor: default;
}

@keyframes guideFloat {
  0% { transform: translateY(0); }
  100% { transform: translateY(-5px); }
}

.thu-envelope-guide.hide {
  opacity: 0 !important;
  transform: translateY(-10px) !important;
  pointer-events: none !important;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.envelope.active ~ .thu-envelope-guide {
  opacity: 0 !important;
  pointer-events: none !important;
}

@media (max-width: 650px) {
  .thu-envelope-guide {
    top: -45px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 320px;
  }
}
