/* Inter 4.1 by Rasmus Andersson, licensed under SIL OFL 1.1.
   Self hosted so the interface never waits on an external font service. */
@font-face {
  font-family: "InterVariable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/InterVariable-4.1.woff2") format("woff2");
}

:root {
  --font-ui: "InterVariable", Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-family: var(--font-ui);
  font-feature-settings: "liga" 1, "calt" 1;
  font-optical-sizing: auto;
}

body, body.hybrid-app { font-family: var(--font-ui); }
button, input, textarea, select { font-family: inherit; }
h1, h2, h3, h4, h5, h6,
.hybrid-app h1, .hybrid-app h2, .hybrid-app h3,
.hybrid-app .step-heading h3, .proposal-heading h3 {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: -.035em;
}
.hybrid-app h1 { font-size: clamp(28px, 3vw, 40px); line-height: 1.18; }
.hybrid-app h2 { font-size: clamp(22px, 2.2vw, 28px); line-height: 1.25; }
.hybrid-app .step-heading h3 { font-size: clamp(21px, 2vw, 25px); line-height: 1.25; }
.hybrid-app .creation-summary strong { font-weight: 600; letter-spacing: -.02em; }
.hybrid-app .brand-copy strong { font-family: var(--font-ui); font-weight: 600; font-size: 14px; letter-spacing: .16em; }
.dashboard-metric strong, .member-app .creator-metric strong { font-weight: 600; letter-spacing: -.04em; }
.billing-plan > strong { font-weight: 600; letter-spacing: -.025em; }

/* This is the first painted view, before any API response or script runs. */
.boot-loader { padding: 28px 0 8px; }
.boot-heading { display: flex; align-items: flex-start; gap: 20px; margin-bottom: 30px; }
.boot-heading h1 { margin: 0 0 10px; }
.boot-heading .eyebrow { margin-bottom: 12px; }
.boot-heading p:last-child { max-width: 660px; margin: 0; font-size: 14px; color: var(--muted); }
.boot-spinner { flex: 0 0 40px; width: 40px; height: 40px; margin-top: 5px; border: 3px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: boot-spin .9s linear infinite; }
.loading-progress { display: block; width: 100%; height: 8px; overflow: hidden; border: 0; border-radius: 999px; appearance: none; -webkit-appearance: none; background: #e9e1d4; color: var(--accent); }
.loading-progress::-webkit-progress-bar { background: transparent; border-radius: inherit; }
.loading-progress::-webkit-progress-value { background: linear-gradient(90deg, #ad813a, #d2ae70); border-radius: inherit; transition: width .4s ease; }
.loading-progress::-moz-progress-bar { background: linear-gradient(90deg, #ad813a, #d2ae70); border-radius: inherit; transition: width .4s ease; }
.loading-progress[value]::-webkit-progress-value { background: linear-gradient(100deg, #ad813a 15%, #d2ae70 40%, #eed6ab 50%, #d2ae70 60%, #ad813a 85%); background-size: 200% 100%; animation: loading-progress-shimmer 2.8s ease-in-out infinite; }
.loading-progress[value]::-moz-progress-bar { background: linear-gradient(100deg, #ad813a 15%, #d2ae70 40%, #eed6ab 50%, #d2ae70 60%, #ad813a 85%); background-size: 200% 100%; animation: loading-progress-shimmer 2.8s ease-in-out infinite; }
.loading-progress:indeterminate { background-image: linear-gradient(90deg, transparent, #b68b47 30%, #d2ae70 70%, transparent); background-size: 45% 100%; background-repeat: no-repeat; animation: loading-progress-travel 1.7s ease-in-out infinite; }
.loading-progress:indeterminate::-moz-progress-bar { background: transparent; }
.boot-loading-progress { margin: 0 0 28px; }
.generation-loading { padding: 26px 28px; margin: 0 0 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.generation-loading-heading { display: flex; align-items: flex-start; gap: 18px; margin-bottom: 22px; }
.generation-loading-heading .boot-spinner { flex-basis: 32px; width: 32px; height: 32px; margin-top: 2px; }
.generation-loading-heading .eyebrow { margin: 0 0 9px; }
.generation-loading-heading h2 { margin: 0 0 9px; }
.generation-loading-heading p:last-child { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }
#generationLoading:not([hidden]) + #apiNotice { display: none; }
.boot-project { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 28px; }
.boot-panel { display: grid; align-content: start; gap: 24px; min-width: 0; padding: 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.boot-line, .boot-steps i, .boot-styles i, .boot-action, .boot-photo { position: relative; overflow: hidden; background: var(--soft); border-radius: 8px; }
.boot-line::after, .boot-steps i::after, .boot-styles i::after, .boot-action::after, .boot-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 20%, #fff8 50%, transparent 80%); transform: translateX(-100%); animation: boot-shimmer 1.9s ease-in-out infinite; }
.boot-line { width: 83%; height: 12px; }
.boot-line-title { width: 57%; height: 23px; }
.boot-line-short { width: 45%; }
.boot-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.boot-steps i { height: 36px; }
.boot-styles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.boot-styles i { height: 126px; border: 1px solid var(--line); background: linear-gradient(160deg, #f4efe7, #e8e0d3); }
.boot-action { height: 47px; width: 100%; margin-top: 6px; }
.boot-preview { gap: 19px; }
.boot-photo { display: grid; place-items: center; min-height: 242px; aspect-ratio: 4/3; border: 1px solid var(--line); background: linear-gradient(145deg, #f3eee5, #e8e0d3); }
.boot-photo svg { width: 54px; height: 54px; color: #a99b84; }
.boot-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-top: 20px; }
.boot-footer p { margin: 0; color: var(--muted); font-size: 12px; }
.boot-loader.has-error .boot-spinner { animation: none; border-color: var(--line); border-top-color: var(--error); }
.boot-loader.has-error .boot-project { opacity: .6; }
.boot-loader.has-error .boot-project ::after { animation: none; }
.boot-loader.has-error .boot-loading-progress { display: none; animation: none; }
.studio-app:has(#bootLoader:not([hidden])) #saveStatus { display: none; }
.studio-app:has(#bootLoader:not([hidden])) .hybrid-nav > :not(a[href*="view=help"]) { display: none; }

/* First project: the photo, the style and the generation are the whole journey. */
body.onboarding-mode .hybrid-nav :is(#dashboardBtn, #homeBtn, a[href*="view=images"], [data-view="home"], [data-view="projects"], [data-view="images"]),
body.onboarding-mode :is(#headerCredits, #creditBadge, #dashboard, #home, #realisations, #library),
body.onboarding-mode #workspace > .breadcrumbs,
body.onboarding-mode #workspace > .project-bar > .actions,
body.onboarding-mode :is(.room-settings, #roomTabs, [data-hybrid-projects]) { display: none !important; }
body.onboarding-mode .project-bar { margin-bottom: 24px; }
body.onboarding-mode .hybrid-nav { margin-left: auto; }

@keyframes boot-spin { to { transform: rotate(360deg); } }
@keyframes boot-shimmer { 55%, 100% { transform: translateX(100%); } }
@keyframes loading-progress-travel { 0%, 100% { background-position: 0 0; } 50% { background-position: 100% 0; } }
@keyframes loading-progress-shimmer { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0 0; } }
@media (max-width: 760px) {
  .boot-loader { padding-top: 18px; }
  .boot-heading { gap: 14px; margin-bottom: 24px; }
  .boot-heading h1 { font-size: 25px; }
  .boot-heading .eyebrow { font-size: 9px; }
  .boot-heading p:last-child { font-size: 13px; }
  .boot-spinner { width: 30px; height: 30px; flex-basis: 30px; border-width: 2px; }
  .boot-loading-progress { margin-bottom: 20px; }
  .generation-loading { padding: 22px 20px; margin-bottom: 20px; }
  .generation-loading-heading { gap: 14px; margin-bottom: 18px; }
  .generation-loading-heading .boot-spinner { flex-basis: 26px; width: 26px; height: 26px; }
  .generation-loading-heading h2 { font-size: 22px; }
  .generation-loading-heading p:last-child { font-size: 13px; }
  .boot-project { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .boot-panel { padding: 20px; gap: 20px; }
  .boot-preview { display: none; }
  .boot-styles i { height: 100px; }
  .boot-steps { gap: 8px; }
  .boot-footer { margin-top: 16px; }
  .boot-footer button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .boot-spinner, .boot-project ::after, .loading-progress:indeterminate { animation: none; }
  .loading-progress:indeterminate { background-position: center; }
  .loading-progress::-webkit-progress-value, .loading-progress::-moz-progress-bar { transition: none; }
  .loading-progress[value]::-webkit-progress-value, .loading-progress[value]::-moz-progress-bar { animation: none; }
  .boot-line::after, .boot-steps i::after, .boot-styles i::after, .boot-action::after, .boot-photo::after { display: none; }
}
