/*
Author: Mohammad Zare
Author URI: http://mohammadz.com/
*/
@charset "UTF-8";

:root {
  --pgutter-x: 20px;
  --gutter-x: 20px;
  --pgutter-y: 20px;
  --gutter-y: 20px;

  --gap: 4px;
  /* کوچک‌ترین عرض طراحی‌شده (Mobile) */
  --vw-min: 390;
  /* کوچک‌ترین ارتفاع طراحی‌شده (Mobile) */
  --vh-min: 844;
  /* بزرگ‌ترین عرض طراحی‌شده (Desktop) */
  --vw-max: 1920;
  /* بزرگ‌ترین ارتفاع طراحی‌شده (Desktop) */
  --vh-max: 1080;
  /* حداکثر عرض هدف */
  --screen-vw-max: 1920;
  /* حداکثر ارتفاع هدف */
  --screen-vh-max: 1080;

  /* تفاوت بازه طراحی */
  --vw-range: calc(var(--vw-max) - var(--vw-min));
  --vh-range: calc(var(--vh-max) - var(--vh-min));
  /* نسبت اسکیل تا بزرگ‌ترین اسکرین */
  --vw-scale-to-screen: calc(var(--screen-vw-max) / var(--vw-max));
  --vh-scale-to-screen: calc(var(--screen-vh-max) / var(--vh-max));
  /* شیب تغییرات برای فونت/ابعاد بین موبایل ↔ دسکتاپ */
  --vw-slope: calc(1 / var(--vw-range));
  --vh-slope: calc(1 / var(--vh-range));
  /* واحدهای کمکی */
  --vw-unit: calc(100vw - var(--vw-min) * 1px);
  --vh-unit: calc(100vh - var(--vh-min) * 1px);
}

@font-face {
  font-family: "Plus Jakarta Sans";
  src: url("../fonts/PlusJakartaSans-VariableFont_wght.ttf") format("truetype-variations");
  font-weight: 1 999;
}

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

:focus {
  outline: 0 !important;
}

::selection {
  background: rgba(0, 0, 0, 0.1);
}

::-moz-selection {
  background: rgba(0, 0, 0, 0.1);
}

html,
body {
  width: 100vw;
}

body {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
  background: #fff;
  color: #000;

  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  backface-visibility: hidden;

  font-family: "Plus Jakarta Sans";
  font-weight: 400;
  font-style: normal;
}

#wrapper {
  width: 100%;
  height: 100%;
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: clamp(80px, 2.61vw + 69.80px, 120px);
  max-width: calc(var(--screen-vw-max) * 1px);
  max-width: 1600px;
  margin: 0 auto;
}

#logo {
  width: 100%;
  height: 100%;
  max-width: 100%;
  filter: blur(15px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-50px) scale(1.5);
  transition: all 500ms ease-in-out;
}

body.page-loaded #logo {
  filter: blur(0);
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

#title {
  position: absolute;
  opacity: 0;
  visibility: hidden;
}

#footer {
  width: 100%;
  text-align: start;
}

.newsletter {
  display: flex;
  justify-content: center;
  align-items: end;
  margin: 0 auto;
  gap: clamp(60px, 4.58vw + 42.16px, 130px);
}

body:not(.page-loaded) .newsletter {
  opacity: 0;
  visibility: visible;
}

.newsletter-title {
  font-weight: 620;
  font-size: calc(clamp(45px, 1.90vw + 37.61px, 74px) * var(--vh-scale-to-screen));
  letter-spacing: -0.154166667vw;
  color: #000;
  text-align: start;
  margin: 0;
  white-space: nowrap;
  line-height: 1.5;
  transform: translateY(10%);
}
.newsletter-title>div:not(:last-child) {
  transform: translateY(25%);
}
.newsletter-body {
  width: 100%;
  position: relative;
}

.newsletter-form {
  width: 100%;
  display: flex;
  gap: clamp(20px, 0.26vw + 18.98px, 24px);
  align-items: end;
  opacity: 0;
  visibility: hidden;
  filter: blur(10px);
  transition: all 600ms 400ms ease-in-out;
}

body.page-loaded .newsletter-form {
  opacity: 1;
  visibility: visible;
  filter: blur(0);
}

.marquee-placeholder,
.newsletter-form input[type="email"] {
  color: #000;
  font-size: clamp(16px, 0.39vw + 14.47px, 22px);
  font-weight: 218;
  line-height: 1.5;
  text-align: start;
}

.newsletter-form input[type="email"] {
  border: none;
  border-bottom: 2px solid #000;
  width: 100%;
  height: 100%;
  background-color: transparent;
  padding-bottom: clamp(10px, 0.94vw + 6.48px, 20px);
}

.input-field:focus+.marquee-placeholder,
.input-field:not(:placeholder-shown)+.marquee-placeholder {
  display: none;
}

.marquee-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  max-width: calc(100% - clamp(36px, 1.18vw + 31.41px, 54px) - clamp(20px, 0.26vw + 18.98px, 24px));
}

.marquee-text {
  display: inline-block;
  padding-left: 20px;
}

.marquee-text.active {
  animation: marquee 10s linear infinite;
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-100%);
  }
}

.newsletter-form:hover .marquee-text.active {
  animation-play-state: paused;
}

.marquee-text:not(.active) {
  text-overflow: ellipsis;
  overflow: hidden;
  padding-left: 0;
}

.newsletter-form input[type="email"]::placeholder {
  color: #000;
  font-size: clamp(16px, 0.39vw + 14.47px, 22px);
  font-weight: 218;
  line-height: 1;
  text-align: start;
}

.newsletter-form input[type="email"]:-webkit-autofill {
  color: #000 !important;
  font-size: clamp(16px, 0.39vw + 14.47px, 22px) !important;
  font-weight: 218;
  line-height: 1 !important;
  text-align: start !important;
  -webkit-box-shadow: 0 0 0px 1000px #fff inset !important;
  box-shadow: 0 0 0px 1000px #fff inset !important;
  -webkit-text-fill-color: #000 !important;
}

.newsletter-form button[type="submit"] {
  min-width: clamp(36px, 1.18vw + 31.41px, 54px);
  width: clamp(36px, 1.18vw + 31.41px, 54px);
  height: clamp(36px, 1.18vw + 31.41px, 54px);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 57.94 57.94'%3E%3Cpath d='M30.71 44.34h-5.33l12.29-12.29H13.06v-3.79h24.61L25.38 15.97h5.33l14.18 14.18-14.18 14.18Z'/%3E%3Cpath d='M28.97 57.94C13 57.94 0 44.94 0 28.97S13 0 28.97 0s28.97 13 28.97 28.97-13 28.97-28.97 28.97Zm0-54.94C14.65 3 3 14.65 3 28.97s11.65 25.97 25.97 25.97 25.97-11.65 25.97-25.97S43.29 3 28.97 3Z'/%3E%3C/svg%3E%0A");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  background-color: transparent;
  font-size: 0;
  border: none;
  padding: 0;
  cursor: pointer;
}

.newsletter-message {
  position: absolute;
  top: 100%;
  left: 0;
  margin: 12px 0 0;
  font-size: 0.9rem;
  line-height: 1.4;
  color: #333;
}

.newsletter-message[data-state="success"] {
  color: #036d19;
}

.newsletter-message[data-state="error"] {
  color: #b00020;
}

.line,
.word,
.letter {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
}

.line {
  display: block;
}

.mask-inner {
  display: inline-block;
  opacity: 0;
  will-change: opacity;
}

@media screen and (orientation: portrait) {
  #logo {
    height: calc(190px * var(--vh-scale-to-screen));
  }

  .newsletter {
    flex-direction: column;
    align-items: start;
  }
}

@media screen and (orientation: landscape) {
  #logo {
    width: calc(470px * var(--vw-scale-to-screen));
  }
}

@media (prefers-reduced-motion: reduce) {}