/* Responsive adaptations — tablet & mobile.
   The page designs use inline styles; these rules adapt them to smaller screens
   without changing the desktop layout. Desktop (>1024px) is untouched. */

html { -webkit-text-size-adjust: 100%; }
body { overflow-x: clip; }
img { max-width: 100%; }

/* ---------- Tablet (≤1024px) ---------- */
@media (max-width: 1024px) {
  [style*="font-size: 104px"] { font-size: 84px !important; }
  [style*="font-size: 88px"]  { font-size: 70px !important; }
  [style*="font-size: 72px"]  { font-size: 60px !important; }
  [style*="grid-template-columns: 1fr 400px"] { grid-template-columns: 1fr 320px !important; }
  [style*="px 48px"], [style*="padding: 0 48px"] { padding-left: 32px !important; padding-right: 32px !important; }
  [style*="padding: 0px 56px"] { padding-left: 36px !important; padding-right: 36px !important; }
  [style*="padding: 56px 96px"] { padding: 56px 64px !important; }
  [style*="gap: 74px"], [style*="gap: 72px"], [style*="gap: 64px"] { gap: 44px !important; }
  [style*="width: 1280px"] { width: 100% !important; }
}

/* ---------- Mobile & small tablet (≤760px) ---------- */
@media (max-width: 760px) {
  /* Type scale */
  [style*="font-size: 104px"] { font-size: 60px !important; }
  [style*="font-size: 88px"]  { font-size: 50px !important; line-height: 1 !important; }
  [style*="font-size: 72px"]  { font-size: 46px !important; }
  [style*="font-size: 62px"]  { font-size: 44px !important; }
  [style*="font-size: 56px"]  { font-size: 42px !important; }
  [style*="font-size: 54px"]  { font-size: 38px !important; }
  [style*="font-size: 50px"]  { font-size: 36px !important; }
  [style*="font-size: 46px"]  { font-size: 34px !important; }
  [style*="font-size: 40px"]  { font-size: 32px !important; }
  [style*="font-size: 38px"]  { font-size: 30px !important; }
  h1, h2, h3, p, span, a, label { overflow-wrap: break-word; }

  /* Side padding */
  [style*="px 40px"], [style*="padding: 0 40px"] { padding-left: 20px !important; padding-right: 20px !important; }
  [style*="px 48px"], [style*="padding: 0 48px"] { padding-left: 20px !important; padding-right: 20px !important; }
  [style*="padding: 0px 56px"] { padding: 28px 4px 8px !important; }

  /* Vertical rhythm */
  [style*="padding: 90px 40px"], [style*="padding: 84px 40px"], [style*="padding: 96px 40px"] { padding-top: 56px !important; padding-bottom: 56px !important; }
  [style*="padding: 110px 40px 90px"] { padding-top: 64px !important; padding-bottom: 56px !important; }
  [style*="padding: 76px 40px 72px"], [style*="padding: 74px 40px 90px"] { padding-top: 44px !important; padding-bottom: 56px !important; }
  [style*="padding: 54px 40px"], [style*="padding: 56px 40px 10px"] { padding-top: 36px !important; }
  [style*="padding: 46px 40px 90px"], [style*="padding: 40px 40px 96px"] { padding-bottom: 64px !important; }

  /* Gaps */
  [style*="gap: 74px"], [style*="gap: 72px"], [style*="gap: 64px"], [style*="gap: 52px"],
  [style*="gap: 48px"], [style*="gap: 46px"], [style*="gap: 44px"], [style*="gap: 40px"] { gap: 28px !important; }

  /* Grids collapse to one column */
  [style*="grid-template-columns: 1fr 1fr"],
  [style*="grid-template-columns: 1fr 400px"],
  [style*="grid-template-columns: 1fr 320px"],
  [style*="grid-template-columns: 1.15fr 1fr"],
  [style*="grid-template-columns: 1fr 1.4fr"],
  [style*="grid-template-columns: 1fr auto"],
  [style*="grid-template-columns: minmax(0, 620px)"] { grid-template-columns: minmax(0, 1fr) !important; }
  [style*="grid-template-columns: 1fr 1.75fr"] { grid-template-columns: 1fr 1fr !important; }
  [style*="grid-template-columns: repeat(3, 1fr)"] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  [style*="grid-column: 1 / -1"] { grid-column: 1 / -1 !important; }
  [style*="text-align: right"] { text-align: left !important; }
  [style*="align-items: flex-end"][style*="flex-direction: column"] { align-items: flex-start !important; }

  /* Home: Shoot / Retouch chooser stacks */
  [style*="grid-template-columns: 1fr auto 1fr"] { grid-template-columns: 1fr !important; gap: 10px !important; }
  [style*="grid-template-columns: 1fr auto 1fr"] > [style*="height: 150px"] { width: 72px !important; height: 1px !important; justify-self: center; }
  [style*="min-height: 680px"] { min-height: 100svh !important; height: auto !important; display: flex; flex-direction: column; }
  [style*="min-height: 680px"] > [style*="position: absolute"][style*="top: 0px"][style*="z-index: 5"] { position: relative !important; padding: 18px 20px !important; flex-wrap: nowrap !important; }
  [style*="min-height: 680px"] > [style*="position: absolute"][style*="top: 0px"][style*="z-index: 5"] > [style*="gap: 34px"] { gap: 18px !important; }
  [style*="min-height: 680px"] > [style*="z-index: 4"][style*="height: 100%"] { flex: 1; height: auto !important; padding: 28px 20px 40px !important; gap: 30px !important; }
  [style*="min-height: 680px"] > [style*="position: absolute"][style*="bottom: 0px"][style*="z-index: 5"] { position: relative !important; }
  [style*="letter-spacing: 6px"], [style*="letter-spacing: 5px"], [style*="letter-spacing: 8px"] { letter-spacing: 3px !important; text-align: center; }

  /* Flex rows wrap instead of overflowing */
  [style*="justify-content: space-between"], [style*="gap: 34px"] { flex-wrap: wrap !important; row-gap: 12px !important; }
  [style*="position: absolute"][style*="bottom: 0px"][style*="justify-content: space-between"] {
    flex-direction: column !important; align-items: center !important; text-align: center; gap: 6px !important; padding-top: 14px !important; padding-bottom: 14px !important;
  }

  /* Sticky header: logo + Shoot/Retouch on top, links underneath */
  [style*="position: sticky"][style*="justify-content: space-between"] { padding: 12px 18px !important; column-gap: 12px !important; }
  [style*="position: sticky"] > [style*="gap: 34px"] { order: 3; width: 100%; justify-content: space-between; gap: 8px 14px !important; }
  [style*="gap: 34px"] > a, [style*="gap: 34px"] summary { display: inline-block; padding: 10px 0; }
  [style*="padding: 9px 15px"] { padding: 12px 14px !important; }

  /* Galleries */
  [style*="column-count: 3"] { column-count: 2 !important; column-gap: 8px !important; }
  [style*="flex: 0 0 calc"] { flex-basis: calc((100% - 10px) / 2) !important; }
  [style*="height: 720px"], [style*="height: 620px"] { height: auto !important; min-height: 440px; }

  /* Lightbox */
  [style*="padding: 56px 96px"] { padding: 64px 10px !important; }

  /* Short labels never break mid-word */
  a[href^="mailto"], [style*="letter-spacing: 3.4px"], [style*="padding: 14px 30px"], a > [style*="font-size: 20px"], a > [style*="font-size: 21px"] { white-space: nowrap; }

  /* Forms: 16px text stops iOS zooming in */
  input, textarea, select { font-size: 16px !important; }
}

/* ---------- Small phones (≤380px) ---------- */
@media (max-width: 380px) {
  [style*="font-size: 104px"] { font-size: 52px !important; }
  [style*="font-size: 88px"]  { font-size: 44px !important; }
  [style*="font-size: 72px"]  { font-size: 40px !important; }
  [style*="font-size: 62px"]  { font-size: 38px !important; }
  [style*="px 40px"], [style*="px 48px"], [style*="padding: 0 40px"], [style*="padding: 0 48px"] { padding-left: 16px !important; padding-right: 16px !important; }
  [style*="gap: 34px"] { font-size: 10px !important; letter-spacing: 1.6px !important; }
}
