/* public/css/landing.css — landing-page styles and iMessage demo */

/* ── Landing page card ────────────────────────────────────────────────────── */

/* Slightly wider than the default 440px to give the phone shadow room */
.landing-page {
  max-width: 460px;
  text-align: center;
}

/* Feature list reads better left-aligned within the centered card */
.landing-page .feature-list {
  text-align: left;
}

/* On narrow viewports, reduce horizontal padding so the phone fits comfortably */
@media (max-width: 480px) {
  .landing-page {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* ── Demo wrapper ─────────────────────────────────────────────────────────── */

.demo-wrapper {
  display: flex;
  justify-content: center;
  /* overflow: visible so the phone's box-shadow is not clipped by the wrapper */
  overflow: visible;
  padding: 4px 12px 0;
  margin: 0.5rem 0 1.5rem;
}

/* ── Phone shell ──────────────────────────────────────────────────────────── */

.demo-phone {
  position: relative;
  width: 228px;
  background: linear-gradient(160deg, #252528 0%, #1a1a1e 50%, #141416 100%);
  border-radius: 46px;
  padding: 10px 12px 14px;
  box-shadow:
    0 0 0 1.5px #3a3a3c,
    0 8px 20px rgba(0, 0, 0, 0.35),
    0 32px 72px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Left side buttons (volume up / volume down) */
.demo-phone::before {
  content: '';
  position: absolute;
  top: 82px;
  left: -3.5px;
  width: 3.5px;
  height: 26px;
  background: #3a3a3c;
  border-radius: 2px 0 0 2px;
  /* box-shadow stacks a second button below the first */
  box-shadow: 0 38px 0 #3a3a3c;
}

/* Right side button (power) */
.demo-phone::after {
  content: '';
  position: absolute;
  top: 102px;
  right: -3.5px;
  width: 3.5px;
  height: 52px;
  background: #3a3a3c;
  border-radius: 0 2px 2px 0;
}

/* ── Dynamic Island notch ─────────────────────────────────────────────────── */

.demo-notch {
  width: 54px;
  height: 10px;
  background: #1a1a1e;
  border-radius: 7px;
  margin: 0 auto 4px;
}

/* ── Screen ───────────────────────────────────────────────────────────────── */

.demo-screen {
  background: #f2f2f7;
  border-radius: 34px;
  height: 418px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  /* Match the iOS system font stack */
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', sans-serif;
}

/* ── Status bar ───────────────────────────────────────────────────────────── */

.demo-statusbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 16px 2px;
  font-size: 10px;
  font-weight: 600;
  color: #1c1c1e;
  flex-shrink: 0;
}

.demo-statusbar__icons {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ── Contact header ───────────────────────────────────────────────────────── */

.demo-contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 12px 7px;
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.12);
  flex-shrink: 0;
}

.demo-contact__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #007aff;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 3px;
}

.demo-contact__name {
  font-size: 10px;
  font-weight: 600;
  color: #1c1c1e;
}

/* ── Messages area ────────────────────────────────────────────────────────── */

.demo-messages {
  flex: 1;
  overflow-y: auto;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  /* Hide the scrollbar — scrolling is decorative */
  scrollbar-width: none;
}

.demo-messages::-webkit-scrollbar {
  display: none;
}

/* ── Message bubbles ──────────────────────────────────────────────────────── */

.demo-bubble {
  max-width: 78%;
  padding: 7px 11px;
  border-radius: 17px;
  font-size: 8px;
  line-height: 1.4;
  text-align: left;
  word-break: break-word;
  /* Preserve \n line breaks in textContent */
  white-space: pre-wrap;
}

/* Received (LowSignalMail → user) */
.demo-bubble--system {
  background: #e5e5ea;
  color: #1c1c1e;
  align-self: flex-start;
  border-bottom-left-radius: 3px;
}

/* Sent (user → LowSignalMail) */
.demo-bubble--user {
  background: #007aff;
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 3px;
}

@keyframes demo-bubble-in {
  from {
    opacity: 0;
    transform: scale(0.88) translateY(6px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .demo-bubble {
    animation: demo-bubble-in 0.22s cubic-bezier(0.34, 1.4, 0.64, 1) both;
  }
}

/* ── Input bar ────────────────────────────────────────────────────────────── */

.demo-inputbar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px 8px;
  background: #f2f2f7;
  border-top: 0.5px solid rgba(0, 0, 0, 0.14);
  flex-shrink: 0;
}

.demo-inputbar__field {
  flex: 1;
  background: #fff;
  border: 0.75px solid #c7c7cc;
  border-radius: 18px;
  padding: 5px 11px;
  font-size: 10px;
  line-height: 1.3;
  text-align: left;
  color: #8e8e93;
  font-family: inherit;
  user-select: none;
}

.demo-inputbar__btn {
  width: 24px;
  height: 24px;
  background: #007aff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  user-select: none;
}
