@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Roboto:wght@300;400;500;600;700&family=Playfair+Display:wght@400;600;700&display=swap');

/* === Cấu hình chung === */
body {
  margin: 0;
  font-family: 'Roboto', sans-serif;
  background-color: #fff;
  color: #333;
  overflow-x: hidden;
}

/* === Hero Section (ảnh chính) === */
/* --- HERO BANNER FIX --- */
.hero {
  position: relative;
  text-align: center;
  width: 100%;
  height: 100dvh; /* Chiều cao hiển thị động, an toàn trên mobile */
  min-height: 500px;
  max-height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #fff;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transition: all 0.5s ease;
  min-width: 100%;
  min-height: 100%;
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
}

/* Responsive cho màn hình lớn (desktop) */
@media (min-width: 1200px) {
  .hero {
    height: 100vh;
  }
  .hero-img {
    object-fit: cover;
    object-position: center center;
  }
}

/* Màn hình vừa (tablet) */
@media (min-width: 768px) and (max-width: 1199px) {
  .hero {
    height: 80vh;
    min-height: 500px;
  }
  .hero-img {
    object-fit: cover;
    object-position: center center;
  }
}

/* Màn hình nhỏ (mobile) */
@media (max-width: 767px) {
  .hero {
    height: 70vh;
    min-height: 400px;
    position: relative;
  }
  .hero-img {
    object-fit: cover;
    object-position: center center;
    width: 100%;
    height: 100%;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
  }
}

/* Màn hình rất nhỏ */
@media (max-width: 480px) {
  .hero {
    height: 60vh;
    min-height: 350px;
    position: relative;
  }
  .hero-img {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
  }
}

/* Màn hình ngang (landscape) */
@media (orientation: landscape) and (max-height: 600px) {
  .hero {
    height: 100vh;
  }
  .hero-img {
    object-fit: cover;
    object-position: center center;
  }
}

/* Overlay và chữ giữ nguyên */
.overlay {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 50%;
  background: linear-gradient(transparent, rgba(255,255,255,0.95));
  z-index: 2;
  pointer-events: none;
}

.hero-text {
  position: absolute;
  bottom: 10%;
  width: 100%;
  color: #a3142d;
  padding: 0 20px;
  z-index: 10;
  pointer-events: none;
}


.hero-text h1 {
  font-family: 'Playfair Display', serif;
  font-size: 64px;
  font-weight: 700;
  margin: 0;
  letter-spacing: 2px;
}

.hero-text p {
  margin: 8px 0;
  font-size: 20px;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(255,255,255,0.8);
}

/* Responsive text trong hero */
@media (max-width: 768px) {
  .hero-text {
    bottom: 8%;
    padding: 0 15px;
  }
  
  .hero-text h1 {
    font-size: 42px;
    letter-spacing: 1px;
    margin-bottom: 10px;
  }
  
  .hero-text p {
    font-size: 16px;
    margin: 6px 0;
    line-height: 1.5;
  }
  
  .overlay {
    height: 55%;
  }
}

@media (max-width: 480px) {
  .hero-text {
    bottom: 6%;
    padding: 0 10px;
  }
  
  .hero-text h1 {
    font-size: 32px;
    letter-spacing: 1px;
    margin-bottom: 8px;
  }
  
  .hero-text p {
    font-size: 14px;
    margin: 5px 0;
    line-height: 1.4;
  }
  
  .overlay {
    height: 60%;
  }
}

/* === Các phần nội dung === */
section {
  text-align: center;
  padding: 50px 20px;
}

h2 {
  font-family: 'Playfair Display', serif;
  color: #a3142d;
  font-size: 36px;
  font-weight: 700;
  letter-spacing: 1px;
  line-height: 1.3;
}

.invitation p, .details p {
  font-size: 18px;
  max-width: 600px;
  margin: 10px auto;
}

/* === Form lời chúc === */
form {
  display: flex;
  flex-direction: column;
  max-width: 400px;
  margin: 0 auto;
  gap: 10px;
}

input, textarea {
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
}

button {
  background-color: #a3142d;
  color: #fff;
  border: none;
  padding: 10px;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
}

button:hover {
  background-color: #800f21;
  transform: scale(1.05);
}

/* === Lời chúc hiển thị === */
#wishes {
  list-style: none;
  padding: 0;
  max-width: 400px;
  margin: 20px auto;
  text-align: left;
}

#wishes li {
  background: #f8f8f8;
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 10px;
  border-left: 3px solid #a3142d;
}

/* === Footer === */
footer {
  background: #f7e7e9;
  padding: 20px 15px;
  color: #a3142d;
  text-align: center;
}

footer p {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
}

@media (max-width: 768px) {
  footer {
    padding: 15px 10px;
  }
  
  footer p {
    font-size: 14px;
  }
}

/* === Nút nhạc === */
#music-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #a3142d;
  color: #fff;
  border: none;
  padding: 12px 15px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  z-index: 1000;
  font-size: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#music-toggle:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

#music-toggle:active {
  transform: scale(0.95);
}

@media (max-width: 768px) {
  #music-toggle {
    bottom: 15px;
    right: 15px;
    padding: 10px 13px;
    font-size: 16px;
  }
}

/* === Hiệu ứng hoa bay === */
.flower-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* === STORY SECTION === */
.story {
  background: #fff7f8;
  color: #a3142d;
  padding: 60px 20px;
}

.story-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
}

.story-content p {
  margin: 20px 0;
  line-height: 1.8;
  font-size: 18px;
  color: #333;
}

.story-content .quote {
  font-style: italic;
  color: #a3142d;
  font-size: 20px;
  text-align: center;
  margin: 25px auto;
  padding: 15px 20px;
  background: rgba(163, 20, 45, 0.05);
  border-left: 4px solid #a3142d;
  border-radius: 5px;
  max-width: 600px;
}

.story-content .story-ending {
  text-align: center;
  font-size: 20px;
  color: #a3142d;
  font-weight: 500;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 2px solid rgba(163, 20, 45, 0.2);
  line-height: 1.8;
}

@media (max-width: 768px) {
  .story {
    padding: 40px 15px;
  }
  
  .story-content {
    text-align: left;
  }
  
  .story-content p {
    font-size: 16px;
    margin: 15px 0;
    line-height: 1.7;
  }
  
  .story-content .quote {
    font-size: 18px;
    margin: 20px auto;
    padding: 12px 15px;
  }
  
  .story-content .story-ending {
    font-size: 18px;
    margin-top: 25px;
    padding-top: 15px;
  }
}

/* === WEDDING DATE SECTION === */
.wedding-date-section {
  background: #ffffff;
  padding: 60px 20px;
  text-align: center;
}

.wedding-date-container {
  max-width: 800px;
  margin: 0 auto;
}

.wedding-date-title {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  color: #a3142d;
  margin-bottom: 40px;
  font-weight: 700;
  letter-spacing: 2px;
  line-height: 1.4;
  text-transform: uppercase;
}

.wedding-time-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}

.time-label {
  font-size: 18px;
  color: #a3142d;
  font-weight: 500;
}

.time-value {
  font-size: 32px;
  font-weight: bold;
  color: #a3142d;
}

.date-separator {
  font-size: 24px;
  color: #a3142d;
  opacity: 0.5;
}

.date-info {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  color: #a3142d;
}

.day-name {
  font-weight: 500;
}

.date-separator-vertical {
  font-size: 20px;
  color: #a3142d;
  opacity: 0.5;
}

.date-number {
  font-size: 36px;
  font-weight: bold;
  color: #a3142d;
}

.month-name {
  font-weight: 500;
}

.year-value {
  font-size: 32px;
  font-weight: bold;
  color: #a3142d;
}

.calendar-widget {
  max-width: 400px;
  margin: 0 auto;
  background: #fff;
  border: 2px solid #f0f0f0;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(163, 20, 45, 0.1);
}

.calendar-header {
  background: #a3142d;
  color: #fff;
  padding: 15px;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
}

.calendar-grid {
  padding: 20px;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.calendar-day-header {
  text-align: center;
  font-weight: 600;
  font-size: 12px;
  color: #666;
  padding: 8px 0;
  text-transform: uppercase;
}

.calendar-day {
  text-align: center;
  padding: 10px 5px;
  font-size: 14px;
  color: #333;
  border-radius: 5px;
  position: relative;
  cursor: default;
}

.calendar-day.other-month {
  color: #ccc;
}

.calendar-day.wedding-day {
  background: #fff7f8;
  color: #a3142d;
  font-weight: bold;
  position: relative;
}

.calendar-day.wedding-day::after {
  content: "❤️";
  position: absolute;
  top: -5px;
  right: -5px;
  font-size: 16px;
}

.calendar-grid {
  position: relative;
}

.calendar-year-watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 120px;
  font-weight: bold;
  color: rgba(163, 20, 45, 0.05);
  pointer-events: none;
  z-index: 0;
  white-space: nowrap;
}

.calendar-day {
  position: relative;
  z-index: 1;
}

.calendar-day-header {
  position: relative;
  z-index: 1;
}

/* Responsive */
@media (max-width: 768px) {
  .wedding-date-section {
    padding: 40px 15px;
  }
  
  .wedding-date-title {
    font-size: 22px;
    letter-spacing: 1px;
    margin-bottom: 30px;
  }
  
  .wedding-time-info {
    flex-direction: column;
    gap: 15px;
    margin-bottom: 35px;
  }
  
  .date-separator {
    display: none;
  }
  
  .date-info {
    flex-direction: column;
    gap: 8px;
  }
  
  .date-separator-vertical {
    display: none;
  }
  
  .time-value,
  .date-number,
  .year-value {
    font-size: 28px;
  }
  
  .time-label {
    font-size: 16px;
  }
  
  .day-name,
  .month-name {
    font-size: 18px;
  }
  
  .calendar-widget {
    max-width: 100%;
  }
  
  .calendar-header {
    padding: 12px;
    font-size: 16px;
  }
  
  .calendar-grid {
    gap: 5px;
    padding: 15px;
  }
  
  .calendar-day-header {
    font-size: 11px;
    padding: 6px 0;
  }
  
  .calendar-day {
    padding: 8px 3px;
    font-size: 12px;
  }
  
  .calendar-year-watermark {
    font-size: 80px;
  }
}




/* === EMAIL SETUP SECTION === */
.email-setup-section {
  background: #fff;
  padding: 60px 20px;
  border-bottom: 2px solid #fff7f8;
}

.email-setup-section h2 {
  margin-bottom: 20px;
}

.email-setup-section p {
  max-width: 600px;
  margin: 10px auto 30px;
  color: #666;
  font-size: 16px;
}

.setup-note {
  margin-top: 20px;
  color: #28a745;
  font-weight: 500;
  display: none;
}

.change-email-btn {
  margin-top: 15px;
  background-color: #6c757d;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.change-email-btn:hover {
  background-color: #5a6268;
  transform: scale(1.05);
}

@media (max-width: 768px) {
  .email-setup-section {
    padding: 40px 15px;
  }
}

/* === CHECK-IN SECTION === */
.checkin {
  background: #fff7f8;
  padding: 60px 20px;
}

@media (max-width: 768px) {
  .checkin {
    padding: 40px 15px;
  }
}

.checkin p {
  max-width: 600px;
  margin: 10px auto 30px;
  font-size: 18px;
  color: #a3142d;
}

.success-message {
  max-width: 400px;
  margin: 20px auto;
  padding: 15px;
  background: #d4edda;
  border: 1px solid #c3e6cb;
  border-radius: 5px;
  color: #155724;
  text-align: center;
}

.checkin-list {
  max-width: 600px;
  margin: 30px auto 0;
  padding: 20px;
  background: #f8f8f8;
  border-radius: 10px;
}

.checkin-item {
  background: #fff;
  padding: 15px;
  margin-bottom: 10px;
  border-radius: 5px;
  border-left: 3px solid #a3142d;
  text-align: left;
}

.checkin-item strong {
  color: #a3142d;
  display: block;
  margin-bottom: 5px;
}

/* === QR CODE SECTION (SIMPLE) === */
.qr-section {
  background: #fff7f8;
  padding: 60px 20px;
}

.qr-description {
  font-size: 18px;
  color: #666;
  margin-bottom: 30px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.qr-simple-container {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
}

.qr-image-container {
  background: #fff;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(163, 20, 45, 0.15);
  margin-bottom: 25px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.qr-image-container:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 25px rgba(163, 20, 45, 0.2);
}

.qr-image {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
  width: 100%;
  max-width: 400px;
}

.qr-note {
  margin-top: 20px;
  color: #666;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.6;
}

/* === WISHES SECTION === */
.wish-subtitle {
  max-width: 600px;
  margin: 10px auto 30px;
  font-size: 16px;
  color: #666;
  font-style: italic;
}

#wishList {
  list-style: none;
  padding: 0;
  max-width: 600px;
  margin: 30px auto 0;
  text-align: left;
}

#wishList li {
  background: #f8f8f8;
  padding: 15px;
  border-radius: 6px;
  margin-bottom: 15px;
  border-left: 3px solid #a3142d;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

#wishList li strong {
  color: #a3142d;
  display: block;
  margin-bottom: 8px;
}

/* Responsive forms */
@media (max-width: 768px) {
  form {
    max-width: 100%;
    padding: 0 10px;
  }
  
  .qr-section {
    padding: 40px 15px;
  }
  
  .qr-description {
    font-size: 16px;
    margin-bottom: 25px;
  }
  
  .qr-simple-container {
    max-width: 100%;
    padding: 0;
  }
  
  .qr-image-container {
    padding: 20px;
    margin-bottom: 20px;
  }
  
  .qr-image {
    max-width: 100%;
  }
  
  .qr-note {
    font-size: 14px;
    padding: 0 10px;
  }
  
  h2 {
    font-size: 28px;
  }
  
  section {
    padding: 40px 15px;
  }
}
