html {
  scroll-behavior: smooth;
}

body {
  color: #273b34;
  font-family: Arial, sans-serif;
}

.header {
  background: white;
  border-bottom: 1px solid #e2e9e2;
}

.navbar {
  min-height: 76px;
  gap: 18px;
}

.navbar-brand {
  color: #273b34;
  font-size: 1.35rem;
  font-weight: bold;
}

.nav-link {
  color: #273b34;
}

.sign-in {
  white-space: nowrap;
}

.hero {
  background: #f2f6f1;
}

.eyebrow {
  color: #537762;
  font-weight: bold;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
}

h1 {
  font-size: clamp(2.4rem, 5vw, 4.3rem);
  font-weight: bold;
  line-height: 1.1;
}

h2 {
  font-weight: bold;
}

.hero-photo {
  width: 100%;
  height: 350px;
  object-fit: cover;
  border-radius: 10px;
  animation: appear 0.8s ease both;
}

.section {
  padding-top: 80px;
  padding-bottom: 80px;
}

.book {
  height: 100%;
  transition: transform 0.2s ease;
}

.book:hover {
  transform: translateY(-6px);
}

.book h3 {
  font-size: 1.2rem;
  margin-top: 18px;
}

.book p {
  color: #617267;
}

.book img {
  width: 100%;
  height: 230px;
  object-fit: cover;
  border-radius: 8px;
}

.reviews {
  background: #f2f6f1;
}

.carousel {
  max-width: 700px;
}

.carousel-item {
  padding: 28px 12px 10px;
}

blockquote {
  font-size: 1.3rem;
  min-height: 80px;
}

.carousel-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.carousel-buttons button {
  font-size: 1.4rem;
  line-height: 1;
}

footer {
  background: #273b34;
  color: white;
  padding: 25px 0;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
  padding-right: 55px;
}

.footer-content span:last-child {
  margin-left: auto;
}

.up {
  position: fixed;
  right: 20px;
  bottom: 20px;
  background: #273b34;
  color: white;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  text-decoration: none;
  font-size: 1.5rem;
  transition: background 0.2s;
}

.up:hover {
  color: white;
  background: #537762;
}

.error {
  display: none;
  color: #aa3030;
  font-size: 0.9rem;
  margin-top: 5px;
}

input:not(:placeholder-shown):invalid {
  border-color: #aa3030;
}

input:not(:placeholder-shown):invalid + .error {
  display: block;
}

input:not(:placeholder-shown):valid {
  border-color: #39824c;
}

.invitation-page {
  background: #f2f6f1;
}

.invitation-wrap {
  max-width: 750px;
}

.invitation, .envelope {
  background: white;
  border: 1px solid #b8c9ba;
  padding: 55px;
  margin: 20px auto 40px;
}

.invitation {
  text-align: center;
  min-height: 540px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}

.invitation h1 {
  font-family: Georgia, serif;
  font-size: 3rem;
}

.envelope {
  min-height: 310px;
  position: relative;
}

.stamp {
  position: absolute;
  right: 40px;
  top: 35px;
  border: 2px dashed #537762;
  padding: 12px;
  text-align: center;
}

.recipient {
  margin-top: 85px;
  margin-left: 30%;
  line-height: 1.3;
}

@keyframes appear {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@media (max-width: 767px) {
  .navbar {
    padding-right: 90px;
  }
  .sign-in {
    position: fixed;
    right: 12px;
    top: 16px;
    z-index: 1020;
  }
  .navbar-toggler {
    margin-left: auto;
  }
  .navbar-collapse {
    order: 3;
    flex-basis: 100%;
  }
  .section {
    padding-top: 55px;
    padding-bottom: 55px;
  }
  .hero-photo {
    height: 250px;
  }
  .book img {
    height: 210px;
  }
  .invitation, .envelope {
    padding: 30px;
  }
  .recipient {
    margin-left: 0;
    font-size: 0.9rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .hero-photo {
    animation: none;
  }
}
@media print {
  .print-actions {
    display: none;
  }
  body {
    background: white !important;
  }
  .invitation-wrap {
    width: 100%;
    max-width: none;
  }
  .invitation, .envelope {
    margin: 0;
    border: 1px solid #555;
    box-shadow: none;
  }
  .invitation {
    min-height: 220mm;
    break-after: page;
  }
  .envelope {
    min-height: 120mm;
  }
}
