/* =========================================================
   Search & Discover — Shared Stylesheet
   ========================================================= */

/* ---- Variables ---- */
:root {
  --accent:       #ff6f00;
  --accent-hover: #e65c00;
  --bg:           #f5f5f5;
  --surface:      #fff;
  --text:         #1a1a1a;
  --text-muted:   #555;
  --text-faint:   #888;
  --border:       #eee;
  --shadow:       0 4px 24px rgba(0, 0, 0, 0.12);
  --radius:       16px;
  --font:         -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                  Helvetica, Arial, sans-serif;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ---- Base ---- */
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.5;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Layout shells ---- */
/* Full-page column flex used by all pages */
.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.page-shell > main { flex: 1; }

/* ---- Site Nav ---- */
.site-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 56px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-brand {
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}
.nav-brand:hover { text-decoration: none; color: var(--accent); }
.nav-links {
  list-style: none;
  display: flex;
  gap: 24px;
}
.nav-links a {
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
}
.nav-links a:hover { color: var(--accent); }

/* ---- Site Footer ---- */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 24px;
  text-align: center;
  font-size: 13px;
  color: var(--text-faint);
}
.site-footer .footer-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 8px;
}
.site-footer .footer-links a { color: var(--text-faint); font-size: 13px; }
.site-footer .footer-links a:hover { color: var(--accent); text-decoration: none; }

/* ---- Card ---- */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: 400px;
  width: 100%;
  padding: 40px 32px;
  text-align: center;
}
.card h1 {
  font-size: 26px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.icon { font-size: 64px; margin-bottom: 16px; }
.subtitle {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.5;
}
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}

/* ---- Buttons ---- */
.open-app-btn {
  display: block;
  width: 100%;
  padding: 14px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  margin-bottom: 12px;
  transition: opacity 0.15s;
}
.open-app-btn:hover { opacity: 0.9; text-decoration: none; }

.store-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}
.store-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  transition: opacity 0.15s;
}
.store-btn:hover { opacity: 0.85; text-decoration: none; }
.store-btn svg { flex-shrink: 0; }
.store-btn.play  { background: #1a73e8; }
.store-btn.apple { background: var(--text); }

/* ---- Hint text ---- */
.hint { font-size: 13px; color: var(--text-faint); line-height: 1.5; }
#open-status { display: none; }

/* ---- Steps (tag page) ---- */
.steps {
  text-align: left;
  background: #f9f9f9;
  border-radius: 10px;
  padding: 16px 20px;
  margin-bottom: 24px;
}
.steps p { font-size: 14px; font-weight: 600; color: #444; margin-bottom: 8px; }
.steps ol { font-size: 14px; color: var(--text-muted); padding-left: 20px; line-height: 1.8; }

/* ---- Deep-link page layout (join / tag) ---- */
.deeplink-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.deeplink-footer {
  padding: 16px 24px;
  text-align: center;
  font-size: 12px;
  color: var(--text-faint);
}
.deeplink-footer .footer-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 4px;
}
.deeplink-footer .footer-links a { color: var(--text-faint); font-size: 12px; }
.deeplink-footer .footer-links a:hover { color: var(--accent); }

/* ---- Legal / content page layout ---- */
.legal-main {
  flex: 1;
  max-width: 800px;
  margin: 0 auto;
  padding: 48px 24px 64px;
  width: 100%;
}
.legal-main h1 { font-size: 32px; font-weight: 700; margin-bottom: 8px; }
.legal-main .doc-meta { font-size: 13px; color: var(--text-faint); margin-bottom: 40px; }
.legal-main h2 {
  font-size: 20px;
  font-weight: 700;
  margin-top: 40px;
  margin-bottom: 12px;
  color: var(--text);
}
.legal-main h3 {
  font-size: 16px;
  font-weight: 600;
  margin-top: 24px;
  margin-bottom: 8px;
  color: var(--text);
}
.legal-main p { font-size: 15px; color: #333; line-height: 1.7; margin-bottom: 12px; }
.legal-main ul,
.legal-main ol { margin: 0 0 12px 24px; font-size: 15px; color: #333; line-height: 1.8; }
.legal-main a { color: var(--accent); }
.legal-notice {
  background: #fff8e1;
  border-left: 4px solid var(--accent);
  padding: 12px 16px;
  border-radius: 0 8px 8px 0;
  font-size: 14px;
  color: #5d4037;
  margin-bottom: 24px;
}

/* ---- Responsive ---- */
@media (max-width: 600px) {
  .nav-links { gap: 12px; }
  .nav-links a { font-size: 13px; }
  .legal-main { padding: 32px 16px 48px; }
  .legal-main h1 { font-size: 26px; }
}
@media (max-width: 400px) {
  .nav-links { gap: 8px; }
}
