/* Shared palette. The product concept and marketing pages use the same tokens. */
:root {
  color-scheme: light;
  --surface: #ffffff;
  --paper: #f5f5f7;
  --soft: #edf1f7;
  --accent: #dce6f4;
  --ink: #1d1d1f;
  --secondary: #454d5a;
  --muted: #566171;
  --line: #dfe3e9;
  --line-strong: #aeb9c8;
  --blue: #2767b3;
  --solid: #155fbd;
  --on-solid: #ffffff;
  --focus: #2772d3;
  --hardware: #30343b;
  --warning: #825d13;
  --warning-soft: #f7edda;
  --danger: #b02d35;
  --danger-soft: #fae9eb;
  --header-glass: #ffffffed;
  --white: var(--surface);
  --deep: var(--solid);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --surface: #111216;
  --paper: #1b1d23;
  --soft: #242a35;
  --accent: #303e53;
  --ink: #f1f2f6;
  --secondary: #cbd0db;
  --muted: #a2aab8;
  --line: #343944;
  --line-strong: #5d6b80;
  --blue: #8bbaff;
  --solid: #2265bc;
  --focus: #9ac5ff;
  --hardware: #596373;
  --warning: #e5bd71;
  --warning-soft: #382e1c;
  --danger: #ffa3aa;
  --danger-soft: #3c222a;
  --header-glass: #111216ed;
}
body {
  background: var(--surface);
}
.site-header {
  background: var(--header-glass);
  border-color: var(--line);
}
.header-inner {
  gap: 22px;
}
.header-inner > .brand {
  margin-right: auto;
}
.text-link,
.contact-direct a,
.product-caption a,
.offer-link {
  color: var(--blue);
}
.studio-hero h1 > span {
  color: var(--blue);
}
.btn.dark,
.app-btn.primary {
  background: var(--solid);
  color: var(--on-solid);
}
.btn.dark:hover,
.app-btn.primary:hover {
  background: var(--solid);
  filter: brightness(1.12);
}
.btn:not(.dark) {
  color: var(--ink);
}
.offer-card,
.founder-card {
  background: var(--surface);
}
.offer-card {
  box-shadow: 0 4px 24px #10182706;
}
.product-desktop,
.product-island,
.mini-notch,
.demo-phone-top i {
  background: #24272d;
}
.product-phone,
.mini-phone,
.mini-window,
.demo-phone {
  border-color: #353b45;
}
.product-phone,
.demo-phone {
  box-shadow: 0 18px 45px #10182726;
}
.desktop-camera {
  background: #717c8b;
}
.phone-home-line {
  background: var(--ink);
}
.preview-pill,
.preview-action,
.journey-check {
  background: var(--solid);
  color: #fff;
}
.connection-section {
  background: #161e2b;
  color: #f4f6fb;
}
.connection-section .eyebrow,
.connection-number,
.connection-arrow {
  color: #a9bdd9;
}
.connection-section .studio-section-heading > p:not(.eyebrow),
.connection-story p,
.connection-section .section-footnote {
  color: #b8c2d1;
}
.connection-section .text-link {
  color: #9fc7ff;
}
.journey-ui {
  background: #253248;
  color: #f1f5fc;
}
.journey-ui small {
  color: #b4c3d7;
}
.journey-avatar {
  background: #384e6f;
  color: #fff;
}
.interest-option {
  border-radius: 10px;
  background: var(--surface);
  border-color: var(--line);
}
.interest-option > span,
.interest-option input:checked + span {
  background: transparent;
}
.interest-option:has(input:checked) {
  background: var(--soft);
  border-color: var(--blue);
}
.field input,
.field textarea,
.app-form select,
.assignment-form select {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line-strong);
}
input::placeholder,
textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}
input,
textarea,
select {
  caret-color: var(--blue);
}
dialog {
  background: var(--surface);
  color: var(--ink);
}
dialog::backdrop {
  background: #060a1280;
  backdrop-filter: blur(5px);
}
.toast {
  background: var(--ink);
  color: var(--surface);
}
.app-footnote {
  color: var(--muted) !important;
}
.mobile-menu nav {
  background: var(--header-glass);
  border-color: var(--line);
}
/* A fixed device shell: app content scrolls, the frame and tabs never grow. */
.demo-phone {
  height: 660px;
  display: flex;
  flex-direction: column;
}
.demo-phone-top,
.demo-phone-brand,
.phone-nav {
  flex-shrink: 0;
}
.demo-phone .mobile-content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
  scroll-padding-block: 16px;
}
.phone-nav {
  margin-top: auto;
  background: var(--paper);
}
.demo-phone .app-title {
  scroll-margin-top: 16px;
}
/* Native disclosure and buttons keep appearance settings keyboard accessible. */
.theme-menu {
  display: none;
  position: relative;
  flex-shrink: 0;
}
.theme-ready .theme-menu {
  display: block;
}
.theme-menu summary {
  display: flex;
  align-items: center;
  justify-content: center;
  list-style: none;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--secondary);
}
.theme-menu summary::-webkit-details-marker {
  display: none;
}
.theme-menu summary:hover,
.theme-menu[open] summary {
  background: var(--soft);
  color: var(--ink);
}
.theme-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.theme-options {
  position: absolute;
  right: 0;
  top: 50px;
  width: 190px;
  z-index: 30;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 12px 40px #060a1226;
}
.theme-options p {
  font-size: 11px;
  padding: 3px 10px 8px;
}
.theme-options button {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 0;
  background: transparent;
  border-radius: 8px;
  padding: 10px;
  font-size: 13px;
  color: var(--secondary);
  min-height: 42px;
}
.theme-options button:hover {
  background: var(--paper);
}
.theme-options button[aria-pressed="true"] {
  background: var(--soft);
  color: var(--blue);
  font-weight: 600;
}
.theme-options button span {
  font-size: 17px;
}
.theme-options small {
  display: block;
  font-size: 10px;
  line-height: 1.5;
  color: var(--muted);
  margin: 9px 10px 3px;
}
@media (max-width: 700px) {
  .header-inner {
    gap: 10px;
  }
  .desktop-nav {
    gap: 16px;
  }
}
@media (max-width: 600px) {
  .demo-phone {
    height: 620px;
  }
  .theme-options {
    right: -42px;
  }
  .header-inner {
    gap: 8px;
  }
}
@media (max-width: 360px) {
  .brand {
    font-size: 20px;
    gap: 6px;
  }
  .brand > svg {
    width: 24px;
    height: 24px;
  }
  .demo-phone {
    height: 600px;
  }
}
.phone-island {
  background: #353b45;
}
/* Atmospheric surfaces give the studio its own character in either mode. */
:root {
  --canvas: #eaf0f6;
  --canvas-bottom: #e0e8f2;
  --ambient-blue: #b7cee9;
  --ambient-warm: #eee3d7;
  --ambient-glow: #f7f4ed;
  --contour-ink: #476e9c27;
  --card-glass: #ffffffde;
  --header-glass: #eef2f7e8;
  --surface-shadow: #244a7810;
}
:root[data-theme="dark"] {
  --canvas: #111925;
  --canvas-bottom: #162437;
  --ambient-blue: #223f65;
  --ambient-warm: #302d31;
  --ambient-glow: #202d3c;
  --contour-ink: #b3d5ff17;
  --card-glass: #182332e8;
  --header-glass: #111a26e8;
  --surface-shadow: #00000026;
}
body {
  background:
    radial-gradient(ellipse at 100% 0, var(--ambient-blue), transparent 900px),
    var(--canvas);
}
.studio-hero {
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(ellipse at 9% 6%, var(--ambient-warm), transparent 49%),
    radial-gradient(ellipse at 86% 56%, var(--ambient-blue), transparent 63%),
    linear-gradient(
      160deg,
      var(--ambient-glow),
      var(--canvas) 48%,
      var(--canvas-bottom)
    );
}
.studio-hero::before {
  content: "";
  position: absolute;
  inset: -3% -8% 0;
  z-index: -1;
  background: var(--contour-ink);
  -webkit-mask: url("/assets/brand/studio-contours.svg") center / cover
    no-repeat;
  mask: url("/assets/brand/studio-contours.svg") center / cover no-repeat;
  pointer-events: none;
}
.product-scene::after {
  background: #16345b36;
}
.offers {
  background: var(--canvas-bottom);
  border-top: 1px solid var(--line);
}
.offer-card,
.founder-card {
  background: var(--card-glass);
  border: 1px solid var(--line);
  box-shadow: 0 12px 42px var(--surface-shadow);
}
.offer-visual {
  background: linear-gradient(transparent, var(--soft));
}
.offer-link {
  background: var(--card-glass);
}
.studio-process {
  background: linear-gradient(125deg, var(--ambient-glow), var(--canvas));
}
.founder-section {
  background: var(--canvas);
}
.closing {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 75% 120%, var(--ambient-blue), transparent 70%),
    linear-gradient(140deg, var(--ambient-warm), var(--canvas) 55%);
}
.closing::before {
  content: "";
  position: absolute;
  inset: -80% -15%;
  z-index: -1;
  background: var(--contour-ink);
  -webkit-mask: url("/assets/brand/studio-contours.svg") center / cover
    no-repeat;
  mask: url("/assets/brand/studio-contours.svg") center / cover no-repeat;
  pointer-events: none;
}
.site-footer {
  background: var(--canvas-bottom);
}
.service-art,
.service-art.company,
.service-art.operations {
  background:
    radial-gradient(ellipse at 65% 120%, var(--ambient-blue), transparent 70%),
    linear-gradient(130deg, var(--ambient-glow), var(--canvas-bottom));
  border: 1px solid var(--line);
}
.scenario,
.contact-card {
  background: var(--card-glass);
  border: 1px solid var(--line);
  box-shadow: 0 12px 42px var(--surface-shadow);
}
.experience {
  background: var(--canvas-bottom);
  box-shadow: 0 15px 50px var(--surface-shadow);
}
.preview-steps {
  background: var(--card-glass);
  border: 1px solid var(--line);
}
.preview-steps button[aria-pressed="true"] {
  background: var(--solid);
  color: #fff;
}
.connection-section {
  background:
    radial-gradient(ellipse at 0 100%, #244569 0, transparent 65%), #141f30;
}
@media (max-width: 600px) {
  .studio-hero::before {
    inset: 0 -85%;
    opacity: 0.8;
  }
}
/* Use the actual mark as a large, softly lit part of the background. */
:root {
  --brand-relief-left: #47658a12;
  --brand-relief-right: #3468a124;
}
:root[data-theme="dark"] {
  --brand-relief-left: #99bcea0a;
  --brand-relief-right: #8ebeff1b;
}
.studio-hero::after,
.closing::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: -1;
  width: min(1000px, 79vw);
  aspect-ratio: 1;
  right: -6%;
  top: 2%;
  background: linear-gradient(
    115deg,
    var(--brand-relief-left) 38%,
    var(--brand-relief-right)
  );
  -webkit-mask: url("/assets/brand/emekworks-logo-mark.svg") center / contain
    no-repeat;
  mask: url("/assets/brand/emekworks-logo-mark.svg") center / contain no-repeat;
}
.studio-hero::before {
  opacity: 0.65;
}
.closing::after {
  width: 550px;
  top: -100px;
  right: auto;
  left: -80px;
  transform: rotate(-10deg);
}
@media (max-width: 600px) {
  .studio-hero::after {
    width: 680px;
    right: -290px;
    top: 7%;
  }
  .studio-hero::before {
    opacity: 0.4;
  }
  .closing::after {
    width: 450px;
    left: -160px;
    top: -50px;
  }
}
