/* ============================================
   Creatively Cubic — Simple, clean Jekyll styles
   ============================================ */

:root {
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --text: #0f172a;
  --text-muted: #475569;
  --accent: #0ea5e9;
  --accent-dark: #0284c8;
  --border: #e2e8f0;
  --card: #ffffff;
  --success: #10b981;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.08), 0 10px 15px -3px rgba(15, 23, 42, 0.06);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Layout */
main {
  min-height: 60vh;
}

/* Navigation */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
}

.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.logo-mark:not(img) {
  background: var(--accent);
  color: white;
}

.logo-mark img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
  display: block;
}

.logo-text {
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-links a:hover {
  color: var(--accent);
  text-decoration: none;
}

.nav-cta {
  background: var(--accent);
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9rem;
}

.nav-cta:hover {
  background: var(--accent-dark);
  color: white !important;
  text-decoration: none;
}

/* Mobile nav */
.nav-toggle,
.nav-toggle-label {
  display: none;
}

@media (max-width: 720px) {
  .nav-toggle-label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: 8px;
  }
  .nav-toggle-label span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: 0.2s;
  }
  .nav-links {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 1rem 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border);
    display: none;
  }
  .nav-toggle:checked ~ .nav-links {
    display: flex;
  }
  .nav-links li {
    width: 100%;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border);
  }
  .nav-links li:last-child {
    border-bottom: none;
    padding-top: 1rem;
  }
  .nav-cta {
    display: inline-block;
    width: auto;
  }
}

/* Hero */
.hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 4.5rem 1.25rem 3.5rem;
  text-align: center;
}

.hero h1 {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  font-size: clamp(2.25rem, 6vw, 3.5rem);
  line-height: 1.05;
  margin: 0 0 1rem;
  font-weight: 800;
  letter-spacing: -1.5px;
}

/* Ensure the two lines are treated as centered blocks.
   The flex container + align-items centers them to the same vertical axis,
   so "Colorful [noun]" stays perfectly centered over "that sticks with you"
   even as the animated noun changes length. */
.hero-top,
.hero-bottom {
  display: block;
}

.hero-top {
  /* Keep "Colorful [noun]" as a single non-wrapping unit on one line.
     On mobile the browser was inserting a break between them even when
     there was room (partly because of the previous margin-left eating space).
     width:fit-content makes the centered block size to the actual phrase
     instead of taking full width. */
  white-space: nowrap;
  width: fit-content;
  max-width: 100%;
  padding-left: 2.5rem;
}

.hero .subtitle {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 1.75rem;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Animated rolodex for hero */
.rolodex,
.colorful-rolodex,
.verb-rolodex {
  display: inline-block;
  height: 1.6em;
  overflow: hidden;
  vertical-align: baseline;
  text-align: left;
}

.rolodex-inner,
.colorful-inner,
.verb-inner {
  display: block;
}

.rolodex-word,
.colorful-word,
.verb-word {
  display: block;
  height: 1.6em;
  line-height: 1.6em;
  text-align: left;
}

.colorful-word {
  padding-bottom: 1rem;
}

.rolodex-inner {
  /* transform now set by JS for the sequence */
}

/* User's additional alignment styles for colorful (can be adjusted without affecting animation).
   Target .colorful-rolodex, .colorful-inner or .colorful-word as needed for fine control.
*/
.colorful {
  /* size is now provided by .colorful-word / .colorful-rolodex */
}

@keyframes rolodex-spin {
  0% { transform: translateY(0); }
  4% { transform: translateY(0); }
  5% { transform: translateY(-5%); }
  9% { transform: translateY(-5%); }
  10% { transform: translateY(-10%); }
  14% { transform: translateY(-10%); }
  15% { transform: translateY(-15%); }
  19% { transform: translateY(-15%); }
  20% { transform: translateY(-20%); }
  24% { transform: translateY(-20%); }
  25% { transform: translateY(-25%); }
  29% { transform: translateY(-25%); }
  30% { transform: translateY(-30%); }
  34% { transform: translateY(-30%); }
  35% { transform: translateY(-35%); }
  39% { transform: translateY(-35%); }
  40% { transform: translateY(-40%); }
  44% { transform: translateY(-40%); }
  45% { transform: translateY(-45%); }
  49% { transform: translateY(-45%); }
  50% { transform: translateY(-50%); }
  54% { transform: translateY(-50%); }
  55% { transform: translateY(-55%); }
  59% { transform: translateY(-55%); }
  60% { transform: translateY(-60%); }
  64% { transform: translateY(-60%); }
  65% { transform: translateY(-65%); }
  69% { transform: translateY(-65%); }
  70% { transform: translateY(-70%); }
  74% { transform: translateY(-70%); }
  75% { transform: translateY(-75%); }
  79% { transform: translateY(-75%); }
  80% { transform: translateY(-80%); }
  84% { transform: translateY(-80%); }
  85% { transform: translateY(-85%); }
  89% { transform: translateY(-85%); }
  90% { transform: translateY(-90%); }
  94% { transform: translateY(-90%); }
  95% { transform: translateY(-95%); }
  99% { transform: translateY(-95%); }
  100% { transform: translateY(-95%); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
  text-decoration: none;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover {
  background: var(--accent-dark);
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-secondary {
  background: white;
  color: var(--text);
  border-color: var(--border);
}

.btn-secondary:hover {
  background: var(--bg-alt);
  text-decoration: none;
  border-color: #cbd5e1;
}

/* Sections */
.section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1.25rem;
}

.section-header {
  margin-bottom: 1.75rem;
}

.section-header h2 {
  font-size: 1.85rem;
  margin: 0 0 0.5rem;
  font-weight: 700;
}

.section-header p {
  color: var(--text-muted);
  max-width: 560px;
  margin: 0;
}

/* Cards & Grids */
.grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}

a.card {
  display: block;
  text-decoration: none;
  color: inherit;
}

a.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgb(15 23 42 / 0.1), 0 4px 6px -4px rgb(15 23 42 / 0.1);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgb(15 23 42 / 0.1), 0 4px 6px -4px rgb(15 23 42 / 0.1);
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
}

.card p {
  margin: 0 0 0.75rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card .meta {
  font-size: 0.8rem;
  color: #64748b;
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: #f1f5f9;
}

.gallery-item > a {
  display: block;
  text-decoration: none;
}

.gallery-item .main-image {
  display: block;
  text-decoration: none;
  position: relative;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 1080 / 1215;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.03);
}

.gallery-item .overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(15,23,42,0.75), transparent);
  color: white;
  padding: 1rem 1rem 0.85rem;
}

.gallery-item .overlay h3 {
  margin: 0 0 0.2rem;
  font-size: 1rem;
  font-weight: 600;
}

/* Small Etsy badge on shop listing cards (distinct from main card click-to-detail) */
.gallery-item .etsy-badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  background: rgba(255, 255, 255, 0.95);
  color: #111;
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 3px;
  text-decoration: none;
  font-weight: 600;
  line-height: 1;
  z-index: 10;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.gallery-item .etsy-badge:hover {
  background: #fff;
}

/* Draft indicator badge on /shop listing cards (only for items with draft: true) */
.gallery-item .draft-indicator {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  background: #1f2937;
  color: #f59e0b;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  z-index: 10;
  line-height: 1;
  letter-spacing: 0.5px;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* Subtle visual treatment for draft cards in dev */
.gallery-item.is-draft {
  border-color: #f59e0b;
}

.gallery-item.is-draft img {
  filter: saturate(0.9) brightness(0.97);
}

/* Expanded image view on individual shop item detail pages */
.item-detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.item-detail-gallery img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: block;
}

.item-main-image {
  position: relative;
}

.item-main-image .main-thumbnail {
  width: 100%;
  max-width: 800px;
  height: auto;
  border-radius: var(--radius);
  border: 2px solid var(--accent);
  display: block;
  margin-bottom: 1rem;
}

/* Image lightbox / expanding overlay (shop detail pages only) */
.shop-zoomable {
  cursor: zoom-in;
  transition: transform 120ms ease, box-shadow 120ms ease, filter 120ms ease;
}

.shop-zoomable:hover {
  transform: scale(1.015);
  box-shadow: 0 10px 15px -3px rgba(15, 23, 42, 0.12), 0 4px 6px -4px rgba(15, 23, 42, 0.12);
  filter: brightness(1.02);
}

/* Thangs 3D model embed section (used on shop detail pages for subscription models) */
.thangs-section {
  margin: 2rem 0 1rem;
  padding: 1.25rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.thangs-section h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
}

.thangs-section p {
  margin: 0.4rem 0;
}

.thangs-embed-wrapper {
  position: relative;
  width: 100%;
  max-width: 640px;
  padding-bottom: 75%; /* matches the 480/639 embed ratio */
  height: 0;
  overflow: hidden;
  border-radius: calc(var(--radius) - 2px);
  background: #f1f5f9;
  border: 1px solid var(--border);
}

.thangs-embed-wrapper iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* Prose links that trigger the same lightbox zoom (used in journal entries) */
.zoom-link {
  cursor: zoom-in;
}

.shop-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: block;
}

.shop-lightbox[hidden] {
  display: none;
}

.shop-lightbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.88);
  opacity: 0;
  transition: opacity 200ms ease;
  pointer-events: none;
}

.shop-lightbox.is-open .shop-lightbox-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.shop-lightbox-close {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 10003;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  font-size: 26px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition: transform 120ms ease, background 120ms ease;
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
}

.shop-lightbox.is-open .shop-lightbox-close {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.shop-lightbox-close:hover {
  background: white;
  transform: scale(1.05);
}

.shop-lightbox-fly {
  /* positioned + sized via JS during open/close animation */
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  background: white;
  box-sizing: border-box;
}

.video-poster {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  cursor: pointer;
}

.video-poster img {
  width: 100%;
  height: auto;
  display: block;
}

.media-play-overlay {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.92);
  color: #111827;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  pointer-events: none;
  z-index: 2;
}

.gallery-item .main-image {
  position: relative;
}

.card-media {
  position: relative;
  margin-bottom: 0.5rem;
}

.card-media img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  display: block;
}

.shop-lightbox-video {
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.gallery-item .overlay p {
  margin: 0;
  font-size: 0.8rem;
  opacity: 0.9;
}

/* Forms */
.form {
  max-width: 520px;
}

.form-group {
  margin-bottom: 1.1rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  background: white;
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* Local tools page (campaign URL builder etc.) */
.campaign-form {
  max-width: 560px;
}

.campaign-result {
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  word-break: break-all;
}

.campaign-result a {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.95rem;
  color: var(--accent);
  text-decoration: none;
}

.campaign-result a:hover {
  text-decoration: underline;
}

.copy-btn {
  margin-left: 0.5rem;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  border-radius: 6px;
}

/* Floating built URL bar (tools page) */
#campaign-floating {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 250;
  background: var(--bg);
  border-top: 1px solid var(--border);
  box-shadow: 0 -3px 10px rgba(0, 0, 0, 0.07);
  padding: 0.55rem 1rem;
  display: none; /* controlled by JS */
}

#campaign-floating .floating-inner {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.875rem;
}

#campaign-floating .floating-label {
  flex-shrink: 0;
  font-weight: 600;
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-right: 0.25rem;
}

#campaign-floating a {
  flex: 1 1 auto;
  min-width: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.85rem;
  color: var(--accent);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#campaign-floating a:hover {
  text-decoration: underline;
}

#campaign-floating .copy-btn {
  margin-left: 0;
  padding: 0.25rem 0.6rem;
  font-size: 0.72rem;
  flex-shrink: 0;
}

/* About & content pages */
.page-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
}

.page-content h1 {
  font-size: 2.25rem;
  margin-top: 0;
}

.page-content h2 {
  margin-top: 2.25rem;
}

.page-content ul,
.page-content ol {
  padding-left: 1.35rem;
}

.page-content li + li {
  margin-top: 0.35rem;
}

/* Brochure page: QR code to the right of Featured Creations list */
.featured-with-qr {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  align-items: flex-start;
}

.featured-with-qr ul {
  flex: 1 1 280px;
  min-width: 0;
  margin: 0;
  padding-left: 1.35rem;
}

.featured-with-qr ul li {
  overflow-wrap: break-word;
}

.featured-with-qr > p {
  margin: 0;
}

.featured-with-qr .qr {
  display: block;
  flex: 0 0 auto;
  width: 240px;      /* default size - edit this or add width="..." to the image in markdown to make bigger */
  max-width: 240px;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 4px;
}

.featured-with-qr > ul > li:nth-child(5) {
  position: relative;
}

/* Blog / Journal listing */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.post-list li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.post-list li:last-child {
  border-bottom: none;
}

.post-list .post-date {
  font-size: 0.8rem;
  color: #64748b;
  display: block;
  margin-bottom: 0.15rem;
}

.post-list h3 {
  margin: 0;
  font-size: 1.15rem;
}

/* Journal entries with co-located thumbnails (new _journal/ structure) */
.journal-list-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.journal-list-item .journal-thumb {
  flex: 0 0 72px;
  min-width: 72px;
}

.journal-list-item .journal-thumb img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--radius);
  display: block;
  border: 1px solid var(--border);
}

.journal-list-item .journal-list-meta {
  flex: 1;
  min-width: 0;
}

.journal-list-item .journal-meta {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Single post */
.post-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.post-header h1 {
  margin: 0 0 0.5rem;
}

.post-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Utility */
.text-center { text-align: center; }
.mt-2 { margin-top: 1.5rem; }

/* Footer */
.footer {
  background: #0f172a;
  color: #cbd5e1;
  margin-top: 4rem;
  font-size: 0.9rem;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.75rem 1.25rem 2rem;
  display: grid;
  gap: 2.25rem;
  grid-template-columns: 1.25fr 2.75fr;
}

@media (max-width: 720px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 1.5rem; /* tighter stack on mobile */
  }
}

.footer-brand .logo {
  color: white;
  margin-bottom: 0.5rem;
}

.footer-brand p {
  margin: 0.35rem 0 0;
  font-size: 0.9rem;
  opacity: 0.85;
}

.footer-links {
  display: grid;
  /* Mobile-first: use auto-fit so the number of columns adjusts.
     A 125px min keeps each section (including Legal) usable and reduces
     the relative size of gaps. On phones this typically yields 2 columns. */
  grid-template-columns: repeat(auto-fit, minmax(125px, 1fr));
  gap: 1rem;
}

@media (min-width: 721px) {
  .footer-links {
    /* Desktop: 4 columns. Give Legal substantially more width on big screens
       so the copyright line fits without wrapping (plenty of room available). */
    grid-template-columns: minmax(95px, 1fr) minmax(95px, 1fr) minmax(95px, 1fr) minmax(200px, 1.8fr);
    gap: 1.25rem;
  }

  /* The © line is now guaranteed enough width; prevent wrap */
  .footer-links > div:last-child span:first-child {
    white-space: nowrap;
  }
}

.footer-links strong {
  display: block;
  color: white;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
  letter-spacing: 0.5px;
}

.footer-links a,
.footer-links span {
  display: block;
  color: #94a3b8;
  margin: 0.3rem 0;
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: #e0f2fe;
  text-decoration: none;
}

.social-icons {
  display: flex;
  gap: 0.9rem;
  margin-top: 0.75rem;
}

.social-icons a {
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  transition: color 0.2s ease, transform 0.1s ease;
}

.social-icons a:hover {
  color: #e0f2fe;
  transform: translateY(-1px);
}

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

.footer-bottom {
  border-top: 1px solid #1e2937;
  text-align: center;
  padding: 1rem 1.25rem;
  font-size: 0.75rem;
  opacity: 0.7;
}

/* Small polish */
hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

/* Product badges for shop & gallery (fun, colorful maker vibe) */
.product-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.1rem 0.45rem;
  border-radius: 9999px;
  background: #ec4899;
  color: white;
  margin-right: 0.25rem;
  vertical-align: middle;
}
.product-badge.magnetic { background: #0ea5e9; }
.product-badge.glow { background: #a78bfa; }
.product-badge.multicolor { background: #f97316; }

/* Journal entries carousel on homepage */
.journal-carousel {
  margin: 1.5rem 0;
}

.journal-carousel .section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.journal-carousel .section-header h2 {
  margin: 0;
  font-size: 1.1rem;
}

.journal-carousel .section-header a {
  font-size: 0.85rem;
}

.carousel-wrapper {
  position: relative;
  padding-left: 8px;
  padding-right: 8px;
  margin-left: -8px;
  margin-right: -8px;
}

.carousel-track {
  display: flex;
  gap: 1rem;
  width: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 0.25rem 0 0.75rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-card {
  flex: 0 0 260px;
  min-width: 260px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.carousel-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.1);
}

.carousel-card img {
  width: 100%;
  height: 135px;
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.carousel-card-body {
  padding: 0.6rem 0.7rem 0.7rem;
}

.carousel-card.no-image .carousel-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.carousel-card.no-image .carousel-card-body p {
  flex: 1;
}

.carousel-card-body h3 {
  font-size: 0.92rem;
  line-height: 1.25;
  margin: 0.2rem 0 0.35rem;
  font-weight: 600;
}

.carousel-card-body p {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.3;
}

.carousel-date {
  font-size: 0.68rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.3px;
}

.carousel-btn {
  position: absolute;
  top: 42%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 9999px;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  z-index: 5;
  transition: all 120ms ease;
  color: #334155;
}

.carousel-btn:hover {
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.18);
  transform: translateY(-50%) scale(1.05);
}

.carousel-prev {
  left: -6px;
}

.carousel-next {
  right: -6px;
}

@media (max-width: 640px) {
  .carousel-btn {
    display: none;
  }
  .carousel-card {
    flex: 0 0 220px;
    min-width: 220px;
  }
}

/* Shop product carousels (pals, keychains, fidgets, functional) on homepage */
.shop-carousel .section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 0.6rem;
}
.shop-carousel .section-header h2 {
  margin: 0;
  font-size: 1.15rem;
}
.shop-carousel .section-header a {
  font-size: 0.82rem;
}

.carousel-track .card {
  flex: 0 0 205px;
  min-width: 205px;
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  scroll-snap-align: start;
}
.carousel-track .card img {
  width: 100%;
  height: 115px;
  object-fit: cover;
  border-radius: 4px;
  display: block;
  margin-bottom: 0.3rem;
}
.carousel-track .card h3 {
  font-size: 0.85rem;
  margin: 0 0 0.1rem;
  line-height: 1.15;
  font-weight: 600;
}
.carousel-track .card .meta {
  font-size: 0.68rem;
  margin: 0;
  color: var(--text-muted);
  line-height: 1.2;
}

@media (max-width: 640px) {
  .carousel-track .card {
    flex: 0 0 175px;
    min-width: 175px;
  }
  .carousel-track .card img {
    height: 98px;
  }
}

/* ============================================
   Events page: Visual calendar
   ============================================ */

.calendar-wrapper {
  margin: 0.5rem 0 1rem;
}

.card .calendar-wrapper {
  margin: 0;
}

.calendar-controls {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.calendar-arrow {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: white;
  color: var(--accent-dark);
  font: inherit;
  font-size: 1.25rem;
  line-height: 1;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.calendar-arrow:hover:not(:disabled),
.calendar-arrow:focus-visible {
  border-color: var(--accent);
  background: var(--bg-alt);
  transform: translateY(-1px);
}

.calendar-arrow:disabled {
  opacity: 0.35;
  cursor: default;
  box-shadow: none;
}

.calendar-months {
  display: flex;
  gap: 0.85rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 #f1f5f9;
}

.cal-month {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.9rem 0.75rem 1rem;
  flex: 0 0 255px;
  min-width: 240px;
  scroll-snap-align: start;
}

.cal-month-header {
  font-size: 0.95rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.55rem;
  color: var(--text);
}

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 0.62rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-bottom: 0.2rem;
}

.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.cal-day {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  border-radius: 6px;
  color: var(--text);
  background: white;
  border: 1px solid transparent;
  min-height: 26px;
}

.cal-day.other-month {
  color: #94a3b8;
  background: transparent;
  border-color: transparent;
}

.cal-day.event {
  font-weight: 700;
  position: relative;
  cursor: pointer;
  transition: transform 80ms ease, filter 80ms ease;
}

.cal-day.event:active {
  transform: scale(0.9);
  filter: brightness(1.08);
}

.cal-day.event::after {
  content: '';
  position: absolute;
  bottom: 3px;
  left: 22%;
  width: 56%;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  opacity: 0.55;
}

@keyframes calDayClick {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(14, 165, 233, 0.25); }
  22% { transform: scale(0.82); box-shadow: 0 0 0 5px rgba(14, 165, 233, 0.22); }
  52% { transform: scale(1.13); box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.12); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(14, 165, 233, 0); }
}

.cal-day.event.clicked {
  animation: calDayClick 260ms cubic-bezier(0.25, 0.9, 0.3, 1.15);
}

.cal-day.little-paws {
  background: #bae6fd;
  color: #0369a1;
  border-color: #7dd3fc;
}

.cal-day.st-johns {
  background: #fde68a;
  color: #92400e;
  border-color: #fbbf24;
}

.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  margin-top: 1rem;
  font-size: 0.8rem;
}

.cal-legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.cal-legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  border: 1px solid;
}

/* Event popup (small clickable modal) */
.event-popup {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.event-popup[hidden] {
  display: none;
}

.event-popup-content {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.15rem 1.1rem;
  max-width: 310px;
  width: 100%;
  box-shadow: 0 10px 15px -3px rgb(15 23 42 / 0.18), 0 4px 6px -4px rgb(15 23 42 / 0.1);
}

.event-popup-close {
  position: absolute;
  top: 4px;
  right: 6px;
  width: 26px;
  height: 26px;
  border: none;
  background: transparent;
  font-size: 1.65rem;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
}

.event-popup-close:hover {
  color: var(--text);
  background: var(--bg-alt);
}

.event-popup-content h4 {
  margin: 0 0 0.25rem;
  font-size: 1rem;
  font-weight: 700;
  padding-right: 18px;
  color: var(--text);
}

.event-popup-content .popup-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0 0 0.55rem;
  line-height: 1.35;
}

.event-popup-content .popup-desc {
  font-size: 0.88rem;
  margin: 0 0 0.7rem;
  line-height: 1.4;
  color: var(--text);
}

.event-popup-content a {
  font-size: 0.82rem;
  font-weight: 600;
}

.event-popup-content .popup-adds a {
  margin-left: 0.35rem;
}

/* Popup entrance animation */
.event-popup.is-open {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.event-popup.is-open .event-popup-content {
  animation: popupEnter 210ms cubic-bezier(0.23, 1.0, 0.32, 1);
}

@keyframes popupEnter {
  from {
    opacity: 0;
    transform: scale(0.86) translateY(14px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.cal-legend-dot.lp {
  background: #bae6fd;
  border-color: #7dd3fc;
}

.cal-legend-dot.sj {
  background: #fde68a;
  border-color: #fbbf24;
}

/* Add to calendar buttons on /events (placed after visual calendar) */
.add-to-cal {
  margin: 0.6rem 0 1.1rem;
}

.add-to-cal h3 {
  font-size: 1.05rem;
  margin: 0 0 0.4rem;
  font-weight: 700;
}

.add-cal-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.add-cal-btn {
  padding: 0.5rem 0.9rem;
  font-size: 0.85rem;
}

.add-to-cal .meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0.4rem 0 0;
  line-height: 1.35;
}

/* ============================================
   Print styles (site-wide)
   Makes the entire site nicely printable via @media print.
   Header, footer, interactive elements, overlays, and decorative
   UI are hidden. Content is optimized for paper (page breaks,
   contrast, links, images, etc.).
   Normal screen view is completely unaffected.
============================================ */

@media print {
  /* Hide all site chrome and interactive/non-printable UI */
  .nav,
  footer,
  .nav-toggle,
  .nav-toggle-label,
  #draft-filter-notice,
  .btn,
  .add-to-cal,
  .shop-lightbox,
  .event-popup,
  .thangs-section,
  .thangs-embed-wrapper,
  .calendar-wrapper .event-popup,
  .draft-indicator {
    display: none !important;
  }

  /* Reset layout & typography for clean print output */
  html,
  body {
    background: #fff !important;
    color: #000 !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 11pt;
    line-height: 1.45;
  }

  main {
    min-height: 0 !important;
  }

  .page-content {
    max-width: 100% !important;
    width: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    --badge-left: 16.5em !important;
    --badge-top: 0.1em !important;
    --badge-height: 100px !important;
  }

  /* Paper setup */
  @page {
    size: letter portrait;
    margin: 0.5in;
  }

  /* Content elements */
  a {
    color: #000 !important;
    text-decoration: underline;
  }

  /* Show destination for external links */
  .page-content a[href^="http"]:after,
  .page-content a[href^="https"]:after {
    content: " (" attr(href) ")";
    font-size: 8pt;
    color: #555;
    word-break: break-all;
  }

  /* Don't print the URL for the ACT insurance seal in the brochure */
  .page-content a.act-insurance:after {
    content: none !important;
  }
  .page-content a.act-insurance {
    text-decoration: none !important;
  }

  img {
    max-width: 100% !important;
    height: auto !important;
    page-break-inside: avoid;
    break-inside: avoid;
  }

  .featured-with-qr {
    display: flex !important;
    gap: 0.6rem !important;
    width: 100% !important;
  }
  .featured-with-qr .qr {
    width: 200px !important;
    max-width: none !important;
  }
  .featured-with-qr ul {
    flex: 1 1 400px !important;
    font-size: 11pt !important;
  }

  .featured-with-qr > ul > li:nth-child(5) {
    position: relative;
  }

  hr {
    border-top-color: #aaa;
    margin: 0.35rem 0;
  }

  /* Avoid awkward breaks */
  ul, ol, li, h1, h2, h3, h4, .card, .gallery-item, .carousel-card {
    page-break-inside: avoid;
    break-inside: avoid;
  }

  h1, h2, h3, h4 {
    page-break-after: avoid;
    break-after: avoid;
  }

  /* Cards and containers */
  .card {
    box-shadow: none !important;
    border: 1px solid #ddd;
    break-inside: avoid;
  }

  /* Make carousels (journal + others) flow reasonably on paper */
  .carousel-wrapper {
    overflow: visible !important;
  }
  .carousel-track {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    overflow: visible !important;
  }
  .carousel-card {
    flex: none !important;
    min-width: 0 !important;
    width: 100% !important;
    break-inside: avoid;
    border: 1px solid #ddd;
  }

  /* Visual calendar — make the grid printable (2 per row) */
  .calendar-controls {
    display: none;
  }

  .calendar-months {
    overflow: visible;
    flex-wrap: wrap;
    gap: 0.4rem;
  }
  .cal-month {
    flex: 0 0 calc(50% - 0.2rem);
    min-width: 0;
    break-inside: avoid;
    page-break-inside: avoid;
  }
  .cal-month-header {
    font-size: 0.8rem;
    margin-bottom: 0.3rem;
  }
  .cal-days {
    gap: 2px;
  }
  .cal-day {
    font-size: 0.55rem;
    min-height: 16px;
  }
  .cal-legend {
    display: none;
  }

  /* Gallery / shop listing cards — clean images, hide overlays & badges */
  .gallery-item .overlay,
  .gallery-item .etsy-badge,
  .gallery-item .draft-indicator {
    display: none !important;
  }
  .gallery-grid,
  .item-detail-gallery {
    gap: 0.4rem;
  }

  /* Remove interactive/hover treatments */
  .shop-zoomable,
  .shop-zoomable:hover,
  .carousel-card:hover,
  .card:hover,
  .gallery-item:hover img {
    transform: none !important;
    box-shadow: none !important;
    filter: none !important;
  }
}

.brochure-badge {
  position: absolute;
  left: var(--badge-left, 16.5em) !important;
  top: var(--badge-top, 0.1em) !important;
  height: var(--badge-height, 100px) !important;
  width: auto;
}

.share-fab {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 120;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 1px solid rgba(14, 165, 233, 0.25);
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
  padding: 0.8rem 1rem;
  font: inherit;
  font-weight: 700;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
  cursor: pointer;
  backdrop-filter: blur(12px);
}

.share-fab:hover {
  transform: translateY(-1px);
  background: white;
}

.share-fab svg {
  color: var(--accent-dark);
}

.share-overlay {
  position: fixed;
  inset: 0;
  z-index: 10010;
  display: grid;
  place-items: end;
  padding: 1rem;
}

.share-overlay[hidden] {
  display: none;
}

.share-overlay-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(4px);
}

.share-overlay-panel {
  position: relative;
  width: min(360px, 100%);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
  padding: 1rem;
}

.share-overlay-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.share-overlay-header h2 {
  margin: 0 0 0.2rem;
  font-size: 1.1rem;
}

.share-overlay-header p,
.share-overlay-note,
.share-status {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.share-overlay-close {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 9999px;
  background: var(--bg-alt);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.share-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.share-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  justify-content: flex-start;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-alt);
  color: var(--text);
  padding: 0.9rem 0.95rem;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.share-option:hover,
.share-overlay-close:hover {
  background: white;
}

.share-option-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  background: white;
  border: 1px solid var(--border);
  color: var(--accent-dark);
  font-size: 1rem;
  font-weight: 800;
  flex-shrink: 0;
}

.share-overlay-note {
  margin-bottom: 0.5rem;
}

.share-status {
  min-height: 1.4em;
}

body.share-overlay-open {
  overflow: hidden;
}

@media (max-width: 640px) {
  .share-fab {
    right: 12px;
    bottom: 12px;
    padding: 0.78rem 0.95rem;
  }

  .share-overlay {
    place-items: end stretch;
    padding: 0.75rem;
  }

  .share-overlay-panel {
    width: 100%;
  }

  .share-actions {
    grid-template-columns: 1fr;
  }
}
