/* Beibu Gulf Insurance — Apple-inspired claims story page */

:root {
  --bg: #f5f5f7;
  --bg-elevated: #ffffff;
  --ink: #1d1d1f;
  --ink-secondary: #6e6e73;
  --ink-tertiary: #86868b;
  --line: rgba(0, 0, 0, 0.08);
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --accent-deep: #0a4d8c;
  --gold: #b08d3a;
  --radius: 18px;
  --nav-h: 64px;
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei",
    sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.47;
  font-weight: 400;
  letter-spacing: -0.01em;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ——— Nav ——— */
.site-nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.25rem, 4vw, 2.5rem);
  background: rgba(245, 245, 247, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.site-nav.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(245, 245, 247, 0.88);
}

.brand img {
  height: 36px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-secondary);
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-cta {
  color: #fff !important;
  background: var(--accent);
  padding: 0.45rem 0.95rem;
  border-radius: 980px;
  transition: background 0.2s var(--ease), transform 0.15s var(--ease);
}

.nav-cta:hover {
  background: var(--accent-hover);
}

.nav-cta:active {
  transform: scale(0.98);
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 0;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.25s var(--ease);
}

.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3.75px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3.75px) rotate(-45deg);
}

/* ——— Hero ——— */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--nav-h) + 2rem) clamp(1.25rem, 5vw, 4rem) 4.5rem;
  color: #fff;
  isolation: isolate;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 35% 40%;
  transform: scale(1.06);
  transition: transform 1.2s var(--ease);
}

.hero.is-ready .hero-img {
  transform: scale(1);
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      105deg,
      rgba(8, 18, 32, 0.78) 0%,
      rgba(8, 18, 32, 0.45) 48%,
      rgba(8, 18, 32, 0.25) 100%
    ),
    linear-gradient(to top, rgba(8, 18, 32, 0.7) 0%, transparent 45%);
}

.hero-content {
  max-width: 36rem;
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease) 0.15s, transform 0.9s var(--ease) 0.15s;
}

.hero.is-ready .hero-content {
  opacity: 1;
  transform: none;
}

.brand-mark {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #fff;
  margin-bottom: 0.85rem;
}

.hero h1 {
  font-size: clamp(2.75rem, 7vw, 4.75rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.05;
  margin-bottom: 1.1rem;
}

.hero-sub {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.88);
  max-width: 28ch;
  margin-bottom: 1.75rem;
  font-weight: 400;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.7rem 1.35rem;
  border-radius: 980px;
  font-size: 0.9375rem;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.2s var(--ease), color 0.2s var(--ease),
    transform 0.15s var(--ease), border-color 0.2s var(--ease);
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(8px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* ——— Sections ——— */
.section {
  padding: clamp(4.5rem, 10vw, 7.5rem) clamp(1.25rem, 5vw, 4rem);
}

.section-inner {
  max-width: 1080px;
  margin: 0 auto;
}

.section h2 {
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.lead {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: var(--ink-secondary);
  max-width: 38rem;
  line-height: 1.5;
  margin-bottom: 3rem;
}

/* Story */
.story {
  background: var(--bg-elevated);
}

.story-figure {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: #e8e8ed;
}

.story-figure img {
  width: 100%;
  aspect-ratio: 16 / 11;
  object-fit: cover;
  object-position: center 30%;
}

.story-figure figcaption {
  padding: 1rem 1.25rem 1.25rem;
  font-size: 0.875rem;
  color: var(--ink-tertiary);
  background: var(--bg-elevated);
  border-top: 1px solid var(--line);
}

/* Quote */
.quote-band {
  padding: clamp(4rem, 9vw, 6.5rem) clamp(1.25rem, 5vw, 4rem);
  background: var(--accent-deep);
  color: #fff;
}

.quote-band blockquote {
  max-width: 820px;
  margin: 0 auto;
  text-align: center;
}

.quote-band p {
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.35;
  margin-bottom: 1.25rem;
}

.quote-band cite {
  font-style: normal;
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.65);
}

/* Process chapters */
.process {
  background: var(--bg);
}

.chapter {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  padding: 3rem 0;
  border-top: 1px solid var(--line);
}

.chapter:last-child {
  padding-bottom: 0;
}

.chapter-flip .chapter-text {
  order: 2;
}

.chapter-flip .chapter-visual {
  order: 1;
}

.chapter-num {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.06em;
  margin-bottom: 0.75rem;
}

.chapter h3 {
  font-size: clamp(1.5rem, 2.5vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 0.85rem;
}

.chapter-text p {
  font-size: 1.0625rem;
  color: var(--ink-secondary);
  line-height: 1.65;
  max-width: 36ch;
}

.chapter-visual {
  border-radius: var(--radius);
  overflow: hidden;
  background: #e8e8ed;
  min-height: 280px;
}

.chapter-visual img {
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
}

.chapter-visual--dark {
  background: #1d1d1f;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 2.5rem;
  min-height: 320px;
}

.metric-list {
  list-style: none;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.metric-list li {
  display: grid;
  gap: 0.25rem;
}

.metric-list strong {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.metric-list span {
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.6);
}

.chapter-visual--stat {
  background: linear-gradient(160deg, #0a4d8c 0%, #0071e3 100%);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 320px;
  padding: 2rem;
}

.big-stat {
  font-size: clamp(4.5rem, 10vw, 6.5rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1;
}

.big-stat span {
  font-size: 0.35em;
  font-weight: 600;
  margin-left: 0.15em;
  letter-spacing: -0.02em;
}

.big-stat-label {
  margin-top: 0.75rem;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.75);
}

/* Promise */
.promise {
  background: var(--bg-elevated);
}

.promise-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
}

.promise-item {
  padding: 2rem 1.5rem 0.5rem 0;
  border-right: 1px solid var(--line);
}

.promise-item:last-child {
  border-right: 0;
  padding-right: 0;
}

.promise-item:not(:first-child) {
  padding-left: 1.5rem;
}

.promise-item h3 {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.65rem;
}

.promise-item p {
  font-size: 1rem;
  color: var(--ink-secondary);
  line-height: 1.55;
  max-width: 22ch;
}

/* Expert */
.expert {
  background: var(--bg);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

.expert-layout {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.expert-copy h2 {
  margin-bottom: 1.1rem;
}

.expert-copy p {
  font-size: 1.125rem;
  color: var(--ink-secondary);
  line-height: 1.6;
  max-width: 32ch;
  margin-bottom: 1.75rem;
}

.expert-visual {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: #0071e3;
  box-shadow: 0 24px 60px rgba(0, 65, 140, 0.18);
}

.expert-visual img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* Contact */
.contact {
  padding: clamp(5rem, 12vw, 8rem) clamp(1.25rem, 5vw, 4rem);
  background: #000;
  color: #fff;
  text-align: center;
}

.contact-inner {
  max-width: 640px;
  margin: 0 auto;
}

.contact h2 {
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
}

.contact p {
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.55;
  margin-bottom: 2rem;
}

.phone {
  display: inline-block;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--accent);
  margin-bottom: 1.5rem;
  transition: color 0.2s var(--ease);
}

.phone:hover {
  color: #2997ff;
}

.contact-note {
  font-size: 0.9375rem !important;
  color: rgba(255, 255, 255, 0.45) !important;
  margin-bottom: 0 !important;
}

/* Footer */
.site-footer {
  background: #000;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2.5rem clamp(1.25rem, 5vw, 4rem) 3rem;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
}

.footer-inner {
  max-width: 640px;
  margin: 0 auto;
}

.footer-logo {
  margin: 0 auto 1rem;
  height: 32px;
  width: auto;
  filter: grayscale(1) brightness(2);
  opacity: 0.7;
}

.site-footer p {
  font-size: 0.875rem;
  margin-bottom: 0.35rem;
}

.footer-meta {
  font-size: 0.6875rem !important;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
}

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ——— Responsive ——— */
@media (max-width: 900px) {
  .chapter,
  .chapter-flip {
    grid-template-columns: 1fr;
  }

  .chapter-flip .chapter-text,
  .chapter-flip .chapter-visual {
    order: unset;
  }

  .chapter-text p {
    max-width: none;
  }

  .promise-grid {
    grid-template-columns: 1fr;
  }

  .promise-item {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 1.75rem 0;
  }

  .promise-item:not(:first-child) {
    padding-left: 0;
  }

  .promise-item:last-child {
    border-bottom: 0;
  }

  .promise-item p {
    max-width: none;
  }

  .expert-layout {
    grid-template-columns: 1fr;
  }

  .expert-copy p {
    max-width: none;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem 1.25rem 1.25rem;
    background: rgba(245, 245, 247, 0.96);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--line);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
  }

  .nav-links.is-open {
    transform: none;
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links a {
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--line);
    font-size: 1rem;
  }

  .nav-cta {
    margin-top: 0.75rem;
    text-align: center;
    border-bottom: 0 !important;
  }

  .hero {
    align-items: flex-end;
    padding-bottom: 3rem;
    min-height: 92dvh;
  }

  .hero h1 {
    font-size: clamp(2.4rem, 11vw, 3.25rem);
  }

  .hero-sub {
    max-width: none;
  }

  .story-figure img {
    aspect-ratio: 4 / 5;
    object-position: center 20%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-content,
  .hero-img,
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
