/* ==========================================================================
   Suria Crestway Sdn. Bhd. — About Us page
   Standalone from the homepage stylesheet on purpose: this ships as its own
   WordPress plugin, so it carries its own tokens, reset and entrance rules
   rather than depending on css/style.css being enqueued.

   Everything is scoped under .sc-about and prefixed .sc- so it can be dropped
   into a shortcode without fighting the active theme.

   IMAGE RULES ARE PREFIXED `.sc-about` ON PURPOSE — don't "simplify" them.
   Page builders ship a blanket image reset at the same specificity as a plain
   component rule. Elementor's is

       .elementor img { border:none; border-radius:0; box-shadow:none;
                        height:auto; max-width:100% }

   which is (0,1,1) — identical to `.sc-pagehero__media img`. A plugin
   stylesheet is enqueued before the theme's and before Elementor's, so on an
   equal-specificity tie the later sheet wins and every image depending on a
   CSS height collapses. The `.sc-about` prefix makes these (0,2,1), which wins
   on specificity and so holds regardless of load order.
   ========================================================================== */

.sc-about {
  /* Brand */
  --sc-brand:      #262aad;
  --sc-brand-dark: #1c1f8a;
  --sc-brand-tint: #eef0fb;
  --sc-brand-tint2:#e3e7f8;
  --sc-accent:     #f42e39;

  /* Neutrals */
  --sc-navy:  #070a26;
  --sc-ink:   #0e1130;
  --sc-ink-2: #474c6d;
  --sc-ink-3: #7a7f9c;
  --sc-line:  #e3e6f1;
  --sc-cream: #f8f7f4;
  --sc-paper: #ffffff;

  /* Layout */
  --sc-w: 1340px;

  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: var(--sc-ink-2);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* --- reset (scoped) ------------------------------------------------------
   Wrapped in :where() so it carries ZERO specificity. Without this the
   reset outranks the component classes below (and would, for example,
   repaint .sc-pagehero__title with the default heading colour).         */
.sc-about *,
.sc-about *::before,
.sc-about *::after { box-sizing: border-box; }

:where(.sc-about) :where(h1, h2, h3, p, figure) { margin: 0; }
:where(.sc-about) :where(img) { display: block; max-width: 100%; }
:where(.sc-about) :where(a) { color: inherit; text-decoration: none; }

:where(.sc-about) :where(h1, h2, h3) {
  font-family: "Archivo", "Inter", sans-serif;
  color: var(--sc-ink);
  font-weight: 600;
}

/* The helpers below (.sc-container, .sc-i, .sc-h2, .sc-eyebrow, .sc-dot) share
   their names with css/style.css in the header/home/footer plugin. They are
   PREFIXED `.sc-about` on purpose so the two stylesheets can coexist on one
   page: unprefixed, the two sheets would be an equal-specificity tie that load
   order decides, and their responsive overrides differ (this page takes .sc-h2
   to 22px on mobile, the homepage sheet takes it to 23px) — so whichever loaded
   last would silently restyle the other plugin's sections. Don't unprefix them. */

/* 1340px fixed, matching the homepage. Below that the safety inset keeps
   content off the viewport edge. */
.sc-about .sc-container {
  width: var(--sc-w);
  max-width: 100%;
  margin-inline: auto;
}
@media (max-width: 1379px) {
  .sc-about .sc-container { padding-inline: 24px; }
}

.sc-about .sc-i { width: 1em; height: 1em; fill: none; stroke: currentColor;
        stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
        flex: none; }

/* --- shared type --------------------------------------------------------- */
.sc-about .sc-h2 {
  font-size: 33px;
  line-height: 1.36;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.sc-about .sc-eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--sc-ink);
}
.sc-about .sc-eyebrow__dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--sc-accent);
  flex: none;
}


/* ==========================================================================
   1. PAGE HERO BANNER — 50vh
   ========================================================================== */
.sc-pagehero {
  position: relative;
  background: var(--sc-navy);
  min-height: 50vh;
  min-height: 50svh;
  display: flex;
  align-items: flex-end;
  padding-top: 150px;   /* clears the fixed site header */
  padding-bottom: 66px;
  isolation: isolate;
}
.sc-pagehero__media {
  position: absolute; inset: 0; z-index: -2;
  overflow: hidden;
}
.sc-about .sc-pagehero__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}

/* Same two-layer recipe as the homepage hero: a directional wash that keeps
   the left-hand type readable, plus a vertical pass so the header sits on
   something dark at the top and the section joint reads at the bottom. */
.sc-pagehero__scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(98deg,
      rgba(7,10,38,.94) 0%,
      rgba(7,10,38,.86) 26%,
      rgba(8,14,44,.62) 46%,
      rgba(8,16,48,.34) 64%,
      rgba(8,18,52,.24) 100%),
    linear-gradient(to bottom, rgba(7,10,38,.55) 0%, rgba(7,10,38,0) 32%, rgba(7,10,38,.3) 100%);
}

.sc-pagehero__inner { position: relative; }

.sc-pagehero__sub {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: rgba(255,255,255,.82);
}
.sc-pagehero__sub .sc-dot-mark {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--sc-accent);
  flex: none;
}

/* Matches .sc-hero__title on the homepage exactly — the banner headline is the
   page's opening statement, so it keeps the hero scale rather than dropping to
   the 33px .sc-h2 used by the section headings below it. */
.sc-pagehero__title {
  margin-top: 22px;
  max-width: 900px;
  font-size: 50px;
  line-height: 1.12;
  font-weight: 500;
  letter-spacing: -0.028em;
  color: #fff;
}
.sc-pagehero__title strong { font-weight: 700; }
.sc-about .sc-dot { color: var(--sc-accent); }


/* ==========================================================================
   2. CAPABILITIES — centred head + four cards
   ========================================================================== */
.sc-abfeat { background: #fff; padding: 104px 0 96px; }

.sc-abfeat__head {
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}
.sc-abfeat__head .sc-eyebrow { justify-content: center; }
.sc-abfeat__head .sc-h2 { margin-top: 18px; }
/* Targeted by class, NOT `.sc-abfeat__head p` — the eyebrow above is also a
   <p>, and a descendant element selector (0,1,1) outranks .sc-eyebrow (0,1,0),
   so a bare `p` rule here silently repaints the eyebrow at this size/colour. */
.sc-abfeat__lede {
  margin-top: 18px;
  font-size: 15px;
  line-height: 1.72;
  color: var(--sc-ink-3);
}

.sc-abfeat__grid {
  margin-top: 54px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.sc-abcard {
  background: var(--sc-cream);
  border: 1px solid #efeee9;
  border-radius: 8px;
  padding: 26px 26px 30px;
  transition: background-color .24s ease, border-color .24s ease, transform .24s ease;
}
.sc-abcard:hover {
  background: #fff;
  border-color: var(--sc-brand-tint2);
  transform: translateY(-3px);
}
.sc-abcard__icon {
  width: 46px; height: 46px;
  border-radius: 8px;
  background: var(--sc-brand);
  color: #fff;
  display: grid;
  place-items: center;
  transition: background-color .24s ease;
}
.sc-abcard__icon .sc-i { font-size: 21px; }
.sc-abcard:hover .sc-abcard__icon { background: var(--sc-brand-dark); }
.sc-abcard h3 {
  margin-top: 44px;
  font-size: 16.5px;
  letter-spacing: -0.012em;
}
.sc-abcard p {
  margin-top: 11px;
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--sc-ink-3);
}


/* ==========================================================================
   3. OUR STORY — image left, content right
   ========================================================================== */
.sc-story { background: var(--sc-cream); padding: 100px 0 108px; }

.sc-story__grid {
  display: grid;
  grid-template-columns: 560px 1fr;
  gap: 72px;
  align-items: center;
}

/* Positioning context for the floating readout panel, which is a sibling of
   the figure rather than a child of it. */
.sc-story__media { position: relative; }

.sc-story__visual {
  border-radius: 8px;
  overflow: hidden;
  background: #eceef5;
  aspect-ratio: 1 / 1;
}
.sc-about .sc-story__visual img { width: 100%; height: 100%; object-fit: cover; }

/* Floating readout panel over the photograph — the reference layout's inset
   card. Frosted rather than solid so the image still reads behind it. */
.sc-readout {
  position: absolute;
  left: 26px; right: 26px; top: 26px;
  padding: 20px 22px 22px;
  border-radius: 8px;
  background: rgba(255,255,255,.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.6);
  box-shadow: 0 18px 40px -22px rgba(7,10,38,.5);
}
.sc-readout__title {
  font-family: "Archivo", sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--sc-ink);
}
.sc-readout__rows { margin-top: 16px; display: grid; gap: 11px; }
.sc-readout__row {
  display: grid;
  grid-template-columns: 1fr 100px 40px;
  align-items: center;
  gap: 12px;
  font-size: 12.5px;
  color: var(--sc-ink-2);
}
.sc-readout__track {
  height: 5px;
  border-radius: 3px;
  background: #e6e8f1;
  overflow: hidden;
}
.sc-readout__fill {
  display: block;
  height: 100%;
  border-radius: 3px;
  background: var(--sc-brand);
}
.sc-readout__val {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--sc-ink-3);
}

/* No max-width: the column already sets the measure. Capping it here left a
   dead gutter on the right and stopped the stats rule short of the column edge. */
.sc-story__body .sc-h2 { margin-top: 18px; }
.sc-story__lede {
  margin-top: 22px;
  font-size: 15px;
  line-height: 1.78;
  color: var(--sc-ink-3);
}

.sc-checks {
  margin-top: 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 28px;
}
.sc-check {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--sc-ink);
}
.sc-check__mark {
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--sc-brand);
  color: #fff;
  display: grid;
  place-items: center;
  flex: none;
}
.sc-check__mark .sc-i { font-size: 13px; stroke-width: 2.6; }

.sc-story__stats {
  margin-top: 46px;
  padding-top: 34px;
  border-top: 1px solid #e7e6e0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.sc-story__stat .sc-story__num {
  display: block;
  font-family: "Archivo", sans-serif;
  font-size: 38px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--sc-ink);
}
.sc-story__stat .sc-story__label {
  display: block;
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--sc-ink-3);
}


/* ==========================================================================
   Responsive — the design width is 1340px; these keep it usable below that
   ========================================================================== */
@media (max-width: 1200px) {
  .sc-pagehero__title { font-size: 44px; }
  .sc-abfeat__grid { grid-template-columns: 1fr 1fr; }
  .sc-story__grid { grid-template-columns: 1fr; gap: 44px; }
  .sc-story__visual { aspect-ratio: 16 / 10; }
}

@media (max-width: 900px) {
  .sc-pagehero { min-height: 0; padding-top: 96px; padding-bottom: 52px; }
  .sc-pagehero__title { font-size: 38px; }
  .sc-about .sc-pagehero__media img { object-position: 70% 50%; }
  .sc-abfeat { padding: 72px 0 66px; }
  .sc-abfeat__grid { margin-top: 40px; }
  .sc-story { padding: 72px 0 78px; }

  /* Stop floating the panel over the photo. Overlaid, it grew taller than the
     image and hid it completely — a four-row readout simply doesn't fit inside
     a narrow 16:10 frame. Below the photo it gets its own space and the
     photograph stays fully visible. */
  .sc-readout {
    position: static;
    margin-top: 14px;
    background: #fff;
    border: 1px solid var(--sc-line);
    box-shadow: 0 2px 10px -4px rgba(14, 17, 48, .1);
  }
}

@media (max-width: 620px) {
  /* Banner headline stays the largest type on the page at 30px; every section
     heading drops to 22px. */
  .sc-pagehero__title { font-size: 30px; }
  .sc-about .sc-h2 { font-size: 22px; }
  .sc-abfeat__grid { grid-template-columns: 1fr; }
  .sc-checks { grid-template-columns: 1fr; }
  .sc-readout { padding: 16px 18px 18px; }
  /* Narrower bar so label, bar and value still share one row at 390px. */
  .sc-readout__row { grid-template-columns: 1fr 68px 34px; gap: 10px; }
  .sc-story__stats { grid-template-columns: 1fr 1fr; gap: 26px 18px; }
  .sc-story__stat .sc-story__num { font-size: 31px; }
}


/* ==========================================================================
   ENTRANCE ANIMATION
   [data-anim] elements rise/fade in as they scroll into view. The resting
   state here is fully VISIBLE — the hidden state only exists under
   .sc-anim-on, which js/about.js adds. So with JS off, JS broken, or
   IntersectionObserver missing, every element just renders normally.
   Stagger comes from --sc-d, set per element by the same module.
   ========================================================================== */
.sc-about.sc-anim-on [data-anim] {
  opacity: 0;
}
.sc-about.sc-anim-on [data-anim="up"]    { transform: translateY(22px); }
.sc-about.sc-anim-on [data-anim="left"]  { transform: translateX(-26px); }
.sc-about.sc-anim-on [data-anim="scale"] { transform: scale(.965); }

/* Transition lives on the "in" state only, so applying the hidden state at
   startup can't animate backwards from visible. */
.sc-about.sc-anim-on [data-anim].sc-anim-in {
  opacity: 1;
  transform: none;
  transition:
    opacity .72s cubic-bezier(.22,.61,.36,1) var(--sc-d, 0ms),
    transform .72s cubic-bezier(.22,.61,.36,1) var(--sc-d, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  .sc-about *, .sc-about *::before, .sc-about *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }
  /* Never leave anything hidden waiting on a transition that won't run. */
  .sc-about.sc-anim-on [data-anim] {
    opacity: 1 !important;
    transform: none !important;
  }
}
