/* ==========================================================================
   SBTI Test — Global Styles
   Domain: sbtitest.wtf
   ========================================================================== */

:root {
  --bg: #f6faf6;
  --panel: #ffffff;
  --text: #1e2a22;
  --muted: #6a786f;
  --line: #dbe8dd;
  --soft: #edf6ef;
  --accent: #6c8d71;
  --accent-strong: #4d6a53;
  --shadow: 0 16px 40px rgba(47, 73, 55, 0.08);
  --radius: 22px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, #f8fff8 0, #f6faf6 36%, #f2f7f3 100%);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
}

h1, h2, h3, h4, p { margin: 0; }
a { color: var(--accent-strong); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Layout Shell ---- */
.shell {
  max-width: 980px;
  margin: 0 auto;
  padding: 24px 16px 56px;
}

/* ---- Site Header / Nav ---- */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 10px;
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(246,250,246,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.site-logo {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}
.site-logo span { color: var(--accent-strong); }
.site-nav {
  display: flex;
  gap: 18px;
  align-items: center;
  flex-wrap: wrap;
}
.site-nav a {
  font-size: 14px;
  color: var(--muted);
  transition: color .15s;
}
.site-nav a:hover { color: var(--accent-strong); text-decoration: none; }
.site-nav .nav-cta {
  font-weight: 700;
  color: var(--accent-strong);
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
  transition: background .15s, color .15s;
}
.site-nav .nav-cta:hover {
  background: var(--accent-strong);
  color: #fff;
}
.lang-switch {
  font-size: 12px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent-strong);
  cursor: pointer;
  font-weight: 700;
}

/* ---- Card ---- */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ---- Hero ---- */
.hero {
  padding: 28px;
  margin-top: 20px;
  overflow: hidden;
  position: relative;
}
.hero::after {
  content: "";
  position: absolute;
  right: -60px; top: -60px;
  width: 180px; height: 180px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(127,165,134,0.18), rgba(127,165,134,0.02));
  pointer-events: none;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--accent-strong);
  border: 1px solid var(--line);
  background: var(--soft);
  border-radius: 999px;
  padding: 8px 12px;
  margin-bottom: 16px;
}
.hero h1 {
  font-size: clamp(28px, 5vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  max-width: 680px;
}
.hero .sub {
  margin-top: 14px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
  max-width: 720px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 18px;
  align-items: stretch;
  margin-top: 24px;
}
.mini-panel {
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #fbfefb, #f3f8f4);
}
.mini-panel h3 { font-size: 15px; margin-bottom: 10px; }
.mini-panel ul {
  margin: 0; padding-left: 18px;
  color: var(--muted);
  line-height: 1.8; font-size: 14px;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}
.hero-minimal {
  min-height: 48vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 42px 20px;
}
.hero-minimal::after { display: none; }
.hero-minimal h1 { max-width: none; margin: 0; }
.hero-actions-single {
  justify-content: center;
  margin-top: 28px;
}

/* ---- Buttons ---- */
button {
  border: 0; cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, opacity .16s ease;
  font: inherit;
}
button:hover { transform: translateY(-1px); }
button:disabled { cursor: not-allowed; opacity: 0.55; transform: none; }

.btn-primary {
  background: var(--accent-strong);
  color: #fff;
  padding: 14px 20px;
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(77,106,83,0.18);
  font-weight: 700;
}
.btn-secondary {
  background: #fff;
  color: var(--accent-strong);
  padding: 14px 20px;
  border-radius: 14px;
  border: 1px solid var(--line);
  font-weight: 700;
}
.btn-link {
  background: none;
  color: var(--accent-strong);
  padding: 14px 20px;
  font-weight: 700;
  text-decoration: underline;
}

/* ---- Screen Toggle ---- */
.screen { display: none; }
.screen.active { display: block; }

/* ---- Test Section ---- */
.test-wrap { margin-top: 22px; padding: 28px; min-height: 60vh; display: flex; flex-direction: column; }
.result-wrap { margin-top: 22px; padding: 22px; }

.topbar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}
.progress-info {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.progress-info #progressText {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}
.progress-info #progressPercent {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-strong);
}
.progress {
  width: 100%;
  height: 8px;
  background: var(--soft);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}
.progress > span {
  display: block; width: 0; height: 100%;
  background: linear-gradient(90deg, #a3c4a9, #4d6a53);
  border-radius: inherit;
  transition: width .4s cubic-bezier(.4, 0, .2, 1);
  position: relative;
}
.progress > span::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,.35) 50%, rgba(255,255,255,0) 100%);
  animation: progressShine 2s ease-in-out infinite;
}
@keyframes progressShine {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* ---- Single Question Card ---- */
.question-container {
  flex: 1;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.question {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
  background: linear-gradient(180deg, #ffffff, #fbfdfb);
}
.question-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 12px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 6px 12px;
  background: var(--soft);
  border: 1px solid var(--line);
  font-weight: 700;
  color: var(--accent-strong);
}
.question-title {
  font-size: 16px;
  line-height: 1.75;
  white-space: pre-wrap;
}
.options { display: grid; gap: 10px; margin-top: 18px; }
.option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: #fff;
  cursor: pointer;
  transition: border-color .18s, background .18s, transform .18s, box-shadow .18s;
}
.option:hover {
  border-color: #bcd0c1;
  background: #f8fcf9;
  transform: translateY(-1px);
}
.option.selected {
  border-color: var(--accent-strong);
  background: linear-gradient(135deg, #eef6ef, #e4f0e6);
  box-shadow: 0 2px 12px rgba(77,106,83,.12);
}
.option.selected .option-code {
  background: var(--accent-strong);
  color: #fff;
}
.option input {
  position: absolute;
  opacity: 0;
  width: 0; height: 0;
}
.option-code {
  font-weight: 800;
  color: var(--accent-strong);
  min-width: 28px; height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1.5px solid var(--line);
  background: var(--soft);
  font-size: 13px;
  flex-shrink: 0;
  transition: background .18s, color .18s, border-color .18s;
}
.option.selected .option-code {
  border-color: var(--accent-strong);
}

/* ---- Card Transition Animation ---- */
.fade-slide-in {
  animation: fadeSlideIn .32s cubic-bezier(.4, 0, .2, 1) both;
}
@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- Test Navigation ---- */
.test-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.test-nav .btn-quit {
  font-size: 13px;
  padding: 10px 14px;
  color: var(--muted);
  border-color: transparent;
  background: none;
}
.test-nav .btn-quit:hover { color: var(--accent-strong); background: var(--soft); border-color: var(--line); }
.test-nav .btn-submit {
  background: linear-gradient(135deg, #4d6a53, #3a5240);
  box-shadow: 0 6px 20px rgba(58,82,64,.25);
}

/* ---- Result Section ---- */
.result-layout { display: grid; gap: 18px; }
.result-top {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 18px;
  align-items: stretch;
}
.poster-box, .type-box, .analysis-box, .dim-box, .note-box {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  background: linear-gradient(180deg, #ffffff, #fbfdfb);
}
.poster-box {
  display: grid;
  grid-template-rows: 1fr auto;
  min-height: 280px;
  overflow: hidden;
  position: relative;
  background:
    radial-gradient(circle at top right, rgba(127,165,134,0.16), rgba(127,165,134,0) 40%),
    linear-gradient(180deg, #ffffff, #f7fbf8);
}
.poster-box::after {
  content: "";
  position: absolute;
  right: -46px; bottom: -46px;
  width: 140px; height: 140px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(127,165,134,0.12), rgba(127,165,134,0.01));
  pointer-events: none;
}
.poster-image {
  width: 100%;
  min-height: 220px; max-height: 460px;
  object-fit: contain;
  border-radius: 18px;
  background: rgba(255,255,255,0.75);
  position: relative; z-index: 1;
}
.poster-box.no-image .poster-image { display: none; }
.poster-caption {
  margin-top: 14px;
  color: var(--muted);
  font-size: 14px; line-height: 1.8;
  position: relative; z-index: 1;
}
.type-kicker {
  font-size: 12px;
  color: var(--accent-strong);
  margin-bottom: 8px;
  letter-spacing: .06em;
}
.type-name {
  font-size: clamp(30px, 5vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}
.type-subname {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px; line-height: 1.8;
}
.match {
  margin-top: 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 10px 14px;
  background: var(--soft);
  border: 1px solid var(--line);
  color: var(--accent-strong);
  font-weight: 700;
  font-size: 14px; line-height: 1.4;
}
.analysis-box h3, .dim-box h3, .note-box h3 {
  font-size: 16px; margin-bottom: 12px;
}
.analysis-box p {
  margin: 0;
  color: #304034;
  font-size: 15px; line-height: 1.9;
  white-space: pre-wrap;
}
.dim-list { display: grid; gap: 12px; }
.dim-item {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: #fff;
}
.dim-item-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.dim-item-name { font-size: 14px; font-weight: 700; color: var(--text); }
.dim-item-score {
  color: var(--accent-strong);
  font-weight: 800; font-size: 14px;
  white-space: nowrap;
}
.dim-item p {
  margin: 0;
  color: var(--muted);
  font-size: 13px; line-height: 1.8;
}
.note-box p {
  margin: 0;
  color: var(--muted);
  font-size: 13px; line-height: 1.8;
}

/* ---- Author Box ---- */
.author-box {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, #ffffff, #fbfdfb);
  overflow: hidden;
}
.author-box summary {
  list-style: none;
  cursor: pointer;
  padding: 18px;
  font-size: 16px; font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.author-box summary::-webkit-details-marker { display: none; }
.author-box summary::after {
  content: '展开';
  font-size: 12px; font-weight: 700;
  color: var(--accent-strong);
  border: 1px solid var(--line);
  background: var(--soft);
  padding: 6px 10px;
  border-radius: 999px;
  flex-shrink: 0;
}
.author-box[open] summary::after { content: '收起'; }
.author-content {
  border-top: 1px solid var(--line);
  padding: 0 18px 18px;
}
.author-content p {
  margin: 14px 0 0;
  color: #304034;
  font-size: 14px; line-height: 1.9;
}
.result-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 22px;
}

/* ---- SEO Content Sections (Homepage) ---- */
.seo-section {
  margin-top: 32px;
  padding: 28px;
}
.seo-section h2 {
  font-size: clamp(20px, 3vw, 28px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.seo-section p {
  color: #304034;
  font-size: 15px;
  line-height: 1.85;
  margin-bottom: 12px;
}
.seo-section ul {
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.8;
  font-size: 14px;
}

/* ---- FAQ ---- */
.faq-list { display: grid; gap: 12px; }
.faq-item {
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 18px;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 18px; font-weight: 700;
  color: var(--accent-strong);
  flex-shrink: 0;
}
.faq-item[open] summary::after { content: '−'; }
.faq-item .faq-answer {
  padding: 0 18px 16px;
  color: var(--muted);
  font-size: 14px; line-height: 1.85;
}

/* ---- Types Grid (homepage preview / types page) ---- */
.types-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.type-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px;
  background: #fff;
  transition: box-shadow .2s, transform .2s;
  text-align: center;
}
.type-card:hover {
  box-shadow: 0 8px 24px rgba(47,73,55,0.1);
  transform: translateY(-2px);
}
.type-card img {
  width: 80px; height: 80px;
  object-fit: contain;
  border-radius: 12px;
  margin-bottom: 10px;
}
.type-card .type-card-code {
  font-size: 16px; font-weight: 800;
  color: var(--accent-strong);
}
.type-card .type-card-cn {
  font-size: 13px; color: var(--muted);
  margin-top: 4px;
}

/* ---- Ad Slots ---- */
.ad-slot {
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--line);
  border-radius: 14px;
  margin: 20px 0;
  background: var(--soft);
  overflow: hidden;
  position: relative;
}
.ad-slot::before {
  content: attr(data-ad-label);
  position: absolute;
  top: 4px; left: 10px;
  font-size: 10px;
  color: var(--muted);
  opacity: 0.6;
}
.ad-slot.ad-fallback { min-height: 0; border: none; background: none; margin: 0; }
.ad-slot.ad-fallback::before { display: none; }

/* ---- Site Footer ---- */
.site-footer {
  margin-top: 48px;
  padding: 24px 0;
  border-top: 1px solid var(--line);
  text-align: center;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}
.site-footer a { color: var(--accent-strong); }
.site-footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

/* ---- Share Card Modal ---- */
.share-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
.share-modal.open {
  display: flex;
}
.share-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
}
.share-modal-body {
  position: relative;
  z-index: 1;
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(0,0,0,0.2);
  max-width: 420px;
  width: calc(100% - 32px);
  max-height: 90vh;
  overflow-y: auto;
  animation: fadeSlideIn .28s cubic-bezier(.4,0,.2,1) both;
}
.share-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px 0;
}
.share-modal-header h3 {
  font-size: 17px;
  font-weight: 700;
}
.share-modal-close {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--soft);
  border: 1px solid var(--line);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  cursor: pointer;
  transition: background .15s, color .15s;
}
.share-modal-close:hover {
  background: var(--line);
  color: var(--text);
  transform: none;
}
.share-modal-content {
  padding: 16px 20px 20px;
}
.share-hint-mobile {
  display: none;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
  margin-top: 10px;
}
@media (hover: none) and (pointer: coarse) {
  .share-hint-mobile { display: block; }
}
.share-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.share-actions button {
  flex: 1;
  min-width: 0;
  padding: 12px 10px;
  font-size: 14px;
  text-align: center;
  white-space: nowrap;
}
.btn-share-card {
  background: linear-gradient(135deg, #4d6a53, #3a5240) !important;
  box-shadow: 0 6px 20px rgba(58,82,64,.25) !important;
}

/* ---- Social Share Buttons ---- */
.share-social {
  margin-top: 14px;
}
.share-social-label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
  text-align: center;
}
.share-social-btns {
  display: flex;
  gap: 10px;
  justify-content: center;
}
.btn-social {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--soft);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s;
  white-space: nowrap;
}
.btn-social:hover {
  background: #fff;
  border-color: #999;
}
.btn-social:active {
  transform: scale(0.96);
}
.btn-social svg {
  flex-shrink: 0;
}
.btn-social-twitter {
  color: #000;
}
.btn-social-wechat {
  color: #07c160;
}
.btn-social-wechat svg { fill: #07c160; }
.btn-social-xhs {
  color: #ff2442;
}
.btn-social-xhs svg { fill: #ff2442; }

/* ---- Share Card (HTML version) ---- */
.sc {
  border-radius: 16px;
  overflow: hidden;
  padding: 24px 22px 20px;
  background: linear-gradient(170deg, #eaf4eb 0%, #f5faf5 35%, #ffffff 100%);
  position: relative;
  text-align: center;
}
.sc-qr-wrap {
  position: absolute;
  top: 16px; right: 16px;
  width: 66px; height: 66px;
  background: #fff;
  border-radius: 10px;
  border: 1.5px solid #d0e2d3;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.sc-qr-wrap img { width: 56px !important; height: 56px !important; }
.sc .sc-kicker {
  font-size: 13px;
  color: #7a8e7f;
  margin-bottom: 4px;
  text-align: left;
}
.sc .sc-type-code {
  font-size: 44px;
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #1e2a22;
  margin-bottom: 2px;
}
.sc .sc-type-cn {
  font-size: 19px;
  font-weight: 700;
  color: #4d6a53;
  margin-bottom: 14px;
}
.sc-avatar-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 14px;
}
.sc-avatar {
  width: 140px;
  height: 140px;
  object-fit: contain;
  border-radius: 18px;
  background: #fff;
  border: 2px solid #d4e5d7;
  box-shadow: 0 6px 20px rgba(77,106,83,0.1);
}
.sc-avatar-wrap:empty, .sc-avatar[src=""] { display: none; }
.sc .sc-badge {
  display: inline-block;
  padding: 7px 16px;
  border-radius: 999px;
  background: #4d6a53;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 14px;
}
.sc .sc-intro {
  font-size: 15px;
  line-height: 1.7;
  color: #2a3e2e;
  padding: 12px 14px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid #d4e5d7;
  margin-bottom: 10px;
  text-align: left;
}
.sc-desc-box {
  background: rgba(255,255,255,0.85);
  border-radius: 12px;
  border: 1px solid #d4e5d7;
  padding: 14px;
  margin-bottom: 16px;
  text-align: left;
}
.sc-desc-title {
  font-size: 13px;
  font-weight: 700;
  color: #4d6a53;
  margin-bottom: 8px;
}
.sc .sc-desc {
  font-size: 13.5px;
  line-height: 1.8;
  color: #4a5e4e;
}
.sc .sc-footer {
  padding-top: 14px;
  border-top: 1px solid #d4e5d7;
}
.sc .sc-url {
  font-size: 15px;
  font-weight: 700;
  color: #4d6a53;
  margin-bottom: 3px;
}
.sc .sc-cta {
  font-size: 12px;
  color: #8a9c8e;
}

/* ---- Floating Share FAB (Result Page) ---- */
.result-float-bar {
  position: fixed;
  bottom: 24px;
  left: 0;
  right: 0;
  z-index: 100;
  display: none;
  justify-content: center;
  padding-bottom: env(safe-area-inset-bottom, 0px);
  pointer-events: none;
}
.result-float-bar.visible { display: flex; }
@keyframes fabBounceIn {
  from { transform: scale(0) translateY(30px); opacity: 0; }
  to   { transform: scale(1) translateY(0); opacity: 1; }
}
.btn-float-share {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px !important;
  font-size: 14px !important;
  font-weight: 700;
  border-radius: 999px;
  background: linear-gradient(135deg, #4d6a53, #3a5240);
  color: #fff;
  box-shadow: 0 4px 16px rgba(58,82,64,.3), 0 1px 3px rgba(0,0,0,.1);
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: box-shadow .15s;
  pointer-events: auto;
  animation: fabBounceIn .4s cubic-bezier(.34,1.56,.64,1) both;
}
.btn-float-share:hover {
  box-shadow: 0 6px 24px rgba(58,82,64,.35), 0 2px 6px rgba(0,0,0,.1);
}
.btn-float-share svg {
  width: 18px; height: 18px;
  flex-shrink: 0;
}
.btn-native-share {
  background: linear-gradient(135deg, #4d6a53, #3a5240) !important;
  box-shadow: 0 6px 20px rgba(58,82,64,.25) !important;
}

/* ---- Responsive ---- */
@media (max-width: 860px) {
  .hero-grid, .result-top { grid-template-columns: 1fr; }
  .types-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}
@media (max-width: 600px) {
  .shell { padding: 14px 12px 42px; }
  .hero, .test-wrap, .result-wrap, .seo-section { padding: 16px; }
  .hero h1 { font-size: 32px; }
  .question { padding: 18px; }
  .question-title { font-size: 15px; }
  .option { padding: 13px; }
  .test-nav { gap: 8px; }
  .test-nav .btn-primary,
  .test-nav .btn-secondary { padding: 12px 14px; font-size: 14px; }
  .test-nav .btn-quit { padding: 8px 10px; font-size: 12px; }
  .site-header { padding: 10px 0; }
  .types-grid { grid-template-columns: repeat(2, 1fr); }
  .share-modal-body { max-width: 100%; width: calc(100% - 24px); border-radius: 18px; }
  .share-social-btns { flex-wrap: wrap; }
  .btn-social { flex: 1; min-width: 0; justify-content: center; padding: 9px 10px; font-size: 12px; }
  .share-actions { flex-direction: column; }
  .share-actions button { flex: none; width: 100%; }
  .result-float-bar { bottom: 16px; justify-content: flex-end; padding-right: 14px; }
  .btn-float-share { padding: 10px 14px !important; font-size: 13px !important; }
}
