img {
  -webkit-user-drag: none;
  user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
}

/* Attribution watermark overlaid on artwork so a saved/screenshotted image still credits the source */
.watermark {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 4px 12px 4px 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  pointer-events: none;
  user-select: none;
}

.watermark img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

.watermark span {
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.watermark small {
  display: block;
  font-size: 0.62rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
}

@media (max-width: 480px) {
  .watermark span { font-size: 0.66rem; }
  .watermark small { font-size: 0.58rem; }
  .watermark img { width: 16px; height: 16px; }
}

#devtoolsBanner {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translate(-50%, 12px);
  background: #17181c;
  color: #f5f6f8;
  font-size: 13px;
  font-weight: 500;
  padding: 10px 18px;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 9999;
}

#devtoolsBanner.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

:root {
  --bg: #ffffff;
  --bg-alt: #f5f6f8;
  --text: #17181c;
  --text-muted: #55585f;
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --border: #e4e5e9;
  --card-bg: #ffffff;
  --bg-rgb: 255, 255, 255;
}

:root[data-theme="dark"] {
  --bg: #0f1115;
  --bg-alt: #16181d;
  --text: #eceef1;
  --text-muted: #a2a6ad;
  --accent: #818cf8;
  --accent-hover: #6366f1;
  --border: #262932;
  --card-bg: #16181d;
  --bg-rgb: 15, 17, 21;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1115;
    --bg-alt: #16181d;
    --text: #eceef1;
    --text-muted: #a2a6ad;
    --accent: #818cf8;
    --accent-hover: #6366f1;
    --border: #262932;
    --card-bg: #16181d;
    --bg-rgb: 15, 17, 21;
  }
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

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

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }
* { scrollbar-color: var(--border) var(--bg); scrollbar-width: thin; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  transition: background 0.2s ease, color 0.2s ease;
  animation: pageFade 0.45s ease both;
}

@keyframes pageFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

a { color: inherit; }

/* Scroll-reveal: JS adds .reveal to sections/cards, then .in-view once visible */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

.nav {
  position: sticky;
  top: 0;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  z-index: 10;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.nav.scrolled {
  background: rgba(var(--bg-rgb), 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--border);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

.nav-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo {
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
  color: var(--text);
}

.nav-inner nav { display: flex; gap: 20px; }

.nav-inner nav a {
  position: relative;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  padding-bottom: 3px;
  transition: color 0.2s ease;
}

.nav-inner nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -3px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transition: right 0.25s ease;
}

.nav-inner nav a:hover { color: var(--accent); }
.nav-inner nav a:hover::after { right: 0; }
.nav-inner nav a.active { color: var(--accent); font-weight: 600; }
.nav-inner nav a.active::after { right: 0; }

.theme-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  font-size: 1rem;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.theme-toggle:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.theme-toggle.spin {
  animation: themeSpin 0.5s ease;
}

@keyframes themeSpin {
  from { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.2); }
  to { transform: rotate(360deg) scale(1); }
}

@media (max-width: 640px) {
  .nav-inner {
    flex-wrap: wrap;
    row-gap: 8px;
    padding: 14px 20px;
  }

  .nav-inner nav {
    order: 3;
    width: 100%;
    justify-content: center;
    gap: 14px;
  }

  .logo { font-size: 1rem; }
  .nav-inner nav a { font-size: 0.9rem; }
}

.hero {
  position: relative;
  max-width: 960px;
  margin: 0 auto;
  padding: 96px 24px 64px;
  overflow: hidden;
  isolation: isolate;
}

.hero-glow {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.28;
  background: var(--accent);
  animation: blobFloat 18s ease-in-out infinite;
  will-change: transform;
}

.blob-1 { top: -140px; left: -100px; }
.blob-2 { top: 20px; right: -120px; background: #f472b6; animation-duration: 22s; animation-delay: -5s; }
.blob-3 { bottom: -160px; left: 28%; background: #22d3ee; animation-duration: 20s; animation-delay: -10s; }

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -24px) scale(1.08); }
  66% { transform: translate(-24px, 22px) scale(0.94); }
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 10%), rgba(129, 140, 248, 0.16), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.hero:hover::after { opacity: 1; }

.hero-inner { position: relative; }

@keyframes heroIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.eyebrow {
  color: var(--accent);
  font-weight: 600;
  margin: 0 0 8px;
  letter-spacing: 0.02em;
  animation: heroIn 0.7s ease 0.05s both;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  margin: 0 0 12px;
  background: linear-gradient(90deg, var(--text) 0%, var(--accent) 50%, var(--text) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: heroIn 0.7s ease 0.15s both, heroGradient 7s ease-in-out 0.85s infinite;
}

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

.tagline {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 560px;
  margin: 0 0 32px;
  animation: heroIn 0.7s ease 0.3s both;
}

.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  animation: heroIn 0.7s ease 0.45s both;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 8px;
  border: 1px solid var(--border);
  text-decoration: none;
  font-weight: 600;
  color: var(--text);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08); }
.btn:active { transform: translateY(0); }

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

.btn.primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 12px 28px rgba(99, 102, 241, 0.35);
}

.btn:not(.primary):hover { border-color: var(--accent); }

@media (max-width: 640px) {
  .blob { width: 260px; height: 260px; filter: blur(50px); }
}

.section {
  max-width: 960px;
  margin: 0 auto;
  padding: 56px 24px;
  border-top: 1px solid var(--border);
}

.section-first { border-top: none; }

.section h2 {
  font-size: 1.6rem;
  margin: 0 0 20px;
}

.section-lede {
  color: var(--text-muted);
  max-width: 640px;
  margin: -8px 0 28px;
}

.about-grid {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 32px;
  align-items: start;
}

.about-photo {
  width: 200px;
  height: 200px;
  border-radius: 16px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.about-body p {
  margin: 0 0 16px;
  color: var(--text-muted);
  line-height: 1.65;
}

.about-body p:last-of-type { margin-bottom: 20px; }
.about-body strong { color: var(--text); }
.about-body em { color: var(--text); font-style: normal; font-weight: 600; }

.about-body h3 {
  font-size: 1.1rem;
  margin: 32px 0 12px;
  color: var(--text);
}

.about-body h3:first-child { margin-top: 0; }

.about-body ul {
  margin: 0 0 16px;
  padding-left: 20px;
  color: var(--text-muted);
  line-height: 1.65;
}

.about-body ul li { margin-bottom: 6px; }

.about-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.about-links a {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  background: var(--bg-alt);
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.about-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

@media (max-width: 560px) {
  .about-grid {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .about-links { justify-content: center; }
}

.marketplace-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

.market-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.market-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.10);
  border-color: var(--accent);
}

.market-media {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
  display: block;
}

.market-media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
}

.market-media-placeholder span {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-muted);
}

.market-body { padding: 20px; display: flex; flex-direction: column; gap: 10px; flex: 1; }

.market-body h3 { margin: 0; font-size: 1.1rem; }

.market-tagline {
  margin: 0;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
}

.market-desc { margin: 0; color: var(--text-muted); font-size: 0.9rem; }

.market-stack { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0; }

.market-stack span {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.market-pricing {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.88rem;
}

.market-pricing .price-row strong { color: var(--text); }
.market-pricing .price-row { color: var(--text-muted); }

.market-cta {
  margin-top: 12px;
  display: inline-block;
  text-align: center;
  padding: 9px 16px;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background 0.2s ease, transform 0.2s ease;
}

.market-cta:hover { background: var(--accent-hover); transform: translateY(-2px); }

.blog-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.blog-post {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.blog-post:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.10);
  border-color: var(--accent);
}

.blog-post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.blog-post-tag {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
  font-weight: 600;
  color: var(--accent);
}

.blog-post h3 { margin: 0 0 10px; font-size: 1.2rem; }

.img-frame {
  position: relative;
  display: block;
}

.blog-post-img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  background: var(--bg-alt);
  border-radius: 10px;
  border: 1px solid var(--border);
}

.blog-post-credit {
  margin: 8px 0 14px;
  font-size: 0.78rem;
  font-style: italic;
  color: var(--text-muted);
}

.blog-post-excerpt, .blog-post-body {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

.blog-post-body { display: none; margin-top: 12px; white-space: pre-line; }
.blog-post.expanded .blog-post-excerpt { display: none; }
.blog-post.expanded .blog-post-body { display: block; }

.blog-read-more {
  margin-top: 14px;
  background: none;
  border: none;
  padding: 0;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.blog-read-more:hover { color: var(--accent-hover); }

.blog-empty {
  color: var(--text-muted);
  border: 1px dashed var(--border);
  border-radius: 14px;
  padding: 32px;
  text-align: center;
}

.comic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.comic-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-align: left;
  cursor: pointer;
  padding: 0;
  font: inherit;
  color: inherit;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.2s ease;
}

.comic-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.10);
}

.comic-cover-wrap {
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
}

.comic-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
  transition: transform 0.25s ease;
}

.comic-card:hover .comic-cover { transform: scale(1.04); }

.comic-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }

.comic-genre {
  align-self: flex-start;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
}

.comic-body h3 { margin: 4px 0 0; font-size: 1.1rem; }

.comic-excerpt { margin: 0; color: var(--text-muted); font-size: 0.9rem; }

.comic-read {
  margin-top: auto;
  padding-top: 10px;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.88rem;
}

/* Full-story reader overlay */
.comic-reader {
  position: fixed;
  inset: 0;
  background: rgba(15, 17, 21, 0.72);
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 32px 16px;
  overflow-y: auto;
  z-index: 100;
}

.comic-reader.open { display: flex; }

.comic-reader-inner {
  background: var(--bg);
  border-radius: 16px;
  max-width: 720px;
  width: 100%;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.comic-reader-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg);
}

.comic-reader-tag {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
}

.comic-reader-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px 8px;
}

.comic-reader-close:hover { color: var(--text); }

.comic-reader-body { padding: 20px 24px 32px; }

.comic-reader-body h3 { margin: 0 0 10px; font-size: 1.4rem; }

.comic-reader-desc {
  color: var(--text-muted);
  margin: 0 0 20px;
  line-height: 1.65;
}

.comic-reader-page {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 28px;
  background: var(--bg-alt);
}

.comic-reader-page img {
  width: 100%;
  height: auto;
  display: block;
  draggable: false;
}

.comic-comments {
  border-top: 1px solid var(--border);
  padding-top: 20px;
}

.comic-comments h4 { margin: 0 0 14px; font-size: 1.05rem; }

.comic-comments-note {
  color: var(--text-muted);
  font-size: 0.88rem;
  border: 1px dashed var(--border);
  border-radius: 10px;
  padding: 16px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-width: 520px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}

.form-row input,
.form-row textarea {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 0.95rem;
  color: var(--text);
  font-family: inherit;
  resize: vertical;
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.contact-form .btn {
  align-self: flex-start;
}

footer {
  text-align: center;
  padding: 32px 24px;
  color: var(--text-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
}

footer a {
  color: var(--text-muted);
  text-decoration: underline;
}

footer a:hover { color: var(--accent); }
