:root {
  --color-offwhite: #FAF7F0;
  --color-dark-text: #3D4043;
  --color-teal: #4E9A9F;
  --color-coral: #F3968F;
  --color-muted: #777;
  --color-border: #E6E6E6;
  --font-primary: 'Poppins', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  font-family: var(--font-primary);
  background-color: var(--color-offwhite);
  color: var(--color-dark-text);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh; /* 모바일 주소창 높이 변화 대응 */
  padding: 20px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 560px;
  width: 100%;
  text-align: center;
  margin: 0 auto;
}

.content {
  animation: fadeIn 1.2s ease-in-out both;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* 접근성: 화면에서 숨기되 스크린리더는 읽도록 */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}

.app-icon {
  width: 104px;
  height: 104px;
  margin-bottom: 20px;
  border-radius: 24px;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.07);
  object-fit: cover;
}

.title {
  font-size: 3rem;
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.subtitle {
  font-size: 1.2rem;
  color: var(--color-muted);
  margin-bottom: 24px;
}

.launch-date {
  background-color: var(--color-coral);
  color: #fff;
  display: inline-block;
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 40px;
}

.email-form-container {
  background-color: #fff;
  padding: 28px;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
  margin-bottom: 24px;
  text-align: left; /* 폼 정렬 자연스럽게 */
}

.form-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}

form {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

form input[type="email"] {
  flex: 1 1 auto;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 12px 14px;
  font-family: var(--font-primary);
  font-size: 1rem;
  background: #fff;
  transition: border-color .2s ease, box-shadow .2s ease;
}

form input[type="email"]::placeholder {
  color: #aaa;
}

form input[type="email"]:focus {
  outline: none;
  border-color: var(--color-teal);
  box-shadow: 0 0 0 3px rgba(78, 154, 159, 0.18);
}

form button {
  background-color: var(--color-teal);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 12px 18px;
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color .18s ease;
  white-space: nowrap;
}

form button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(78, 154, 159, 0.28);
}

form button:focus-visible {
  outline: 3px solid rgba(78, 154, 159, 0.35);
  outline-offset: 2px;
}

.story-link {
  text-align: center;
}

.story-link p {
  font-size: 0.95rem;
  color: #8c8c8c;
}

.story-link a {
  display: inline-block;
  margin-top: 6px;
  color: var(--color-teal);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px dotted rgba(78, 154, 159, 0.5);
  padding-bottom: 1px;
}

.story-link a:hover {
  border-bottom-color: transparent;
  text-decoration: underline;
}

/* 언어 토글 */
#langToggle {
  color: #9a9a9a;
  text-decoration: none;
  transition: color .15s ease;
}

#langToggle:hover {
  color: var(--color-dark-text);
  text-decoration: underline;
}

/* 작은 화면 최적화 */
@media (max-width: 560px) {
  .title { font-size: 2.5rem; }
  .subtitle { font-size: 1.05rem; }
  .email-form-container { padding: 22px; }
}

@media (max-width: 480px) {
  form {
    flex-direction: column;
  }
  form input[type="email"],
  form button {
    width: 100%;
  }
  form button {
    padding: 14px 16px;
  }
}

/* 모션 최소화 선호 시 애니메이션 제거 */
@media (prefers-reduced-motion: reduce) {
  .content { animation: none; }
  * { transition: none !important; }
}

/* Mailchimp 결과 메시지 */
.mc-msg {
  margin-top: 12px;
  font-weight: 600;
  font-size: 0.95rem;
  white-space: pre-line; /* ← \n을 실제 줄바꿈으로 렌더링 */
}
.mc-msg.ok { color: #2f855a; }
.mc-msg.err { color: #c53030; }