/* =========================================
   FUENTE LOCAL
========================================= */

@font-face {
  font-family: "Abhaya Libre";
  src: url("./assets/fonts/AbhayaLibre-Regular.ttf")
    format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}


/* =========================================
   VARIABLES
========================================= */

:root {
  --page-width: 490px;

  --font-display:
    "Cormorant Garamond",
    serif;

  --font-body:
    "Abhaya Libre",
    "Cormorant Garamond",
    serif;

  --font-counter:
    "Ovo",
    serif;

  --ink: #2f2727;
  --red: #a61920;
  --disabled: #c8c8c8;

  --outer-background: #f1eee9;
  --hotel-background: #f6f6f6;

  --gallery-gap: 14px;
  --gallery-height: min(224px, 57.44vw);
}


/* =========================================
   RESET
========================================= */

html {
  width: 100%;
  min-height: 100%;

  margin: 0;
  padding: 0;

  overflow-x: hidden;

  background: var(--outer-background);

  font-family: var(--font-display);
  font-size: 16px;

  scroll-behavior: smooth;

  -webkit-text-size-adjust: 100%;
}

body {
  display: flex;
  align-items: center;
  flex-direction: column;

  width: 100%;
  max-width: var(--page-width);
  min-height: 100vh;

  margin: 0 auto;
  padding: 0;

  overflow-x: hidden;

  background: #ffffff;
  color: var(--ink);

  font-family: var(--font-display);
  font-size: 16px;

  -webkit-text-size-adjust: 100%;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
select {
  -webkit-tap-highlight-color: transparent;
}


/* =========================================
   PORTADA
========================================= */

.portada {
  width: 100%;
}

.portada img {
  width: 100%;
  height: auto;
}


/* =========================================
   REPRODUCTOR
========================================= */

/*
  El elemento de audio conserva el estilo
  predeterminado del navegador.
*/

.player {
  width: 100%;
  margin-top: 24px;
  text-align: center;
}


/* =========================================
   INTRODUCCIÓN
========================================= */

.intro-boda {
  width: 100%;

  margin: 0;
  padding: 35px 0 0;

  text-align: center;
}

.intro-boda__title {
  width: 78%;
  height: auto;

  margin: 0 auto;
}

.intro-boda__text {
  width: 78%;

  margin: 20px auto 0;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  text-align: center;
}

.intro-boda__text strong {
  font-weight: 700;
}

.intro-boda > p:not(.intro-boda__text) {
  margin: 0;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  text-align: center;
}


/* =========================================
   CONTADOR
========================================= */

#countdown {
  width: 100%;
  margin-top: 25px;
}

#countdown table {
  width: 90%;

  margin: 0 auto;

  table-layout: fixed;
  border-collapse: collapse;
}

#countdown td,
#countdown th {
  width: 25%;
  padding: 0;

  color: var(--ink);
}

#countdown td {
  font-family: var(--font-counter);
  font-size: 30px;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  text-align: center;
}

#countdown td span {
  display: inline-block;

  width: 3ch;

  text-align: center;
}

#countdown th {
  font-family: var(--font-counter);
  font-size: 16px;
  font-weight: 400;
  text-align: center;
}


/* =========================================
   GUARDAR FECHA
========================================= */

.save-date {
  width: 90%;
  margin: 28px auto 0;
}

.save-date__button {
  display: block;

  width: 100%;
  height: 36px;

  margin: 0;
  padding: 6px 12px;

  border: 0;
  border-radius: 0;

  background: var(--ink);
  color: #ffffff;

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  text-align: center;
  text-decoration: none;

  cursor: pointer;

  appearance: none;
  -webkit-appearance: none;
}

.save-date__button:hover,
.save-date__button:focus,
.save-date__button:active,
.save-date__button:visited {
  background: var(--ink);
  color: #ffffff;
  text-decoration: none;
}

.save-date__button:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}


/* =========================================
   GALERÍAS
========================================= */

.intro-boda__gallery,
.place-gallery,
.restaurant-gallery {
  display: grid;
  grid-template-columns: 0.8fr 1.38fr 0.8fr;
  align-items: stretch;
  gap: var(--gallery-gap);

  width: 100%;

  margin-right: auto;
  margin-left: auto;

  overflow: hidden;
}

.date_section {
  display: flex;

  max-width: 70%;

  margin: 55px auto 0;
}

.place-gallery,
.restaurant-gallery {
  margin-top: 0;
}

.intro-boda__gallery img,
.place-gallery img,
.restaurant-gallery img {
  width: 100%;
  height: var(--gallery-height);

  max-width: none;

  object-fit: cover;
  object-position: center;
}


/* =========================================
   DETALLES DEL DÍA
========================================= */

.details-section {
  width: 100%;

  margin: 0;
  padding: 55px 0 20px;

  overflow: hidden;
  text-align: center;
}

.details-section__title {
  display: block;

  width: 76%;
  max-width: 296px;
  height: auto;

  margin: 0 auto 42px;
}

.details-section__flowers {
  display: block;

  width: 68%;
  max-width: 265px;
  height: auto;

  margin: 55px auto;
}

.details-section__ceremony {
  display: block;

  width: 90%;
  height: auto;

  margin: 0 auto 42px;
}

.details-section__table {
  display: block;

  width: 80%;
  max-width: 312px;
  height: auto;

  margin: 55px auto 35px;
}


/* =========================================
   HORARIOS DEL DÍA
========================================= */

.wedding-schedule {
  width: calc(100% - 48px);

  margin: 0 auto;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  text-align: left;
}

.wedding-schedule__link {
  display: block;

  width: 100%;

  color: inherit;
  text-decoration: none;

  cursor: pointer;
}

.wedding-schedule__link:visited,
.wedding-schedule__link:hover,
.wedding-schedule__link:focus,
.wedding-schedule__link:active {
  color: inherit;
  text-decoration: none;
}

.wedding-schedule__link:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 4px;
}

.wedding-schedule__link:active {
  opacity: 0.72;
}


/* Fila completa */

.wedding-schedule__item {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  align-items: start;
  column-gap: 14px;

  width: 100%;
  padding: 24px 0;

  border-bottom: 1px solid #e4dfdf;
}

.wedding-schedule__link:first-child .wedding-schedule__item {
  padding-top: 0;
}

.wedding-schedule__item--last {
  border-bottom: 0;
}


/* Columna de la hora */

.wedding-schedule__time-box {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;

  width: 70px;
  min-width: 70px;
  min-height: 0;

  margin: 0;
  padding: 0;
}

.wedding-schedule__time-image {
  display: block;

  width: 70px;
  max-width: 70px;
  height: auto;
  max-height: none;

  margin: 0;
  padding: 0;

  object-fit: contain;
  object-position: left top;
}


/* Columna de contenido */

.wedding-schedule__content {
  min-width: 0;

  margin: 0;
  padding: 0;
}


/* Fila de icono y título */

.wedding-schedule__heading {
  display: flex;
  align-items: flex-start;
  gap: 10px;

  min-height: 0;

  margin: 0;
  padding: 0;
}

.wedding-schedule__heading h3,
.wedding-schedule__content h3 {
  margin: 0;
  padding: 0;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.1;
}


/* Iconos */

.wedding-schedule__icon {
  display: block;
  flex: 0 0 auto;

  width: 29px;
  height: 29px;

  margin: 0;
  padding: 0;

  object-fit: contain;
  object-position: center top;

  transform: translateY(-2px);
}

.wedding-schedule__icon--music {
  width: 29px;
  height: 29px;
}

.wedding-schedule__icon--hearts {
  width: 36px;
  height: 36px;

  transform: translateY(-3px);
}

.wedding-schedule__heading--last {
  align-items: flex-start;
  margin-bottom: 9px;
}


/* Descripción */

.wedding-schedule__content p {
  margin: 0;
  padding: 0;

  color: #514949;

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.45;
}

.wedding-schedule__content strong {
  font-weight: 700;
}


/* Puntos de la última fila */

.wedding-schedule__time-box--dots {
  display: flex;
  align-items: flex-start;
  justify-content: center;

  width: 70px;
  min-width: 70px;

  margin: 0;
  padding: 0;
}

.wedding-schedule__time-image--dots {
  display: block;

  width: 18px;
  max-width: 18px;
  height: auto;
  max-height: 6px;

  margin: 7px auto 0;
  padding: 0;

  object-fit: contain;
  object-position: center top;
}


/* Destinos de los enlaces internos */

.ceremony-location,
.celebration-section {
  scroll-margin-top: 24px;
}


/* =========================================
   SEPARADOR
========================================= */

.separator-line {
  width: 90%;
  height: 1px;
  flex-shrink: 0;

  margin: 0;
  padding: 0;

  border: 0;
  background: #d7d7d7;
}

.separator-line--spaced {
  margin-top: 40px;
}


/* =========================================
   ENLACES DE UBICACIÓN Y COPIA
========================================= */

.details-section__location,
.celebration-section__location {
  width: 100%;

  margin-top: 36px;

  text-align: center;
}

.btn-google-map {
  display: inline-block;

  width: auto;

  margin: 0;
  padding: 0;

  border: 0;

  background: transparent;
  color: #211e17;

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.2;

  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;

  cursor: pointer;

  appearance: none;
  -webkit-appearance: none;
}

.btn-google-map:hover,
.btn-google-map:focus,
.btn-google-map:active,
.btn-google-map:visited {
  color: #211e17;
  text-decoration-line: underline;
}


/* =========================================
   CELEBRACIÓN
========================================= */

.celebration-section {
  width: 100%;

  margin: 0;
  padding: 40px 0 20px;

  overflow: hidden;
  text-align: center;
}

.celebration-section__title {
  width: 76%;
  height: auto;

  margin: 0 auto 42px;
}


/* =========================================
   ASISTENCIA, REGALOS Y HOTEL
========================================= */

.attendance-section {
  width: 100%;

  margin: 30px 0 0;
  padding: 0;

  text-align: center;
}

.gift-section {
  width: 100%;

  margin: 55px 0;
  padding: 0;

  text-align: center;
}

.hotel-section {
  width: 100%;

  margin: 0;
  padding: 0;

  text-align: center;
}

.attendance-section__title {
  width: 76%;
  height: auto;

  margin: 0 auto;
}

.gift-section__title {
  width: 46%;
  height: auto;

  margin: 0 auto;
}

.hotel-section__title {
  width: 56%;
  height: auto;

  margin: 0 auto;
}

.attendance-section__intro {
  width: 72%;

  margin: auto;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  text-align: center;
}

.attendance-section__intro strong {
  font-weight: 700;
}


/* =========================================
   FORMULARIO DE ASISTENCIA
========================================= */

.attendance-container {
  width: 90%;

  margin: 42px auto 0;
}

.attendance-form {
  width: 100%;

  margin: 0;
  padding: 0;

  font-size: 16px;
  text-align: left;
}

.attendance-control,
.attendance-guest-field,
.attendance-field {
  margin-bottom: 27px;
}

.attendance-control label,
.attendance-field label,
.attendance-guest-field label {
  display: block;

  margin: 0 0 10px;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.1;
}


/* =========================================
   SELECTORES DEL FORMULARIO
========================================= */

.attendance-form select {
  width: 100%;
  height: 34px;

  margin: 0;
  padding: 2px 42px 2px 9px;

  border: 0;
  border-radius: 6px;

  background-color: #f4f4f4;

  background-image:
    linear-gradient(
      45deg,
      transparent 50%,
      #cccccc 50%
    ),
    linear-gradient(
      135deg,
      #cccccc 50%,
      transparent 50%
    );

  background-position:
    calc(100% - 17px) 50%,
    calc(100% - 11px) 50%;

  background-size:
    7px 7px,
    7px 7px;

  background-repeat: no-repeat;

  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;

  box-shadow: none;

  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

.attendance-form select:focus {
  border: 0;
  outline: none;
  box-shadow: none;
}


/* =========================================
   CAMPOS DEL FORMULARIO
========================================= */

.attendance-guest-field input,
.attendance-field input {
  display: block;

  width: 100%;
  height: 21px;

  margin: 0;
  padding: 0 0 2px;

  border: 0;
  border-bottom: 1px solid #777777;
  border-radius: 0;

  background: transparent;
  color: var(--ink);

  font-family: var(--font-body);
  font-size: 16px;
  line-height: 19px;

  box-shadow: none;
}

.attendance-guest-field input:focus,
.attendance-field input:focus {
  border-bottom-color: var(--ink);
  outline: none;
  box-shadow: none;
}

.attendance-guest-field input:disabled,
.attendance-field input:disabled {
  color: rgba(47, 39, 39, 0.42);
  border-bottom-color: var(--disabled);

  opacity: 1;
  cursor: not-allowed;
}


/* =========================================
   BOTONES
========================================= */

button {
  width: 84%;

  margin: 30px;
  padding: 6px 12px;

  border: 0;
  border-radius: 0;

  background: var(--ink);
  color: #ffffff;

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  text-align: center;

  cursor: pointer;
  box-shadow: none;

  appearance: none;
  -webkit-appearance: none;
}

.attendance-form .submit-form {
  display: block;

  width: 100%;
  height: 34px;

  margin: 4px 0 0;
  padding: 5px 10px;

  font-size: 16px;
}

.attendance-form .submit-form:hover,
.attendance-form .submit-form:focus,
.attendance-form .submit-form:active {
  background: var(--red);
  color: #ffffff;
  outline: none;
}

.attendance-form .submit-form:disabled {
  background: var(--disabled);
  color: #ffffff;

  opacity: 1;
  cursor: not-allowed;
}


/* =========================================
   SPINNER Y RESPUESTA
========================================= */

.spinner {
  width: 45px;
  height: 45px;

  margin: 20px auto;

  border: 5px solid #e3e3e3;
  border-top-color: #6e5c37;
  border-radius: 50%;

  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

#respuesta {
  width: 100%;

  margin: 0;

  font-size: 16px;
}

#respuesta img {
  width: 100%;
  height: auto;
}


/* =========================================
   LISTA DE REGALOS
========================================= */

#accountNumber {
  white-space: nowrap;
}


/* =========================================
   HOTELES
========================================= */

.gift-hotel-container {
  width: calc(100% - 36px);

  margin: 0 auto 55px;

  background: var(--hotel-background);
}

.gift-hotel-container .hotel-section {
  margin-top: 30px;
}

#btnReservarHotel {
  display: inline-block;

  width: 84%;

  margin: 30px;
  padding: 6px 12px;

  border: 0;
  border-radius: 0;

  background: var(--ink);
  color: #ffffff;

  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  text-align: center;
  text-decoration: none;

  cursor: pointer;
}

#btnReservarHotel:hover,
#btnReservarHotel:focus,
#btnReservarHotel:active,
#btnReservarHotel:visited {
  background: var(--ink);
  color: #ffffff;
  text-decoration: none;
}


/* =========================================
   AVISO FLOTANTE DE COPIA
========================================= */

.copy-toast {
  position: fixed;
  left: 50%;
  bottom: calc(22px + env(safe-area-inset-bottom));
  z-index: 99999;

  width: max-content;
  max-width: calc(100% - 40px);

  padding: 10px 16px;

  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;

  background: rgba(35, 35, 35, 0.88);
  color: #ffffff;

  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "SF Pro Text",
    "Helvetica Neue",
    sans-serif;

  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
  text-align: center;

  box-shadow:
    0 8px 30px rgba(0, 0, 0, 0.2),
    0 2px 8px rgba(0, 0, 0, 0.12);

  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);

  opacity: 0;
  pointer-events: none;

  transform:
    translateX(-50%)
    translateY(12px)
    scale(0.96);

  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

.copy-toast.is-visible {
  opacity: 1;

  transform:
    translateX(-50%)
    translateY(0)
    scale(1);
}

/* =========================================
   IMAGEN DE LA FECHA
========================================= */

.date-section {
  width: 80%;

  margin: 35px auto;
}
/* =========================================
   FOOTER
========================================= */

.footer {
  width: 100%;

  padding: 24px 20px;

  color: #6f6767;

  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.4;
  text-align: center;
}

.footer p {
  margin: 0;
}


/* =========================================
   PANTALLAS PEQUEÑAS
========================================= */

@media (max-width: 430px) {
  .wedding-schedule {
    width: calc(100% - 40px);
  }

  .wedding-schedule__item {
    grid-template-columns: 70px minmax(0, 1fr);
    column-gap: 10px;
  }

  .wedding-schedule__time-box {
    width: 70px;
    min-width: 70px;
  }

  .wedding-schedule__time-image {
    width: 50px;
    max-width: 50px;
  }

  .wedding-schedule__heading {
    gap: 12px;
  }

  .wedding-schedule__icon {
    width: 27px;
    height: 27px;
  }

  .wedding-schedule__icon--hearts {
    width: 34px;
    height: 34px;
  }

  .wedding-schedule__time-image--dots {
    width: 18px;
    max-width: 18px;
    max-height: 6px;
  }
}