/* Homepage Instagram strip, design proposals A/B/C (views/nd/partials/ig-feed.ejs). Homepage tokens: ink #151515, stone
   #f2f2f2, Rivian's secondary heading 44/48 (phone 36/40), 56px pill buttons, 16px tile radius. Scoped under .igf. */
.igf { --ink: #151515; --muted: #5c5c5c; --stone: #f2f2f2; font-family: Inter, system-ui, sans-serif; letter-spacing: -.32px; }
.igf *, .igf *::before, .igf *::after { box-sizing: border-box; }
.igf ul { list-style: none; margin: 0; padding: 0; }
.igf img { display: block; width: 100%; height: 100%; object-fit: cover; }
.igf a { color: inherit; text-decoration: none; }
.igf-in { max-width: 1360px; margin: 0 auto; padding: 0 16px; }
.igf-h { margin: 0; font-size: 36px; line-height: 40px; font-weight: 600; letter-spacing: -.72px; }
.igf-sub { margin: 10px 0 0; font-size: 16px; line-height: 24px; color: var(--muted); }
.igf-glyph { width: 20px; height: 20px; flex: none; }
.igf .igf-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 28px; border-radius: 999px;
  font-size: 16px; font-weight: 500; white-space: nowrap; transition: background-color .2s, transform .2s; }
.igf .igf-btn:active { transform: scale(.98); }
.igf .igf-btn-ink { background: var(--ink); color: #fff; }
.igf .igf-btn-ink:hover { background: #3d3d3d; }
.igf .igf-btn-white { background: #fff; color: var(--ink); }
.igf .igf-btn-white:hover { background: #e6e6e6; }
.igf :focus-visible { outline: 3px solid currentColor; outline-offset: 3px; border-radius: 12px; }
@media (min-width: 1024px) { .igf-h { font-size: 44px; line-height: 48px; letter-spacing: -.88px; } .igf-in { padding: 0 48px; } }

/* A: six posts in one row on a white band, between the stone reviews and the grey services band */
.igf-a { background: #fff; padding: 64px 0; }
.igf-a .igf-head { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; margin-bottom: 28px; }
.igf .igf-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.igf .igf-row li { aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--stone); }
.igf .igf-row a { position: relative; display: block; width: 100%; height: 100%; }
.igf .igf-row img { transition: transform .6s cubic-bezier(.16, 1, .3, 1), opacity .3s; }
@media (hover: hover) { .igf .igf-row a:hover img { transform: scale(1.05); opacity: .92; } }
.igf-type { position: absolute; top: 10px; right: 10px; width: 22px; height: 22px; color: #fff; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .5)); }
.igf-type svg { width: 100%; height: 100%; }
@media (min-width: 900px) {
  .igf-a { padding: 96px 0; }
  .igf-a .igf-head { flex-direction: row; align-items: flex-end; justify-content: space-between; margin-bottom: 40px; }
  .igf .igf-row { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
  .igf .igf-row li { border-radius: 16px; }
}

/* B: dark reels strip that scrolls sideways, after the dark brands band */
.igf-b { background: #000; color: #fff; padding: 64px 0; }
.igf-head-c { text-align: center; max-width: 640px; margin: 0 auto 32px; }
.igf-b .igf-sub { color: #bdbdbd; }
.igf .igf-reels { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-left: 16px; padding: 0 16px 8px; scrollbar-width: none; }
.igf .igf-reels::-webkit-scrollbar { display: none; }
.igf .igf-reels li { flex: 0 0 62vw; max-width: 280px; scroll-snap-align: start; }
.igf .igf-reels a { display: flex; flex-direction: column; gap: 10px; }
.igf-reel-img { position: relative; display: block; aspect-ratio: 9 / 16; border-radius: 16px; overflow: hidden; background: #1c1c1c; }
.igf-play { position: absolute; left: 14px; bottom: 14px; z-index: 1; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .22); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); color: #fff; }
.igf-play svg { width: 18px; height: 18px; margin-left: 2px; }
.igf-cap { font-size: 15px; line-height: 20px; color: #d6d6d6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.igf-foot { display: flex; justify-content: center; margin-top: 32px; }
@media (hover: hover) { .igf .igf-reels a:hover .igf-play { background: rgba(255, 255, 255, .4); } }
@media (min-width: 900px) {
  .igf-b { padding: 96px 0; }
  .igf-head-c { margin-bottom: 48px; }
  .igf .igf-reels { gap: 14px; padding: 0 48px 8px; padding-left: max(48px, calc((100% - 1360px) / 2 + 48px)); scroll-padding-left: max(48px, calc((100% - 1360px) / 2 + 48px)); }
  .igf .igf-reels li { flex-basis: 260px; }
}

/* C: edge-to-edge mosaic with a Follow pill, right before "Visit us" */
.igf-c { position: relative; background: #000; }
.igf .igf-mosaic { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.igf .igf-mosaic li { aspect-ratio: 1; overflow: hidden; }
.igf .igf-mosaic li:nth-child(n+10) { display: none; } /* a 3x3 square on phones */
.igf .igf-mosaic img { transition: transform .8s cubic-bezier(.16, 1, .3, 1), filter .3s; }
@media (hover: hover) { .igf .igf-mosaic a:hover img { transform: scale(1.06); filter: brightness(1.08); } }
.igf-c::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at center, rgba(0, 0, 0, .35), rgba(0, 0, 0, 0) 60%); }
.igf .igf-pill { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 1; display: flex; align-items: center; gap: 14px;
  padding: 14px 26px 14px 18px; border-radius: 999px; background: #fff; color: var(--ink); box-shadow: 0 12px 40px rgba(0, 0, 0, .28); white-space: nowrap;
  transition: transform .2s; }
.igf .igf-pill:hover { transform: translate(-50%, -50%) scale(1.03); }
.igf .igf-pill .igf-glyph { width: 30px; height: 30px; }
.igf .igf-pill span { display: flex; flex-direction: column; line-height: 1.2; }
.igf .igf-pill b { font-size: 17px; font-weight: 600; letter-spacing: -.4px; }
.igf .igf-pill em { font-style: normal; font-size: 14px; color: var(--muted); }
@media (min-width: 900px) {
  .igf .igf-mosaic { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .igf .igf-mosaic li:nth-child(n+10) { display: block; }
  .igf .igf-pill { padding: 18px 34px 18px 22px; }
  .igf .igf-pill .igf-glyph { width: 36px; height: 36px; }
  .igf .igf-pill b { font-size: 20px; }
  .igf .igf-pill em { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) { .igf img, .igf .igf-pill, .igf .igf-btn { transition: none !important; } }

/* A on phones: the posts first, the Follow button under them; square crops of vertical reels keep the rider */
.igf .igf-row img { object-position: 50% 35%; }
.igf .igf-phone-only { display: inline-flex; margin-top: 24px; }
.igf .igf-wide-only { display: none; }
@media (min-width: 900px) { .igf .igf-phone-only { display: none; } .igf .igf-wide-only { display: inline-flex; } }

/* Dark spots (owner, 2026-11-26): above "Our brands" the strip takes the 1998 band's #252826, which is where the brands band
   gradient starts, so the three read as one dark run; above "Keep exploring" it is black, the colour the engine-size band
   ends on and "Keep exploring" starts from. Heading = the homepage's H2_BIG, button = DARK_BTN, like the bands around it. */
.igf.igf-dark { padding: 56px 0; color: #fff; }
.igf.igf-on-brands { background: #252826; }
.igf.igf-on-explore, .igf.igf-on-afterbrands { background: #000; }
.igf-dark .igf-head-c { display: flex; flex-direction: column; align-items: center; gap: 16px; max-width: 720px; margin: 0 auto 40px; text-align: center; }
.igf-dark .igf-sub-d { max-width: 520px; }
.igf-dark .igf-row li { background: #1c1c1c; }
.igf .igf-foot { position: relative; display: flex; justify-content: center; margin-top: 32px; }
.igf .igf-follow { gap: 10px; }
.igf .igf-arrows { display: none; }
.igf .igf-reel-img .igf-type { top: 12px; right: 12px; }
.igf .igf-reels li { flex-basis: 54vw; max-width: 240px; }
@media (min-width: 900px) {
  .igf.igf-dark { padding: 80px 0; }
  .igf-dark .igf-head-c { margin-bottom: 56px; }
  .igf .igf-foot { margin-top: 40px; }
  .igf .igf-arrows { display: flex; gap: 8px; position: absolute; right: 48px; top: 50%; transform: translateY(-50%); }
  .igf .igf-arrow { width: 40px; height: 40px; display: grid; place-items: center; }
  .igf .igf-reels li { flex-basis: 260px; max-width: none; }
}
/* the white DARK_BTN keeps its dark label (".igf a" would make it inherit the band's white) */
.igf.igf-dark .igf-follow { color: #151515; }
.igf-dark .igf-sub-d { text-wrap: balance; }

/* Dark spots on the homepage's own spacing tokens (review 2026-11-26), the same values "Our brands" and "Keep exploring" use:
   80px side padding up to a 1920px wrap, 80px heading to content (lg:gap-[8rem] / mb-large-l2), gap-8 heading to sub,
   gap-[4rem] content to button, .8rem / 1.7rem tile gaps, normal tracking and text-body100 for the small text. */
.igf.igf-dark { letter-spacing: normal; }
.igf-dark .igf-head-c { gap: 2rem; }
.igf.igf-dark .igf-foot { margin-top: 4rem; }
.igf-dark .igf-row, .igf-dark .igf-reels { gap: .8rem; }
.igf-dark .igf-cap { color: inherit; }
@media (min-width: 900px) {
  .igf-dark .igf-in { max-width: 1920px; padding: 0 80px; }
  .igf-dark .igf-head-c { margin-bottom: 80px; }
  .igf-dark .igf-row, .igf-dark .igf-reels { gap: 1.7rem; }
  .igf.igf-dark .igf-reels { padding-left: max(80px, calc((100% - 1920px) / 2 + 80px)); padding-right: 80px; scroll-padding-left: max(80px, calc((100% - 1920px) / 2 + 80px)); }
  .igf-dark .igf-arrows { right: 80px; }
}
/* phones: the same 20px side edge as the brands and Keep exploring cards (px-medium-m1) */
@media (max-width: 899px) { .igf-dark .igf-in { padding: 0 20px; } .igf.igf-dark .igf-reels { padding-left: 20px; padding-right: 20px; scroll-padding-left: 20px; } }

/* Real videos in the reel cards, and the post viewer (owner, 2026-11-26: "functional, with actual posts and videos") */
.igf .igf-reel-img video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.igf .igf-reel-img .igf-type { z-index: 1; }
.igf-lb { border: 0; padding: 0; margin: 0; width: 100vw; height: 100dvh; max-width: none; max-height: none; background: #0a0a0a; color: #fff; }
.igf-lb::backdrop { background: #0a0a0a; }
.igf-lb[open] { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; }
.igf-lb-stage { display: flex; align-items: center; justify-content: center; max-width: calc(100vw - 32px); }
.igf-lb-stage img, .igf-lb-stage video { display: block; max-width: min(1100px, calc(100vw - 180px)); max-height: calc(100dvh - 170px); width: auto; height: auto; border-radius: 16px; background: #111; }
.igf-lb-meta { display: flex; flex-direction: column; align-items: center; gap: 12px; max-width: 640px; padding: 0 16px; text-align: center; }
.igf-lb-cap { margin: 0; font: 400 16px/24px Inter, system-ui, sans-serif; color: #d6d6d6; text-wrap: balance; }
.igf .igf-lb-link { display: inline-flex; align-items: center; gap: 8px; font: 500 15px/20px Inter, system-ui, sans-serif; color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.igf-lb-x, .igf-lb-nav { position: fixed; display: grid; place-items: center; border: 0; cursor: pointer; color: #fff; background: rgba(255, 255, 255, .12);
  border-radius: 50%; font: 400 30px/1 Inter, system-ui, sans-serif; transition: background-color .2s; }
.igf-lb-x:hover, .igf-lb-nav:hover { background: rgba(255, 255, 255, .24); }
.igf-lb-x { top: 16px; right: 16px; width: 48px; height: 48px; }
.igf-lb-nav { top: 50%; transform: translateY(-50%); width: 56px; height: 56px; font-size: 40px; padding-bottom: 4px; }
.igf-lb-prev { left: 20px; }
.igf-lb-next { right: 20px; }
@media (max-width: 899px) {
  .igf-lb-stage img, .igf-lb-stage video { max-width: calc(100vw - 24px); max-height: calc(100dvh - 230px); }
  .igf-lb-nav { top: auto; bottom: 20px; transform: none; width: 52px; height: 52px; }
  .igf-lb-prev { left: calc(50% - 64px); }
  .igf-lb-next { right: calc(50% - 64px); }
  .igf-lb[open] { padding-bottom: 72px; }
}
/* phones: the close button sits above the post, not on it */
@media (max-width: 899px) { .igf-lb[open] { padding-top: 76px; } .igf-lb-stage img, .igf-lb-stage video { max-height: calc(100dvh - 300px); } }

/* A: 4:5 tiles (Instagram's own grid shape) keep more of a vertical video's frame; corner icons sit on a soft shade */
.igf .igf-row li { aspect-ratio: 4 / 5; }
.igf .igf-row a::after { content: ""; position: absolute; top: 0; right: 0; width: 64px; height: 64px; pointer-events: none;
  background: radial-gradient(circle at 100% 0, rgba(0, 0, 0, .45), rgba(0, 0, 0, 0) 70%); }
.igf .igf-row .igf-type { z-index: 1; }
.igf .igf-reel-img::before { content: ""; position: absolute; top: 0; right: 0; width: 72px; height: 72px; z-index: 1; pointer-events: none;
  background: radial-gradient(circle at 100% 0, rgba(0, 0, 0, .45), rgba(0, 0, 0, 0) 70%); }
.igf .igf-reel-img .igf-type { z-index: 2; }

/* B, owner 2026-11-26: heading only, no captions, 3:4 cards like Instagram's profile grid, one row that scrolls sideways.
   Desktop: 300px cards, four and a bit in view; phones: 62vw, one and a half in view so the row reads as scrollable. */
.igf .igf-reel-img { aspect-ratio: 3 / 4; }
.igf .igf-reels li { flex-basis: 62vw; max-width: 280px; }
@media (min-width: 900px) { .igf .igf-reels li { flex-basis: 300px; max-width: none; } }
/* above "Keep exploring": the engine-size band's own bottom padding already gives the space above the heading */
.igf.igf-on-explore { padding-top: 0; }
