/* ===================================================================
   DAMALMARK TRADE — Design Tokens
   =================================================================== */

:root,
[data-theme='light'] {
  /* Surfaces — warm cream heritage palette */
  --color-bg: #f7f3ea;
  --color-surface: #fbf8f0;
  --color-surface-2: #fdfbf6;
  --color-surface-offset: #efe7d3;
  --color-surface-offset-2: #e6dab9;
  --color-surface-dynamic: #ded0a8;
  --color-divider: #e2d6b8;
  --color-border: #d8cba5;

  /* Text */
  --color-text: #221f19;
  --color-text-muted: #6b6152;
  --color-text-faint: #a89c81;
  --color-text-inverse: #fbf8f0;

  /* Primary accent — heritage racing green */
  --color-primary: #1f4a3d;
  --color-primary-hover: #163831;
  --color-primary-active: #0f2b26;
  --color-primary-highlight: #cfe0d6;

  /* Secondary accent — brass / gold */
  --color-accent: #b4802e;
  --color-accent-hover: #966a22;
  --color-accent-active: #7a551b;
  --color-accent-highlight: #ebddbb;

  /* Status */
  --color-warning: #954a24;
  --color-error: #a13a3a;
  --color-success: #3e6b2e;

  /* Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1.25rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Shadows — warm tinted */
  --shadow-sm: 0 1px 2px oklch(0.25 0.03 90 / 0.08);
  --shadow-md: 0 6px 16px oklch(0.25 0.03 90 / 0.1);
  --shadow-lg: 0 16px 40px oklch(0.25 0.03 90 / 0.16);

  /* Content widths */
  --content-narrow: 640px;
  --content-default: 1000px;
  --content-wide: 1240px;
  --content-full: 100%;

  /* Fonts */
  --font-display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --font-body: 'Work Sans', 'Segoe UI', sans-serif;
}

[data-theme='dark'] {
  --color-bg: #16130f;
  --color-surface: #1b1712;
  --color-surface-2: #1f1b15;
  --color-surface-offset: #241f17;
  --color-surface-offset-2: #2b241a;
  --color-surface-dynamic: #332b1e;
  --color-divider: #2c2617;
  --color-border: #3a3120;
  --color-text: #ede7d8;
  --color-text-muted: #a79c86;
  --color-text-faint: #6e6552;
  --color-text-inverse: #17140f;
  --color-primary: #6bab92;
  --color-primary-hover: #85bda6;
  --color-primary-active: #9dceba;
  --color-primary-highlight: #24382f;
  --color-accent: #d6a855;
  --color-accent-hover: #e0ba76;
  --color-accent-active: #ebc98d;
  --color-accent-highlight: #3d3220;
  --color-warning: #c98352;
  --color-error: #cc7373;
  --color-success: #86b169;
  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
  --shadow-md: 0 6px 16px oklch(0 0 0 / 0.36);
  --shadow-lg: 0 16px 40px oklch(0 0 0 / 0.48);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #16130f;
    --color-surface: #1b1712;
    --color-surface-2: #1f1b15;
    --color-surface-offset: #241f17;
    --color-surface-offset-2: #2b241a;
    --color-surface-dynamic: #332b1e;
    --color-divider: #2c2617;
    --color-border: #3a3120;
    --color-text: #ede7d8;
    --color-text-muted: #a79c86;
    --color-text-faint: #6e6552;
    --color-text-inverse: #17140f;
    --color-primary: #6bab92;
    --color-primary-hover: #85bda6;
    --color-primary-active: #9dceba;
    --color-primary-highlight: #24382f;
    --color-accent: #d6a855;
    --color-accent-hover: #e0ba76;
    --color-accent-active: #ebc98d;
    --color-accent-highlight: #3d3220;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
    --shadow-md: 0 6px 16px oklch(0 0 0 / 0.36);
    --shadow-lg: 0 16px 40px oklch(0 0 0 / 0.48);
  }
}

:root {
  /* Type scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.25rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 4.5rem);
  --text-hero: clamp(2.75rem, 1rem + 5.5vw, 5.5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;
}

/* ===================================================================
   Layout primitives
   =================================================================== */

.container {
  max-width: var(--content-wide);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.container--narrow {
  max-width: var(--content-default);
}

section {
  padding-block: clamp(var(--space-16), 9vw, var(--space-32));
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.section-eyebrow::before {
  content: '';
  width: var(--space-6);
  height: 2px;
  background: var(--color-accent);
  display: inline-block;
}

.section-title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 600;
  color: var(--color-text);
  margin-top: var(--space-3);
  max-width: 20ch;
}

.section-lede {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 60ch;
  margin-top: var(--space-4);
}

.section-head {
  margin-bottom: var(--space-12);
}

/* ===================================================================
   Header
   =================================================================== */

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in oklab, var(--color-bg) 88%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.08);
  transition:
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.header--hidden {
  transform: translateY(-100%);
}

.header--scrolled {
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  padding-block: var(--space-4);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: var(--color-text);
  text-decoration: none;
}

.brand-mark {
  width: 40px;
  height: 40px;
  color: var(--color-primary);
  flex-shrink: 0;
}

.brand-mark--logo {
  width: auto;
  height: 40px;
  object-fit: contain;
}

.brand-name {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  line-height: 1.1;
}

.brand-name span {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-top: 2px;
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-links {
  display: flex;
  gap: var(--space-6);
}

.nav-links a {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  text-decoration: none;
  padding-block: var(--space-1);
  position: relative;
}

.nav-links a:hover {
  color: var(--color-text);
}

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width var(--transition-interactive);
}

.nav-links a:hover::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  border: 1px solid oklch(from var(--color-text) l c h / 0.12);
}

.icon-btn:hover {
  color: var(--color-text);
  background: var(--color-surface-offset);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

/* Language switcher */
.lang-switch {
  position: relative;
}

.lang-current {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: 40px;
  padding-inline: var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid oklch(from var(--color-text) l c h / 0.12);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: 0.04em;
}

.lang-current:hover {
  background: var(--color-surface-offset);
}

.lang-current svg {
  width: 14px;
  height: 14px;
  color: var(--color-text-muted);
  transition: transform var(--transition-interactive);
}

.lang-switch[data-open='true'] .lang-current svg {
  transform: rotate(180deg);
}

.lang-menu {
  position: absolute;
  top: calc(100% + var(--space-2));
  right: 0;
  min-width: 160px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--space-2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition:
    opacity var(--transition-interactive),
    transform var(--transition-interactive),
    visibility var(--transition-interactive);
}

.lang-switch[data-open='true'] .lang-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-align: left;
}

.lang-menu button:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
}

.lang-menu button[aria-current='true'] {
  color: var(--color-primary);
  font-weight: 600;
}

.nav-toggle {
  display: none;
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: var(--color-bg);
  padding: var(--space-6) var(--space-5) var(--space-8);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-menu[data-open='true'] {
  transform: translateX(0);
}

.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-12);
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.mobile-menu-links a {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--color-text);
  text-decoration: none;
}

.mobile-menu-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-divider);
}

.mobile-lang-list {
  display: flex;
  gap: var(--space-2);
}

.mobile-lang-list button {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-text-muted);
}

.mobile-lang-list button[aria-current='true'] {
  color: var(--color-text-inverse);
  background: var(--color-primary);
  border-color: var(--color-primary);
}

/* ===================================================================
   Buttons
   =================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-text-inverse);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--color-primary-hover);
  box-shadow: var(--shadow-md);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text);
  border: 1px solid oklch(from var(--color-text) l c h / 0.18);
}

.btn-ghost:hover {
  background: var(--color-surface-offset);
}

/* ===================================================================
   Hero
   =================================================================== */

.hero {
  padding-top: clamp(var(--space-16), 10vw, var(--space-24));
  padding-bottom: clamp(var(--space-16), 8vw, var(--space-24));
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-16);
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-5);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: var(--text-hero);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--color-text);
  max-width: 15ch;
}

.hero h1 em {
  font-style: italic;
  color: var(--color-primary);
}

.hero-lede {
  margin-top: var(--space-6);
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  max-width: 46ch;
  font-weight: 400;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-top: var(--space-8);
  flex-wrap: wrap;
}

.hero-visual {
  position: relative;
}

.hero-visual img {
  width: 100%;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}

.hero-stats {
  display: flex;
  gap: var(--space-8);
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-divider);
}

.hero-stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-xl);
  color: var(--color-primary);
}

.hero-stat span {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ===================================================================
   About
   =================================================================== */

.about {
  background: var(--color-surface);
  border-top: 1px solid var(--color-divider);
  border-bottom: 1px solid var(--color-divider);
}

.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: var(--space-16);
  align-items: center;
}

.about-visual img {
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
}

.about-body p {
  margin-top: var(--space-5);
  color: var(--color-text-muted);
  max-width: 62ch;
}

.about-body p:first-of-type {
  margin-top: var(--space-6);
}

.about-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-5);
  margin-top: var(--space-8);
}

.about-fact {
  padding: var(--space-5);
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.about-fact strong {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}

.about-fact span {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* ===================================================================
   Services
   =================================================================== */

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}

.service-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.service-card--feature {
  grid-column: span 2;
  grid-row: span 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.service-card--feature .service-media {
  aspect-ratio: auto;
  height: 100%;
}

.service-media {
  aspect-ratio: 4 / 3;
  background: var(--color-surface-offset);
  overflow: hidden;
}

.service-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-body {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: center;
}

.service-card--feature .service-body {
  padding: var(--space-8);
}

.service-index {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  color: var(--color-accent);
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.service-body h3 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--color-text);
}

.service-card--feature .service-body h3 {
  font-size: var(--text-xl);
}

.service-body p {
  margin-top: var(--space-2);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

/* ===================================================================
   Gallery
   =================================================================== */

.gallery {
  background: var(--color-surface);
  border-top: 1px solid var(--color-divider);
  border-bottom: 1px solid var(--color-divider);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-5);
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow-sm);
}

.gallery-item:nth-child(1) {
  grid-column: span 2;
  aspect-ratio: 16 / 9;
}

.gallery-open {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
}

.gallery-open img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-item:hover .gallery-open img {
  transform: scale(1.045);
}

.gallery-open::after {
  content: '';
  position: absolute;
  inset: 0;
  background: oklch(0.15 0.02 150 / 0);
  transition: background 0.3s ease;
}

.gallery-item:hover .gallery-open::after {
  background: oklch(0.15 0.02 150 / 0.12);
}

.gallery-open:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: -2px;
}

.gallery-caption {
  pointer-events: none;
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  padding: var(--space-4) var(--space-5);
  background: linear-gradient(to top, oklch(0.15 0.02 150 / 0.72), transparent);
  color: #fff;
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
}

/* ===================================================================
   Contact
   =================================================================== */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-16);
  align-items: start;
}

.contact-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  box-shadow: var(--shadow-sm);
}

.contact-card dl {
  display: grid;
  gap: var(--space-5);
  margin-top: var(--space-6);
}

.contact-card .contact-row {
  padding-top: var(--space-5);
  border-top: 1px solid var(--color-divider);
}

.contact-card .contact-row:first-child {
  padding-top: 0;
  border-top: none;
}

.contact-card dt {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-faint);
  margin-bottom: var(--space-1);
}

.contact-card dd {
  font-size: var(--text-base);
  color: var(--color-text);
  font-weight: 500;
}

.contact-note p {
  margin-top: var(--space-5);
  color: var(--color-text-muted);
  max-width: 48ch;
}

/* ===================================================================
   Footer
   =================================================================== */

.footer {
  border-top: 1px solid var(--color-divider);
  padding-block: var(--space-12);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.footer-brand svg {
  width: 28px;
  height: 28px;
  color: var(--color-primary);
}

.footer-meta {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.footer-legal {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  text-align: right;
}

/* ===================================================================
   Reveal on scroll
   =================================================================== */

[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ===================================================================
   Responsive
   =================================================================== */

@media (max-width: 960px) {
  .hero-grid,
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: var(--space-10);
  }

  .about-visual {
    order: -1;
  }

  .service-card--feature {
    grid-column: span 2;
    grid-row: span 1;
    grid-template-columns: 1fr;
  }

  .service-card--feature .service-media {
    aspect-ratio: 16 / 9;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-item:nth-child(1) {
    grid-column: span 2;
    grid-row: span 1;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 720px) {
  .nav-links,
  .header-actions .btn {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .services-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .service-card--feature {
    grid-column: span 1;
  }

  .gallery-item:nth-child(1) {
    grid-column: span 1;
  }

  .about-facts {
    grid-template-columns: 1fr 1fr;
  }

  .hero-stats {
    flex-wrap: wrap;
    gap: var(--space-6);
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }

  .footer-legal {
    text-align: left;
  }
}

/* ===================================================================
   Lightbox
=================================================================== */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  background: oklch(0.1 0.01 150 / 0.92);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  padding: var(--space-5);
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-stage {
  position: relative;
  max-width: min(1100px, 92vw);
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-image {
  max-width: 100%;
  max-height: 78vh;
  width: auto;
  height: auto;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  background: #111;
  opacity: 0;
  transform: scale(0.98);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.lightbox-image.is-visible {
  opacity: 1;
  transform: scale(1);
}

.lightbox-meta {
  margin-top: var(--space-3);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  color: #f2efe7;
  font-size: var(--text-sm);
}

.lightbox-caption {
  font-family: var(--font-display);
  font-weight: 600;
}

.lightbox-count {
  color: oklch(0.9 0.01 90 / 0.6);
  font-variant-numeric: tabular-nums;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  border: 1px solid oklch(1 0 0 / 0.18);
  background: oklch(1 0 0 / 0.08);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.lightbox-close svg,
.lightbox-nav svg {
  width: 22px;
  height: 22px;
}

.lightbox-close:hover,
.lightbox-nav:hover {
  background: oklch(1 0 0 / 0.18);
  border-color: oklch(1 0 0 / 0.32);
}

.lightbox-close {
  top: var(--space-5);
  right: var(--space-5);
}

.lightbox-nav {
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-prev {
  left: var(--space-5);
}

.lightbox-next {
  right: var(--space-5);
}

@media (max-width: 720px) {
  .lightbox-close {
    top: var(--space-3);
    right: var(--space-3);
    width: 38px;
    height: 38px;
  }

  .lightbox-nav {
    width: 38px;
    height: 38px;
  }

  .lightbox-prev {
    left: var(--space-2);
  }

  .lightbox-next {
    right: var(--space-2);
  }

  .lightbox-image {
    max-height: 68vh;
  }
}
