/* BASE */
* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --texto: #302921;
  --dorado: #98704c;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 48px 22px;
  background: #e9e5de;
  color: var(--texto);
  font-family: Arial, Helvetica, sans-serif;
  isolation: isolate;
}

/* FONDO GIF */
.landscape {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;

  background-color: #e9e5de;
  background-image: var(--fondo-gif, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.landscape::after {
  content: "";
  position: absolute;
  inset: 0;

  background:
    radial-gradient(
      ellipse at 50% 25%,
      rgba(255, 250, 240, 0.78),
      transparent 75%
    ),
    linear-gradient(
      135deg,
      rgba(245, 239, 229, 0.58),
      rgba(244, 239, 232, 0.48) 55%,
      rgba(220, 229, 218, 0.65)
    );
}

/* CONTENIDO */
main {
  width: 100%;
  max-width: 880px;
  text-align: center;
}

header {
  animation: aparecer 0.8s ease both;
}

/* MARCA */
.brand {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(72px, 13vw, 108px);
  font-weight: normal;
  letter-spacing: -7px;
  line-height: 1;
  text-shadow: 0 5px 25px rgba(255, 255, 255, 0.5);
}

.brand span {
  display: inline-block;
  color: var(--dorado);
}

.subtitle {
  margin: 16px 0 30px;
  padding-left: 5px;
  color: #66503f;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 5px;
  text-transform: uppercase;
}

.subtitle::after {
  content: "";
  display: block;
  width: 54px;
  height: 1px;
  margin: 26px auto 0;

  background: linear-gradient(
    90deg,
    transparent,
    #98704c,
    transparent
  );
}

h2 {
  margin: 0 0 12px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(28px, 5vw, 40px);
  font-weight: normal;
  letter-spacing: -0.8px;
}

.intro {
  margin: 0 0 36px;
  color: #5c5148;
  font-size: 14px;
  line-height: 1.7;
}

/* TARJETAS */
.choices {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.choice {
  --acento: #795638;
  --acento-claro: #946d49;

  position: relative;
  isolation: isolate;
  overflow: hidden;

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

  min-width: 0;
  padding: 38px 30px 28px;

  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;

  background: rgba(255, 253, 249, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 26px;

  box-shadow:
    0 16px 45px rgba(62, 44, 28, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);

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

  animation: aparecer 0.8s ease 0.12s both;

  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease,
    border-color 0.35s ease,
    background-color 0.35s ease;
}

.choice-family {
  --acento: #344d40;
  --acento-claro: #526d5b;

  animation-delay: 0.24s;
}

/* Línea decorativa superior */
.choice::before {
  content: "";
  position: absolute;
  top: 0;
  left: 24%;
  right: 24%;
  height: 2px;

  background: linear-gradient(
    90deg,
    transparent,
    var(--acento-claro),
    transparent
  );

  opacity: 0.6;

  transition:
    left 0.35s ease,
    right 0.35s ease,
    opacity 0.35s ease;
}

.choice:focus-visible {
  outline: 3px solid var(--acento);
  outline-offset: 6px;
}

/* LOGOS */
.company-logo {
  display: block;
  width: 160px;
  max-width: 100%;
  height: 100px;
  margin: 0 auto 26px;
  object-fit: contain;

  transition: transform 0.4s ease;
}

/* NOMBRES */
.name {
  margin: 0 0 10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(25px, 3vw, 30px);
  font-weight: normal;
  letter-spacing: -0.6px;
}

.location {
  margin: 0 0 30px;
  color: #706459;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* BOTONES */
.enter {
  position: relative;
  isolation: isolate;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;

  width: 100%;
  min-height: 60px;
  margin-top: auto;
  padding: 12px 14px 12px 20px;

  background: linear-gradient(
    120deg,
    var(--acento),
    var(--acento-claro)
  );

  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;

  font-size: 13px;
  font-weight: 600;
  text-align: left;

  box-shadow: 0 6px 16px rgba(44, 36, 28, 0.1);

  transition:
    box-shadow 0.3s ease,
    filter 0.3s ease;
}

/* Brillo que recorre el botón */
.enter::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;

  background: linear-gradient(
    110deg,
    transparent 20%,
    rgba(255, 255, 255, 0.24) 50%,
    transparent 80%
  );

  transform: translateX(-150%);
}

.button-text {
  position: relative;
  z-index: 1;
}

/* ÍCONO DE PUERTA */
.button-icon {
  position: relative;
  z-index: 1;

  display: grid;
  place-items: center;

  flex: 0 0 38px;
  width: 38px;
  height: 38px;

  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;

  transition:
    background-color 0.35s ease,
    box-shadow 0.35s ease;
}

.button-icon svg {
  display: block;
  width: 24px;
  height: 24px;
  overflow: visible;

  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.door-frame {
  opacity: 0.55;
}

.door-panel {
  transform-box: view-box;
  transform-origin: 5px 12px;

  transition:
    transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.door-panel path {
  fill: var(--acento);
}

.door-panel circle {
  fill: currentColor;
  stroke: none;
}

/* INTERACCIÓN CON TECLADO */
.choice:focus-visible .door-panel {
  transform: skewY(-12deg) scaleX(0.55);
}

.choice:focus-visible .button-icon {
  background: rgba(255, 255, 255, 0.24);
}

.choice:focus-visible .enter::before {
  animation: brillo-boton 0.8s ease;
}

/* INTERACCIÓN CON MOUSE */
@media (hover: hover) and (pointer: fine) {
  .choice:hover {
    transform: translateY(-8px);
    background-color: rgba(255, 253, 249, 0.96);
    border-color: #c7b39c;

    box-shadow:
      0 26px 55px rgba(62, 44, 28, 0.16),
      inset 0 1px 0 #fff;
  }

  .choice-family:hover {
    border-color: #9bad9e;
  }

  .choice:hover::before {
    left: 12%;
    right: 12%;
    opacity: 1;
  }

  .choice:hover .company-logo {
    transform: translateY(-3px) scale(1.04);
  }

  .choice:hover .enter {
    filter: brightness(1.06);
    box-shadow: 0 9px 20px rgba(44, 36, 28, 0.2);
  }

  .choice:hover .enter::before {
    animation: brillo-boton 0.8s ease;
  }

  .choice:hover .door-panel {
    transform: skewY(-12deg) scaleX(0.55);
  }

  .choice:hover .button-icon {
    background: rgba(255, 255, 255, 0.24);
    box-shadow: 0 0 18px rgba(255, 255, 255, 0.12);
  }
}

/* AL PRESIONAR, TAMBIÉN EN CELULAR */
.choice:active {
  transform: scale(0.98);
}

.choice:active .button-icon {
  background: rgba(255, 255, 255, 0.3);
}

/* PIE DE PÁGINA */
footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;

  margin-top: 34px;
  color: #5f5348;
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;

  animation: aparecer 0.8s ease 0.35s both;
}

footer::before,
footer::after {
  content: "";
  width: 32px;
  height: 1px;
  background: currentColor;
  opacity: 0.35;
}

/* ANIMACIONES */
@keyframes aparecer {
  from {
    opacity: 0;
    translate: 0 22px;
  }

  to {
    opacity: 1;
    translate: 0 0;
  }
}

@keyframes brillo-boton {
  from {
    transform: translateX(-150%);
  }

  to {
    transform: translateX(150%);
  }
}

/* CELULARES */
@media (max-width: 560px) {
  body {
    padding: 30px 18px;
  }

  .brand {
    font-size: 76px;
  }

  .subtitle {
    margin-bottom: 24px;
    font-size: 10px;
    letter-spacing: 4px;
  }

  .subtitle::after {
    margin-top: 20px;
  }

  .intro {
    margin-bottom: 26px;
    font-size: 13px;
  }

  .choices {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .choice {
    padding: 25px 24px 22px;
    border-radius: 22px;
  }

  .company-logo {
    width: 140px;
    height: 80px;
    margin-bottom: 20px;
  }

  .name {
    font-size: 26px;
  }

  .location {
    margin-bottom: 22px;
    font-size: 10px;
  }

  footer {
    margin-top: 28px;
    font-size: 9px;
  }
}

/* ACCESIBILIDAD */
@media (prefers-reduced-motion: reduce) {
  .landscape {
    background-image: none;
  }

  header,
  footer,
  .choice,
  .choice::before,
  .company-logo,
  .enter,
  .enter::before,
  .button-icon,
  .door-panel {
    animation: none !important;
    transition: none !important;
  }

  .choice:hover,
  .choice:active,
  .choice:hover .company-logo,
  .choice:hover .door-panel,
  .choice:focus-visible .door-panel {
    transform: none;
  }
}