/* =========================================
   SEAMEW — Design System
   親民、明亮、有溫度的 IoT 簡訊管理品牌站
   ========================================= */

:root {
  /* Surface — 暖白基調 */
  --bg: #FAFAF7;
  --bg-elev: #FFFFFF;
  --bg-soft: #F2F1EC;
  --bg-deep: #E9E7DF;

  /* Ink */
  --ink: #14181D;
  --ink-2: #2A3038;
  --ink-3: #4A525C;
  --ink-mute: #828A93;
  --ink-faint: #B6BCC3;

  /* Lines */
  --line: #E2E0D7;
  --line-strong: #C9C6B9;

  /* Accent — 海洋天空藍 (呼應海鷗 + 訊號) */
  --accent: #2E6BFF;
  --accent-2: #1A4BCC;
  --accent-soft: #E5EDFF;
  --accent-glow: rgba(46, 107, 255, 0.18);

  /* Status */
  --ok: #15A66E;
  --warn: #D97706;
  --bad: #D63A47;

  /* Type */
  --font-sans: "Inter", "Noto Sans TC", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", ui-monospace, Menlo, monospace;
  --font-display: "Inter", "Noto Sans TC", system-ui, sans-serif;

  /* Spacing scale */
  --r-sm: 6px;
  --r: 10px;
  --r-lg: 16px;
  --r-xl: 24px;

  /* Shadows — soft, low spread */
  --shadow-1: 0 1px 2px rgba(20, 24, 29, 0.04), 0 2px 8px rgba(20, 24, 29, 0.04);
  --shadow-2: 0 2px 6px rgba(20, 24, 29, 0.05), 0 12px 28px rgba(20, 24, 29, 0.08);
  --shadow-3: 0 8px 16px rgba(20, 24, 29, 0.06), 0 24px 60px rgba(20, 24, 29, 0.12);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ============ Layout ============ */
.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
  margin: 0;
}
h1 { font-size: clamp(48px, 7vw, 96px); font-weight: 700; }
h2 { font-size: clamp(34px, 4.4vw, 56px); font-weight: 600; }
h3 { font-size: clamp(22px, 2.2vw, 28px); font-weight: 600; }

p { margin: 0; color: var(--ink-2); }
.muted { color: var(--ink-3); }
.mono { font-family: var(--font-mono); }

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink);
  color: var(--bg);
  box-shadow: var(--shadow-1);
}
.btn-primary:hover {
  background: var(--accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow-2);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover {
  background: var(--bg-elev);
  border-color: var(--ink-3);
}

/* ============ Sections ============ */
section {
  padding: 120px 0;
  position: relative;
}
section.tight { padding: 80px 0; }

.section-head {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 64px;
  max-width: 760px;
}
.section-head .eyebrow { align-self: flex-start; }
.section-head p {
  font-size: 18px;
  color: var(--ink-3);
}

/* Grid lines decoration */
.grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: linear-gradient(to bottom, transparent, black 20%, black 80%, transparent);
  opacity: 0.5;
  pointer-events: none;
}

/* ============ Cards ============ */
.card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  padding: 28px;
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.card:hover {
  border-color: var(--ink-faint);
  box-shadow: var(--shadow-1);
}

/* ============ Topnav ============ */
.topnav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 247, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topnav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.brand img { height: 28px; }
.brand span {
  font-size: 18px;
  letter-spacing: 0.18em;
}
.nav-links {
  display: flex;
  gap: 36px;
  font-size: 14px;
  color: var(--ink-3);
}
.nav-links a:hover { color: var(--ink); }

/* ============ Hero ============ */
.hero {
  padding-top: 60px;
  padding-bottom: 40px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 64px;
  align-items: center;
  position: relative;
  z-index: 2;
}
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
}

.hero h1 {
  font-size: clamp(56px, 8.6vw, 124px);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.03em;
}
.hero h1 .it {
  font-style: italic;
  font-weight: 300;
  color: var(--accent);
}
.hero .sub-zh {
  font-size: 20px;
  color: var(--ink-3);
  margin-top: 28px;
  max-width: 460px;
}
.hero .cta-row {
  margin-top: 36px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.hero .meta-row {
  margin-top: 48px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  padding-top: 28px;
  border-top: 1px dashed var(--line-strong);
}
.hero .meta-row .meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hero .meta-row .num {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 600;
  color: var(--ink);
}
.hero .meta-row .lbl {
  font-size: 12px;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-mute);
}

/* Hero visual — Logo + flying animation */
.hero-visual {
  position: relative;
  height: 540px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-visual .ring {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, var(--accent-soft) 0%, transparent 55%);
  opacity: 0.7;
  pointer-events: none;
}
.hero-visual .seamew-logo {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: auto;
  z-index: 2;
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

/* Floating SMS bubbles */
.bubble {
  position: absolute;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-2);
  box-shadow: var(--shadow-2);
  display: flex;
  flex-direction: column;
  gap: 2px;
  white-space: nowrap;
  z-index: 3;
  animation: floatX 7s ease-in-out infinite;
}
.bubble .from {
  font-size: 10px;
  color: var(--ink-mute);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.bubble.b1 { border-left: 3px solid #2E6BFF; }
.bubble.b1 .from { color: #2E6BFF; }
.bubble.b1 .body { color: #14181D; font-weight: 600; }
.bubble.b1 .code { color: #2E6BFF; font-weight: 700; letter-spacing: 0.04em; }

.bubble.b2 { border-left: 3px solid #E26A4F; }
.bubble.b2 .from { color: #E26A4F; }
.bubble.b2 .body { color: #14181D; }
.bubble.b2 .order { color: #E26A4F; font-weight: 600; }

.bubble.b3 { border-left: 3px solid #15A66E; }
.bubble.b3 .from { color: #15A66E; }
.bubble.b3 .body { color: #14181D; }
.bubble.b3 .amount { color: #15A66E; font-weight: 700; }
.bubble.b1 { top: 4%;  left: -8%;  animation-delay: 0s; }
.bubble.b2 { top: 30%; right: -10%; animation-delay: 1.4s; }
.bubble.b3 { bottom: 6%; left: -4%;  animation-delay: 2.8s; }
@keyframes floatX {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50%      { transform: translateY(-8px) rotate(1deg); }
}

/* ============ Pain → Solution ============ */
.compare {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 28px;
  align-items: stretch;
}
@media (max-width: 900px) {
  .compare { grid-template-columns: 1fr; }
  .compare .arrow { transform: rotate(90deg); margin: 0 auto; }
}
.compare .col {
  border-radius: var(--r-xl);
  padding: 32px;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.compare .before {
  background: var(--bg-soft);
  border: 1px dashed var(--line-strong);
}
.compare .after {
  background: var(--ink);
  color: var(--bg);
  position: relative;
  overflow: hidden;
}
.compare .after::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 100% 0%, var(--accent-glow), transparent 50%);
  pointer-events: none;
}
.compare .col h3 { font-size: 22px; }
.compare .after h3 { color: var(--bg); }
.compare .col .label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.compare .after .label { color: var(--accent-soft); opacity: 0.7; }
.compare .arrow {
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; color: var(--ink-faint);
}

.phone-list {
  display: flex; flex-direction: column; gap: 8px;
  margin-top: auto;
}
.phone-list .phone {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 14px; border-radius: 10px;
  background: var(--bg-elev);
  font-family: var(--font-mono);
  font-size: 13px;
  border: 1px solid var(--line);
}
.phone-list .phone .badge {
  font-size: 10px; letter-spacing: 0.08em;
  padding: 2px 8px; border-radius: 999px;
  background: var(--bg-soft); color: var(--ink-mute);
}

.unified-inbox {
  margin-top: auto;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  padding: 14px;
  display: flex; flex-direction: column; gap: 8px;
}
.unified-inbox .row {
  display: flex; gap: 12px; align-items: center;
  padding: 8px 6px;
  font-family: var(--font-mono);
  font-size: 12px;
}
.unified-inbox .row + .row { border-top: 1px solid rgba(255,255,255,0.08); }
.unified-inbox .pill {
  font-size: 10px; padding: 2px 8px; border-radius: 999px;
  background: var(--accent); color: white;
}
.unified-inbox .num { color: var(--accent-soft); }
.unified-inbox .msg { color: rgba(255,255,255,0.85); flex: 1; }
.unified-inbox .time { color: rgba(255,255,255,0.5); font-size: 11px; }

/* ============ Features ============ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
@media (max-width: 800px) { .features-grid { grid-template-columns: 1fr; } }

.feature {
  position: relative;
  padding: 36px;
  border-radius: var(--r-xl);
  background: var(--bg-elev);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 280px;
  overflow: hidden;
}
.feature.dark {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink-2);
}
.feature.dark h3 { color: var(--bg); }
.feature.dark .muted { color: rgba(255,255,255,0.6); }

.feature .icon-wrap {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: var(--accent-soft);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
}
.feature.dark .icon-wrap {
  background: rgba(46,107,255,0.18);
  color: var(--accent-soft);
}
.feature h3 { font-size: 24px; }
.feature p { font-size: 15px; }
.feature .visual {
  margin-top: auto;
  padding-top: 20px;
}

/* ============ Mockup section ============ */
.mockup-stage {
  position: relative;
  padding: 80px 40px 40px;
  background: linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 100%);
  border-radius: var(--r-xl);
  border: 1px solid var(--line);
  overflow: hidden;
}
.mockup-stage::before {
  content: "";
  position: absolute;
  top: -100px; right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, var(--accent-glow), transparent 60%);
  pointer-events: none;
}
.mockup-stack {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 40px;
  align-items: end;
}
@media (max-width: 900px) {
  .mockup-stack { grid-template-columns: 1fr; }
}

.browser {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-3);
  overflow: hidden;
}
.browser-bar {
  background: var(--bg-soft);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
}
.browser-dots { display: flex; gap: 6px; }
.browser-dots span {
  width: 11px; height: 11px; border-radius: 999px;
  background: var(--line-strong);
}
.browser-url {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 4px 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-mute);
}

/* ============ Who's it for ============ */
.who-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 800px) { .who-grid { grid-template-columns: 1fr; } }
.who-card {
  padding: 0;
  border-radius: var(--r-xl);
  border: 1px solid var(--line);
  background: var(--bg-elev);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.who-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--bg-soft);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.who-img img,
.who-img image-slot {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.who-card-body {
  padding: 28px 26px 26px;
  display: flex; flex-direction: column; gap: 10px;
  flex: 1;
}
.who-card .role {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.who-card h4 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.who-card p { font-size: 14px; color: var(--ink-3); }

/* ============ CTA banner ============ */
.cta-banner {
  background: var(--ink);
  color: var(--bg);
  border-radius: var(--r-xl);
  padding: 80px 64px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(46,107,255,0.25), transparent 40%),
    radial-gradient(circle at 80% 70%, rgba(46,107,255,0.18), transparent 45%);
  pointer-events: none;
}
.cta-banner > * { position: relative; z-index: 2; }
.cta-banner h2 { color: var(--bg); }
.cta-banner p { color: rgba(255,255,255,0.7); margin-top: 16px; }
.cta-banner .btn-primary { background: var(--bg); color: var(--ink); }
.cta-banner .btn-primary:hover { background: var(--accent); color: white; }

/* ============ Footer ============ */
footer {
  padding: 60px 0 40px;
  border-top: 1px solid var(--line);
}
footer .foot-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}
footer .foot-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-mute);
  letter-spacing: 0.06em;
}

/* ============ Utility ============ */
.flex { display: flex; }
.col { display: flex; flex-direction: column; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; }
.center { align-items: center; }
.between { justify-content: space-between; }

/* Reveal-on-scroll */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
