@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-weight: 400;
  font-stretch: 75% 100%;
  font-display: block;
  src: url("https://shakl.cc/fonts/InstrumentSans-latin-ext.woff2") format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113,
    U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-weight: 400;
  font-stretch: 75% 100%;
  font-display: block;
  src: url("https://shakl.cc/fonts/InstrumentSans-latin.woff2") format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308,
    U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  font-family: "Instrument Sans", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
  text-rendering: geometricPrecision;

  --ink: #0a0a0a;
  --paper: #ffffff;
  --on-ink: #ffffff;
  --soft: #f7f7f5;
  --cloud: #efefed;
  --muted: #73746f;
  --muted-strong: #666762;
  --icon-on-light: #5b3fc4;
  --icon-on-dark: #ffffff;
  --shakl-aqua-strong: #70ddda;
  --shakl-violet-strong: #ab8cf6;
  --shakl-sky-soft: #c9edff;
  --sky: #a9e1f7;
  --aqua: #63d9db;
  --mint: #8fe46c;
  --violet: #b99af8;
  --radius: 40px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shakl-page-x: 3vw;
  --shakl-content-x: 4vw;
  --shakl-section-gap: 112px;
  --shakl-section-gap-compact: 72px;
  --shakl-card-gap: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html,
body,
#root {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--paper);
}

html,
body,
button,
input,
textarea,
select {
  font-family: "Instrument Sans", system-ui, sans-serif;
}

button,
input { font: inherit; }

button { cursor: pointer; }

a {
  color: inherit;
  text-decoration: none;
}

::selection {
  background: #b9a0ff;
  color: var(--ink);
}

.app-shell { min-height: 100vh; }

.header {
  position: fixed;
  z-index: 50;
  top: 18px;
  left: 28px;
  right: 28px;
  height: 66px;
  padding: 0 18px 0 22px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border: 1px solid rgba(10, 10, 10, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(22px) saturate(140%);
  box-shadow: 0 12px 44px rgba(20, 25, 30, 0.06);
}

.brand {
  width: 114px;
  display: flex;
  color: var(--ink);
}

.brand svg,
.footer-brand svg {
  display: block;
  width: 100%;
  height: auto;
}

.desktop-nav {
  display: flex;
  gap: 34px;
  font-size: 14px;
}

.desktop-nav a {
  transition: opacity 0.25s;
}

.desktop-nav a:hover { opacity: 0.45; }

.header-cta {
  justify-self: end;
  min-height: 42px;
  padding: 0 19px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--on-ink);
  font-size: 14px;
}

.menu-toggle {
  display: none;
  border: 0;
  background: transparent;
}

.mobile-nav { display: none; }

.workspace {
  position: relative;
  min-height: 100vh;
  padding-top: 102px;
}

.tool-status {
  position: absolute;
  z-index: 4;
  top: 116px;
  right: calc(var(--shakl-page-x) + 14px);
  min-height: 36px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(10, 10, 10, 0.09);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #73746f;
  font-size: 12px;
  backdrop-filter: blur(16px);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--mint);
}

.empty-stage {
  min-height: calc(100vh - 102px);
  padding: 30px var(--shakl-content-x) 44px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(520px, 1.1fr);
  gap: clamp(48px, 7vw, 120px);
  align-items: center;
}

.hero-copy { align-self: center; }

.eyebrow {
  margin: 0 0 26px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.hero-copy h1 {
  max-width: 800px;
  margin: 0;
  font-size: clamp(64px, 7.6vw, 136px);
  font-weight: 500;
  line-height: 0.82;
  letter-spacing: -0.07em;
}

.hero-description {
  max-width: 480px;
  margin: 34px 0 0;
  color: #5f615d;
  font-size: clamp(18px, 1.35vw, 24px);
  line-height: 1.4;
}

.drop-zone {
  position: relative;
  min-height: min(68vw, 730px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 34px;
  border: 1px solid #ecece8;
  border-radius: 40px;
  background:
    radial-gradient(circle at 22% 70%, rgba(99, 217, 219, 0.42), transparent 42%),
    radial-gradient(circle at 82% 24%, rgba(185, 154, 248, 0.38), transparent 42%),
    linear-gradient(145deg, #f9fbff, #edf5ff);
  transition:
    transform 0.45s var(--ease),
    box-shadow 0.45s;
}

.drop-zone:hover,
.drop-zone.is-dragging {
  transform: translateY(-7px);
  box-shadow: 0 28px 70px rgba(25, 30, 35, 0.09);
}

@keyframes orbit {
  from { transform: rotate(-8deg) translate3d(-2%, 1%, 0); }
  to { transform: rotate(12deg) translate3d(3%, -2%, 0); }
}

.drop-copy {
  position: relative;
  display: grid;
  gap: 6px;
  margin-bottom: 22px;
}

.drop-copy strong {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.035em;
}

.drop-copy span {
  color: #676862;
  font-size: 14px;
}

.primary-button,
.secondary-button {
  min-height: 50px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  transition:
    transform 0.35s var(--ease),
    background 0.35s,
    color 0.35s;
}

.primary-button {
  position: relative;
  width: 100%;
  padding: 0 23px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--ink);
  color: var(--on-ink);
}

.secondary-button {
  margin-top: auto;
  padding: 0 20px;
  background: var(--paper);
  color: var(--ink);
}

.landing-actions {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 100%;
}

.landing-actions > * {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  margin: 0;
  min-height: 100px;
  border-radius: 20px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px;
  padding: 18px 12px !important;
  text-align: center;
  font-size: 13px;
}

.landing-editor-button {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-inline: 12px;
}

.primary-button:hover,
.secondary-button:hover { transform: translateY(-2px); }

.error-message {
  margin: 14px 0 0;
  color: #8b1d1d;
  font-size: 13px;
}

.upload-feedback{
  position:relative;
  z-index:2;
  margin:0 0 10px;
  padding:10px 12px;
  display:flex;
  align-items:center;
  gap:8px;
  border:1px solid rgba(10,10,10,.08);
  border-radius:12px;
  background:rgba(255,255,255,.82);
  color:#5f615d;
  font-size:12px;
  backdrop-filter:blur(12px)
}
.upload-feedback-dot{
  width:7px;height:7px;border-radius:50%;background:var(--aqua);flex:0 0 auto
}
.upload-feedback.is-error{
  border-color:rgba(139,29,29,.18);
  color:#8b1d1d;
  background:rgba(255,248,248,.92)
}
.upload-feedback.is-error .upload-feedback-dot{background:#8b1d1d}
.primary-button:disabled{opacity:.58;cursor:wait;transform:none}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.editor-stage {
  min-height: calc(100vh - 102px);
  padding: 0 var(--shakl-page-x) 28px;
  display: grid;
  grid-template-columns: 238px minmax(0, 1fr) 318px;
  gap: var(--shakl-card-gap);
}

.tool-panel,
.analysis-panel {
  padding: 28px;
  border: 1px solid #ecece8;
  border-radius: 28px;
  background: var(--soft);
}

.tool-panel {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.tool-panel h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.04em;
  word-break: break-word;
}

.meta-list {
  display: grid;
  gap: 1px;
  margin: 0;
}

.meta-list div,
.feature-row {
  padding: 14px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid #dadad6;
}

.meta-list dt,
.feature-row span:first-child {
  color: #73746f;
  font-size: 12px;
}

.meta-list dd,
.feature-row span:last-child {
  margin: 0;
  font-size: 12px;
}

.feature-row span:last-child { color: var(--muted-strong); }

.panel-note {
  display: flex;
  gap: 10px;
  color: #656660;
  font-size: 12px;
  line-height: 1.5;
}

.panel-note-dot {
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--violet);
}

.canvas-wrap {
  position: relative;
  min-width: 0;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 1px solid #ecece8;
  border-radius: var(--radius);
  background: var(--cloud);
}

.canvas-grid {
  position: absolute;
  inset: 0;
  opacity: 0.46;
  background-image:
    linear-gradient(rgba(10, 10, 10, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(10, 10, 10, 0.045) 1px, transparent 1px);
  background-size: 24px 24px;
}

.svg-preview {
  position: relative;
  z-index: 1;
  width: min(72%, 780px);
  max-height: 72vh;
  padding: clamp(28px, 5vw, 72px);
  display: grid;
  place-items: center;
  border: 1px solid #ecece8;
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 28px 70px rgba(25, 30, 35, 0.08);
}

.svg-preview svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 56vh;
}

.canvas-caption {
  position: absolute;
  z-index: 2;
  right: 22px;
  bottom: 18px;
  left: 22px;
  display: flex;
  justify-content: space-between;
  color: #73746f;
  font-size: 11px;
}

.site-footer {
  margin: 72px 2vw 8px;
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  border-radius: 28px;
  background: var(--ink);
  color: var(--on-ink);
}

.footer-top,
.footer-bottom {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-bottom {
  border-top: 1px solid #2c2c2c;
  padding-top: 20px;
}

.footer-brand {
  width: 110px;
  flex-shrink: 0;
  display: flex;
  color: var(--on-ink);
}

.footer-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px 24px;
  color: #bbb;
  font-size: 13px;
}

.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  white-space: nowrap;
  transition: color 0.25s, opacity 0.25s;
}

.site-footer a:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 5px;
  border-radius: 4px;
}

.footer-nav a:hover { color: var(--on-ink); }

.social-links--compact {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 8px;
}

.social-links--compact a {
  width: 38px;
  height: 38px;
  min-height: 38px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid #343434;
  border-radius: 999px;
  color: #bbb;
  transition: 0.3s;
}

.social-links--compact a:hover {
  border-color: var(--on-ink);
  background: var(--paper);
  color: var(--ink);
}

.social-links--compact svg {
  width: 18px;
  height: 18px;
}

.footer-signature {
  margin: 0;
  color: #f2f2f2;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: -0.025em;
  white-space: normal;
  text-wrap: balance;
}

.shakl-heart {
  display: inline-block;
  margin: 0 0.16em;
  font-size: 1.12em;
  line-height: 1;
  background: linear-gradient(90deg, var(--sky), var(--aqua), var(--mint), var(--violet), var(--sky));
  background-size: 300% 100%;
  background-position: 0 50%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: saturate(1.08);
  will-change: transform, background-position;
  animation:
    shakl-heart-flow 5s linear infinite,
    shakl-heart-float 2.8s ease-in-out infinite;
}

.footer-signature:hover .shakl-heart {
  animation-duration: 2.8s, 2.1s;
}

@keyframes shakl-heart-flow {
  to { background-position: 300% 50%; }
}

@keyframes shakl-heart-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}

@media (max-width: 1100px) {
  :root {
    --shakl-section-gap: 88px;
    --shakl-section-gap-compact: 60px;
  }

  .empty-stage { grid-template-columns: 1fr; }

  .drop-zone { min-height: 560px; }

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

  .analysis-panel { display: none; }

}

@media (max-width: 760px) {
  :root {
    --shakl-section-gap: 64px;
    --shakl-section-gap-compact: 48px;
    --shakl-card-gap: 10px;
  }

  .header {
    top: 10px;
    left: 12px;
    right: 12px;
    height: 58px;
    padding: 0 15px;
    grid-template-columns: 1fr auto;
  }

  .brand { width: 96px; }

  .desktop-nav,
  .header-cta { display: none; }

  .menu-toggle {
    display: block;
    justify-self: end;
    padding: 8px;
    font-size: 22px;
    line-height: 1;
  }

  .mobile-nav {
    position: absolute;
    top: 66px;
    left: 0;
    right: 0;
    padding: 18px;
    display: grid;
    gap: 12px;
    border: 1px solid rgba(10, 10, 10, 0.1);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 48px rgba(20, 25, 30, 0.1);
    backdrop-filter: blur(22px);
  }

  .workspace { padding-top: 82px; }

  .tool-status {
    top: 94px;
    right: 22px;
  }

  .empty-stage {
    min-height: calc(100vh - 82px);
    padding: 24px 18px 28px;
  }

  .hero-copy h1 {
    font-size: clamp(56px, 17vw, 88px);
  }

  .drop-zone {
    min-height: 440px;
    padding: 24px;
    border-radius: 32px;
  }

  .landing-actions {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .landing-actions > * {
    min-height: 54px !important;
    border-radius: 999px !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    padding: 0 22px !important;
    font-size: 14px;
  }

  .editor-stage {
    min-height: calc(100vh - 82px);
    grid-template-columns: 1fr;
    padding: 0 12px 12px;
  }

  .tool-panel { display: none; }

  .canvas-wrap {
    min-height: calc(100vh - 94px);
    border-radius: 32px;
  }

  .svg-preview {
    width: 90%;
    padding: 24px;
    border-radius: 28px;
  }

  .site-footer {
    margin: 48px 4px 4px;
    padding: 24px;
    border-radius: 26px;
    gap: 20px;
  }

  .footer-top,
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .footer-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 4px 20px;
    line-height: 1.5;
  }

  .footer-signature {
    white-space: normal;
    font-size: 14px;
  }

}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .shakl-heart {
    animation: none;
    background-position: 50% 50%;
  }
}

/* A quiet SHAKL violet wash belongs to the editor page, behind its panels.
   Canvas themes and exported artwork keep their own backgrounds. */
.app-shell.is-editor{
  min-height:100vh;
  background:
    radial-gradient(circle at 85% 14%,rgba(185,154,248,.16),transparent 42%),
    #fbfbfa;
}
.app-shell.is-editor .workspace{
  background:transparent;
}
.app-shell.is-editor .site-footer{
  margin-top:72px;
}

/* Tool identity beside the SHAKL wordmark. */
.header-tool-name{grid-column:1;grid-row:1;justify-self:start;display:inline-flex;align-items:center;flex-shrink:0;margin-left:142px;padding-left:18px;border-left:1px solid #a3a3a3;font-size:17px;letter-spacing:-.02em;font-weight:500;color:var(--ink);white-space:nowrap;}
.header>.brand{grid-column:1;grid-row:1;justify-self:start;}
.header>.desktop-nav{grid-column:2;grid-row:1;}
.header>.header-cta{grid-column:3;grid-row:1;}
@media(max-width:760px){.header-tool-name{margin-left:118px;padding-left:10px;font-size:13px;letter-spacing:-.02em;}}

/* Landing illustration (PathHero), drawn like the SHAKL hero eye, with the build sequence. */
.path-hero{--px:0;--py:0;position:absolute;top:8%;left:50%;width:min(32vw,440px);aspect-ratio:21/20;transform:translateX(-50%)}
.ph-svg{width:100%;height:100%;overflow:visible;filter:drop-shadow(0 22px 38px rgba(87,126,170,.06))}
/* Pointer depth, like the eye: deeper layers move less. */
.ph-depth-1,.ph-depth-2,.ph-depth-3{transition:transform .3s cubic-bezier(.22,1,.36,1)}
.ph-depth-1{transform:translate(calc(var(--px) * 5px),calc(var(--py) * 4px))}
.ph-depth-2{transform:translate(calc(var(--px) * 10px),calc(var(--py) * 7px)) rotate(calc(var(--px) * 1deg))}
.ph-depth-3{transform:translate(calc(var(--px) * 20px),calc(var(--py) * 14px))}

.ph-plane{opacity:0;transform-box:fill-box;animation:ph-plane 7s var(--ease) infinite}
.ph-plane--top{transform-origin:right top}
.ph-plane--bottom{transform-origin:left bottom;animation-delay:.1s}
.ph-body{opacity:0;transform-box:fill-box;transform-origin:left bottom;animation:ph-body 7s var(--ease) infinite}
/* Handles trim on from their anchor, then the knob lands at the end. */
.ph-arm{stroke:rgba(255,255,255,.95);stroke-width:3;stroke-linecap:round;stroke-dasharray:1;stroke-dashoffset:1;animation:ph-trim 7s var(--ease) infinite}
.ph-arm:nth-of-type(2){animation-delay:.08s}
.ph-arm:nth-of-type(3){animation-delay:.16s}
.ph-arm:nth-of-type(4){animation-delay:.24s}
.ph-knob{opacity:.85;stroke:#fff;stroke-opacity:.8;stroke-width:2;transform-box:fill-box;transform-origin:center;transform:scale(0);animation:ph-knob 7s var(--ease) infinite}
.ph-knob:nth-of-type(2){animation-delay:.08s}
.ph-knob:nth-of-type(3){animation-delay:.16s}
.ph-knob:nth-of-type(4){animation-delay:.24s}
.ph-tile{transform-box:fill-box;transform-origin:center;transform:scale(0);animation:ph-tile 7s var(--ease) infinite}
.ph-tile:nth-child(2){animation-delay:.14s}

@keyframes ph-plane{0%{opacity:0;transform:scale(.6)}16%,86%{opacity:.5;transform:scale(1)}96%,100%{opacity:0;transform:scale(1)}}
@keyframes ph-body{0%,12%{opacity:0;transform:scale(.2)}30%,86%{opacity:.68;transform:scale(1)}96%,100%{opacity:0;transform:scale(1)}}
@keyframes ph-tile{0%,26%{transform:scale(0)}34%{transform:scale(1.1)}38%,86%{transform:scale(1)}96%,100%{transform:scale(0)}}
/* Trim on, hold, then trim back toward the anchor. */
@keyframes ph-trim{0%,36%{stroke-dashoffset:1}48%,84%{stroke-dashoffset:0}94%,100%{stroke-dashoffset:1}}
@keyframes ph-knob{0%,45%{transform:scale(0)}50%{transform:scale(1.15)}53%,82%{transform:scale(1)}86%,100%{transform:scale(0)}}

.drop-zone.is-dragging .ph-body{opacity:.8}
@media (prefers-reduced-motion:reduce){
  .ph-plane,.ph-body,.ph-arm,.ph-knob,.ph-tile{animation:none;transform:none}
  .ph-plane,.ph-body{opacity:.5}.ph-arm{stroke-dashoffset:0}
  .ph-depth-1,.ph-depth-2,.ph-depth-3{transform:none}
}
@media(max-width:760px){.path-hero{width:min(80vw,360px)}}

/* Functional interface symbols share one stroke style across landing and editor. */
.app-icon{display:block;flex-shrink:0;color:var(--icon-on-light)}
.primary-button .app-icon{color:var(--icon-on-dark)}

/* One focus treatment on light surfaces; the footer needs its inverse. */
:where(button,a,summary,input,select,[role="button"]):focus-visible{outline:2px solid var(--icon-on-light);outline-offset:3px}
.site-footer a:focus-visible{outline-color:var(--on-ink)}

.landing-actions .landing-check-button{border-color:#d9cef3;background:#f3eefe}
