:root {
  --delivery-bg: #f9fafb;
  --delivery-panel: #ffffff;
  --delivery-ink: #111827;
  --delivery-muted: #5f6b7a;
  --delivery-line: #d8dee7;
  --delivery-dark: #111827;
  --delivery-teal: #f97316;
  --delivery-teal-dark: #ea580c;
  --delivery-orange: #f97316;
  --delivery-yellow: #facc15;
  --delivery-radius: 8px;
  --delivery-shadow: 0 22px 60px rgba(17, 24, 39, 0.14);
}

* {
  box-sizing: border-box;
}

body.delivery-body {
  min-height: 100vh;
  margin: 0;
  color: var(--delivery-ink);
  background: var(--delivery-bg);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
textarea,
select {
  font: inherit;
}

.delivery-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}

.delivery-sidebar {
  position: sticky;
  top: 0;
  min-height: 100vh;
  padding: 26px 20px;
  color: #f9fafb;
  background:
    linear-gradient(160deg, rgba(249, 115, 22, 0.24), transparent 40%),
    var(--delivery-dark);
}

.delivery-brand-logo {
  display: block;
  width: min(100%, 216px);
  margin-bottom: 22px;
}

.delivery-brand-logo img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 22px rgba(0, 0, 0, 0.28));
}

.delivery-sidebar h1,
.delivery-sidebar p {
  margin: 0;
}

.delivery-sidebar h1 {
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1.05rem;
}

.delivery-sidebar p {
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.86rem;
}

.delivery-nav {
  display: grid;
  gap: 8px;
  margin-top: 34px;
}

.delivery-nav a,
.delivery-nav-button {
  display: block;
  width: 100%;
  padding: 12px 13px;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 700;
  text-align: left;
  text-decoration: none;
  background: transparent;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
}

.delivery-nav a[aria-current="page"],
.delivery-nav a:hover,
.delivery-nav-button:hover,
.delivery-nav-button:focus-visible {
  color: #111827;
  background: var(--delivery-teal);
}

.delivery-sidebar-note {
  margin-top: 36px;
  padding: 14px;
  color: rgba(255, 255, 255, 0.76);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--delivery-radius);
  font-size: 0.82rem;
  line-height: 1.5;
}

.delivery-main {
  min-width: 0;
  padding: clamp(24px, 4vw, 44px);
}

.delivery-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.delivery-eyebrow,
.delivery-panel-title span,
.shoot-card-meta,
.asset-label {
  color: var(--delivery-muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.delivery-topbar h2,
.delivery-section h2,
.shoot-editor-title h2 {
  margin: 6px 0 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  letter-spacing: 0;
}

.delivery-topbar p,
.delivery-section > p,
.shoot-editor-title p {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--delivery-muted);
  line-height: 1.6;
}

.editor-email-status {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.email-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  color: var(--delivery-dark);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--delivery-yellow);
  border-radius: 999px;
}

.email-status-pill.sent {
  background: var(--delivery-teal);
}

.email-status-pill.pending {
  color: #ffffff;
  background: #667085;
}

.delivery-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 15px;
  color: var(--delivery-ink);
  font-weight: 800;
  text-decoration: none;
  background: var(--delivery-teal);
  border: 1px solid var(--delivery-teal);
  border-radius: 6px;
  cursor: pointer;
}

.delivery-button:hover,
.delivery-button:focus-visible {
  background: #fb923c;
  border-color: #fb923c;
}

.delivery-button:disabled {
  color: #667085;
  background: #e5e7eb;
  border-color: #d0d5dd;
  cursor: not-allowed;
}

.delivery-button-secondary {
  color: var(--delivery-ink);
  background: #ffffff;
  border-color: var(--delivery-line);
}

.delivery-button-danger {
  color: #ffffff;
  background: #b42318;
  border-color: #b42318;
}

.delivery-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.42fr) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.backend-status-panel {
  margin-bottom: 22px;
}

.backend-status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.backend-status-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.backend-status-item strong {
  display: block;
  color: var(--delivery-ink);
  font-family: "Sora", "Inter", sans-serif;
  font-size: 0.94rem;
}

.backend-status-item p {
  margin: 5px 0 0;
  color: var(--delivery-muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.backend-status-dot {
  width: 12px;
  height: 12px;
  flex: 0 0 auto;
  margin-top: 4px;
  border-radius: 999px;
}

.backend-status-dot.ready {
  background: #16a34a;
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.12);
}

.backend-status-dot.waiting {
  background: var(--delivery-yellow);
  box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.18);
}

.delivery-stacked-panels {
  display: grid;
  gap: 22px;
}

.delivery-panel {
  padding: clamp(18px, 2.4vw, 26px);
  background: var(--delivery-panel);
  border: 1px solid var(--delivery-line);
  border-radius: var(--delivery-radius);
  box-shadow: var(--delivery-shadow);
}

.delivery-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.delivery-panel-title h3 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
}

.delivery-form {
  display: grid;
  gap: 14px;
}

.delivery-field {
  display: grid;
  gap: 7px;
  color: var(--delivery-muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.delivery-field-note {
  color: var(--delivery-muted);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.5;
}

.delivery-field-spacer {
  display: block;
}

.delivery-notice {
  margin: 0;
  padding: 12px 14px;
  color: #7c2d12;
  font-weight: 800;
  background: #ffedd5;
  border: 1px solid #fed7aa;
  border-radius: var(--delivery-radius);
}

.shoot-list-view > .delivery-notice {
  margin-bottom: 20px;
}

.admin-login-card {
  background:
    radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.28), transparent 30%),
    linear-gradient(90deg, rgba(17, 24, 39, 0.97), rgba(17, 24, 39, 0.66)),
    url("assets/industrial-photographer-landing.jpg") center / cover no-repeat;
}

.admin-login-inner {
  max-width: 820px;
}

.admin-login-inner .delivery-brand-logo {
  width: min(100%, 300px);
}

.admin-login-inner h1 {
  max-width: 720px;
}

.admin-login-form input {
  font-weight: 800;
}

.delivery-field input,
.delivery-field select,
.delivery-field textarea,
.delivery-search input {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  color: var(--delivery-ink);
  background: #ffffff;
  border: 1px solid var(--delivery-line);
  border-radius: 6px;
  outline: none;
}

.delivery-field textarea {
  min-height: 96px;
  resize: vertical;
}

.delivery-field input:focus,
.delivery-field select:focus,
.delivery-field textarea:focus,
.delivery-search input:focus {
  border-color: var(--delivery-teal);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.16);
}

.delivery-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.delivery-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 12px;
  margin-bottom: 16px;
}

.shoot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.shoot-card {
  min-height: 162px;
  display: grid;
  align-content: space-between;
  gap: 14px;
  padding: 18px;
  color: #f9fafb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(249, 115, 22, 0.16), transparent),
    var(--delivery-dark);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--delivery-radius);
  cursor: pointer;
}

.shoot-card:hover,
.shoot-card:focus-visible {
  border-color: var(--delivery-teal);
  transform: translateY(-1px);
}

.shoot-card h3 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1.08rem;
}

.shoot-card p {
  margin: 5px 0 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

.shoot-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.84rem;
}

.shoot-status {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 8px;
  color: var(--delivery-dark);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  background: var(--delivery-yellow);
  border-radius: 999px;
}

.shoot-status.published {
  background: var(--delivery-teal);
}

.shoot-status.draft {
  color: #ffffff;
  background: #475467;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 260px;
  padding: 36px;
  color: var(--delivery-muted);
  text-align: center;
  border: 1px dashed var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.compact-empty-state {
  min-height: 160px;
}

.shoot-editor {
  display: grid;
  gap: 22px;
}

.shoot-editor[hidden],
.shoot-list-view[hidden] {
  display: none;
}

.shoot-editor-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
}

.shoot-editor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.editor-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  gap: 22px;
  align-items: start;
}

.email-history-panel {
  grid-column: 1;
}

.email-history-list {
  display: grid;
  gap: 10px;
}

.email-history-item,
.email-history-empty {
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--delivery-line);
  border-radius: 10px;
}

.email-history-item span {
  color: var(--delivery-muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.email-history-item strong,
.email-history-empty strong {
  display: block;
  margin-top: 4px;
}

.email-history-item p,
.email-history-empty p {
  margin: 4px 0 0;
  color: var(--delivery-muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.asset-panel {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: grid;
  gap: 18px;
}

.dropzone {
  min-height: 210px;
  display: grid;
  place-items: center;
  padding: 28px;
  color: var(--delivery-muted);
  text-align: center;
  background: #f8fafc;
  border: 2px dashed #bdc6d2;
  border-radius: var(--delivery-radius);
  cursor: pointer;
}

.dropzone.is-over {
  color: var(--delivery-ink);
  background: rgba(249, 115, 22, 0.12);
  border-color: var(--delivery-teal);
}

.dropzone.is-locked {
  cursor: not-allowed;
  opacity: 0.62;
  background: #f1f5f9;
}

.delivery-lock-message {
  margin: -4px 0 16px;
  padding: 12px 14px;
  color: #7c2d12;
  font-size: 0.9rem;
  font-weight: 800;
  background: #ffedd5;
  border: 1px solid #fed7aa;
  border-radius: var(--delivery-radius);
}

.dropzone strong {
  display: block;
  margin-bottom: 8px;
  color: var(--delivery-ink);
  font-family: "Sora", "Inter", sans-serif;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
}

.photo-tile {
  overflow: hidden;
  background: #ffffff;
  border: 1px solid var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.photo-tile img {
  width: 100%;
  aspect-ratio: 4 / 3;
  display: block;
  object-fit: cover;
  background: #e5e7eb;
}

.photo-tile-body {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.photo-tile-body strong {
  overflow: hidden;
  font-size: 0.82rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.photo-tile-actions {
  display: flex;
  gap: 8px;
}

.photo-tile-actions a,
.photo-tile-actions button {
  flex: 1;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 8px;
  color: var(--delivery-ink);
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
  background: #f8fafc;
  border: 1px solid var(--delivery-line);
  border-radius: 5px;
  cursor: pointer;
}

.asset-card {
  padding: 18px;
  background: #f8fafc;
  border: 1px solid var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.asset-card h4 {
  margin: 6px 0 12px;
  font-family: "Sora", "Inter", sans-serif;
}

.video-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.client-access-card {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.95), rgba(17, 24, 39, 0.64)),
    url("assets/industrial-photographer-landing.jpg") center / cover no-repeat;
}

.client-access-card[hidden],
.client-gallery-shell[hidden] {
  display: none;
}

.client-access-inner {
  width: min(100%, 760px);
  padding: clamp(24px, 4vw, 42px);
  color: #ffffff;
  background: rgba(17, 24, 39, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--delivery-radius);
  box-shadow: var(--delivery-shadow);
}

.client-access-inner h1 {
  margin: 8px 0 12px;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
}

.client-access-inner p {
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.7;
}

.client-logo {
  width: min(100%, 360px);
  margin-bottom: 30px;
}

.client-form {
  display: flex;
  gap: 10px;
  margin-top: 24px;
}

.client-form input {
  flex: 1;
  min-height: 48px;
  padding: 12px 14px;
  color: var(--delivery-ink);
  border: 0;
  border-radius: 6px;
}

.client-message {
  margin-top: 16px;
  padding: 12px 14px;
  color: #ffe4e6;
  background: rgba(180, 35, 24, 0.24);
  border: 1px solid rgba(254, 205, 211, 0.28);
  border-radius: 6px;
}

.client-video-message {
  margin: 14px 0 0;
}

.client-access-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
}

.client-access-links a {
  color: rgba(255, 255, 255, 0.78);
  font-weight: 800;
  text-decoration: none;
}

.client-access-links a:hover,
.client-access-links a:focus-visible {
  color: var(--delivery-teal);
}

.client-gallery-shell {
  min-height: 100vh;
  padding: clamp(20px, 4vw, 48px);
}

.client-hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  align-items: end;
  margin-bottom: 22px;
  padding: clamp(22px, 4vw, 36px);
  color: #ffffff;
  background: var(--delivery-dark);
  border-radius: var(--delivery-radius);
}

.client-hero-panel h1 {
  margin: 8px 0 8px;
  font-family: "Sora", "Inter", sans-serif;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 1;
}

.client-hero-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
}

.client-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.client-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.client-meta-card {
  padding: 16px;
  background: #ffffff;
  border: 1px solid var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.client-meta-card span {
  color: var(--delivery-muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.client-meta-card strong {
  display: block;
  margin-top: 8px;
}

.client-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.34fr);
  gap: 22px;
  align-items: start;
}

.client-side-panel {
  display: grid;
  gap: 18px;
}

.client-gallery-panel .delivery-panel-title h2,
.client-resource-card .delivery-panel-title h2,
.client-note-panel .delivery-panel-title h2 {
  margin: 0;
  font-family: "Sora", "Inter", sans-serif;
  font-size: 1.2rem;
}

.client-count {
  color: var(--delivery-muted);
  font-size: 0.84rem;
  font-weight: 800;
}

.client-resource-card p,
.client-note-panel p {
  margin: 0 0 16px;
  color: var(--delivery-muted);
  line-height: 1.6;
}

.client-download-actions {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.client-download-actions .delivery-button {
  justify-content: center;
  width: 100%;
}

.client-code-pill {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 16px;
  padding: 10px 12px;
  color: var(--delivery-dark);
  font-weight: 900;
  letter-spacing: 0.08em;
  background: var(--delivery-teal);
  border-radius: 999px;
}

.client-photo-grid {
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
}

.client-empty {
  padding: 28px;
  color: var(--delivery-muted);
  background: #ffffff;
  border: 1px dashed var(--delivery-line);
  border-radius: var(--delivery-radius);
}

.client-empty p {
  margin-bottom: 0;
}

@media (max-width: 1080px) {
  .delivery-shell,
  .delivery-grid,
  .editor-grid,
  .client-content-grid {
    grid-template-columns: 1fr;
  }

  .delivery-sidebar {
    position: static;
    min-height: auto;
  }

  .asset-panel,
  .email-history-panel {
    grid-column: auto;
    grid-row: auto;
  }

  .delivery-nav {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

@media (max-width: 720px) {
  .delivery-body {
    font-size: 15px;
  }

  .delivery-main {
    padding: 14px;
  }

  .delivery-shell {
    padding: 0;
  }

  .delivery-panel,
  .client-meta-card,
  .client-hero-panel {
    border-radius: 14px;
  }

  .delivery-topbar,
  .shoot-editor-header,
  .client-hero-panel,
  .client-form,
  .client-hero-actions {
    display: grid;
  }

  .delivery-form-row,
  .delivery-search {
    grid-template-columns: 1fr;
  }

  .shoot-grid,
  .client-photo-grid,
  .photo-grid {
    grid-template-columns: 1fr;
  }

  .client-gallery-shell,
  .client-access-card {
    padding: 14px;
  }

  .client-access-inner {
    padding: 22px;
  }

  .client-logo {
    width: min(100%, 240px);
    margin-bottom: 20px;
  }

  .client-meta-grid {
    grid-template-columns: 1fr;
  }

  .dropzone {
    min-height: 150px;
    padding: 20px;
  }

  .shoot-editor-actions,
  .video-actions {
    justify-content: stretch;
  }

  .delivery-button,
  .shoot-editor-actions .delivery-button,
  .video-actions .delivery-button {
    width: 100%;
  }
}
