/* ==========================================================================
   HOME PAGE — page-specific styles (extends main.css)
   ========================================================================== */

/* Stop the whole page from scrolling horizontally (root cause: .app-download uses 100vw) */
html, body {
  overflow-x: hidden;
  max-width: 100%;
}

/* ---- Hero ---- */
.hero {
  min-height: 100vh;
  padding: 0;
  background: linear-gradient(180deg, #fbfcff 0%, #ffffff 100%);
  overflow: hidden; /* prevents the scaled hero-visual from stretching page width and hiding the 3rd stat card */
}
.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  align-items: center;
  min-height: 100vh;
  overflow: hidden;
}
.hero-copy {
  transform: translateY(-18px);
}
.hero-tags {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.03em;
  margin: 18px 0 20px;
}
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 18px 0 0;
  width: 100%;
  max-width: 460px; /* slightly wider row, still contained inside the left column */
}
.hero-stat-card {
  min-width: 0;
  aspect-ratio: 4 / 3; /* wider & shorter than before (was 1/1) */
  padding: 10px 8px;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, #0f5fa8, #123e6b);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.hero-stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}
/* give each card its own dark sky-blue shade so the row feels colourful but cohesive */
.hero-stat-card:nth-child(1) { background: linear-gradient(145deg, #1c6fb0, #0d3a63); }
.hero-stat-card:nth-child(2) { background: linear-gradient(145deg, #1477c2, #0a2e52); }
.hero-stat-card:nth-child(3) { background: linear-gradient(145deg, #2586c9, #103f6e); }

.hero-actions { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero-visual { margin-top: 0; }
.hero-visual__frame { max-height: 520px; }
.hero-stat-value {
  font-size: 22px;
  line-height: 1.1;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}
.hero-stat-card h4 {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 0;
  color: #eaf3ff;
  line-height: 1.3;
}
.hero-tags span:nth-child(1) { color: var(--color-invest); }
.hero-tags span:nth-child(3) { color: var(--color-loan); }
.hero-tags span:nth-child(5) { color: var(--color-insurance); }
.hero-tags .dot { color: var(--color-border); font-weight: 400; }

.hero h1 {
  font-size: 46px;
  line-height: 1.30;
}
.hero h1 span { color: var(--color-primary); }
.hero p.hero-desc {
  color: var(--color-text-muted);
  font-size: 16px;
  max-width: 480px;
  margin: 18px 0 30px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-visual {
  position: relative;
  max-width: 700px;
  width: 100%;
  margin-left: auto;
  transform: scale(1.18);
  transform-origin: bottom right;
}
.hero-visual__frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
  max-height: 610px;
  background: linear-gradient(135deg, #e9f0fd 0%, #f7f4ee 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: linear-gradient(135deg, #e9f0fd 0%, #f7f4ee 100%);
}
.hero-visual__badge {
  position: absolute;
  bottom: -24px;
  right: -16px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card-hover);
  padding: 20px 22px;
  max-width: 220px;
  transform: translateY(-20%);
}
.hero-visual__badge-icons { display: flex; gap: 8px; margin-bottom: 12px; }
.hero-visual__badge-icons span {
  width: 30px; height: 30px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
}
.hero-visual__badge h4 { font-size: 14px; margin-bottom: 4px; }
.hero-visual__badge p { font-size: 12px; color: var(--color-text-muted); }

/* ---- Hero visual slider (Company / Investment / Loan / Insurance) ---- */
.hero-slider {
  overflow: hidden; /* clips slides; outer size/scale/position unchanged from before */
}
.hero-slider__track {
  display: flex;
  width: 100%;
  transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1);
}
.hero-slide {
  flex: 0 0 100%;
  min-width: 0;
  position: relative;
}
/* Company slide (slide 1) keeps the original video frame styling untouched */

/* Service slides (Investment / Loan / Insurance) reuse the same frame box,
   just swap the video for a big centered icon on a tinted brand gradient */
.hero-visual__frame--service {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.hero-visual__frame--service::before,
.hero-visual__frame--service::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}
.hero-visual__frame--service::before {
  width: 62%;
  aspect-ratio: 1/1;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.hero-visual__frame--service::after {
  width: 38%;
  aspect-ratio: 1/1;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.55);
}
.hero-slide--invest .hero-visual__frame--service {
  background: linear-gradient(135deg, var(--color-invest-bg) 0%, #eaf2ff 100%);
}
.hero-slide--loan .hero-visual__frame--service {
  background: linear-gradient(135deg, var(--color-loan-bg) 0%, #fff0f4 100%);
}
.hero-slide--insurance .hero-visual__frame--service {
  background: linear-gradient(135deg, var(--color-insurance-bg) 0%, #eafcf3 100%);
}
.hero-slide__icon {
  width: 38%;
  max-width: 230px;
  height: auto;
  object-fit: contain;
  position: relative;
  z-index: 1;
  border-radius: 22px;
  background: #fff;
  padding: 18px;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.14);
  animation: heroSlideIconIn 0.6s ease both;
}
@keyframes heroSlideIconIn {
  from { opacity: 0; transform: scale(0.85) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.hero-slider__dots {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}
.hero-slider__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: rgba(255, 255, 255, 0.55);
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}
.hero-slider__dot.is-active {
  background: #ffffff;
  transform: scale(1.25);
}

@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; padding: 48px 0; }
  .hero h1 { font-size: 34px; }
  .hero-visual { order: -1; }
  .hero-copy { transform: translateY(-10px); }
}

/* ---- Service Cards (Investment / Loan / Insurance) ---- */
.service-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.service-card {
  border-radius: var(--radius-lg);
  padding: 30px 24px;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-card-hover);
}
.service-card:hover { background-color: var(--color-primary-light); }
.service-card--invest { background: var(--color-invest-bg); }
.service-card--loan { background: var(--color-loan-bg); }
.service-card--insurance { background: var(--color-insurance-bg); }

.service-card__icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  overflow: hidden;
}
.service-card__icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.service-card--invest .service-card__icon { background: var(--color-invest); }
.service-card--loan .service-card__icon { background: var(--color-loan); }
.service-card--insurance .service-card__icon { background: var(--color-insurance); }

.service-card h3 { font-size: 21px; margin-bottom: 6px; }
.service-card--invest h3 { color: var(--color-invest); }
.service-card--loan h3 { color: var(--color-loan); }
.service-card--insurance h3 { color: var(--color-insurance); }
.service-card > p { font-size: 14px; color: var(--color-text-muted); margin-bottom: 20px; }

.service-card__list { margin-bottom: 26px; }
.service-card__list li {
  display: flex; align-items: center; gap: 10px;
  font-size: 14px; margin-bottom: 12px; color: var(--color-text);
}
.service-card__list li svg { flex-shrink: 0; }
.service-card--invest .service-card__list li svg { color: var(--color-invest); }
.service-card--loan .service-card__list li svg { color: var(--color-loan); }
.service-card--insurance .service-card__list li svg { color: var(--color-insurance); }

.service-card .btn { width: 100%; }
.service-card--invest .btn { background: var(--color-invest); color: #fff; }
.service-card--loan .btn { background: var(--color-loan); color: #fff; }
.service-card--insurance .btn { background: var(--color-insurance); color: #fff; }

@media (max-width: 900px) {
  .service-cards { grid-template-columns: 1fr; }
}

/* ---- Feature strip (4 cols) ---- */
.feature-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  background: var(--color-bg-alt);
  border-radius: var(--radius-lg);
  padding: 40px;
}
.feature-strip__item { display: flex; gap: 14px; }
.feature-strip__icon {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--color-primary-light);
  color: var(--color-primary);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.feature-strip__item h4 { font-size: 15px; margin-bottom: 6px; }
.feature-strip__item p { font-size: 13px; color: var(--color-text-muted); line-height: 1.6; }

@media (max-width: 900px) {
  .feature-strip { grid-template-columns: 1fr 1fr; padding: 28px; }
}
@media (max-width: 560px) {
  .feature-strip { grid-template-columns: 1fr; }
}

/* ---- How It Works (steps) ---- */
.steps-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  position: relative;
}
.step-item { text-align: center; padding: 0 16px; position: relative; }
.step-item__icon-wrap { position: relative; display: inline-block; margin-bottom: 18px; }
.step-item__icon {
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--color-primary-light);
  color: var(--color-primary);
  display: flex; align-items: center; justify-content: center;
}
.step-item__num {
  position: absolute; top: -6px; left: -6px;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  font-family: var(--font-heading); font-weight: 700; font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  border: 3px solid #fff;
}
.step-item:nth-child(2) .step-item__num { background: var(--color-loan); }
.step-item:nth-child(3) .step-item__num { background: var(--color-insurance); }
.step-item:nth-child(4) .step-item__num { background: var(--color-primary); }
.step-item h4 { font-size: 16px; margin-bottom: 8px; }
.step-item p { font-size: 13px; color: var(--color-text-muted); }
.step-arrow {
  position: absolute; top: 36px; right: -8%;
  color: var(--color-border);
}

@media (max-width: 900px) {
  .steps-row { grid-template-columns: 1fr 1fr; row-gap: 40px; }
  .step-arrow { display: none; }
}
@media (max-width: 560px) {
  .steps-row { grid-template-columns: 1fr; }
}

/* ---- Journey + Enquiry split ---- */
.journey-enquiry {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: stretch;
}
.journey-panel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #111;
}
.journey-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/identify-your-financial-goals.jpg") center/cover no-repeat;
  transform: scale(1.05);
  opacity: 1;
  z-index: 0;
}
.journey-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 0;
}
.journey-panel > * { position: relative; z-index: 1; }
.journey-panel h2 { color: #fff; font-size: 28px; margin-bottom: 14px; }
.journey-panel p { color: rgba(255, 255, 255, 0.88); margin-bottom: 26px; max-width: 420px; }
.journey-panel__visual {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 32px;
}
.journey-coin-stack { display: flex; align-items: flex-end; gap: 4px; }
.journey-coin-stack span {
  width: 14px; border-radius: 3px 3px 0 0;
  background: linear-gradient(180deg, #f4c542, #d89e1f);
}

.enquiry-panel {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-card);
}
.enquiry-panel h3 { font-size: 22px; margin-bottom: 22px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.form-field label {
  display: block; font-size: 13px; font-weight: 600;
  color: var(--color-text); margin-bottom: 6px;
}
.form-field input {
  width: 100%; padding: 13px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: 14px;
  background: var(--color-bg-alt);
}
.form-field input:focus { outline: 2px solid var(--color-primary); background: #fff; }
.radio-row { display: flex; gap: 24px; margin: 8px 0 22px; }
.radio-option { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.radio-option input { accent-color: var(--color-primary); width: 16px; height: 16px; }

@media (max-width: 900px) {
  .journey-enquiry { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}

/* ---- Trust stats strip ---- */
.trust-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  background: var(--color-bg-alt);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
}
.trust-item { display: flex; align-items: center; gap: 14px; }
.trust-item__icon {
  width: 46px; height: 46px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  background: var(--color-primary-light);
  color: var(--color-primary);
}
.trust-item h4 { font-size: 15px; color: var(--color-navy); margin-bottom: 3px; }
.trust-item p { font-size: 12.5px; color: var(--color-text-muted); }

@media (max-width: 900px) { .trust-strip { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .trust-strip { grid-template-columns: 1fr; } }

/* ---- Insights preview ---- */
.insights-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 32px;
}
.insight-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--color-border);
  transition: background-color 0.2s ease;
}
.insight-card:hover { background-color: var(--color-primary-light); }
.insight-card__img {
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, var(--color-primary-light), #f7f4ee);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.insight-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.insight-card__body { padding: 18px 20px 22px; }
.insight-card__body h4 { font-size: 15px; margin-bottom: 10px; line-height: 1.5; }
.insight-card__body a {
  font-size: 13.5px; font-weight: 600; color: var(--color-primary);
  display: inline-flex; align-items: center; gap: 6px;
}
.insights-footer { text-align: center; }

/* ---- App download ---- */
.app-download {
  background: var(--color-primary-light);
  border-radius: 0;
  padding: 44px 48px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: center;
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
.app-download__phone {
  width: 90px; height: 130px;
  background: var(--color-navy);
  border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.app-download__text h3 { font-size: 22px; margin-bottom: 6px; }
.app-download__text p { color: var(--color-text-muted); font-size: 14px; margin-bottom: 18px; }
.app-download__features { display: flex; gap: 22px; flex-wrap: wrap; }
.app-download__features span {
  display: flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 600; color: var(--color-navy);
}
.app-download__stores { display: flex; flex-direction: column; gap: 10px; }
.store-badge {
  display: flex; align-items: center; gap: 10px;
  background: #111; color: #fff;
  padding: 10px 18px; border-radius: var(--radius-sm);
  font-size: 12px;
}
.store-badge strong { display: block; font-size: 14px; font-family: var(--font-heading); }

@media (max-width: 900px) {
  .app-download { grid-template-columns: 1fr; text-align: center; }
  .app-download__phone { margin: 0 auto; }
  .app-download__features { justify-content: center; }
  .app-download__stores { flex-direction: row; justify-content: center; }
}