/* Instagram screens drawn in HTML and CSS, for the phones on the home page's social section and the social media page
   (David 10/27: "make it super realistic, like actual Instagram posts"). Six screens: a profile (.ig--profile), a feed
   post (.ig--post), a reel (.ig--reel), a story (.ig--story), a comments sheet (.ig--comments) and a message thread
   (.ig--dm). Rules for what goes in them: the clients' own photos and video only; a
   handle only where the client's own website links to that account, otherwise the business name with no @; captions
   and bios in the client's own words from their site; no counts of any kind (likes, followers, views, posts) and no
   times. The comments and the messages are an invented example: the page labels them as one, the customer has a made-up
   first name and the default avatar, and no client is named in them. The page says near the phones that they are mock-ups. Every size is in em off one font size that follows the
   screen's width (container query units), so the same markup fits any phone frame. The screens are decoration: the
   page marks each phone aria-hidden and data-client-words. */
.ig {
  container-type: inline-size; position: relative; width: 100%; height: 100%; overflow: hidden; background: #000;
  color: #f5f5f5; text-align: left; letter-spacing: normal;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.ig-in { position: absolute; inset: 0; display: flex; flex-direction: column; padding-bottom: 4.6em; font-size: 9px; line-height: 1.32; }
@supports (font-size: 1cqi) {
  .ig-in { font-size: 4.1cqi; }
}
.ig b { font-weight: 600; }
.ig img { display: block; }
.ig-i { flex: none; width: 1.9em; height: 1.9em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ig-i--fill { fill: currentColor; stroke: none; }

/* The bar at the top: back, the handle or the screen's name, and the icons on the right. */
.ig-top { flex: none; display: flex; align-items: center; gap: .7em; padding: 2.9em 1.1em .9em; }
.ig-handle, .ig-title { font-size: 1.24em; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-top-r { margin-left: auto; display: flex; align-items: center; gap: 1em; }

/* Avatars: round, the client's own mark. */
.ig-av { flex: none; width: 2.5em; height: 2.5em; border-radius: 50%; object-fit: cover; background: #1c1c1c; }
.ig-av--lg { width: 6em; height: 6em; box-shadow: 0 0 0 .14em #000, 0 0 0 .3em #3a3a3a; }
.ig-av--nav { width: 2em; height: 2em; box-shadow: 0 0 0 .12em #f5f5f5; }
.ig-av--sm { width: 2.2em; height: 2.2em; }
.ig-av--brand { padding: .3em; background: #fefffe; object-fit: contain; } /* the Chamberlin Studio mark on white */
svg.ig-av { background: none; } /* the default avatar and the example business's mark are drawn in the SVG */
.ig-av--xs { width: 1.75em; height: 1.75em; }

/* Profile: the mark and the name, the bio and its link, Follow and Message, the tabs, then the grid of posts. */
.ig-head { flex: none; display: flex; align-items: center; gap: 1.3em; padding: .5em 1.1em .2em; }
.ig-name { font-size: 1.15em; line-height: 1.25; }
.ig-bio { flex: none; padding: .75em 1.1em 0; font-size: 1em; }
.ig-link { flex: none; padding: .15em 1.1em 0; font-size: 1em; font-weight: 600; color: #e0f1ff; }
.ig-btns { flex: none; display: flex; gap: .45em; padding: 1em 1.1em .9em; }
.ig-btn { flex: 1 1 0; display: grid; place-items: center; padding: .62em 0; border-radius: .7em; background: #262626; font-size: .98em; font-weight: 600; }
.ig-btn--blue { background: #0874d1; color: #fff; } /* a touch deeper than the app's blue, so its white words pass 4.5:1 */
.ig-btn--sq { flex: 0 0 2.5em; padding: .3em 0; }
.ig-btn--sq .ig-i { width: 1.5em; height: 1.5em; }
.ig-tabs { flex: none; display: flex; border-top: 1px solid #1f1f1f; }
.ig-tabs > span { flex: 1 1 0; display: grid; place-items: center; padding: .65em 0 .55em; color: #8e8e8e; border-bottom: .12em solid transparent; }
.ig-tabs > span.is-on { color: #f5f5f5; border-bottom-color: #f5f5f5; }
.ig-tabs .ig-i { width: 1.65em; height: 1.65em; }
.ig-grid { flex: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; }
.ig-grid > span { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: #1a1a1a; }
.ig-grid img { width: 100%; height: 100%; object-fit: cover; }
.ig-grid .ig-pos-l { object-position: 0 50%; }
.ig-grid .ig-pos-r { object-position: 100% 50%; }
.ig-grid .ig-pos-b { object-position: 50% 100%; }
.ig-tile-badge { position: absolute; top: .45em; right: .45em; width: 1.35em; height: 1.35em; color: #fff; filter: drop-shadow(0 0 .2em rgba(0, 0, 0, .5)); }

/* A feed post: the account row, the photo (4:5, Instagram's tall post), the actions, the caption. */
.ig-post-head { flex: none; display: flex; align-items: center; gap: .7em; padding: .4em 1.1em .7em; }
.ig-post-head b { font-size: 1em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-post-head .ig-i { margin-left: auto; width: 1.6em; height: 1.6em; }
.ig-photo { flex: none; aspect-ratio: 4 / 5; overflow: hidden; background: #1a1a1a; }
.ig-photo img { width: 100%; height: 100%; object-fit: cover; }
.ig-actions { flex: none; display: flex; align-items: center; gap: 1.05em; padding: .8em 1.1em .55em; }
.ig-actions .ig-save { margin-left: auto; }
.ig-cap { flex: none; padding: 0 1.1em; font-size: 1em; }
.ig-cap b { margin-right: .3em; }

/* A reel: the video fills the screen, the actions stand down the right, the account and caption sit at the foot. */
.ig-reel-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ig--reel .ig-in { background: linear-gradient(180deg, rgba(0, 0, 0, .45), rgba(0, 0, 0, 0) 18%, rgba(0, 0, 0, 0) 58%, rgba(0, 0, 0, .62)); }
.ig--reel .ig-i { filter: drop-shadow(0 0 .25em rgba(0, 0, 0, .45)); }
.ig-side { position: absolute; right: .9em; bottom: 9em; display: flex; flex-direction: column; align-items: center; gap: 1.5em; }
.ig-side .ig-i { width: 2.2em; height: 2.2em; }
.ig-reel-foot { position: absolute; left: 1.1em; right: 4.4em; bottom: 5.6em; display: grid; gap: .55em; }
.ig-reel-who { display: flex; align-items: center; gap: .6em; min-width: 0; }
.ig-reel-who b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-follow { flex: none; padding: .22em .7em; border: 1px solid rgba(255, 255, 255, .75); border-radius: .55em; font-size: .92em; font-weight: 600; }
.ig--reel .ig-cap { padding: 0; }
.ig-audio { display: flex; align-items: center; gap: .4em; font-size: .92em; }
.ig-audio .ig-i { width: 1.2em; height: 1.2em; }

/* A story: the photo fills the screen; the progress bars and the account across the top (no time), the reply bar at
   the foot, and no bar at the bottom of the app. */
.ig--story .ig-in {
  padding-bottom: 0; color: #fff;
  background: linear-gradient(180deg, rgba(0, 0, 0, .5), rgba(0, 0, 0, 0) 20%, rgba(0, 0, 0, 0) 76%, rgba(0, 0, 0, .5));
}
.ig--story .ig-i, .ig--story b { filter: drop-shadow(0 0 .25em rgba(0, 0, 0, .4)); }
.ig-story-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ig-story-bars { flex: none; display: flex; gap: .3em; padding: 2.4em .7em 0; }
.ig-story-bars span { flex: 1 1 0; height: .2em; border-radius: .1em; background: rgba(255, 255, 255, .4); }
.ig-story-bars .is-done { background: #fff; }
.ig-story-bars .is-now { background: linear-gradient(90deg, #fff 45%, rgba(255, 255, 255, .4) 45%); }
.ig-story-head { flex: none; display: flex; align-items: center; gap: .6em; padding: .75em .9em; }
.ig-story-head b { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-story-head .ig-top-r { gap: .8em; }
.ig-story-foot { position: absolute; left: .9em; right: .9em; bottom: 1.5em; display: flex; align-items: center; gap: 1em; }
.ig-story-reply {
  flex: 1 1 auto; min-width: 0; padding: .7em 1.1em; border: 1px solid rgba(255, 255, 255, .75); border-radius: 999px;
  font-size: .95em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* A comments sheet: the post dimmed behind, then the sheet with its grabber and title, the comments (a reply sits in
   under its comment) and the box to add one. */
.ig--comments .ig-in { padding-bottom: 0; }
.ig-cm-behind { position: absolute; inset: 0 0 auto; height: 42%; overflow: hidden; }
.ig-cm-behind img { width: 100%; height: 100%; object-fit: cover; filter: blur(.6em) brightness(.45); transform: scale(1.15); }
.ig-sheet {
  position: absolute; inset: 37% 0 0; display: flex; flex-direction: column; border-radius: 1.3em 1.3em 0 0;
  background: #1f1f1f;
}
.ig-sheet-grab { align-self: center; flex: none; width: 2.8em; height: .3em; margin-top: .6em; border-radius: 1em; background: #555; }
.ig-sheet-title { flex: none; padding: .65em 0 .75em; border-bottom: 1px solid #2f2f2f; text-align: center; font-size: 1.05em; font-weight: 600; }
.ig-cm { flex: none; display: flex; align-items: flex-start; gap: .7em; padding: 1em 1em 0; }
.ig-cm--reply { padding-left: 3.4em; }
.ig-cm-body { flex: 1 1 auto; min-width: 0; }
.ig-cm-body b { font-size: .92em; }
.ig-cm-body p { margin-top: .12em; font-size: 1em; }
.ig-cm-meta { display: block; margin-top: .3em; font-size: .84em; font-weight: 600; color: #a8a8a8; }
.ig-cm > .ig-i { width: 1.25em; height: 1.25em; margin-top: .55em; color: #a8a8a8; }
.ig-cm-add {
  margin-top: auto; display: flex; align-items: center; gap: .7em; padding: .8em 1em 1.7em; border-top: 1px solid #2f2f2f;
}
.ig-cm-add span { flex: 1 1 auto; min-width: 0; padding: .65em 1em; border: 1px solid #3a3a3a; border-radius: 999px; font-size: .92em; color: #a8a8a8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* A message thread: the person at the top; the thread sits on the box to write one, starting with their picture and
   name (a new thread); their messages on the left in gray, the account's on the right in blue (deep enough for white
   words at 4.5:1). */
.ig--dm .ig-in { padding-bottom: 0; }
.ig-dm-who { min-width: 0; font-size: 1.1em; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-dm-intro { align-self: stretch; display: grid; justify-items: center; gap: .35em; padding: 0 0 1.2em; text-align: center; }
.ig-dm-intro .ig-av { width: 5em; height: 5em; }
.ig-dm-intro b { margin-top: .3em; font-size: 1.1em; }
.ig-dm-intro span { margin-top: .4em; padding: .5em 1em; border-radius: .7em; background: #262626; font-size: .9em; font-weight: 600; }
.ig-dm-thread { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: .5em; padding: .8em .9em .6em; }
.ig-msg { max-width: 78%; padding: .6em .9em; border-radius: 1.25em; font-size: 1.04em; line-height: 1.3; }
.ig-msg--out { align-self: flex-end; background: #0874d1; color: #fff; }
.ig-msg-in { align-self: flex-start; display: flex; align-items: flex-end; gap: .45em; max-width: 86%; }
.ig-msg-in .ig-msg { max-width: none; background: #262626; }
.ig-dm-bar {
  flex: none; display: flex; align-items: center; gap: .65em; margin: .3em .7em 1.5em; padding: .35em .8em .35em .35em;
  border-radius: 999px; background: #262626;
}
.ig-dm-cam { flex: none; width: 2.1em; height: 2.1em; display: grid; place-items: center; border-radius: 50%; background: #0874d1; color: #fff; }
.ig-dm-cam .ig-i { width: 1.25em; height: 1.25em; }
.ig-dm-ph { flex: 1 1 auto; min-width: 0; color: #a8a8a8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ig-dm-bar > .ig-i { width: 1.45em; height: 1.45em; }

/* The bar at the bottom of the app. */
.ig-nav { position: absolute; inset: auto 0 0; display: flex; align-items: center; justify-content: space-around; padding: .95em .4em 1.5em; background: #000; border-top: 1px solid #1a1a1a; }
.ig--reel .ig-nav { background: #000; }
