/* Basem Elkady site. Design: Ivory Mist background, warm black accent, card style B with shadow D, Helvetica Neue. */
:root {
  --ink: #1c1a17;
  --muted: rgba(28, 26, 23, .55);
  --paper: #f4f1eb;
  --radius: 10px;
  --edge: inset 0 0 0 1px rgba(0, 0, 0, .09);
  --shadow-d: 26px 34px 50px -14px rgba(28, 26, 23, .55), 8px 10px 18px -6px rgba(28, 26, 23, .30);
  --gutter: 4vw;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--paper) url("img/ivory-mist.jpg") center top / cover no-repeat fixed;
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body > main { flex: 1 0 auto; width: 100%; }
a { color: inherit; }
img { display: block; max-width: 100%; }

/* Header */
.site-header { text-align: center; padding: 34px var(--gutter) 0; position: relative; z-index: 3; }
.site-title { display: inline-block; font-size: 30px; font-weight: 700; letter-spacing: .04em; text-decoration: none; line-height: 1.2; }
.site-nav { margin-top: 18px; display: flex; justify-content: center; gap: 28px; }
.site-nav a { font-weight: 700; font-size: 17px; text-decoration: none; padding-bottom: 4px; border-bottom: 1.5px solid transparent; }
.site-nav a[aria-current="page"] { border-bottom-color: currentColor; }

/* Cards */
.card { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-d); background: #111; }
.card::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: var(--edge); pointer-events: none; }
.ratio-16x9 { aspect-ratio: 16 / 9; }
.ratio-9x16 { aspect-ratio: 9 / 16; }
.card iframe, .card img { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }

/* Portfolio grid */
.work { max-width: 1320px; margin: 0 auto; padding: 72px var(--gutter) 120px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 72px 56px; }
.grid-item { text-decoration: none; display: block; }
.grid-item .card img { transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.grid-item:hover .card img { transform: scale(1.035); }
.grid-item h2 { font-size: 1.15rem; font-weight: 700; letter-spacing: -.01em; margin-top: 22px; line-height: 1.3; }

/* Project page */
.project { padding: 80px var(--gutter) 110px; }
.project .video { width: 69%; max-width: 1100px; margin: 0 auto; }
.project-text { max-width: 620px; margin: 96px auto 0; text-align: center; }
.project-text h1 { font-size: 34px; font-weight: 700; line-height: 1.25; }
.client { margin-top: 22px; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.project-text .sentence { margin-top: 18px; }
.shorts { max-width: 640px; margin: 72px auto 0; text-align: center; }
.shorts .client { margin: 0 0 28px; }
.shorts-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }

/* Prev / next */
.pager { background: #fff; display: flex; justify-content: space-between; align-items: center; padding: 34px var(--gutter); }
.pager a { display: flex; align-items: center; gap: 18px; font-size: 26px; font-weight: 700; text-decoration: none; line-height: 1.2; }
.pager .next { margin-left: auto; text-align: right; }
.pager svg { width: 14px; height: 26px; flex: none; }

/* About */
.about { max-width: 1320px; margin: 0 auto; padding: 72px var(--gutter) 120px; display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.about h1 { font-size: 64px; font-weight: 700; line-height: 1.05; margin-bottom: 32px; }
.about-copy p + p { margin-top: 16px; }
.about-side { text-align: center; }
.portrait { width: min(100%, 300px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; margin: 0 auto; }
.portrait img { width: 100%; height: 100%; object-fit: cover; }
.about-side h2 { font-size: 40px; font-weight: 700; line-height: 1.2; margin: 48px 0 20px; }
.about-side p + p { margin-top: 12px; }

/* Home */
.home { background: #000; color: #fff; }
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hero-bg iframe { position: absolute; top: 50%; left: 50%; width: max(100vw, 177.78vh); height: max(56.25vw, 100vh); transform: translate(-50%, -50%) scale(1.35); border: 0; opacity: 0; animation: hero-in 1.2s ease 2.8s forwards; }
@keyframes hero-in { to { opacity: 1; } }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
.home .site-header { color: #fff; }
.hero-copy { position: relative; z-index: 2; margin: auto; padding: 0 var(--gutter) 12vh; text-align: center; max-width: 980px; }
.eyebrow { font-weight: 700; font-size: 18px; letter-spacing: .02em; }
.hero-copy h1 { margin-top: 26px; font-size: clamp(30px, 3.4vw, 48px); font-weight: 700; line-height: 1.25; }
.button { display: inline-block; margin-top: 30px; background: #fff; color: var(--ink); font-weight: 700; font-size: 16px; text-decoration: none; padding: 1.1em 1.7em; border-radius: var(--radius); box-shadow: var(--edge), 0 20px 40px -24px rgba(0, 0, 0, .5); transition: transform .2s ease; white-space: nowrap; }
.button:hover { transform: translateY(-1px); }

/* Footer */
.site-footer { background: #fff; color: var(--ink); text-align: center; padding: 80px var(--gutter) 90px; }
.site-footer h3 { font-size: 30px; font-weight: 700; line-height: 1.35; max-width: 560px; margin: 0 auto 26px; }
.site-footer a { text-decoration: none; }

@media (max-width: 767px) {
  body { font-size: 17px; background-attachment: scroll; }
  .site-title { font-size: 24px; }
  .site-nav { gap: 22px; }
  .grid { grid-template-columns: 1fr; gap: 52px; }
  .work, .about { padding-top: 48px; }
  .project { padding-top: 48px; }
  .project .video { width: 100%; }
  .project-text { margin-top: 56px; }
  .project-text h1 { font-size: 28px; }
  .shorts { max-width: 340px; }
  .shorts-row { grid-template-columns: 1fr; gap: 28px; }
  .pager a { font-size: 18px; gap: 10px; }
  .about { grid-template-columns: 1fr; gap: 48px; }
  .about h1 { font-size: 48px; }
  .about-side h2 { font-size: 32px; margin-top: 32px; }
  .site-footer h3 { font-size: 24px; }
}
.about-side a, .site-footer a { text-decoration: none; }
.about-side a:hover, .site-footer a:hover { text-decoration: underline; }
