/* =============================================
   eSWIT Case Study — style.css
   ============================================= */

:root {
  --c-bg: #F5F5F7;
  --c-dark: black;
  --c-blue: #1549F3;
  --c-card-dark: #2B2C30;
  --c-muted: #797979;
  --c-border: #E1E1E1;
  --c-stats-bg: #EDEFF5;
  --font: system-ui, -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
  --radius: 18px;
  --max-w: 1120px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--c-bg);
  font-family: var(--font);
  color: var(--c-dark);
  font-size: 16px;
  line-height: 1.6;
}

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

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

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

.divider {
  border: none;
  border-top: 1px solid var(--c-border);
  width: calc(100% - 48px);
  max-width: 1120px;
  margin: 0 auto;
}

.c-muted { color: var(--c-muted); }

.section-num {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-blue);
  margin-bottom: 12px;
}

.caption {
  font-size: 13px;
  color: var(--c-muted);
  text-align: center;
  margin-top: 12px;
  max-width: 370px;
}

/* =============================================
   TOP NAV
   ============================================= */
.topnav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(245,245,247,0.88);
  backdrop-filter: blur(12px);
  padding: 48px 0 36px;
}

.nav-spacer { height: 0; }

.topnav .container { display: flex; align-items: center; }

.topnav__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 21px;
  font-weight: 500;
}

.topnav__avatar {
  width: 40px;
  height: 40px;
  object-fit: cover;
}

/* =============================================
   HERO
   ============================================= */
.hero {
  padding: 80px 0 0;
}

.hero__inner {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hero__title {
  font-family: var(--font);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
  padding-bottom: 64px;
}

.hero__meta {
  font-family: var(--font);
  max-width: 575px;
  margin: 0 auto;
  text-align: center;
  padding-bottom: 64px;
  padding-top: 0;
}

.hero__meta .section-num {
  color: #797979;
  font-size: 24px;
  letter-spacing: 0.02em;
  text-transform: capitalize;
}

.section-num--context {
  color: #797979;
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: capitalize;
}

.hero__context {
  font-family: var(--font);
  font-size: 26px;
  color: var(--c-dark);
  line-height: 1.65;
  margin-top: 8px;
  width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.hero__img {
  display: block;
  width: 100%;
  max-width: 1040px;
  border-radius: 16px;
  align-self: center;
}

.hero__video-wrap {
  display: block;
  width: 100%;
  max-width: 1040px;
  border-radius: 16px;
  overflow: hidden;
  align-self: center;
  line-height: 0;
  transform: translateZ(0);
  margin-bottom: 128px;
}

.hero__video-wrap video {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: -40px;
}

/* =============================================
   SECTION BASE
   ============================================= */
.section {
  padding: 80px 0;
}

.section--center .section__intro {
  text-align: center;
  max-width: 573px;
  margin: 0 auto 56px;
}

.section__title {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700;
  font-synthesis: none;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 20px;
}

.section__title--emphasis {
  font-size: 70px;
  font-weight: 700;
  line-height: 76px;
}

.section__title--stronger {
  font-size: 70px;
  font-weight: 700;
  line-height: calc(76 / 70);
}

.section__title--wide {
  margin-bottom: 32px;
}

.section__subtitle {
  margin-top: 34px;
  max-width: 396px;
  margin-left: auto;
  margin-right: auto;
}

.section__subtitle strong {
  display: block;
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 16px;
}

.section__subtitle p {
  font-size: 16px;
  line-height: 22px;
  color: black;
}

.section__objective {
  margin-top: 22px;
}

.section__objective strong {
  display: inline;
  font-size: inherit;
  margin-bottom: 0;
  font-weight: 600;
  color: var(--c-dark);
}

.section__desc {
  font-size: 14px;
  line-height: 1.7;
  color: var(--c-dark);
  width: 396px;
  margin: 0 auto 16px;
}

/* =============================================
   02. TWO-COL LAYOUT
   ============================================= */
.section__twocol {
  display: grid;
  grid-template-columns: 430px 1fr;
  gap: 80px;
  align-items: start;
}

.section__twocol .section-num {
  color: #797979;
  font-size: 24px;
  letter-spacing: 0.02em;
  text-transform: none;
}

.section__twocol .section__title {
  font-size: clamp(40px, 5vw, 58px);
  line-height: 1.08;
}

.section__body p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--c-dark);
  margin-bottom: 16px;
}

.highlight-question {
  font-size: 16px;
  font-weight: 600;
  color: #1549F3;
  background: #E3E7F7;
  padding: 0;
  line-height: 1.5;
  margin: 24px 0 32px !important;
}

.meta-list { display: flex; flex-direction: column; gap: 0; }

.meta-list__row {
  display: flex;
  gap: 16px;
  padding: 12px 0;
  border-top: 1px solid var(--c-border);
  font-size: 16px;
}

.meta-list__row:last-child { border-bottom: 1px solid var(--c-border); }

.meta-list dt { color: var(--c-muted); min-width: 90px; }
.meta-list dd { font-weight: 500; }

/* =============================================
   STATS CARD
   ============================================= */
.stats-card {
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--c-border);
}

.stats-card__top {
  background: var(--c-stats-bg);
  padding: 32px;
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.stat-bubble {
  background: white;
  border-radius: 50%;
  width: 160px;
  height: 160px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  gap: 6px;
}

.stat-bubble__num {
  font-size: 36px;
  font-weight: 800;
  color: var(--c-blue);
  line-height: 1;
}

.stat-bubble__text {
  font-size: 10px;
  line-height: 1.4;
  color: #555;
}

.stat-tiles {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.stat-tile {
  background: white;
  border-radius: 10px;
  padding: 12px 16px;
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.stat-tile__num {
  font-size: 22px;
  font-weight: 800;
  color: var(--c-blue);
}

.stat-tile__unit {
  font-size: 12px;
  color: var(--c-muted);
}

.stats-card__bottom {
  background: var(--c-blue);
  color: white;
  padding: 24px 32px;
  font-size: 13px;
  line-height: 1.5;
}

.stats-card__bottom strong {
  display: block;
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 4px;
}

.stats-card__bottom p {
  font-size: 13px;
  opacity: 0.85;
  margin-top: 4px;
}

/* =============================================
   03. RESEARCH BOX
   ============================================= */
.research-box {
  background: var(--c-stats-bg);
  border-radius: 20px;
  padding: 36px 50px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  grid-template-areas:
    "intro quote"
    "stats quote";
  column-gap: 64px;
  row-gap: 24px;
  margin-bottom: 48px;
}

.research-box__intro {
  grid-area: intro;
  font-size: 16px;
  font-weight: 400;
  text-align: left;
}

.research-box__stats {
  grid-area: stats;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 26px;
}

.r-stat { display: flex; flex-direction: column; gap: 8px; width: 211px; }

.r-stat__num {
  font-size: 24px;
  font-weight: 800;
  color: black;
  line-height: 1;
}

.r-stat p { font-size: 14px; line-height: 1.55; color: black; }

.research-box__quote {
  grid-area: quote;
  border-top: none;
  border-left: none;
  padding-top: 28px;
  padding-left: 48px;
  text-align: left;
  max-width: 416px;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  font-weight: 500;
}

.research-box__quote p {
  font-size: 24px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.45;
  color: var(--c-dark);
  margin-bottom: 22px;
}

.research-box__quote cite {
  font-size: 16px;
  color: #2d2d2d;
  font-style: normal;
  display: flex;
  align-items: center;
  gap: 12px;
}

.research-box__quote cite img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* KEY POINTS */
.key-points {
  text-align: left;
  display: grid;
  grid-template-columns: 220px 1fr;
  column-gap: 100px;
  align-items: start;
  max-width: 697px;
  margin: 64px auto 0;
}

.key-points__label {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--c-dark);
  margin-bottom: 0;
}

.key-points__list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.key-point {
  background: transparent;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-width: 421px;
}

.key-point strong {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
}

.key-point p {
  font-size: 16px;
  line-height: 1.55;
  color: black;
  max-width: 760px;
}

/* =============================================
   04. PROCESS
   ============================================= */
.screenshot-frame {
  margin-top: 32px;
}

.screenshot-frame img {
  width: 100%;
  border-radius: 16px;
  border: 1px solid rgba(218,218,218,0.8);
}

.workflow {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
  margin-bottom: 40px;
  max-width: 823px;
  margin-left: auto;
  margin-right: auto;
}

.section--workflow .section__title {
  text-align: center;
  line-height: 76px;
  margin-bottom: 52px;
}

.workflow__col { display: flex; flex-direction: column; gap: 28px; width: 346px; }

.workflow__col:last-child { width: 379px; }

.workflow__col strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
}

.workflow__heading--tight {
  margin-bottom: 4px !important;
}

.workflow__heading--tight + .workflow__list {
  margin-top: calc(-28px + 3px);
}

.workflow__col p {
  font-size: 14px;
  line-height: 1.65;
  color: black;
  max-width: 450px;
}

.workflow__list {
  margin: 0;
  padding-left: 26px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.workflow__list li {
  font-size: 14px;
  line-height: 1.65;
  color: black;
}

.workflow__list--spaced {
  gap: 3px;
}

.workflow__list--spaced li strong {
  display: inline;
  margin-bottom: 0;
  font-size: 14px;
}

.screenshot-pair {
  display: grid;
  grid-template-columns: 838fr 1174fr;
  gap: 20px;
  align-items: start;
}

.screenshot-card {
  position: relative;
}

.screenshot-pair img {
  width: 100%;
  height: auto;
  display: block;
}

.screenshot-card--overlay {
  position: relative;
}

.screenshot-card--overlay .caption {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  margin-top: 0;
  text-align: center;
  color: #6f6f73;
  width: calc(100% - 40px);
}

/* FEATURES */
.features {
  display: flex;
  flex-wrap: wrap;
  gap: 96px;
  margin-top: 40px;
  max-width: 100%;
}

.feature {
  background: transparent;
  border: 0px;
  border-radius: 12px;
  padding: 20px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 129px;
  height: 146px;
  font-size: 14px;
  font-weight: 500;
  text-align: center;
  color: black;
}

.feature__icon {
  width: 88px;
  height: 88px;
  object-fit: contain;
}

/* =============================================
   05. PRODUCT CARDS
   ============================================= */
.product-cards {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.product-card {
  background: var(--c-card-dark);
  border-radius: var(--radius);
  padding: 40px 48px;
  color: white;
  overflow: hidden;
}

.product-card__header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin-bottom: 36px;
}

.product-card__title {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.3;
  width: 314px;
}

.product-card__desc {
  font-size: 14px;
  line-height: 20px;
  color: #fff;
}

.product-card__img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.1);
}

.product-card__img--dashboard {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 480px;
  width: 100%;
  border-radius: 12px;
}

.product-card__img--centralized {
  width: calc(100% + 96px);
  max-width: none;
  margin-left: -48px;
  margin-right: -48px;
  margin-top: 0;
  margin-bottom: 0;
  border: none;
  border-radius: 0;
}

.product-card--flush-img .product-card__header {
  margin-bottom: 0;
}

.product-card--flush-img .product-card__sub {
  margin-top: 0;
}

.product-card__sub {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.product-card__lead {
  width: 440px;
  font-size: 14px;
  line-height: 20px;
  color: #fff;
}

.product-card__sub > div > strong {
  display: block;
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 3px;
}

.product-card__sub > div > p {
  font-size: 14px;
  line-height: 20px;
  color: #fff;
  width: 390px;
}

.product-card__screenshots {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-top: 0px;
}

.product-card__screenshots--onboarding {
  display: grid;
  grid-template-columns: minmax(0, 2.5fr) minmax(180px, 1fr) minmax(220px, 1.35fr);
  gap: 16px;
  align-items: start;
}

.product-card__screenshots--onboarding > * {
  align-self: start;
}

.product-card__screenshots img {
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.12);
}

.product-card__shot {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
}

.product-card__shot--large {
  height: 320px;
  object-fit: contain;
}

.product-card__shot--tall {
  height: 320px;
  object-fit: contain;
}

.product-card__screenshots-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.product-card__screenshots-stack--compact {
  height: auto;
  justify-content: flex-start;
  gap: 12px;
  align-self: start;
  padding-top: 18px;
}

.product-card__screenshots-stack--compact .product-card__shot {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.product-card__screenshots--onboarding .product-card__shot,
.product-card__screenshots--onboarding .product-card__screenshots-stack--compact .product-card__shot {
  border: none;
}

.product-card__screenshots--pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.product-card__screenshots--pair img {
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.12);
}

.product-card__sub--triple {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin-top: 48px;
  align-items: start;
}

.product-card__detail {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.product-card__detail p {
  font-size: 14px;
  line-height: 20px;
  color: #fff;
  min-height: 72px;
}

.product-card__detail img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
}

.product-card__screenshots--access-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 6px;
}

.product-card__screenshots--access-top img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  border: none;
}

.product-card__access-bottom {
  margin-top: 20px;
}

.product-card__access-bottom img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 14px;
  border: none;
}

/* =============================================
   06. LEARNINGS
   ============================================= */
.learnings {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  margin-bottom: 56px;
  text-align: left;
  width: 911px;
  margin-left: auto;
  margin-right: auto;
}

.learnings__col { display: flex; flex-direction: column; gap: 8px; width: 415px; }

.learnings__col > strong {
  font-size: 16px !important;
  font-weight: 600;
  display: block;
}

.learnings__col p strong {
  font-size: 14px;
  font-weight: 600;
}

.learnings__col p { font-size: 14px; line-height: 22px; color: black; width: 390px; }

.learnings__list {
  list-style: disc;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.learnings__list li {
  font-size: 14px;
  line-height: 22px;
  color: black;
  width: 390px;
}

.learnings__list li strong {
  font-size: 14px;
  font-weight: 600;
}

.learnings__list {
  list-style: disc;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.learnings__list li {
  font-size: 14px;
  line-height: 22px;
  color: black;
  width: 390px;
}

.learnings__list li strong {
  font-size: 14px;
  font-weight: 600;
}

.events-caption {
  font-size: 15px;
  line-height: 1.6;
  color: #555;
  max-width: 680px;
  margin: 0 auto 40px;
  text-align: center;
}

.divider--before-caption {
  margin-top: 0;
  margin-bottom: 64px;
}

.events-photos {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.events-photos img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid var(--c-border);
}

.divider--after-gallery {
  margin-top: 64px;
}

/* =============================================
   NEXT / FOOTER
   ============================================= */
.section--next {
  padding: 0 0 80px;
  margin-top: 0;
}

.section--next .container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.next__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--c-muted);
  transition: color 0.2s;
}

.next__back:hover { color: var(--c-dark); }

.next__back--home {
  font-size: 24px;
  font-weight: 500;
  color: black;
  gap: 10px;
}

.next__back--home:hover {
  color: #2d2d31;
}

.next-showcase {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}

.next-showcase__copy h2 {
  font-size: 36px;
  font-weight: 500;
  line-height: 46px;
  letter-spacing: -0.03em;
  color: var(--c-dark);
}

.next-project-card {
  min-height: 0;
  background-size: cover;
  background-position: top center;
  border-radius: 16px;
  overflow: hidden;
  gap: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  max-width: 486px;
  width: 100%;
  padding: 32px 0 0 40px;
  justify-self: start;
}

.next-project-card__content {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-right: 32px;
}

.next-project-card .case-card__title,
.next-project-card .case-card__desc,
.next-project-card .tag {
  color: #fff !important;
}

.next-project-card .tag {
  border: 1px solid #fff !important;
}

.next-project-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.next-project-card__image {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 439 / 356;
  height: auto;
  display: block;
  margin-top: auto;
  border-top-left-radius: 8px;
  object-fit: cover;
  object-position: left top;
}

.next-card {
  background: var(--c-stats-bg);
  border: 1px solid var(--c-border);
  border-radius: 20px;
  padding: 40px 48px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: box-shadow 0.2s;
}

.next-card:hover { box-shadow: 0 8px 32px rgba(0,0,0,0.08); }

.next-card h3 {
  font-size: 22px;
  font-weight: 700;
}

.next-card p {
  font-size: 14px;
  color: #555;
  max-width: 500px;
  line-height: 1.6;
}

.case-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.tag {
  display: inline-block;
  padding: 5px 12px;
  background: rgba(21,73,243,0.08);
  color: var(--c-blue);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 900px) {
  .section__twocol,
  .research-box__stats,
  .key-points__list,
  .workflow,
  .learnings,
  .product-card__header,
  .events-photos,
  .next-showcase {
    grid-template-columns: 1fr;
  }

  .screenshot-pair {
    grid-template-columns: 1fr;
  }

  .stat-bubble { width: 120px; height: 120px; }

  .hero__title { font-size: 36px; }

  .container { padding: 0 20px; }

  .section { padding: 56px 0; }

  .product-card { padding: 28px 24px; }

  .events-photos {
    grid-template-columns: 1fr 1fr;
  }

  .next-project-card {
    min-height: 0;
  }

  .next-project-card__content {
    padding: 28px 28px 0;
  }
}
