* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: #fff;
  background: #1a1a1a url('assets/wallpaper.jpg') center/cover no-repeat fixed;
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
}

/* -------- page layout -------- */
.page {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 40px 20px;
  padding-top: max(40px, env(safe-area-inset-top, 0px));
  padding-bottom: max(24px, env(safe-area-inset-bottom, 0px));
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

.center {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
}

.logo {
  display: block;
  margin: 0 auto 28px;
  width: clamp(200px, 60vw, 480px);
  height: auto;
}

.title {
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 500;
  letter-spacing: 2px;
  line-height: 1.25;
  margin: 0 0 16px;
  color: #fff;
}

.sub {
  font-size: clamp(14px, 1.6vw, 16px);
  font-weight: 400;
  letter-spacing: 0.5px;
  margin: 0 0 32px;
  color: #fff;
  opacity: 0.95;
}

/* -------- buttons -------- */
.notify-btn {
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 2px;
  color: #fff;
  background: transparent;
  border: 1px solid #fff;
  padding: 14px 36px;
  min-height: 44px;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}
.notify-btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.notify-btn--block { width: 100%; padding: 14px; margin-top: 4px; }

.cta-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.cta-hint {
  margin: 18px 0 0;
  font-size: 11px;
  letter-spacing: 2px;
  color: #fff;
  opacity: 0.7;
}

/* -------- footer -------- */
.footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  padding-top: 24px;
}
.footer a {
  color: #fff;
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 2px;
  opacity: 0.85;
  transition: opacity 160ms ease;
  display: inline-flex;
  align-items: center;
  padding: 6px 0;
}

/* -------- modal -------- */
.modal {
  position: fixed; inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 50;
}
.modal[aria-hidden="false"] { display: flex; }

.modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.65);
  animation: fade 160ms ease;
}

.modal__panel {
  position: relative;
  background: #fff;
  color: #1a1a1a;
  width: 100%;
  max-width: 420px;
  padding: 36px 32px 28px;
  animation: pop 200ms ease;
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
}

.modal__close {
  position: absolute;
  top: 4px; right: 4px;
  background: transparent;
  border: 0;
  font-size: 26px;
  line-height: 1;
  color: #888;
  cursor: pointer;
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal__title {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 3px;
  margin: 0 0 8px;
  text-align: center;
}
.modal__sub {
  margin: 0 0 24px;
  color: #555;
  font-size: 13px;
  text-align: center;
  line-height: 1.5;
}

/* -------- form -------- */
.form { display: flex; flex-direction: column; gap: 14px; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field__label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  color: #1a1a1a;
  text-transform: uppercase;
}

.field input,
.field select {
  font-family: inherit;
  font-size: 16px; /* 16px prevents iOS Safari zoom-on-focus */
  padding: 12px 14px;
  border: 1px solid #ccc;
  background: #fff;
  color: #1a1a1a;
  border-radius: 0;
  transition: border-color 140ms ease;
}
.field input {
  -webkit-appearance: none;
  appearance: none;
}
.field input:focus,
.field select:focus {
  outline: none;
  border-color: #1a1a1a;
}

.notify-btn--block {
  color: #fff;
  background: #1a1a1a;
  border-color: #1a1a1a;
}

.hp {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0,0,0,0);
}

.form__status {
  margin: 6px 0 0;
  font-size: 13px;
  min-height: 1.2em;
  text-align: center;
}
.form__status.is-success { color: #2e7d4f; }
.form__status.is-error { color: #c23b3b; }

/* -------- animations -------- */
@keyframes pop {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* -------- hover (only on real hover devices, not touch) -------- */
@media (hover: hover) {
  .notify-btn:hover { background: #fff; color: #1a1a1a; }
  .notify-btn--block:hover { background: #fff; color: #1a1a1a; border-color: #1a1a1a; }
  .modal__close:hover { color: #1a1a1a; }
  .footer a:hover { opacity: 1; }
}

/* -------- narrow screens (phones) -------- */
@media (max-width: 520px) {
  .footer {
    justify-content: center;
    padding-top: 32px;
  }
  .cta-row {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 320px;
  }
  .cta-row .notify-btn {
    width: 100%;
    padding: 14px;
  }
}

/* -------- tiny screens (iPhone SE etc) -------- */
@media (max-width: 400px) {
  .modal { padding: 12px; }
  .modal__panel { padding: 32px 20px 24px; }
}
