:root {
  --bg: #f7f8fc;
  --panel: #ffffff;
  --ink: #101828;
  --muted: #596579;
  --line: #e4e8f0;
  --brand: #6374f4;
  --brand-2: #8b5bd6;
  --cyan: #18c8f4;
  --pink: #f45ca4;
  --green: #23d883;
  --orange: #ff8a1f;
  --shadow: 0 20px 60px rgba(37, 47, 76, .14);
  --soft-shadow: 0 12px 32px rgba(44, 55, 88, .1);
  --radius: 18px;
  --max: 1180px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }

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

.skip-link,
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.skip-link:focus {
  width: auto;
  height: auto;
  clip: auto;
  z-index: 1000;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: white;
}

.site-header {
  position: sticky;
  z-index: 50;
  top: 0;
  border-bottom: 1px solid rgba(228, 232, 240, .82);
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(18px);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
}

.brand {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  color: var(--brand);
  font-weight: 850;
  font-size: clamp(1.05rem, 2vw, 1.45rem);
}

.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, #fff 0 3px, transparent 4px),
    radial-gradient(circle at 66% 31%, #fff 0 3px, transparent 4px),
    radial-gradient(circle at 49% 62%, #fff 0 3px, transparent 4px),
    linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 8px 18px rgba(99, 116, 244, .28);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  color: #465266;
  font-weight: 750;
}

.nav-links a,
.nav-button {
  border: 0;
  padding: 8px 0;
  background: transparent;
  color: inherit;
}

.nav-links a:hover,
.nav-button:hover {
  color: var(--brand);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: var(--ink);
}

.hero {
  position: relative;
  isolation: isolate;
  min-height: calc(100vh - 76px);
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(99, 116, 244, .09), rgba(255, 255, 255, .78) 58%, #fff),
    radial-gradient(circle at 50% 0, rgba(24, 200, 244, .16), transparent 42%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 960px;
  padding: 82px 0 74px;
  text-align: center;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--brand);
  font-size: .78rem;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 940px;
  margin: 0 auto;
  font-size: clamp(3rem, 8vw, 6.8rem);
  line-height: .92;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.hero-copy {
  max-width: 760px;
  margin: 28px auto 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.32rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 34px;
}

.button,
.tool-button,
.subscribe-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid transparent;
  padding: 0 22px;
  font-weight: 850;
}

.button.primary,
.subscribe-form button {
  color: white;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 14px 28px rgba(99, 116, 244, .28);
}

.button.secondary,
.tool-button {
  color: var(--brand);
  background: white;
  border-color: rgba(99, 116, 244, .34);
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 28px;
}

.trust-row span {
  border: 1px solid rgba(99, 116, 244, .22);
  border-radius: 999px;
  padding: 8px 13px;
  color: #43506a;
  background: rgba(255, 255, 255, .78);
  font-size: .88rem;
  font-weight: 750;
}

.hero-art span {
  position: absolute;
  z-index: 1;
  pointer-events: none;
}

.orb {
  border-radius: 50%;
  filter: saturate(1.2);
}

.orb-a {
  width: 220px;
  height: 220px;
  left: 8%;
  top: 24%;
  background: conic-gradient(from 40deg, var(--brand), var(--pink), var(--orange), var(--cyan), var(--brand));
  opacity: .32;
  animation: float 9s ease-in-out infinite;
}

.orb-b {
  width: 290px;
  height: 290px;
  right: 7%;
  top: 26%;
  background: conic-gradient(from 120deg, #00f580, #00d5ff, #ff00c8, #fff000, #00f580);
  opacity: .28;
  animation: float 12s ease-in-out infinite reverse;
}

.orb-c {
  width: 120px;
  height: 120px;
  right: 24%;
  bottom: 12%;
  background: linear-gradient(135deg, var(--green), var(--cyan));
  opacity: .34;
  animation: float 10s ease-in-out infinite;
}

.stripe {
  width: 36vw;
  height: 80px;
  border-radius: 999px;
  opacity: .12;
  transform: rotate(-16deg);
}

.stripe-a {
  left: -9%;
  bottom: 8%;
  background: var(--brand);
}

.stripe-b {
  right: -12%;
  bottom: 20%;
  background: var(--pink);
}

@keyframes float {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(0, -18px, 0) scale(1.04); }
}

.section-pad {
  padding: 92px 0;
}

.section-heading {
  max-width: 760px;
  margin: 0 auto 38px;
}

.section-heading.centered {
  text-align: center;
}

.section-heading h2,
.story h2,
.contact-band h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: 0;
}

.section-heading p:not(.eyebrow),
.story-copy,
.contact-band p {
  color: var(--muted);
}

.picker-app {
  display: grid;
  grid-template-columns: minmax(260px, .85fr) minmax(280px, 1fr) minmax(280px, .95fr);
  gap: 18px;
  align-items: stretch;
}

.picker-preview,
.value-panel,
.palette-panel,
.post-card,
.category-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--soft-shadow);
}

.picker-preview,
.value-panel,
.palette-panel {
  padding: 18px;
}

.color-stage {
  display: grid;
  min-height: 280px;
  place-items: center;
  border-radius: 14px;
  color: white;
  background: #6374f4;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22);
}

.color-stage span {
  border-radius: 999px;
  padding: 12px 18px;
  background: rgba(0, 0, 0, .25);
  font-weight: 900;
  font-size: 1.35rem;
}

.picker-controls {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: end;
  margin-top: 14px;
}

.picker-controls label {
  grid-column: 1 / -1;
  color: var(--muted);
  font-weight: 800;
}

input[type="color"] {
  width: 100%;
  height: 48px;
  border: 0;
  padding: 0;
  background: transparent;
}

.format-grid {
  display: grid;
  gap: 10px;
}

.format-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px;
  background: #fbfcff;
}

.format-item span {
  color: var(--muted);
  font-size: .8rem;
  font-weight: 850;
  text-transform: uppercase;
}

.format-item code {
  overflow: hidden;
  color: var(--ink);
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.copy-mini,
.text-button {
  border: 0;
  border-radius: 9px;
  padding: 8px 10px;
  color: var(--brand);
  background: rgba(99, 116, 244, .09);
  font-weight: 850;
}

.contrast-box {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.contrast-box div {
  border-radius: 12px;
  padding: 12px;
  background: #f3f6ff;
}

.mini-label {
  display: block;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 800;
}

.contrast-box strong {
  display: block;
  margin-top: 4px;
  font-size: 1.15rem;
}

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

.panel-title h3 {
  margin: 0;
  font-size: 1rem;
}

.panel-title span {
  color: var(--muted);
  font-weight: 800;
}

.swatches,
.harmony-row {
  display: grid;
  gap: 10px;
}

.swatch,
.harmony-swatch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 54px;
  border-radius: 12px;
  padding: 0 12px;
  color: white;
  font-weight: 900;
  text-shadow: 0 1px 12px rgba(0, 0, 0, .28);
}

.harmony-row {
  grid-template-columns: repeat(4, 1fr);
}

.harmony-swatch {
  min-height: 76px;
  justify-content: center;
  font-size: .78rem;
}

.tools-preview {
  background: #fff;
}

.home-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.category-card {
  min-height: 150px;
  padding: 22px;
  text-align: left;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: rgba(99, 116, 244, .46);
  box-shadow: var(--shadow);
}

.category-card span {
  display: block;
  color: var(--brand);
  font-weight: 900;
}

.category-card strong {
  display: block;
  margin-top: 40px;
  font-size: 1.25rem;
}

.story {
  color: white;
  background:
    linear-gradient(135deg, rgba(99, 116, 244, .97), rgba(139, 91, 214, .97)),
    #6374f4;
}

.story .eyebrow,
.story-copy {
  color: rgba(255, 255, 255, .82);
}

.story-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 64px;
}

.story-copy p {
  margin: 0 0 18px;
}

.blog-section {
  background: #f2f4f8;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.post-card {
  overflow: hidden;
}

.post-art {
  height: 180px;
  background:
    radial-gradient(circle at 50% 48%, rgba(255, 255, 255, .95) 0 16px, transparent 17px),
    linear-gradient(135deg, var(--brand), var(--brand-2));
}

.art-2 { background:
  radial-gradient(circle at 50% 48%, rgba(255, 255, 255, .95) 0 16px, transparent 17px),
  linear-gradient(135deg, #ef5350, #f45ca4); }
.art-3 { background:
  radial-gradient(circle at 50% 48%, rgba(255, 255, 255, .95) 0 16px, transparent 17px),
  linear-gradient(135deg, #19b7f5, #19d6c7); }

.post-body {
  padding: 22px;
}

.post-meta {
  margin: 0 0 8px;
  color: var(--brand);
  font-size: .78rem;
  font-weight: 850;
}

.post-card h3 {
  margin: 0;
  font-size: 1.12rem;
  line-height: 1.25;
}

.post-card p:not(.post-meta) {
  color: var(--muted);
}

.post-card a {
  color: var(--brand);
  font-weight: 850;
}

.contact-band {
  padding: 46px 0;
  color: white;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

.contact-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.contact-band h2 {
  font-size: clamp(1.7rem, 3vw, 2.5rem);
}

.subscribe-form {
  display: flex;
  gap: 10px;
  width: min(100%, 470px);
}

.subscribe-form input {
  flex: 1;
  min-width: 0;
  border: 0;
  border-radius: 12px;
  padding: 0 16px;
}

.subscribe-form button {
  background: var(--green);
  box-shadow: none;
}

.site-footer {
  padding: 74px 0 22px;
  color: #b8c1d4;
  background:
    radial-gradient(circle at 18% 0, rgba(99, 116, 244, .12), transparent 34%),
    linear-gradient(180deg, #141d34, #10172a);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.55fr repeat(4, 1fr);
  gap: 46px 36px;
}

.seo-footer-grid {
  align-items: start;
}

.footer-about {
  max-width: 360px;
}

.footer-brand {
  color: white;
}

.site-footer h3 {
  position: relative;
  margin: 0 0 28px;
  border-bottom: 1px solid rgba(99, 116, 244, .24);
  padding-bottom: 14px;
  color: white;
  font-size: .96rem;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.site-footer h3::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 52px;
  height: 2px;
  border-radius: 999px;
  background: var(--brand);
}

.site-footer a {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 22px;
  color: #b8c1d4;
  font-weight: 750;
  transition: color .2s ease, transform .2s ease;
}

.footer-nav a::before {
  content: "->";
  color: rgba(99, 116, 244, .86);
  font-weight: 900;
}

.site-footer a:hover {
  color: white;
  transform: translateX(2px);
}

.site-footer p {
  margin: 28px 0 0;
  color: #b8c1d4;
  font-size: 1.03rem;
  line-height: 1.65;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 22px;
  margin-top: 52px;
  border-top: 1px solid rgba(99, 116, 244, .22);
  padding-top: 34px;
}

.footer-legal a {
  display: inline-flex;
  margin: 0;
}

.footer-legal span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(99, 116, 244, .72);
}

.footer-bottom {
  margin-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  padding-top: 24px;
  text-align: center;
  color: #8996ad;
  font-weight: 700;
}

.modal {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: none;
}

.modal.is-open {
  display: block;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(16, 24, 40, .42);
  backdrop-filter: blur(8px);
}

.modal-panel {
  position: relative;
  width: min(1240px, calc(100% - 28px));
  max-height: min(860px, calc(100vh - 28px));
  margin: 14px auto;
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 26px;
  padding: 34px;
  background: rgba(255, 255, 255, .96);
  box-shadow: var(--shadow);
}

.modal-close {
  position: sticky;
  z-index: 2;
  top: 0;
  float: right;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  color: #3e4a5e;
  background: #eef1f7;
  font-size: 1.8rem;
  line-height: 1;
}

.modal-head {
  max-width: 760px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 24px;
}

.modal-head h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.2rem);
}

.modal-head p:not(.eyebrow) {
  color: var(--muted);
}

.modal-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 24px 0;
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-tabs button {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 13px;
  color: #40506a;
  background: white;
  font-weight: 800;
}

.filter-tabs button.active {
  color: white;
  border-color: var(--brand);
  background: var(--brand);
}

.search-box input {
  width: min(300px, 100%);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 12px 16px;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.tool-card {
  display: grid;
  gap: 8px;
  min-height: 156px;
  align-content: start;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px;
  background: #fff;
  transition: transform .2s ease, box-shadow .2s ease;
}

.tool-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--soft-shadow);
}

.tool-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .28), rgba(255, 255, 255, 0)),
    linear-gradient(135deg, var(--brand), var(--pink));
  box-shadow: 0 8px 20px rgba(99, 116, 244, .16);
  color: white;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tool-icon svg {
  width: 20px;
  height: 20px;
  stroke-width: 2.25px;
}

.icon-designer { background: linear-gradient(135deg, #6366f1, #a855f7) !important; }
.icon-developer { background: linear-gradient(135deg, #0ea5e9, #2563eb) !important; }
.icon-palette { background: linear-gradient(135deg, #ec4899, #f43f5e) !important; }
.icon-gradient { background: linear-gradient(135deg, #f97316, #eab308) !important; }
.icon-accessibility { background: linear-gradient(135deg, #10b981, #059669) !important; }
.icon-ai { background: linear-gradient(135deg, #7c3aed, #db2777) !important; }

.tool-card strong {
  font-size: 1.02rem;
}

.tool-card small {
  color: var(--muted);
}

.tool-card.is-hidden {
  display: none;
}

.toast {
  position: fixed;
  z-index: 120;
  left: 50%;
  bottom: 22px;
  transform: translate(-50%, 20px);
  opacity: 0;
  border-radius: 999px;
  padding: 11px 16px;
  color: white;
  background: var(--ink);
  font-weight: 850;
  transition: opacity .2s ease, transform .2s ease;
}

.toast.show {
  transform: translate(-50%, 0);
  opacity: 1;
}

.tool-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 20%, rgba(24, 200, 244, .22), transparent 28%),
    radial-gradient(circle at 82% 16%, rgba(244, 92, 164, .16), transparent 30%),
    linear-gradient(180deg, #eef4ff, #fff);
}

.tool-hero-inner {
  max-width: 880px;
  padding: 78px 0 64px;
  text-align: center;
}

.breadcrumb {
  display: inline-flex;
  margin-bottom: 18px;
  border: 1px solid rgba(99, 116, 244, .26);
  border-radius: 999px;
  padding: 8px 13px;
  color: var(--brand);
  background: rgba(255, 255, 255, .82);
  font-weight: 850;
}

.tool-hero h1 {
  margin: 0;
  font-size: clamp(2.4rem, 7vw, 5.2rem);
  line-height: .95;
  overflow-wrap: anywhere;
}

.tool-hero p:not(.eyebrow) {
  max-width: 700px;
  margin: 22px auto 0;
  color: var(--muted);
  font-size: 1.14rem;
}

.tool-workspace {
  display: grid;
  grid-template-columns: minmax(260px, 380px) 1fr;
  gap: 24px;
}

.tool-controls,
.tool-preview-panel {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  box-shadow: var(--soft-shadow);
}

.tool-controls {
  display: grid;
  align-content: start;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.controls-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, #f8faff, #fff);
  font-weight: 900;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.controls-header i {
  color: var(--brand);
}

.controls-body {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.control-field {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 850;
  font-size: 0.88rem;
}

.control-field input,
.control-field select {
  min-height: 46px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 14px;
  color: var(--ink);
  background: #fbfcff;
  font-weight: 700;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.control-field input:focus,
.control-field select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(99, 116, 244, 0.12);
}

.control-field input[type="color"] {
  padding: 4px;
  cursor: pointer;
  border-radius: 12px;
}

.control-field input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  min-height: auto;
  border: none;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--pink));
  cursor: pointer;
  padding: 0;
}

.control-field input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid white;
  background: var(--brand);
  box-shadow: 0 2px 8px rgba(99, 116, 244, 0.3);
  cursor: grab;
  transition: transform 0.15s ease;
}

.control-field input[type="range"]::-webkit-slider-thumb:active {
  transform: scale(1.2);
  cursor: grabbing;
}

.color-input-group {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfcff;
  transition: border-color 0.2s ease;
}

.color-input-group:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(99, 116, 244, 0.12);
}

.color-capsule {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 2px solid rgba(0,0,0,0.06);
  cursor: pointer;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.color-capsule input[type="color"] {
  position: absolute;
  inset: -8px;
  width: calc(100% + 16px);
  height: calc(100% + 16px);
  border: none;
  cursor: pointer;
  opacity: 0;
}

.color-input-group input[type="text"] {
  flex: 1;
  border: none;
  background: transparent;
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--ink);
  min-height: auto;
  padding: 0;
}

.color-input-group input[type="text"]:focus {
  outline: none;
  box-shadow: none;
}

.control-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.tool-run {
  width: 100%;
}

.tool-preview-panel {
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 22px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, #f8faff, #fff);
}

.preview-header span {
  font-weight: 900;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

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

.preview-actions button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--muted);
  font-weight: 800;
  font-size: 0.78rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.preview-actions button:hover {
  background: var(--brand);
  color: white;
  border-color: var(--brand);
}

.tool-preview {
  display: grid;
  min-height: 380px;
  place-items: center;
  padding: 32px;
  background: #f8faff;
  color: var(--ink);
  flex: 1;
}

.tool-preview strong {
  font-size: clamp(1.8rem, 5vw, 4rem);
  line-height: 1;
}

.tool-output {
  padding: 22px;
  border-top: 1px solid var(--line);
}

/* Premium Interactive Swatch Cards */
.swatch-grid {
  display: grid;
  width: 100%;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 14px;
}

.swatch-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 160px;
  border: 0;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.swatch-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 32px rgba(0,0,0,0.15);
}

.swatch-color {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.swatch-color .copy-hint {
  opacity: 0;
  font-weight: 900;
  font-size: 0.82rem;
  padding: 6px 12px;
  border-radius: 8px;
  background: rgba(0,0,0,0.5);
  color: white;
  transition: opacity 0.2s ease;
}

.swatch-card:hover .copy-hint {
  opacity: 1;
}

.swatch-info {
  padding: 10px 12px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.swatch-info .swatch-hex {
  font-weight: 900;
  font-size: 0.82rem;
  color: var(--ink);
}

.swatch-info .swatch-badge {
  font-size: 0.65rem;
  font-weight: 900;
  padding: 3px 7px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-aaa {
  background: #d1fae5;
  color: #065f46;
}

.badge-aa {
  background: #fef9c3;
  color: #713f12;
}

.badge-fail {
  background: #fee2e2;
  color: #991b1b;
}

/* Accessibility Playground Mockup */
.a11y-playground {
  width: 100%;
  max-width: 580px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

.a11y-header {
  padding: 24px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.a11y-header h3 {
  margin: 0;
  font-size: 1.3rem;
}

.a11y-body {
  padding: 0 28px 28px;
}

.a11y-body p {
  margin: 0 0 20px;
  line-height: 1.6;
  font-size: 1.05rem;
}

.a11y-card {
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 16px;
  border: 1px solid rgba(0,0,0,0.06);
}

.a11y-btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 900;
  font-size: 0.92rem;
  text-align: center;
}

.a11y-scores {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 20px;
}

.a11y-score-item {
  text-align: center;
  padding: 14px 8px;
  border-radius: 12px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.15);
}

.a11y-score-item .score-value {
  font-size: 1.5rem;
  font-weight: 900;
  display: block;
}

.a11y-score-item .score-label {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 4px;
  display: block;
  opacity: 0.8;
}

/* Glassmorphism Playground */
.glass-playground {
  width: 100%;
  min-height: 340px;
  border-radius: 22px;
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}

.glass-playground::before {
  content: "";
  position: absolute;
  inset: 0;
  background: inherit;
  filter: blur(0px);
}

.glass-card {
  position: relative;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 20px;
  padding: 36px 42px;
  color: white;
  background: rgba(255, 255, 255, .18);
  backdrop-filter: blur(16px);
  text-align: center;
  max-width: 360px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.12);
}

.glass-card h3 {
  margin: 0 0 8px;
  font-size: 1.6rem;
}

.glass-card p {
  margin: 0;
  font-size: 0.92rem;
  opacity: 0.85;
}

/* Drag & Drop Upload Zone */
.upload-zone {
  width: 100%;
  min-height: 220px;
  border: 2px dashed var(--line);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
  background: rgba(99, 116, 244, 0.02);
  color: var(--muted);
  text-align: center;
  padding: 28px;
}

.upload-zone:hover,
.upload-zone.drag-over {
  border-color: var(--brand);
  background: rgba(99, 116, 244, 0.06);
}

.upload-zone svg {
  width: 42px;
  height: 42px;
  color: var(--brand);
  opacity: 0.6;
}

.upload-zone p {
  margin: 0;
  font-weight: 800;
  font-size: 0.92rem;
}

.upload-zone small {
  color: var(--muted);
  font-size: 0.8rem;
}

.extracted-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  width: 100%;
  align-items: start;
}

.extracted-image {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.extracted-image img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

/* Enhanced Gradient Preview */
.gradient-demo {
  width: min(100%, 620px);
  min-height: 280px;
  border-radius: 22px;
  box-shadow: var(--shadow);
  position: relative;
}

.animated-gradient {
  background-size: 300% 300% !important;
  animation: gradientShift 4s ease infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.gradient-border-demo {
  position: relative;
  display: grid;
  place-items: center;
}

.gradient-border-demo::after {
  content: "Gradient Border";
  display: grid;
  position: absolute;
  inset: 18px;
  place-items: center;
  border-radius: 16px;
  background: white;
  color: var(--ink);
  font-weight: 900;
}

.tool-preview-3d {
  transform: perspective(700px) rotateX(16deg) rotateY(-18deg);
}

/* Enhanced Color Picker Preview */
.picker-preview {
  text-align: center;
}

.picker-preview .color-stage {
  width: 160px;
  height: 160px;
  border-radius: 28px;
  margin: 0 auto 20px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.12);
  display: grid;
  place-items: center;
  transition: background 0.3s ease;
}

.picker-preview .color-stage strong {
  font-size: 1.6rem;
  text-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.color-name-tag {
  margin-top: 8px;
  font-size: 1rem;
  color: var(--muted);
  font-weight: 700;
}

/* Type / Contrast Preview */
.type-preview {
  max-width: 520px;
  padding: 30px;
}

.type-preview h3 {
  margin: 0 0 10px;
  font-size: 2rem;
}

/* Color Wheel */
.color-wheel {
  width: min(72vw, 360px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, white 0 24%, transparent 25%),
    conic-gradient(red, yellow, lime, cyan, blue, magenta, red);
  box-shadow: inset 0 0 0 18px var(--selected), var(--shadow);
}

/* Enhanced UI Demo */
.ui-demo {
  display: grid;
  gap: 18px;
  width: min(100%, 560px);
  border-radius: 24px;
  padding: 28px;
  background: linear-gradient(135deg, var(--demo-light), #fff);
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

.ui-demo .ui-demo-nav {
  display: flex;
  gap: 8px;
}

.ui-demo .ui-demo-nav span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.ui-demo button {
  justify-self: start;
  border: 0;
  border-radius: 12px;
  padding: 13px 24px;
  color: white;
  background: var(--demo);
  box-shadow: 0 8px 20px color-mix(in srgb, var(--demo) 30%, transparent);
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ui-demo button:hover {
  transform: translateY(-2px);
}

.ui-demo article {
  border: 1px solid rgba(17, 24, 39, .08);
  border-radius: 16px;
  padding: 18px;
  background: white;
}

.ui-demo h3 {
  margin: 0 0 8px;
}

.ui-demo p {
  margin: 0;
  color: var(--muted);
}

/* Code block styling */
.code-block {
  overflow: auto;
  max-height: 320px;
  margin: 0 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  background: #101828;
  color: #e5edff;
  font-size: .92rem;
  line-height: 1.55;
}


@media (max-width: 980px) {
  .picker-app,
  .story-grid,
  .footer-grid,
  .tool-workspace {
    grid-template-columns: 1fr;
  }

  .footer-about {
    max-width: none;
  }

  .category-grid,
  .post-grid,
  .tools-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-inner,
  .modal-toolbar,
  .home-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .subscribe-form,
  .search-box input {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .shell {
    width: min(var(--max), calc(100% - 28px));
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    inset: 76px 14px auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 12px;
    background: white;
    box-shadow: var(--soft-shadow);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a,
  .nav-button {
    padding: 13px;
    text-align: left;
  }

  .hero {
    min-height: auto;
  }

  .hero-inner {
    padding: 70px 0 58px;
  }

  .hero h1 {
    font-size: clamp(2.35rem, 14vw, 4.3rem);
  }

  .orb-a,
  .orb-b {
    width: 160px;
    height: 160px;
  }

  .picker-controls,
  .contrast-box,
  .post-grid,
  .tools-grid {
    grid-template-columns: 1fr;
  }

  .format-item {
    grid-template-columns: 1fr auto;
  }

  .format-item span {
    grid-column: 1 / -1;
  }

  .harmony-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .section-pad {
    padding: 66px 0;
  }

  .modal-panel {
    padding: 22px;
    border-radius: 20px;
  }

  .subscribe-form {
    flex-direction: column;
  }

  .subscribe-form input,
  .subscribe-form button {
    min-height: 48px;
  }
}

/* --- SEO Blog System Styles --- */
.blog-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 20%, rgba(99, 116, 244, .12), transparent 28%),
    radial-gradient(circle at 82% 16%, rgba(244, 92, 164, .08), transparent 30%),
    linear-gradient(180deg, #eef4ff, #fff);
  text-align: center;
  padding: 82px 0 66px;
}

.blog-hero h1 {
  font-size: clamp(2.4rem, 7vw, 4.8rem);
  line-height: .95;
  margin: 0 0 16px;
}

.blog-hero p {
  max-width: 680px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 1.15rem;
}

.blog-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 38px;
  background: white;
  padding: 16px 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--soft-shadow);
}

.blog-posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.blog-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  transition: transform .2s ease, box-shadow .2s ease;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.blog-card-art {
  height: 190px;
  position: relative;
}

.blog-card-art .badge {
  position: absolute;
  top: 18px;
  left: 18px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 850;
  padding: 6px 12px;
  border-radius: 999px;
  box-shadow: var(--soft-shadow);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.blog-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-card-meta {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  gap: 12px;
}

.blog-card h3 {
  margin: 0 0 12px;
  font-size: 1.25rem;
  line-height: 1.3;
}

.blog-card p {
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.5;
  margin: 0 0 20px;
  flex: 1;
}

.blog-card-link {
  font-weight: 850;
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.blog-card-link::after {
  content: "->";
  transition: transform 0.2s ease;
}

.blog-card:hover .blog-card-link::after {
  transform: translateX(4px);
}

/* Post view typography & structure */
.post-container {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 40px;
  align-items: start;
}

.post-main {
  background: white;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 40px;
  box-shadow: var(--soft-shadow);
}

.post-hero-meta {
  display: flex;
  justify-content: center;
  gap: 16px;
  color: var(--brand);
  font-weight: 800;
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.article-body {
  color: #1e293b;
  font-size: 1.125rem;
  line-height: 1.75;
}

.article-body p {
  margin: 0 0 24px;
}

.article-body h2 {
  font-size: 1.75rem;
  margin: 40px 0 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

.article-body h3 {
  font-size: 1.35rem;
  margin: 28px 0 12px;
}

.article-body blockquote {
  margin: 32px 0;
  border-left: 4px solid var(--brand);
  background: #f8faff;
  padding: 24px;
  border-radius: 0 16px 16px 0;
  font-style: italic;
  font-size: 1.2rem;
  color: #334155;
  line-height: 1.6;
}

.article-body ul, 
.article-body ol {
  margin: 0 0 24px;
  padding-left: 24px;
}

.article-body li {
  margin-bottom: 8px;
}

.article-body pre {
  margin: 32px 0;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.article-body code {
  background: #f1f5f9;
  color: #ef4444;
  padding: 3px 6px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: monospace;
}

.article-body pre code {
  display: block;
  background: #0f172a;
  color: #e2e8f0;
  padding: 20px;
  overflow-x: auto;
  font-size: 0.92rem;
  line-height: 1.5;
  border-radius: 16px;
}

/* Sidebar components */
.post-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 96px;
}

.toc-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 24px;
  box-shadow: var(--soft-shadow);
}

.toc-card h3 {
  margin: 0 0 16px;
  font-size: 0.95rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

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

.toc-list a {
  display: block;
  padding: 8px 0;
  color: var(--muted);
  font-weight: 750;
  font-size: 0.94rem;
  transition: color 0.2s ease, transform 0.2s ease;
}

.toc-list a:hover {
  color: var(--brand);
  transform: translateX(3px);
}

.cta-tool-card {
  background: linear-gradient(135deg, #1e293b, #0f172a);
  color: white;
  border-radius: 20px;
  padding: 28px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.cta-tool-card::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(99, 116, 244, 0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.cta-tool-card h4 {
  color: #94a3b8;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 12px;
}

.cta-tool-card h3 {
  font-size: 1.4rem;
  margin: 0 0 12px;
  color: white;
  line-height: 1.25;
}

.cta-tool-card p {
  font-size: 0.9rem;
  color: #94a3b8;
  line-height: 1.5;
  margin: 0 0 24px;
}

.cta-tool-card .button {
  width: 100%;
  display: block;
  text-align: center;
  background: var(--brand);
  color: white;
  box-shadow: none;
  font-weight: 900;
}

.cta-tool-card .button:hover {
  background: #4f5fd7;
}

@media (max-width: 980px) {
  .blog-posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .post-container {
    grid-template-columns: 1fr;
  }
  
  .post-sidebar {
    position: static;
  }
}

@media (max-width: 640px) {
  .blog-posts-grid {
    grid-template-columns: 1fr;
  }
  
  .post-main {
    padding: 24px;
  }
  
  .blog-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
}
