:root {
  color-scheme: light;
  --canvas: #f4f7f4;
  --surface: #fbfdfb;
  --surface-strong: #eef3ef;
  --surface-accent: #e2efe9;
  --ink: #15221e;
  --ink-soft: #31413b;
  --muted: #596760;
  --line: #d5ded9;
  --line-strong: #718178;
  --accent: #14644f;
  --accent-hover: #0d513f;
  --accent-soft: #dcece5;
  --accent-ink: #f8fcfa;
  --danger: #9f382f;
  --danger-soft: #f8e7e4;
  --warning: #7c5619;
  --shadow: 0 24px 70px rgba(37, 67, 55, 0.1);
  --card-radius: 18px;
  --control-radius: 10px;
  --button-radius: 10px;
  --page-width: 1180px;
  --header-height: 72px;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 20px);
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Helvetica Neue", sans-serif;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.nav-open {
  overflow: hidden;
}

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

button,
select {
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
}

p,
h1,
h2,
h3,
figure,
dl,
dd {
  margin-top: 0;
}

h1,
h2,
h3,
.brand {
  text-wrap: balance;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.08;
}

h1 {
  letter-spacing: -0.055em;
}

h2 {
  letter-spacing: -0.04em;
}

h3 {
  letter-spacing: -0.025em;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid #0b5c47;
  outline-offset: 3px;
}

.route-page h1[tabindex="-1"]:focus {
  outline: none;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 12px;
  z-index: 40;
  transform: translateY(-150%);
  border-radius: var(--button-radius);
  padding: 10px 14px;
  background: var(--ink);
  color: var(--accent-ink);
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.page-shell,
.nav-shell {
  width: min(var(--page-width), calc(100% - 48px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(213, 222, 217, 0.88);
  background: rgba(244, 247, 244, 0.94);
  backdrop-filter: blur(14px);
}

.nav-shell {
  display: flex;
  min-height: var(--header-height);
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 19px;
  font-weight: 750;
  letter-spacing: -0.04em;
  text-decoration: none;
}

.brand-mark {
  position: relative;
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid var(--accent);
  border-radius: 6px;
  transform: rotate(45deg);
}

.brand-mark::after {
  position: absolute;
  right: 3px;
  bottom: 3px;
  width: 6px;
  height: 6px;
  border-radius: 2px;
  background: var(--accent);
  content: "";
}

.nav-drawer,
.primary-nav,
.guest-actions,
.member-actions {
  display: flex;
  align-items: center;
}

.nav-drawer {
  flex: 1;
  justify-content: space-between;
  gap: 28px;
}

.primary-nav {
  gap: 4px;
}

.primary-nav a,
.workspace-nav a {
  border-radius: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
}

.primary-nav a {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  padding: 9px 12px;
}

.primary-nav a:hover,
.primary-nav a[aria-current="page"],
.workspace-nav a:hover,
.workspace-nav a[aria-current="page"] {
  color: var(--accent);
}

.primary-nav a[aria-current="page"] {
  background: var(--surface-accent);
}

.guest-actions,
.member-actions {
  gap: 10px;
}

.mobile-nav-button {
  display: none;
  min-height: 44px;
  border: 1px solid var(--line-strong);
  border-radius: var(--button-radius);
  padding: 8px 11px;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--button-radius);
  padding: 11px 18px;
  font-weight: 750;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}

.button-primary {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 8px 22px rgba(20, 100, 79, 0.18);
}

.button-primary:hover {
  border-color: var(--accent-hover);
  background: var(--accent-hover);
  color: var(--accent-ink);
}

.button-secondary {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--ink);
}

.button-secondary:hover,
.button-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.button-ghost {
  border-color: transparent;
  background: transparent;
  color: var(--ink);
}

.button-small {
  min-height: 42px;
  padding: 8px 14px;
  font-size: 14px;
}

.button-wide {
  width: 100%;
}

.button:active,
.text-link:active,
.text-button:active,
.account-menu-button:active {
  transform: translateY(1px) scale(0.99);
}

.button:disabled,
.text-button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.button[aria-busy="true"],
.text-button[aria-busy="true"] {
  cursor: wait;
}

.text-link,
.back-link,
.text-button {
  color: var(--accent);
  font-weight: 750;
}

.text-link {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
}

.back-link {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
}

.text-button {
  border: 0;
  min-height: 42px;
  padding: 8px 10px;
  background: transparent;
}

.credit-link {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--button-radius);
  padding: 8px 11px;
  color: var(--ink-soft);
  font-size: 13px;
  text-decoration: none;
}

.credit-link strong {
  color: var(--accent);
}

.account-menu {
  position: relative;
}

.account-menu-button {
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  border: 0;
  padding: 4px;
  background: transparent;
  color: var(--ink);
  font-weight: 700;
}

.account-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 9px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
}

.account-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 210px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  padding: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.account-popover a,
.account-popover button {
  display: block;
  width: 100%;
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  padding: 10px;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
  text-align: left;
  text-decoration: none;
}

.account-popover a:hover,
.account-popover button:hover {
  background: var(--surface-strong);
  color: var(--accent);
}

.hero {
  display: grid;
  min-height: calc(100dvh - var(--header-height));
  grid-template-columns: minmax(0, 0.92fr) minmax(380px, 0.88fr);
  align-items: center;
  gap: clamp(44px, 8vw, 110px);
  padding-block: 42px;
}

.hero-copy {
  max-width: 590px;
}

.hero-copy h1 {
  max-width: 12.5ch;
  margin-bottom: 22px;
  font-size: clamp(48px, 6vw, 76px);
  line-height: 0.99;
}

.hero-copy > p {
  max-width: 49ch;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 22px;
}

.hero-visual {
  width: min(100%, 485px);
  margin: 0 0 0 auto;
}

.hero-visual img,
.showcase-image img,
.auth-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-visual img {
  aspect-ratio: 6 / 7;
  border-radius: var(--card-radius);
  box-shadow: var(--shadow);
}

.hero-visual figcaption {
  max-width: 34ch;
  margin-top: 13px;
  color: var(--muted);
  font-size: 13px;
}

.service-strip {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface-strong);
}

.service-strip-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.service-strip p {
  display: grid;
  gap: 3px;
  margin: 0;
  padding: 24px 26px;
  border-right: 1px solid var(--line);
}

.service-strip p:first-child {
  padding-left: 0;
}

.service-strip p:last-child {
  border-right: 0;
}

.service-strip strong {
  font-size: 14px;
}

.service-strip span {
  color: var(--muted);
  font-size: 13px;
}

.editorial-section {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(420px, 1.18fr);
  gap: clamp(50px, 9vw, 130px);
  padding-block: 128px;
}

.eyebrow {
  margin-bottom: 14px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.section-copy {
  align-self: start;
  position: sticky;
  top: calc(var(--header-height) + 46px);
}

.section-copy h2,
.showcase-copy h2,
.home-pricing h2,
.final-cta h2 {
  margin-bottom: 18px;
  font-size: clamp(34px, 4.5vw, 54px);
}

.section-copy > p:last-child,
.showcase-copy > p,
.home-pricing p {
  max-width: 52ch;
  color: var(--muted);
}

.workflow-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.workflow-list li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 20px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.workflow-list li:first-child {
  padding-top: 0;
}

.workflow-index {
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
}

.workflow-list h3 {
  margin-bottom: 7px;
  font-size: 23px;
}

.workflow-list p {
  max-width: 48ch;
  margin-bottom: 0;
  color: var(--muted);
}

.showcase-section {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  align-items: center;
  gap: clamp(48px, 8vw, 105px);
  padding-bottom: 128px;
}

.showcase-image img {
  aspect-ratio: 4 / 3;
  border-radius: var(--card-radius);
}

.showcase-copy h2 {
  max-width: 11ch;
}

.feature-facts {
  display: grid;
  gap: 20px;
  margin: 32px 0 0;
}

.feature-facts div {
  padding-left: 16px;
  border-left: 2px solid var(--accent);
}

.feature-facts dt {
  margin-bottom: 2px;
  font-weight: 800;
}

.feature-facts dd {
  color: var(--muted);
  font-size: 14px;
}

.home-pricing,
.final-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 34px;
}

.home-pricing {
  margin-bottom: 36px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  padding: clamp(34px, 6vw, 64px);
  background: var(--surface);
}

.home-pricing h2 {
  margin-bottom: 10px;
}

.home-pricing p {
  margin-bottom: 0;
}

.final-cta {
  margin-bottom: 110px;
  border-radius: var(--card-radius);
  padding: clamp(34px, 6vw, 64px);
  background: var(--accent-soft);
}

.final-cta h2 {
  max-width: 16ch;
  margin-bottom: 0;
}

.auth-layout {
  display: grid;
  min-height: calc(100dvh - var(--header-height));
  grid-template-columns: minmax(340px, 0.9fr) minmax(420px, 1.1fr);
  gap: clamp(50px, 9vw, 125px);
  align-items: center;
  padding-block: 54px;
}

.auth-art {
  height: min(650px, calc(100dvh - 145px));
  min-height: 500px;
}

.auth-art img {
  border-radius: var(--card-radius);
}

.auth-panel {
  width: min(100%, 460px);
}

.back-link {
  display: inline-block;
  margin-bottom: 34px;
  font-size: 14px;
}

.auth-panel h1 {
  margin-bottom: 12px;
  font-size: clamp(42px, 5vw, 62px);
}

.auth-panel > p:not(.auth-switch) {
  margin-bottom: 30px;
  color: var(--muted);
}

.auth-switch {
  margin: 20px 0 0;
  color: var(--muted);
  text-align: center;
}

form {
  margin: 0;
}

.field-group {
  display: grid;
  gap: 7px;
  margin-bottom: 19px;
}

.field-group label,
fieldset legend,
.history-toolbar label {
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 750;
}

.label-row,
.field-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.label-row a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  font-size: 13px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: var(--control-radius);
  background: var(--surface);
  color: var(--ink);
  outline: none;
}

input,
select {
  min-height: 46px;
  padding: 10px 12px;
}

textarea {
  min-height: 170px;
  padding: 14px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #68766f;
  opacity: 1;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(20, 100, 79, 0.14);
}

input[aria-invalid="true"],
textarea[aria-invalid="true"] {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(159, 56, 47, 0.1);
}

.field-help,
.field-meta,
.field-error,
.form-status {
  margin: 0;
  font-size: 13px;
}

.field-help,
.field-meta {
  color: var(--muted);
}

.field-error,
.form-status.is-error {
  color: var(--danger);
}

.field-error:empty,
.form-status:empty {
  display: none;
}

.form-status {
  min-height: 20px;
  margin: 0 0 12px;
  color: var(--accent);
}

.consent-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 6px;
  color: var(--ink-soft);
  font-size: 13px;
}

.consent-field input {
  flex: 0 0 auto;
  width: 18px;
  min-height: 18px;
  margin-top: 2px;
  accent-color: var(--accent);
}

.workspace-nav {
  border-bottom: 1px solid var(--line);
  background: var(--surface-strong);
}

.workspace-nav-inner {
  display: flex;
  gap: 30px;
  overflow-x: auto;
}

.workspace-nav a {
  position: relative;
  padding: 16px 1px;
  white-space: nowrap;
}

.workspace-nav a[aria-current="page"]::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--accent);
  content: "";
}

.studio-shell,
.standard-page {
  min-height: 70dvh;
  padding-block: 58px 100px;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 38px;
}

.page-heading h1,
.pricing-heading h1,
.content-heading h1 {
  margin-bottom: 10px;
  font-size: clamp(42px, 5.8vw, 68px);
}

.page-heading > div > p:last-child,
.pricing-heading > p:last-child,
.content-heading > p:last-child {
  max-width: 58ch;
  margin-bottom: 0;
  color: var(--muted);
}

.page-heading > p {
  margin: 0 0 9px;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}

.page-heading > p span {
  color: var(--accent);
  font-size: 22px;
  font-weight: 800;
}

.studio-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(360px, 1.05fr);
  gap: 26px;
  align-items: stretch;
}

.composer-card,
.result-panel,
.account-card,
.support-card,
.payment-note {
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--surface);
}

.composer-card {
  padding: clamp(24px, 3vw, 34px);
}

.composer-header,
.generation-submit,
.section-heading-row,
.result-actions {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 22px;
}

.composer-header {
  margin-bottom: 28px;
}

.composer-header h2,
.section-heading-row h2,
.ledger-section h2,
.account-card h2,
.support-card h2 {
  margin-bottom: 5px;
  font-size: 25px;
}

.composer-header p,
.section-heading-row p,
.generation-submit p,
.result-actions p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
}

.model-status {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 9px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.model-status.is-live {
  border-color: rgba(20, 100, 79, 0.35);
  background: var(--accent-soft);
  color: var(--accent);
}

.generation-options {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(155px, 0.7fr);
  gap: 16px;
  align-items: end;
}

fieldset {
  min-width: 0;
  margin: 0 0 19px;
  border: 0;
  padding: 0;
}

fieldset legend {
  margin-bottom: 7px;
}

.segmented-control {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  border-radius: var(--control-radius);
  padding: 4px;
  background: var(--surface-strong);
}

.segmented-control label {
  position: relative;
}

.segmented-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  opacity: 0;
}

.segmented-control span {
  display: block;
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 8px 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
}

.segmented-control input:checked + span {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 2px 8px rgba(37, 67, 55, 0.06);
}

.segmented-control input:focus-visible + span {
  outline: 3px solid #0b5c47;
  outline-offset: 2px;
}

.select-field {
  margin-bottom: 19px;
}

.generation-submit {
  align-items: center;
  margin-top: 4px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.result-panel {
  display: grid;
  min-height: 590px;
  overflow: hidden;
}

.result-panel.is-empty,
.result-panel.is-loading {
  place-items: center;
  padding: 40px;
  background: var(--surface-strong);
}

.result-empty,
.result-loading {
  max-width: 390px;
  text-align: center;
}

.empty-kicker {
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.result-empty h2 {
  margin-bottom: 12px;
  font-size: 32px;
}

.result-empty > p:last-child,
.result-loading p {
  margin-bottom: 0;
  color: var(--muted);
}

.result-loading {
  width: min(100%, 360px);
}

.image-skeleton,
.state-skeleton,
.package-skeleton {
  background: linear-gradient(100deg, #e4eae6 20%, #f1f5f2 42%, #e4eae6 64%);
  background-size: 220% 100%;
}

.image-skeleton {
  width: 100%;
  aspect-ratio: 1;
  margin-bottom: 18px;
  border-radius: 14px;
}

.result-ready {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.result-ready > img {
  width: 100%;
  min-height: 470px;
  flex: 1;
  object-fit: cover;
  background: var(--surface-strong);
}

.result-note {
  display: grid;
  min-height: 470px;
  place-items: center;
  padding: 40px;
  background: var(--surface-strong);
  color: var(--muted);
  text-align: center;
}

.result-actions {
  align-items: center;
  padding: 18px;
}

.studio-recent,
.ledger-section {
  margin-top: 66px;
}

.section-heading-row {
  align-items: flex-end;
  margin-bottom: 20px;
}

.mini-gallery,
.history-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.mini-generation,
.history-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--surface);
}

.mini-generation img,
.history-card img,
.history-placeholder {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--surface-strong);
}

.history-placeholder {
  display: grid;
  place-items: center;
  padding: 20px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.mini-generation div,
.history-card-body {
  padding: 14px;
}

.mini-generation p,
.history-card h2 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.mini-generation p {
  margin-bottom: 5px;
  color: var(--ink-soft);
  font-size: 13px;
}

.mini-generation time,
.history-card time {
  color: var(--muted);
  font-size: 11px;
}

.history-toolbar {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 12px;
  margin: 0 0 24px auto;
}

.history-toolbar select {
  width: auto;
  min-width: 180px;
}

.history-card h2 {
  margin-bottom: 10px;
  font-size: 16px;
  line-height: 1.4;
}

.history-meta,
.history-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.history-meta {
  margin-bottom: 15px;
  color: var(--muted);
  font-size: 11px;
}

.history-status {
  color: var(--accent);
  font-weight: 750;
  text-transform: capitalize;
}

.history-status.is-failed {
  color: var(--danger);
}

.history-card-actions button,
.history-card-actions a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  border: 0;
  padding: 6px 0;
  background: transparent;
  color: var(--accent);
  font-size: 12px;
  font-weight: 750;
}

.page-state,
.inline-loading,
.empty-state,
.error-state,
.payment-disabled-banner {
  grid-column: 1 / -1;
  color: var(--muted);
  text-align: center;
}

.page-state,
.empty-state,
.error-state,
.payment-disabled-banner {
  display: grid;
  min-height: 260px;
  place-items: center;
  align-content: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--card-radius);
  padding: 30px;
}

.page-state p,
.empty-state p,
.error-state p {
  max-width: 48ch;
  margin: 10px auto 0;
}

.state-skeleton {
  width: 120px;
  height: 12px;
  border-radius: 6px;
}

.error-state {
  border-color: rgba(159, 56, 47, 0.3);
  background: var(--danger-soft);
  color: var(--danger);
}

.payment-disabled-banner {
  min-height: auto;
  border-style: solid;
  background: var(--surface-accent);
  color: var(--ink-soft);
}

.payment-disabled-banner p {
  margin-top: 4px;
}

.credit-summary {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--surface);
}

.credit-summary > div {
  display: grid;
  padding: clamp(28px, 5vw, 48px);
}

.credit-summary > div:first-child {
  border-right: 1px solid var(--line);
  background: var(--surface-accent);
}

.credit-summary span,
.credit-summary small {
  color: var(--muted);
}

.credit-summary strong {
  margin: 7px 0 1px;
  color: var(--accent);
  font-size: clamp(48px, 7vw, 76px);
  letter-spacing: -0.06em;
  line-height: 1;
}

.ledger-list {
  border-top: 1px solid var(--line);
}

.ledger-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.ledger-row p {
  margin-bottom: 3px;
  color: var(--ink-soft);
  font-weight: 700;
}

.ledger-row time {
  color: var(--muted);
  font-size: 12px;
}

.ledger-amount {
  font-weight: 800;
  white-space: nowrap;
}

.ledger-amount.is-positive {
  color: var(--accent);
}

.ledger-amount.is-negative {
  color: var(--danger);
}

.order-section {
  margin-top: 66px;
}

.order-list {
  border-top: 1px solid var(--line);
}

.order-list > .inline-loading,
.order-list > .empty-state,
.order-list > .error-state {
  margin-top: 18px;
}

.order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.order-main,
.order-meta {
  min-width: 0;
}

.order-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 3px 24px;
  align-items: center;
}

.order-title,
.order-main > strong {
  display: block;
  grid-row: 1;
  grid-column: 1;
  margin-bottom: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
}

.order-reference,
.order-main > small,
.order-meta,
.order-row time {
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.order-reference {
  grid-row: 2;
  grid-column: 1;
  margin-bottom: 0;
}

.order-meta {
  display: grid;
  grid-row: 1 / span 2;
  grid-column: 2;
  justify-items: end;
  gap: 3px;
  text-align: right;
}

.order-amount {
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
}

.order-status {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  padding: 6px 10px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: capitalize;
  white-space: nowrap;
}

.order-status.is-success,
.order-status.is-paid,
.order-status.is-completed,
.order-status.is-confirmed {
  border-color: rgba(20, 100, 79, 0.5);
  background: var(--accent-soft);
  color: var(--accent);
}

.order-status.is-pending,
.order-status.is-creation-unknown {
  border-color: rgba(124, 86, 25, 0.5);
  background: #f6eddb;
  color: var(--warning);
}

.order-status.is-failed,
.order-status.is-cancelled {
  border-color: rgba(159, 56, 47, 0.45);
  background: var(--danger-soft);
  color: var(--danger);
}

.pricing-heading,
.content-heading {
  max-width: 760px;
  margin: 0 auto 62px;
  text-align: center;
}

.packages-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.package-card,
.package-skeleton {
  min-height: 360px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
}

.package-card {
  display: flex;
  position: relative;
  flex-direction: column;
  padding: 30px;
  background: var(--surface);
}

.package-card.is-featured {
  border-color: var(--accent);
  background: var(--surface-accent);
}

.package-card h2 {
  margin-bottom: 7px;
  font-size: 24px;
}

.package-card > p {
  min-height: 48px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 14px;
}

.package-price {
  margin-bottom: 5px;
  color: var(--ink);
  font-size: 42px;
  font-weight: 800;
  letter-spacing: -0.05em;
}

.package-credits {
  margin-bottom: 26px;
  color: var(--accent);
  font-weight: 750;
}

.package-card .button {
  width: 100%;
  margin-top: auto;
}

.featured-label {
  align-self: flex-start;
  margin-bottom: 14px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.custom-pricing {
  display: grid;
  grid-template-columns: minmax(230px, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(32px, 6vw, 78px);
  align-items: center;
  margin-top: 28px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  padding: clamp(28px, 5vw, 48px);
  background: var(--surface-accent);
}

.custom-pricing h2 {
  margin-bottom: 10px;
  font-size: clamp(28px, 3.2vw, 38px);
}

.custom-pricing > div > p {
  max-width: 42ch;
  margin-bottom: 0;
  color: var(--ink-soft);
}

.custom-pricing form {
  display: grid;
  grid-template-columns: minmax(155px, 0.78fr) minmax(190px, 1fr);
  gap: 14px;
  align-items: end;
}

.custom-amount-field {
  display: grid;
  gap: 7px;
}

.custom-amount-field > label {
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 750;
}

.currency-input {
  position: relative;
}

.currency-input > span {
  position: absolute;
  top: 50%;
  left: 13px;
  z-index: 1;
  color: var(--ink-soft);
  font-weight: 800;
  transform: translateY(-50%);
  pointer-events: none;
}

.currency-input input {
  padding-left: 34px;
  font-weight: 750;
}

.custom-credit-result {
  display: grid;
  min-height: 46px;
  align-content: center;
  border: 1px solid var(--line);
  border-radius: var(--control-radius);
  padding: 7px 12px;
  background: var(--surface);
}

.custom-credit-result span {
  color: var(--muted);
  font-size: 11px;
}

.custom-credit-result strong {
  color: var(--accent);
  font-size: 15px;
}

.custom-pricing .button {
  grid-column: 1 / -1;
  width: 100%;
}

.payment-note {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 22px;
  margin-top: 28px;
  padding: 23px 26px;
}

.payment-note p {
  margin-bottom: 0;
  color: var(--muted);
}

.narrow-page {
  width: min(760px, calc(100% - 48px));
}

.account-card,
.support-card {
  padding: clamp(25px, 4vw, 38px);
}

.account-card dl {
  margin: 26px 0 30px;
}

.account-card dl div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.account-card dt {
  color: var(--muted);
}

.account-card dd {
  overflow-wrap: anywhere;
  font-weight: 750;
}

.support-card {
  margin-top: 18px;
  background: var(--surface-strong);
}

.support-card p {
  margin-bottom: 0;
  color: var(--muted);
}

.about-story {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(330px, 0.92fr);
  gap: clamp(48px, 9vw, 118px);
  align-items: start;
}

.about-story > section h2,
.company-panel h2 {
  margin-bottom: 16px;
  font-size: clamp(30px, 3.7vw, 44px);
}

.about-story > section p {
  max-width: 60ch;
  color: var(--ink-soft);
  font-size: 17px;
}

.about-story > section p:last-child {
  margin-bottom: 0;
}

.about-story dl {
  margin: 0;
  border-top: 1px solid var(--line);
}

.about-story dl > div {
  padding: 21px 0;
  border-bottom: 1px solid var(--line);
}

.about-story dt {
  margin-bottom: 5px;
  color: var(--ink);
  font-weight: 800;
}

.about-story dd {
  color: var(--muted);
  font-size: 14px;
}

.company-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: clamp(34px, 7vw, 84px);
  align-items: start;
  margin-top: 76px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  padding: clamp(30px, 5vw, 52px);
  background: var(--surface-accent);
}

.company-panel p {
  max-width: 56ch;
  margin-bottom: 0;
  color: var(--ink-soft);
}

.company-panel address {
  display: grid;
  gap: 5px;
  padding-left: 22px;
  border-left: 2px solid var(--accent);
  color: var(--ink-soft);
  font-size: 14px;
  font-style: normal;
}

.company-panel address strong {
  margin-bottom: 4px;
  color: var(--ink);
  font-size: 16px;
}

.help-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 13px 20px;
  margin-bottom: 52px;
  border: 1px solid var(--line);
  border-radius: var(--card-radius);
  padding: clamp(20px, 3vw, 28px);
  background: var(--surface);
}

.help-tools > label {
  grid-column: 1 / -1;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 750;
}

.help-tools input {
  min-width: 0;
}

.help-categories {
  display: flex;
  gap: 7px;
  align-items: center;
}

.help-categories button {
  min-height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 8px 13px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 750;
  white-space: nowrap;
}

.help-categories button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.help-categories button.is-active,
.help-categories button[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}

.faq-layout,
.legal-layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.7fr) minmax(0, 1.3fr);
  gap: clamp(45px, 9vw, 120px);
  align-items: start;
}

.help-callout {
  position: sticky;
  top: calc(var(--header-height) + 35px);
  border-radius: var(--card-radius);
  padding: 30px;
  background: var(--surface-accent);
}

.help-callout h2 {
  margin-bottom: 12px;
  font-size: 28px;
}

.help-callout p {
  color: var(--ink-soft);
}

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-list details {
  border-bottom: 1px solid var(--line);
}

.faq-list summary {
  min-height: 64px;
  padding: 22px 36px 22px 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 750;
  cursor: pointer;
}

.faq-list summary:focus-visible {
  outline-offset: 5px;
}

.faq-list details p {
  max-width: 62ch;
  margin: -7px 0 24px;
  color: var(--muted);
}

.help-empty {
  margin: 20px 0 0;
  border: 1px dashed var(--line-strong);
  border-radius: var(--card-radius);
  padding: 28px;
  background: var(--surface);
  color: var(--muted);
  text-align: center;
}

.legal-layout {
  grid-template-columns: 220px minmax(0, 1fr);
}

.legal-nav {
  display: grid;
  position: sticky;
  top: calc(var(--header-height) + 35px);
  gap: 5px;
}

.legal-nav a {
  display: flex;
  min-height: 42px;
  align-items: center;
  border-radius: 8px;
  padding: 9px 10px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.legal-nav a:hover,
.legal-nav a:focus-visible,
.legal-nav a[aria-current="page"] {
  background: var(--surface-accent);
  color: var(--accent);
}

.legal-copy {
  max-width: 750px;
}

.legal-copy article {
  margin-bottom: 66px;
  scroll-margin-top: calc(var(--header-height) + 28px);
}

.legal-copy article + article {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.legal-copy h2 {
  margin-bottom: 20px;
  font-size: 34px;
}

.legal-copy h3 {
  margin: 30px 0 8px;
  font-size: 19px;
}

.legal-copy p,
.legal-copy address {
  color: var(--ink-soft);
}

.legal-copy address {
  font-style: normal;
}

.legal-document-heading {
  max-width: 820px;
  margin-bottom: 58px;
}

.legal-document-heading .back-link {
  margin-bottom: 32px;
}

.legal-document-heading h1 {
  max-width: 14ch;
  margin-bottom: 16px;
  font-size: clamp(42px, 5.8vw, 68px);
}

.legal-document-heading > p:last-child {
  max-width: 62ch;
  margin-bottom: 0;
  color: var(--muted);
}

.legal-document > section {
  margin-bottom: 50px;
  scroll-margin-top: calc(var(--header-height) + 28px);
}

.legal-document > section + section {
  padding-top: 5px;
}

.legal-document h2 {
  margin-bottom: 14px;
  font-size: 30px;
}

.legal-document p {
  max-width: 68ch;
  color: var(--ink-soft);
}

.legal-document p:last-child {
  margin-bottom: 0;
}

.cookie-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0 0;
}

.cookie-facts > div {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--control-radius);
  padding: 17px;
  background: var(--surface);
}

.cookie-facts dt {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.cookie-facts dd {
  color: var(--ink-soft);
  font-size: 14px;
  overflow-wrap: anywhere;
}

code {
  border-radius: 5px;
  padding: 2px 5px;
  background: var(--surface-strong);
  color: var(--ink);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface-strong);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.45fr 0.62fr 0.78fr 0.85fr 1.18fr;
  gap: 32px;
  padding-block: 58px;
}

.footer-company p {
  max-width: 30ch;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.footer-grid nav,
.footer-grid address {
  display: grid;
  align-content: start;
  gap: 9px;
  font-size: 13px;
  font-style: normal;
}

.footer-grid nav strong,
.footer-grid address strong {
  margin-bottom: 4px;
  color: var(--ink);
}

.footer-grid nav a,
.footer-grid address span {
  color: var(--muted);
  text-decoration: none;
}

.footer-grid nav a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-block: 18px 26px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}

.footer-legal-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.footer-legal-links a {
  color: var(--muted);
  text-decoration: none;
}

.footer-legal-links a:hover {
  color: var(--accent);
}

.toast-region {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 30;
  display: grid;
  width: min(360px, calc(100% - 40px));
  gap: 10px;
  pointer-events: none;
}

.toast {
  border: 1px solid var(--line-strong);
  border-radius: var(--control-radius);
  padding: 13px 15px;
  background: var(--ink);
  color: var(--accent-ink);
  box-shadow: var(--shadow);
  font-size: 13px;
}

.toast.is-error {
  border-color: var(--danger);
  background: var(--danger-soft);
  color: var(--danger);
}

@media (prefers-reduced-motion: no-preference) {
  .button,
  .text-link,
  .text-button,
  .account-menu-button,
  .primary-nav a,
  .workspace-nav a,
  .account-popover a,
  .account-popover button {
    transition: transform 160ms ease, color 160ms ease, border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
  }

  .reveal-item {
    animation: reveal 620ms cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .hero-visual {
    animation-delay: 90ms;
  }

  .route-page:not([hidden]) > .standard-page,
  .route-page:not([hidden]) > .studio-shell,
  .route-page:not([hidden]) > .auth-layout {
    animation: route-in 300ms cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .image-skeleton,
  .state-skeleton,
  .package-skeleton {
    animation: shimmer 1.4s linear infinite;
  }

  .toast {
    animation: toast-in 220ms cubic-bezier(0.16, 1, 0.3, 1) both;
  }
}

@keyframes reveal {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes route-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes shimmer {
  to { background-position-x: -220%; }
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1000px) {
  .account-name {
    display: none;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(330px, 0.8fr);
    gap: 40px;
  }

  .hero-copy h1 {
    font-size: clamp(48px, 6.7vw, 66px);
  }

  .editorial-section,
  .showcase-section {
    gap: 52px;
  }

  .studio-grid {
    grid-template-columns: 1fr;
  }

  .result-panel {
    min-height: 520px;
  }

  .mini-gallery,
  .history-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .about-story {
    gap: 54px;
  }

  .package-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }

  .footer-grid {
    grid-template-columns: 1.2fr repeat(3, minmax(0, 0.8fr));
  }

  .footer-grid address {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 64px;
  }

  .page-shell,
  .nav-shell,
  .narrow-page {
    width: min(100% - 30px, var(--page-width));
  }

  .site-header {
    backdrop-filter: none;
    background: var(--canvas);
  }

  .nav-shell {
    position: relative;
  }

  .mobile-nav-button {
    display: inline-flex;
  }

  .nav-drawer {
    position: fixed;
    top: var(--header-height);
    right: 0;
    bottom: 0;
    left: 0;
    display: none;
    align-items: stretch;
    justify-content: flex-start;
    flex-direction: column;
    gap: 28px;
    overflow-y: auto;
    padding: 24px 15px 36px;
    background: var(--canvas);
  }

  body.nav-open .nav-drawer {
    display: flex;
  }

  .primary-nav {
    display: grid;
    gap: 5px;
  }

  .primary-nav a {
    padding: 13px 14px;
    font-size: 17px;
  }

  .guest-actions,
  .member-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .guest-actions .button,
  .credit-link,
  .account-menu-button {
    width: 100%;
  }

  .account-menu-button {
    justify-content: flex-start;
  }

  .account-name {
    display: inline;
  }

  .account-popover {
    position: static;
    width: 100%;
    margin-top: 8px;
    box-shadow: none;
  }

  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 34px;
    padding-block: 52px 60px;
  }

  .hero-copy h1 {
    max-width: 13ch;
    font-size: clamp(45px, 14vw, 62px);
  }

  .hero-copy > p {
    font-size: 17px;
  }

  .hero-visual {
    width: 100%;
    margin: 0;
  }

  .hero-visual img {
    aspect-ratio: 4 / 3;
  }

  .service-strip-inner {
    grid-template-columns: 1fr;
  }

  .service-strip p,
  .service-strip p:first-child {
    padding: 18px 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .service-strip p:last-child {
    border-bottom: 0;
  }

  .editorial-section,
  .showcase-section,
  .auth-layout,
  .about-story,
  .company-panel,
  .custom-pricing,
  .faq-layout,
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .editorial-section {
    gap: 44px;
    padding-block: 82px;
  }

  .section-copy,
  .help-callout,
  .legal-nav {
    position: static;
  }

  .showcase-section {
    gap: 38px;
    padding-bottom: 82px;
  }

  .showcase-copy h2 {
    max-width: none;
  }

  .home-pricing,
  .final-cta,
  .page-heading,
  .section-heading-row,
  .generation-submit {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-pricing,
  .final-cta {
    padding: 30px;
  }

  .home-pricing .button,
  .final-cta .button {
    width: 100%;
  }

  .final-cta {
    margin-bottom: 72px;
  }

  .auth-layout {
    padding-block: 38px 68px;
  }

  .auth-art {
    display: none;
  }

  .auth-panel {
    width: 100%;
  }

  .back-link {
    margin-bottom: 26px;
  }

  .studio-shell,
  .standard-page {
    padding-block: 42px 72px;
  }

  .page-heading {
    gap: 18px;
    margin-bottom: 30px;
  }

  .page-heading .button,
  .page-heading > p {
    width: 100%;
  }

  .studio-grid {
    gap: 16px;
  }

  .composer-card {
    padding: 20px;
  }

  .composer-header {
    align-items: flex-start;
    flex-direction: column-reverse;
  }

  .generation-options {
    grid-template-columns: 1fr;
  }

  .generation-submit .button {
    width: 100%;
  }

  .result-panel {
    min-height: 430px;
  }

  .result-ready > img,
  .result-note {
    min-height: 360px;
  }

  .mini-gallery,
  .history-grid,
  .packages-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .package-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }

  .credit-summary {
    grid-template-columns: 1fr;
  }

  .credit-summary > div:first-child {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .pricing-heading,
  .content-heading {
    margin-bottom: 42px;
    text-align: left;
  }

  .custom-pricing {
    gap: 28px;
  }

  .company-panel {
    gap: 30px;
    margin-top: 56px;
  }

  .help-tools {
    grid-template-columns: 1fr;
    margin-bottom: 38px;
  }

  .help-categories {
    flex-wrap: wrap;
  }

  .order-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px 20px;
  }

  .order-main {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    gap: 4px;
  }

  .order-status {
    align-self: start;
  }

  .order-meta {
    grid-row: auto;
    grid-column: 1;
    justify-items: start;
    text-align: left;
  }

  .order-title,
  .order-reference {
    grid-row: auto;
    grid-column: 1;
  }

  .payment-note {
    grid-template-columns: 1fr;
  }

  .account-card dl div {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .legal-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
  }

  .legal-nav a {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    background: var(--surface);
  }

  .legal-document-heading {
    margin-bottom: 42px;
  }

  .legal-document-heading h1 {
    max-width: 16ch;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 38px 28px;
  }

  .footer-company,
  .footer-grid address {
    grid-column: 1 / -1;
  }

  .footer-grid address {
    grid-column: auto;
  }

  .footer-grid nav a {
    display: flex;
    min-height: 44px;
    align-items: center;
  }
}

@media (max-width: 500px) {
  .brand {
    font-size: 17px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 15px;
  }

  .hero-actions .text-link {
    text-align: center;
  }

  .workflow-list li {
    grid-template-columns: 30px 1fr;
    gap: 12px;
  }

  .segmented-control span {
    font-size: 11px;
  }

  .mini-gallery,
  .history-grid,
  .packages-grid {
    grid-template-columns: 1fr;
  }

  .custom-pricing form,
  .cookie-facts {
    grid-template-columns: 1fr;
  }

  .custom-pricing .button {
    grid-column: auto;
  }

  .help-categories {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .help-categories button {
    width: 100%;
  }

  .order-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .order-main,
  .order-status,
  .order-meta {
    grid-column: auto;
  }

  .order-status {
    justify-self: start;
  }

  .package-card:last-child:nth-child(odd) {
    grid-column: auto;
  }

  .history-toolbar {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
    margin-left: 0;
  }

  .history-toolbar select {
    width: 100%;
  }

  .result-actions,
  .footer-bottom {
    align-items: stretch;
    flex-direction: column;
  }

  .result-actions .button {
    width: 100%;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-legal-links {
    flex-wrap: wrap;
    gap: 4px 18px;
  }

  .footer-legal-links a {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
  }

  .footer-company,
  .footer-grid address {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .site-header {
    background: var(--canvas);
    backdrop-filter: none;
  }
}
