/* ── Custom Font ────────────────────────────────────────────────────────── */
@font-face {
  font-family: 'CACLasko';
  src: url('/static/fonts/CACLaskoEvenWeight.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* ── Bootstrap Overrides ────────────────────────────────────────────────── */
:root {
  --bs-font-sans-serif: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --bs-body-font-family: 'Inter', -apple-system, sans-serif;
  --bs-border-radius:    0;
  --bs-border-radius-sm: 0;
  --bs-border-radius-lg: 0;
  --bs-border-radius-xl: 0;
  --bs-link-color:       #0f62fe;
  --bs-link-hover-color: #0043ce;

  /* CRI-ONE brand palette */
  --blue:     #0f62fe;
  --blue-dk:  #0043ce;
  --dark:     #0a0a0a;
  --nav-bg:   #08101e;   /* dark navy — distinct from black */
  --footer-bg:#0f1828;   /* deep navy — not black, has depth */
  --mid:      #2d2d2d;
  --muted:    #6f6f6f;
  --border:   #d0d0d0;
  --bg:       #f8f8f8;
  --white:    #ffffff;

  /* Froot Loop project colors (0-7) — BIG, bright, saturated */
  --fl-0: #0f62fe;   /* electric blue  */
  --fl-1: #00c4c4;   /* cyan           */
  --fl-2: #9b59f5;   /* violet         */
  --fl-3: #ff6a00;   /* hot orange     */
  --fl-4: #ff1744;   /* hot red        */
  --fl-5: #00e676;   /* neon green     */
  --fl-6: #e91e99;   /* hot pink       */
  --fl-7: #ffea00;   /* electric yellow*/

  /* Product type colors — vivid */
  --type-downloadable: #0f62fe;
  --type-simple:       #00b86b;
  --type-virtual:      #9b59f5;
  --type-configurable: #ff6a00;
  --type-bundle:       #ff1744;
  --type-grouped:      #e91e99;
  --type-default:      #607d8b;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--dark);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-dk); text-decoration: underline; }

/* ════════════════════════════════════════════════════════════════════════════
   DESIGN SYSTEM — Modern component library
   ════════════════════════════════════════════════════════════════════════════ */

/* ── Hero Sections ───────────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--dark) 0%, #1a1a1a 100%);
  color: #fff;
  padding: 80px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: -50%; right: -20%; width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(15, 98, 254, 0.08) 0%, transparent 70%);
  pointer-events: none;
}
.hero-inner {
  max-width: 720px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.hero-eyebrow {
  font-family: 'Arial Black', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  /* Lighter than --fl-0: the brand blue lands at 3.75:1 on the dark hero,
     under the 4.5:1 floor for text this small. */
  color: #6ea8ff;
  margin-bottom: 12px;
}
.hero-title {
  font-family: 'Arial Black', sans-serif;
  font-size: clamp(2rem, 8vw, 3.2rem);
  line-height: 1.1;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}
.hero-lead {
  font-size: 1.05rem;
  line-height: 1.6;
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
}

/* ── Cards ───────────────────────────────────────────────────────────────── */
.card-modern {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 28px;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
}
.card-modern:hover {
  border-color: var(--blue);
  box-shadow: 0 4px 16px rgba(15, 98, 254, 0.08);
}
.card-modern.elevated:hover {
  border-color: var(--blue);
  box-shadow: 0 8px 24px rgba(15, 98, 254, 0.12);
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn-cta {
  display: inline-block;
  background: var(--dark);
  color: #fff;
  padding: 12px 32px;
  font-weight: 700;
  text-decoration: none;
  border: 3px solid var(--fl-7, #ffea00);
  letter-spacing: 0.06em;
  font-size: 0.85rem;
  text-transform: uppercase;
  font-family: 'Arial Black', sans-serif;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-cta:hover {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}
.btn-cta.btn-primary {
  background: var(--fl-0, #0f62fe);
  border-color: var(--fl-0, #0f62fe);
  color: #fff;
}
.btn-cta.btn-primary:hover {
  background: #0f52ce;
  border-color: #0f52ce;
}
.btn-cta.btn-success {
  background: var(--fl-5, #00e676);
  color: #0a0a0a;
  border-color: #0a0a0a;
}
.btn-cta.btn-success:hover {
  background: #00c755;
  box-shadow: 0 2px 8px rgba(0, 230, 118, 0.2);
}

/* ── Section Spacing ─────────────────────────────────────────────────────── */
.section-spaced {
  padding: 60px 24px;
}
.section-bg-light { background: var(--bg); }
.section-bg-white { background: var(--white); }
.section-centered {
  max-width: 1200px;
  margin: 0 auto;
}

/* ── Grid Layouts ────────────────────────────────────────────────────────── */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
@media (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
}

/* ── Typography System ───────────────────────────────────────────────────── */
.h-brand {
  font-family: 'Arial Black', sans-serif;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.h1-brand {
  font-size: clamp(2rem, 5vw, 3rem);
}
.h2-brand {
  font-size: 2rem;
  margin: 0 0 10px;
}
.h3-brand {
  font-size: 1.35rem;
  margin: 0 0 8px;
}

/* ── Standard Headings ───────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Arial Black', sans-serif;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
  line-height: 1.2;
  color: var(--dark);
}
h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.15rem; font-weight: 800; }
h5 { font-size: 1rem; font-weight: 700; }
h6 { font-size: 0.9rem; font-weight: 700; }

/* ── Form Improvements ───────────────────────────────────────────────────── */
input, textarea, select {
  transition: border-color 0.2s, box-shadow 0.2s;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--blue) !important;
  box-shadow: 0 0 0 3px rgba(15, 98, 254, 0.08) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */

/* ── Navigation ─────────────────────────────────────────────────────────── */
.crione-nav {
  background: var(--nav-bg);
  border-bottom: none;
  padding: .75rem 0;
  position: sticky;
  top: 0;
  z-index: 1030;
}
/* Mondrian strip — vivid solid blocks, hard black dividers, no blend */
.crione-nav::after {
  content: '';
  display: block;
  height: 8px;
  background: linear-gradient(90deg,
    var(--fl-0) 0,     var(--fl-0) 36%,
    #000        36%,   #000        37.5%,
    var(--fl-4) 37.5%, var(--fl-4) 57%,
    #000        57%,   #000        58.5%,
    var(--fl-7) 58.5%, var(--fl-7) 78%,
    #000        78%,   #000        79.5%,
    var(--fl-5) 79.5%, var(--fl-5) 100%
  );
}

.brand-masthead {
  font-family: 'Arial Black', 'Arial Bold', Gadget, sans-serif;
  font-size: 2.1rem;
  letter-spacing: .04em;
  color: #fff;
  line-height: 1;
}
.brand-sep {
  color: var(--fl-7);   /* electric yellow — the one bright note */
  margin: 0 1px;
}
.brand-byline {
  display: block;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: .6rem;
  font-weight: normal;
  font-style: italic;
  letter-spacing: .04em;
  text-transform: none;
  color: #8d8d8d;
  line-height: 1;
  margin-top: 3px;
  -webkit-text-fill-color: #8d8d8d;
}
.navbar-brand { text-decoration: none; line-height: 1; }

.crione-nav .nav-link {
  color: #c6c6c6;
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .02em;
  padding: .3rem .75rem;
  transition: color .15s;
}
.crione-nav .nav-link:hover,
.crione-nav .nav-link.active { color: #fff; }

/* ── Nav search bar ──────────────────────────────────────────────────────── */
.nav-search-wrap {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 3px;
  overflow: hidden;
  transition: background .15s, border-color .15s;
}
.nav-search-wrap:focus-within {
  background: rgba(255,255,255,.18);
  border-color: var(--fl-7, #ffea00);
}
.nav-search-input {
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: .78rem;
  padding: 5px 10px;
  width: 180px;
  font-family: inherit;
}
.nav-search-input::placeholder { color: rgba(255,255,255,.45); }
.nav-search-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,.7);
  padding: 5px 10px;
  cursor: pointer;
  font-size: .9rem;
  transition: color .12s;
  line-height: 1;
}
.nav-search-btn:hover { color: var(--fl-7, #ffea00); }

/* ── Nav session chip ────────────────────────────────────────────────────── */
.nav-session { display: flex; align-items: center; }
.nav-session-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px;
  font-size: .72rem; font-weight: 600;
  border-radius: 3px;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.28);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.85);
  transition: background .12s, color .12s, border-color .12s;
  white-space: nowrap; max-width: 200px;
  overflow: hidden; text-overflow: ellipsis;
}
.nav-session-chip:hover { background: rgba(255,255,255,.16); color: #fff; border-color: rgba(255,255,255,.5); }
.nav-chip-dot   { font-size: .7rem; line-height: 1; }
.nav-chip-label { font-size: .72rem; }

.nav-session-member .nav-chip-dot { color: var(--fl-5, #00e676); }
.nav-session-guest  {
  background: rgba(255,234,0,.16);
  border-color: rgba(255,234,0,.5);
  color: var(--fl-7, #ffea00);
}
.nav-session-guest:hover { background: var(--fl-7, #ffea00); color: #0a0a0a; }
.nav-session-signin { color: var(--fl-7, #ffea00); }

/* ── Mega menu ───────────────────────────────────────────────────────────── */
.mega-nav-item .dropdown-toggle::after { border: none; content: "▾"; margin-left: 3px; font-size: .65rem; }
.mega-menu {
  min-width: 480px;
  padding: 0;
  border: none;
  border-radius: 0 0 6px 6px;
  background: #0d1a2d;
  box-shadow: 0 12px 40px rgba(0,0,0,.45);
  left: 0;
}
.mega-menu-inner {
  display: flex;
  gap: 0;
  padding: 20px 24px;
}
.mega-col {
  flex: 1;
  padding: 0 16px;
  border-right: 1px solid rgba(255,255,255,.08);
}
.mega-col:first-child { padding-left: 0; }
.mega-col:last-child  { border-right: none; }
.mega-head {
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--fl-7, #ffea00);
  margin: 0 0 10px;
}
.mega-link {
  display: flex;
  flex-direction: column;
  padding: 5px 0;
  text-decoration: none;
  color: rgba(255,255,255,.78);
  font-size: .78rem;
  line-height: 1.4;
  border-bottom: 1px solid rgba(255,255,255,.05);
  transition: color .12s;
}
.mega-link:last-child { border-bottom: none; }
.mega-link:hover { color: #fff; }
.mega-link-title { font-weight: 600; color: #fff; }
.mega-link-sub   { font-size: .68rem; color: rgba(255,255,255,.5); margin-top: 1px; }

/* ── Founder block ───────────────────────────────────────────────────────── */
.founder-block {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 4px;
}
.founder-photo {
  width: 56px;
  height: 56px;
  object-fit: cover;
  object-position: center top;
  border-radius: 50%;
  border: 2px solid var(--blue);
  flex-shrink: 0;
}
.founder-name  { font-size: .8rem; font-weight: 700; color: #e0e0e0; margin: 0; line-height: 1.3; }
/* #6f6f6f gave 2.17:1 on the dark footer — below the 4.5:1 AA floor. */
.founder-title { font-size: .7rem; color: #9aa4b2; margin: 0; font-style: italic; }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.crione-footer {
  background: var(--footer-bg);
  color: #8d8d8d;
  margin-top: auto;
  border-top: 8px solid transparent;
  border-image: linear-gradient(90deg,
    var(--fl-2) 0,     var(--fl-2) 25%,
    #000        25%,   #000        26.5%,
    var(--fl-6) 26.5%, var(--fl-6) 55%,
    #000        55%,   #000        56.5%,
    var(--fl-3) 56.5%, var(--fl-3) 78%,
    #000        78%,   #000        79.5%,
    var(--fl-1) 79.5%, var(--fl-1) 100%
  ) 1;
}
.footer-brand   { font-weight: 800; font-size: 1.25rem; color: #fff; margin: 0 0 6px; }
.footer-tagline { font-size: .8rem; line-height: 1.5; color: #a8a8a8; margin-bottom: 12px; }
.footer-heading { font-weight: 600; font-size: .8rem; text-transform: uppercase;
                  letter-spacing: .08em; color: #a8a8a8; margin-bottom: 8px; }
.footer-text    { font-size: .8rem; line-height: 1.6; }
/* var(--blue) is 3.55:1 against the dark footer; this lighter blue clears AA. */
.footer-text a  { color: #6ea8ff; }
.footer-biz     { font-size: .78rem; font-weight: 600; color: #a8a8a8; margin-bottom: 4px; }
/* #525252 gave 2.27:1 on the dark footer — below the AA floor. */
.footer-copy    { font-size: .72rem; color: #9aa4b2; margin-top: 8px; }

/* ── Catalog Hero ────────────────────────────────────────────────────────── */
.catalog-hero {
  background: linear-gradient(135deg, var(--dark) 0%, #1a1a1a 100%);
  position: relative;
  overflow: hidden;
}
.catalog-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 80% at 80% 50%, rgba(15,98,254,.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 60% at 10% 80%, rgba(155,89,245,.08) 0%, transparent 60%);
  pointer-events: none;
}
.hero-eyebrow {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .2em;
  /* See note on the earlier .hero-eyebrow rule — brand blue is too dark
     against the hero gradient at this size. */
  color: #6ea8ff;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.hero-title {
  font-family: 'Arial Black', sans-serif;
  font-size: clamp(2.2rem, 6vw, 3.5rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 16px;
  letter-spacing: -.01em;
}
.hero-sub {
  font-size: 1rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 8px;
}
.hero-count {
  font-size: .9rem;
  color: rgba(255, 255, 255, 0.75);
}

/* ── Tag Cloud ───────────────────────────────────────────────────────────── */
.tag-cloud-section {
  background: var(--white);
  border-bottom: 1px solid var(--border);
}
.tag-cloud-label {
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--muted);
  margin-bottom: 12px;
}
.tag-cloud-wrap {
  position: relative;
}
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  align-items: flex-start;
  max-height: 88px;     /* ~3 rows */
  overflow: hidden;
  transition: max-height .35s ease;
}
.tag-cloud.expanded {
  max-height: 600px;
}
.tag-cloud-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 36px;
  background: linear-gradient(transparent, #fff);
  pointer-events: none;
  transition: opacity .25s;
}
.tag-cloud.expanded + .tag-cloud-fade { opacity: 0; }
.tag-cloud-toggle {
  margin-top: 8px;
  font-size: .72rem;
  font-weight: 600;
  color: var(--blue);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  letter-spacing: .02em;
}
.tag-cloud-toggle:hover { text-decoration: underline; }

.tag-chip {
  background: none;
  border: 1px solid var(--border);
  color: var(--mid);
  padding: 3px 10px;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  line-height: 1.5;
  transition: all .12s;
  white-space: nowrap;
  flex-shrink: 0;
}
.tag-chip:hover       { background: var(--blue); color: #fff; border-color: var(--blue); }
.tag-chip.active      { background: var(--blue); color: #fff; border-color: var(--blue); }
.tag-chip.tag-clear   { border-color: #ff1744; color: #ff1744; font-size: .75em !important; }
.tag-chip.tag-clear:hover { background: #ff1744; color: #fff; border-color: #ff1744; }

/* ── View Toggle ─────────────────────────────────────────────────────────── */
.view-toggle .btn { font-size: .78rem; font-weight: 500; gap: 4px; display: inline-flex; align-items: center; }
.catalog-count { font-size: .85rem; color: var(--muted); }

/* ── Masonry View ────────────────────────────────────────────────────────── */
#projectContainer.view-masonry {
  columns: 4 260px;
  column-gap: 1rem;
}
#projectContainer.view-masonry .project-card {
  display: block;
  break-inside: avoid;
  margin-bottom: 1rem;
  width: 100%;
}

/* ── Grid View ───────────────────────────────────────────────────────────── */
#projectContainer.view-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}
#projectContainer.view-grid .project-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* ── List View ───────────────────────────────────────────────────────────── */
#projectContainer.view-list {
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
#projectContainer.view-list .project-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  height: auto;
}
#projectContainer.view-list .project-card-bar   { display: none; }
#projectContainer.view-list .project-card-img   { width: 72px; min-height: 72px; flex-shrink: 0; }
#projectContainer.view-list .project-card-body  { flex: 1; padding: 12px 16px; }
#projectContainer.view-list .project-card-footer { flex-shrink: 0; padding: 0 16px; }
#projectContainer.view-list .project-card-name  { font-size: 1rem; margin: 0; }
#projectContainer.view-list .project-card-meta  { font-size: .78rem; }

/* ── Project Card ────────────────────────────────────────────────────────── */
.project-card {
  background: var(--white);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: all .2s;
  border-radius: 2px;
}
.project-card:hover {
  border-color: var(--blue);
  box-shadow: 0 8px 24px rgba(15, 98, 254, 0.12);
  transform: translateY(-4px);
  text-decoration: none;
  color: inherit;
}

/* Froot Loop top bar */
.project-card-bar { height: 3px; }
.proj-color-0 .project-card-bar { background: var(--fl-0); }
.proj-color-1 .project-card-bar { background: var(--fl-1); }
.proj-color-2 .project-card-bar { background: var(--fl-2); }
.proj-color-3 .project-card-bar { background: var(--fl-3); }
.proj-color-4 .project-card-bar { background: var(--fl-4); }
.proj-color-5 .project-card-bar { background: var(--fl-5); }
.proj-color-6 .project-card-bar { background: var(--fl-6); }
.proj-color-7 .project-card-bar { background: var(--fl-7); }

.project-card-img {
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: #f0f0f0;
}
.project-card-img img { width: 100%; height: 100%; object-fit: cover; }

.project-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Each color class gets its own vivid gradient */
.proj-color-0 .project-card-placeholder {
  background: linear-gradient(135deg, #0f62fe 0%, #00c4c4 100%);
}
.proj-color-1 .project-card-placeholder {
  background: linear-gradient(135deg, #00c4c4 0%, #00e676 100%);
}
.proj-color-2 .project-card-placeholder {
  background: linear-gradient(135deg, #9b59f5 0%, #e91e99 100%);
}
.proj-color-3 .project-card-placeholder {
  background: linear-gradient(135deg, #ff6a00 0%, #ffea00 100%);
}
.proj-color-4 .project-card-placeholder {
  background: linear-gradient(135deg, #ff1744 0%, #e91e99 100%);
}
.proj-color-5 .project-card-placeholder {
  background: linear-gradient(135deg, #00e676 0%, #0f62fe 100%);
}
.proj-color-6 .project-card-placeholder {
  background: linear-gradient(135deg, #e91e99 0%, #9b59f5 100%);
}
.proj-color-7 .project-card-placeholder {
  background: linear-gradient(135deg, #ffea00 0%, #ff6a00 100%);
}

.proj-initials {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 3rem;
  color: rgba(255,255,255,.85);
  letter-spacing: .05em;
  text-shadow: 0 2px 12px rgba(0,0,0,.3);
}

.project-card-body   { padding: 16px 16px 10px; flex: 1; }
.project-card-num    { font-size: .65rem; font-weight: 700; letter-spacing: .12em;
                        text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.project-card-name   { font-size: 1.05rem; font-weight: 700; margin: 0 0 6px;
                        line-height: 1.2; color: var(--dark); }
.project-card-meta   { font-size: .8rem; color: var(--muted); }

.project-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  border-top: 1px solid var(--border);
  font-size: .78rem;
  font-weight: 600;
  color: var(--blue);
}
.project-card-footer .arrow { transition: transform .15s; }
.project-card:hover .project-card-footer .arrow { transform: translateX(4px); }

/* ── No Results ──────────────────────────────────────────────────────────── */
.no-results {
  text-align: center;
  padding: 48px 0;
  color: var(--muted);
}

/* ── Project Hero ────────────────────────────────────────────────────────── */
.project-hero {
  background: var(--dark);
  border-bottom: 4px solid var(--border);
}
.proj-color-0.project-hero { border-bottom-color: var(--fl-0); }
.proj-color-1.project-hero { border-bottom-color: var(--fl-1); }
.proj-color-2.project-hero { border-bottom-color: var(--fl-2); }
.proj-color-3.project-hero { border-bottom-color: var(--fl-3); }
.proj-color-4.project-hero { border-bottom-color: var(--fl-4); }
.proj-color-5.project-hero { border-bottom-color: var(--fl-5); }
.proj-color-6.project-hero { border-bottom-color: var(--fl-6); }
.proj-color-7.project-hero { border-bottom-color: var(--fl-7); }

.project-hero-num  { font-size: .7rem; font-weight: 700; letter-spacing: .15em;
                      text-transform: uppercase; color: #8d8d8d; margin-bottom: 6px; }
.project-hero-name { font-size: clamp(1.6rem, 4vw, 2.8rem); font-weight: 800;
                      color: #fff; line-height: 1.1; margin-bottom: 12px; }
.project-hero-badges { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }

/* ── IP / Patent Badges ─────────────────────────────────────────────────── */
.badge-ip {
  font-size: .65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  padding: 3px 10px;
  border: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.7);
  display: inline-block;
}

/* ── Product List (project page) ─────────────────────────────────────────── */
.section-heading { font-size: 1rem; font-weight: 700; color: var(--muted); text-transform: uppercase;
                    letter-spacing: .05em; margin: 0; }

.product-list { display: flex; flex-direction: column; gap: .5rem; }

.product-row {
  display: flex;
  align-items: flex-start;
  gap: 0;
  background: var(--white);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: box-shadow .15s;
  overflow: hidden;
}
.product-row:hover { box-shadow: 0 2px 12px rgba(0,0,0,.1); text-decoration: none; color: inherit; }

/* Froot Loop left stripe by type */
.product-row::before {
  content: '';
  width: 3px;
  flex-shrink: 0;
  align-self: stretch;
}
.type-downloadable::before { background: var(--type-downloadable); }
.type-simple::before       { background: var(--type-simple); }
.type-virtual::before      { background: var(--type-virtual); }
.type-configurable::before { background: var(--type-configurable); }
.type-bundle::before       { background: var(--type-bundle); }
.type-grouped::before      { background: var(--type-grouped); }

.product-row-img {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  overflow: hidden;
  background: #f0f0f0;
}
.product-row-img img { width: 100%; height: 100%; object-fit: cover; }
.product-row-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .7rem;
  font-weight: 700;
  color: #fff;
  opacity: .8;
}

.product-row-body   { padding: 12px 14px; min-width: 0; }
.product-row-sku    { font-size: .65rem; color: var(--muted); font-family: 'Courier New', monospace;
                       margin-bottom: 2px; }
.product-row-name   { font-size: .95rem; font-weight: 600; line-height: 1.3; margin-bottom: 4px; }
.product-row-desc   { font-size: .78rem; color: var(--muted); line-height: 1.4; }

.product-row-right  { padding: 12px 16px; flex-shrink: 0; display: flex; flex-direction: column;
                       align-items: flex-end; gap: 4px; }
.product-row-price  { font-size: 1.1rem; font-weight: 700; color: var(--dark); }

.mini-tag {
  display: inline-block;
  font-size: .6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  padding: 1px 6px;
  background: #e0e0e0;
  color: var(--mid);
}

/* ── Type Badges ─────────────────────────────────────────────────────────── */
.type-badge {
  font-size: .6rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 2px 8px;
  color: #fff;
  display: inline-block;
}
.type-badge-downloadable { background: var(--type-downloadable); }
.type-badge-simple       { background: var(--type-simple); }
.type-badge-virtual      { background: var(--type-virtual); }
.type-badge-configurable { background: var(--type-configurable); }
.type-badge-bundle       { background: var(--type-bundle); }
.type-badge-grouped      { background: var(--type-grouped); }
.type-badge-             { background: var(--type-default); }

/* Availability tags */
.avail-tag         { font-size: .6rem; font-weight: 700; text-transform: uppercase;
                      letter-spacing: .08em; padding: 2px 8px; }
.avail-instant     { background: #defbe6; color: #0e6027; }
.avail-inquire     { background: #fff8e1; color: #7c4a00; }

/* ── Product Detail Page ─────────────────────────────────────────────────── */
.product-detail-img-wrap {
  border: 2px solid var(--border);
  overflow: hidden;
  background: var(--white);
}
.type-border-downloadable { border-color: var(--type-downloadable); }
.type-border-simple       { border-color: var(--type-simple); }
.type-border-virtual      { border-color: var(--type-virtual); }
.type-border-configurable { border-color: var(--type-configurable); }

.product-detail-placeholder {
  width: 100%;
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: rgba(255,255,255,.6);
}
.type-bg-downloadable { background: var(--type-downloadable); }
.type-bg-simple       { background: var(--type-simple); }
.type-bg-virtual      { background: var(--type-virtual); }
.type-bg-configurable { background: var(--type-configurable); }
.type-bg-bundle       { background: var(--type-bundle); }
.type-bg-             { background: var(--type-default); }

.product-detail-name {
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 8px;
  color: var(--dark);
}
.product-detail-price {
  font-size: 2rem;
  font-weight: 800;
  color: var(--blue);
  margin-bottom: 4px;
}

.product-delivery-note { font-size: .78rem; color: var(--muted); }

/* ── CTA Buttons ─────────────────────────────────────────────────────────── */
.btn-cta {
  display: block;
  padding: 12px 28px;
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-align: center;
  border: 3px solid var(--fl-7, #ffea00);
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Arial Black', sans-serif;
  text-transform: uppercase;
}
.btn-cta-buy {
  background: var(--dark);
  color: #fff;
  border-color: var(--fl-7, #ffea00);
}
.btn-cta-buy:hover {
  background: var(--fl-0, #0f62fe);
  border-color: var(--fl-0, #0f62fe);
  color: #fff;
}
.btn-cta-inquire {
  background: transparent;
  color: var(--dark);
  border-color: var(--dark);
}
.btn-cta-inquire:hover {
  background: var(--dark);
  color: #fff;
  text-decoration: none;
}

/* ── Meta Table ──────────────────────────────────────────────────────────── */
.meta-table { width: 100%; font-size: .82rem; border-collapse: collapse; }
.meta-table th, .meta-table td { padding: 6px 8px; border-bottom: 1px solid var(--border);
                                   text-align: left; }
.meta-table th { font-weight: 600; color: var(--muted); width: 90px; }
.meta-table code { font-size: .75rem; background: #f4f4f4; padding: 1px 5px; }

/* ── Tabs ────────────────────────────────────────────────────────────────── */
.crione-tabs { border-bottom: 1px solid var(--border); }
.crione-tabs .nav-link {
  color: var(--muted);
  font-size: .85rem;
  font-weight: 600;
  padding: 8px 16px;
  border: 1px solid transparent;
  border-bottom: none;
}
.crione-tabs .nav-link.active {
  color: var(--dark);
  background: var(--white);
  border-color: var(--border) var(--border) var(--white);
}
.crione-tabs .nav-link:hover:not(.active) { color: var(--dark); border-color: transparent; }

.crione-tab-content {
  border: 1px solid var(--border);
  border-top: none;
  background: var(--white);
  padding: 20px;
}
.product-desc-lead { font-size: .9rem; line-height: 1.7; color: var(--mid); margin: 0; }

/* ── Product page sticky left column ─────────────────────────────────────── */
@media (min-width: 992px) {
  .product-left-sticky {
    position: sticky;
    top: 72px;           /* clears the nav (~56px) + 16px breathing room */
    align-self: flex-start;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    scrollbar-width: thin;
  }
}

/* Magento Page Builder content wrapper */
.magento-content {
  font-size: .85rem;
  line-height: 1.65;
  color: var(--mid);
  overflow-x: auto;
}
.magento-content h1 { font-size: 1.3rem; font-weight: 700; margin: 16px 0 8px; }
.magento-content h2 { font-size: 1.1rem; font-weight: 700; margin: 14px 0 6px; color: var(--dark); }
.magento-content h3 { font-size: 1rem; font-weight: 700; margin: 12px 0 5px; }
.magento-content p  { margin: 0 0 10px; }
.magento-content [data-pb-style]  { all: unset; display: block; }
.magento-content [data-content-type="row"] { display: block; max-width: 100% !important; }
.magento-content [data-content-type="html"] { display: block; }
.magento-content [data-content-type="image"] { display: none; }

/* Keyword chips on product page */
.kw-chip {
  display: inline-block;
  padding: 5px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: .78rem;
  color: var(--mid);
  font-weight: 500;
}

/* ── Breadcrumb ──────────────────────────────────────────────────────────── */
.crione-breadcrumb {
  font-size: .78rem;
  margin-bottom: 16px;
  --bs-breadcrumb-divider-color: var(--muted);
  --bs-breadcrumb-item-active-color: var(--muted);
}
.crione-breadcrumb a { color: var(--blue); }

/* ── Enter page ──────────────────────────────────────────────────────────── */
.enter-wrap {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.enter-card {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 48px;
  max-width: 440px;
  width: 100%;
}
.enter-title { font-size: 1.5rem; font-weight: 800; margin-bottom: 4px; }
.enter-sub   { font-size: .85rem; color: var(--muted); margin-bottom: 24px; }

.enter-card input[type="text"],
.enter-card input[type="password"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  font-family: 'Inter', sans-serif;
  font-size: .9rem;
  outline: none;
  margin-bottom: 12px;
}
.enter-card input:focus { border-color: var(--blue); box-shadow: 0 0 0 2px rgba(15,98,254,.15); }

/* ── Inquire form ────────────────────────────────────────────────────────── */
.inquire-wrap  { max-width: 620px; margin: 48px auto; }
.inquire-title { font-size: 1.5rem; font-weight: 800; margin-bottom: 4px; }
.inquire-prod  { font-size: .9rem; color: var(--muted); margin-bottom: 24px; }
.inquire-wrap label { font-size: .8rem; font-weight: 600; text-transform: uppercase;
                        letter-spacing: .06em; color: var(--muted); display: block; margin-bottom: 4px; }
.inquire-wrap input,
.inquire-wrap textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  font-family: 'Inter', sans-serif;
  font-size: .9rem;
  margin-bottom: 16px;
  outline: none;
}
.inquire-wrap input:focus,
.inquire-wrap textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 2px rgba(15,98,254,.15); }

/* ── Success page ────────────────────────────────────────────────────────── */
.success-wrap  { min-height: 60vh; display: flex; align-items: center; justify-content: center; }
.success-card  { background: var(--white); border: 1px solid var(--border); padding: 48px;
                  max-width: 540px; width: 100%; text-align: center; }
.success-icon  { font-size: 3rem; margin-bottom: 16px; }
.success-title { font-size: 1.5rem; font-weight: 800; margin-bottom: 8px; }

/* ── Recommendation Rails ────────────────────────────────────────────────── */
.rec-rails {
  border-top: 1px solid var(--border);
  padding-top: 32px;
  padding-bottom: 48px;
}
.rec-section { margin-bottom: 36px; }
.rec-section-label {
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--muted);
  margin-bottom: 12px;
}
.rec-section-label strong { color: var(--dark); }
.rec-carousel {
  display: flex;
  gap: .75rem;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.rec-carousel::-webkit-scrollbar        { height: 3px; }
.rec-carousel::-webkit-scrollbar-track  { background: var(--bg); }
.rec-carousel::-webkit-scrollbar-thumb  { background: var(--border); }
.rec-card {
  flex-shrink: 0;
  width: 168px;
  background: var(--white);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  scroll-snap-align: start;
  transition: box-shadow .15s, transform .12s;
  display: flex;
  flex-direction: column;
}
.rec-card:hover {
  box-shadow: 0 3px 14px rgba(0,0,0,.12);
  transform: translateY(-2px);
  text-decoration: none;
  color: inherit;
}
.rec-card-img {
  width: 100%;
  height: 108px;
  overflow: hidden;
  background: #f0f0f0;
  flex-shrink: 0;
}
.rec-card-img img { width: 100%; height: 100%; object-fit: cover; }
.rec-card-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .08em;
  color: rgba(255,255,255,.75);
}
.rec-card-body { padding: 10px 12px; flex: 1; }
.rec-card-sku   { font-size: .6rem; color: var(--muted); font-family: 'Courier New', monospace;
                   margin-bottom: 2px; }
.rec-card-name  { font-size: .78rem; font-weight: 600; line-height: 1.3; margin-bottom: 4px;
                   display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
                   overflow: hidden; }
.rec-card-price { font-size: .85rem; font-weight: 700; color: var(--blue); }

/* ── Side fly-out tabs ────────────────────────────────────────────────────── */
.side-tab {
  position: fixed;
  top: 50%;
  z-index: 1025;
  writing-mode: vertical-rl;
  font-size: .58rem;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
  padding: 20px 9px;
  cursor: pointer;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: all .15s;
  font-family: 'Inter', sans-serif;
}
.side-tab-left {
  left: 0;
  background: var(--fl-3);
  color: #fff;
  transform: translateY(-50%) rotate(180deg);
  border-radius: 0 0 4px 0;
}
.side-tab-left:hover { background: #e65c00; color: #fff; text-decoration: none; }

.side-tab-right {
  right: 0;
  background: var(--fl-0);
  color: #fff;
  transform: translateY(-50%);
  border-radius: 4px 0 0 4px;
}
.side-tab-right:hover { background: var(--blue-dk); color: #fff; }

/* Share panel */
.share-panel {
  position: fixed;
  right: -300px;
  top: 50%;
  transform: translateY(-50%);
  width: 272px;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: -6px 0 32px rgba(0,0,0,.18);
  z-index: 1024;
  transition: right .28s cubic-bezier(.4,0,.2,1);
  max-height: 88vh;
  overflow-y: auto;
}
.share-panel.open { right: 38px; }

.share-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--border);
}
.share-panel-title { font-size: .8rem; font-weight: 700; color: var(--dark); }
.share-panel-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--muted);
  line-height: 1;
  padding: 0 2px;
}
.share-panel-close:hover { color: var(--dark); }

.share-qr-wrap {
  padding: 20px 20px 12px;
  text-align: center;
  background: var(--bg);
}
.share-qr-wrap canvas { display: block; margin: 0 auto; }
.share-qr-label {
  font-size: .65rem;
  color: var(--muted);
  margin: 8px 0 0;
  letter-spacing: .02em;
}

.share-links {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.share-link-btn {
  display: block;
  padding: 11px 14px;
  font-size: .8rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  text-align: left;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--dark);
  cursor: pointer;
  text-decoration: none;
  transition: all .12s;
}
.share-link-btn:hover {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  text-decoration: none;
}

/* ── Utilities ───────────────────────────────────────────────────────────── */
@media (max-width: 767px) {
  #projectContainer.view-masonry { columns: 2 180px; }
  .product-row-img { width: 56px; height: 56px; }
}
@media (max-width: 480px) {
  #projectContainer.view-masonry { columns: 1; }
  .enter-card { padding: 32px 24px; }
}


/* ═════════════════════════════════════════════════════════════════════════
   READABILITY LAYER  ·  overrides tokens + fixes contrast + sets rhythm
   Kept as one self-contained block so it can be tuned in one place.
   ═════════════════════════════════════════════════════════════════════════ */

:root {
  /* Warm paper background (was cold #f8f8f8) */
  --bg:      #F7F4F0;
  --white:   #FFFFFF;

  /* Stronger neutrals — muted was #6f6f6f (~4.9:1), now #4f4f4f (~8.5:1) */
  --muted:   #4f4f4f;
  --muted-2: #6a6a6a;
  --border:  #a8a5a0;        /* was #d0d0d0 — barely visible */
  --border-soft: #d8d3cc;    /* half-strength for inner rules */

  --dark:    #0a0a0a;

  /* Reading rhythm */
  --measure: 68ch;
  --lh-body: 1.68;
  --lh-tight: 1.28;
}

html { font-size: 17px; }          /* base bump: 16 → 17 */
@media (max-width: 480px) { html { font-size: 16px; } }

body {
  color: var(--dark);
  background: var(--bg);
  font-size: 1rem;
  line-height: var(--lh-body);
  font-feature-settings: "kern","liga","calt";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Anti-tiny-label sweep — raise small labels to ~13px minimum.
   Do NOT touch p/li — those should stay at body 1rem (17px). */
.footer-text, .footer-heading, .enter-primary-note, .enter-secondary-note,
.mega-link, .mega-link-title, .catalog-count, .hero-count, .tag-cloud-label,
.project-card-num, .project-card-meta, .footer-tagline, .founder-title,
.section-heading, .breadcrumb-item, .breadcrumb a {
  font-size: max(.82rem, 13px);
}
.mega-link-sub, .footer-copy, .enter-fine, .auth-fine, .founder-name {
  font-size: max(.78rem, 12.5px);   /* the true fine print — but still ≥12.5px */
}
/* Body copy floor — safety net */
p, li { font-size: 1rem; }

/* Section headings — tighter line-height.
   No blanket `color` here: it overrode the white inherited inside dark hero
   sections, rendering those headings black-on-black. Headings inherit their
   colour from the section they sit in, which is correct on light and dark. */
h1, h2, h3, h4 { line-height: var(--lh-tight); }

/* Long-form content — anchor + measure + rhythm */
.readable {
  max-width: var(--measure);
  margin-left: auto;
  margin-right: auto;
  color: var(--dark);
}
.readable p, .readable li { line-height: var(--lh-body); margin-bottom: 1.1em; }
.readable h2 {
  border-left: 4px solid var(--fl-0, #0f62fe);
  padding-left: 14px;
  margin-top: 2.3em;
}
.readable h3 {
  border-left: 3px solid var(--fl-3, #ff6a00);
  padding-left: 10px;
  margin-top: 1.6em;
}
.readable blockquote {
  border-left: 4px solid var(--fl-2, #9b59f5);
  background: rgba(155,89,245,.06);
  padding: 12px 20px;
  margin: 1.5em 0;
  font-style: italic;
}
.readable a { border-bottom: 1px solid var(--blue); }
.readable a:hover { border-bottom-color: var(--blue-dk); background: rgba(15,98,254,.08); text-decoration: none; }

/* Links — a touch bolder so they stand out on warm bg */
a { color: var(--blue); font-weight: 500; }
a:hover { color: var(--blue-dk); }

/* Cards & panels sit slightly above the warm paper */
.project-card, .search-result-row, .m-cell.grey, .dl-stat, .acct-panel,
.enter-card, .auth-card, .panel {
  background: var(--white);
}

/* Muted text — was too faint */
/* --muted is tuned for light backgrounds. `.footer-tagline`, `.founder-title`
   and `.hero-count` sit on the DARK footer/hero, where it rendered at 2.17:1,
   so they are excluded here and keep their own light-on-dark colours. */
.text-muted, small.text-muted, .catalog-count, .project-card-meta,
.breadcrumb, .breadcrumb a, .tag-cloud-label {
  color: var(--muted) !important;
}

/* Borders — visible now */
.project-card, .search-result-row, .enter-card, .auth-card, .acct-panel,
.dl-table, .dl-stat, .panel, .enter-path, .enter-secondary {
  border-color: var(--border);
}

/* Focus ring — keyboard nav should be obvious */
:focus-visible {
  outline: 3px solid var(--fl-7, #ffea00);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Selection highlight — reads as a design element, not an accident */
::selection { background: var(--fl-7, #ffea00); color: #0a0a0a; }

/* Prevent horizontal-scroll surprises on narrow screens */
img, video, table { max-width: 100%; }
