/* ============================================
   MillionSVG - Design System
   ============================================ */

/* CSS Variables */
:root {
  --bg: #ffffff;
  --bg-secondary: #f8fafc;
  --border: #e5e7eb;
  --text: #111827;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-light: #eff6ff;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.06);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.08);

  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;

  --header-height: 64px;
  --max-width: 1280px;
  --content-padding: 24px;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  min-height: 100vh;
}

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

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

img, svg {
  display: block;
  max-width: 100%;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input {
  font-family: inherit;
}

ul, ol {
  list-style: none;
}

/* ============================================
   Layout
   ============================================ */

.app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
.site-header {
  position: sticky;
  display:flex;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  height: var(--header-height);
}

.header-inner {
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 0 var(--content-padding);
  height: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text);
  letter-spacing: -0.02em;
}

.logo:hover {
  color: var(--text);
}

.logo-icon {
  width: 28px;
  height: 28px;
  color: var(--accent);
}

.search-box{
    position:relative;
    flex:1;
    max-width:none;
}

.search-box input {
    width:100%;
    height:40px;
    padding-left:44px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-secondary);
  font-size: 0.9375rem;
  color: var(--text);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.search-box input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
  background: var(--bg);
}

.search-icon{
    position:absolute;
    left:14px;
    top:50%;
    transform:translateY(-50%);
    color:var(--text-muted);
    display:flex;
    align-items:center;
    justify-content:center;
    width:18px;
    height:18px;
    pointer-events:none;
}

.nav-desktop {
    margin-left:auto;
    display:flex;
    align-items:center;
    gap:24px;
    flex-shrink:0;
}

.nav-desktop a {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
}

.nav-desktop a:hover,
.nav-desktop a.active {
  color: var(--text);
}



/* Main layout */
.main-wrapper {
  display: flex;
  flex: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
  padding: 0 var(--content-padding);
}



/* Page content */
.page-content {
  flex: 1;
  min-width: 0;
  padding: 32px 0 48px 32px;
}



/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-secondary);
  padding: 40px 0;
  margin-top: auto;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--content-padding);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-brand {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4 {
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1rem; }

.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }

/* ============================================
   Cards
   ============================================ */

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-media {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
  padding: 12px;
}

.card-media img {
  border-radius: 12px;
  color: var(--text);
}

.card-body {
  padding: 16px;
  border-top: 1px solid var(--border);
}

.card-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-meta {
  font-size: 0.75rem;
  color:#4b5563;
  margin-top: 4px;
}

/* Collection card */
.collection-card .card-media {
  padding: 32px;
}

.collection-card .card-media svg {
  width: 64px;
  height: 64px;
}


.svg-top {
    display: grid;
    grid-template-columns: 30% 70%;
    gap: 32px;
    align-items: start;
}
@media (max-width: 900px) {
    .svg-top {
        grid-template-columns: 1fr;
    }
}


/* SVG grid card */
.svg-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  transition: border-color 0.15s, box-shadow 0.15s;
  cursor: pointer;
  position: relative;
}

.svg-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.svg-card svg {
  width: 40px;
  height: 40px;
  color: var(--text);
}

.svg-card .svg-label {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 8px;
  font-size: 0.6875rem;
  color: var(--text-muted);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0;
  transition: opacity 0.15s;
}

.svg-card:hover .svg-label {
  opacity: 1;
}

/* ============================================
   Grids
   ============================================ */

.grid {
  display: grid;
  gap: 16px;
}

.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid-cols-5 { grid-template-columns: repeat(5, 1fr); }
.grid-cols-6 { grid-template-columns: repeat(6, 1fr); }
.grid-cols-8 { grid-template-columns: repeat(8, 1fr); }

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 0.9375rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}

.btn-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: #fff;
}

.btn-secondary {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-secondary);
  border-color: var(--text-muted);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid transparent;
}

.btn-ghost:hover {
  background: var(--bg-secondary);
  color: var(--text);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: var(--radius-lg);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.8125rem;
}

/* ============================================
   Sections
   ============================================ */

.section {
  margin-bottom: 16px;
  
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  margin-top: 20px;
  gap: 16px;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom:10px;
}

.section-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent);
  white-space: nowrap;
}

.section-link:hover {
  color: var(--accent-hover);
}

/* Hero */
.hero {
  text-align: center;
  padding: 24px 0 0;
  max-width: 960px;
  margin: 0 auto;
  margin-bottom:24px;
}

.hero h1 {
  font-size: 2.75rem;
  margin-bottom: 12px;
}

.hero p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}


/* Collection hero */
.collection-hero {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 24px;
  margin-bottom: 32px;
}

.collection-hero h1 {
  font-size: 1.75rem;
  margin-bottom: 8px;
}

.collection-hero .description {
  color: var(--text-secondary);
  margin-bottom: 20px;
  font-size: 0.9375rem;
}

.stats {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.stat {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.stat svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  margin-bottom: 24px;
  color: var(--text-muted);
}

.breadcrumbs a {
  color: var(--text-secondary);
}

.breadcrumbs a:hover {
  color: var(--text);
}

.breadcrumbs .separator {
  color: var(--text-muted);
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.pagination a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  border: 1px solid transparent;
}

.pagination a:hover {
  background: var(--bg-secondary);
  color: var(--text);
}

.pagination a.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.pagination a.disabled {
  color: var(--text-muted);
  pointer-events: none;
}






.article-content{
    max-width:800px;
    color:var(--text-secondary);
    line-height:1.8;
}

.article-content h2{
    margin:40px 0 16px;
    color:var(--text);
    font-size:1.35rem;
}

.article-content p{
    margin-bottom:18px;
}

.article-content ul{
    list-style: disc;
    padding-left: 22px;
    margin: 16px 0;
}

.article-content ol{
    list-style: decimal;
    padding-left: 22px;
    margin: 16px 0;
}

.article-content li{
    display: list-item;
    margin-bottom: 8px;
}




/* Tags */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: border-color 0.15s, color 0.15s;
}

.tag:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* FAQ */
.faq-list {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 20px;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
  text-align: left;
}

.faq-question:hover {
  background: var(--bg-secondary);
}

.faq-question svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.faq-question.open svg {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 20px 16px;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
  display: none;
}

.faq-answer.open {
  display: block;
}

/* SVG Preview */
.svg-preview {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
}

.svg-preview img{
    max-width:420px;
    width:100%;
    height:auto;
	border-radius: 12px;
}

.svg-preview svg {
  width: 160px;
  height: 160px;
  color: var(--text);
}

.svg-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.bio-content{
    max-height:420px;
    overflow:hidden;
    position:relative;
    transition:max-height .35s ease;
}

.bio-content h2{
    font-size:24px;
    font-weight:600;
    padding-left:12px;
    border-left:4px solid #2563eb;
    margin:28px 0 16px;
}

.bio-content::after{
    content:"";
    position:absolute;
    left:0;
    right:0;
    bottom:0;
    height:120px;
    background:linear-gradient(
        to bottom,
        rgba(255,255,255,0),
        rgba(255,255,255,.9) 55%,
        #fff 100%
    );
}

.bio-content.expanded{
    max-height:5000px;
}

.bio-content.expanded::after{
    display:none;
}

.read-more{
    position:absolute;
    left:50%;
    bottom:20px;
    transform:translateX(-50%);

    padding:10px 22px;
    background:#fff;
    border:1px solid #ddd;
    border-radius:30px;

    z-index:20;
}

.bio-content.no-bio{
    max-height:none;
    overflow:visible;
}

.bio-content.no-bio::after{
    display:none;
}

.bio-content.no-bio p{
    color:#444;
}

.profile-meta{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin:0 0 10px;
}

.profile-meta span{
    display:inline-flex;
    align-items:center;
    gap:6px;
    padding:6px 6px;
    font-size:13px;
    font-weight:500;
    color:#4b5563;
    background:#f3f4f6;
    border:1px solid #e5e7eb;
    border-radius:999px;
}


.info-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
}

.info-card h1 {
    font-size:40px;
    font-weight:700;
    line-height:1.15;
    letter-spacing:-0.02em;
    margin:0 0 12px;
}

.info-card h4 {
  margin-bottom: 12px;
  font-size: 0.9375rem;
}

.info-table {
  width: 100%;
  font-size: 0.875rem;
}

.info-table td {
  padding: 6px 0;
  color: var(--text-secondary);
}

.info-table td:first-child {
  width: 140px;
  color: var(--text-muted);
}

/* Copy toast */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--text);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-lg);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  z-index: 200;
  opacity: 0;
  transition: transform 0.3s, opacity 0.3s;
  pointer-events: none;
}

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

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 1024px) {
  .grid-cols-8 { grid-template-columns: repeat(6, 1fr); }	
  .grid-cols-6 { grid-template-columns: repeat(5, 1fr); }
  .grid-cols-5 { grid-template-columns: repeat(4, 1fr); }
  .grid-cols-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  :root {
    --content-padding: 16px;
  }

  .nav-desktop {
    display: none;
  }


  .search-box {
    max-width: none;
  }



  .page-content {
    padding: 24px 0 32px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }
  
  .grid-cols-8,
  .grid-cols-6,
  .grid-cols-5,
  .grid-cols-4 {
    grid-template-columns: repeat(3, 1fr);
  }

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

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .grid-cols-8,
  .grid-cols-6,
  .grid-cols-5,
  .grid-cols-4,
  .grid-cols-3,
  .grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .collection-hero {
    padding: 20px;
  }

  .collection-hero h1 {
    font-size: 1.5rem;
  }

  .svg-preview {
    padding: 24px;
  }

  .svg-preview svg {
    width: 100px;
    height: 100px;
  }

  .svg-actions {
    flex-direction: column;
  }

  .svg-actions .btn {
    width: 100%;
  }

  .stats {
    flex-direction: column;
    gap: 8px;
  }
}


.content-card{
    background:#fff;
    border:1px solid #e5e7eb;
    border-radius:16px;
    box-shadow:0 1px 2px rgba(0,0,0,.03);
    padding:40px 48px;
}

.content-card h2{
    margin-top:40px;
}

.content-card p{
    margin:16px 0;
    line-height:1.9;
}

.content-card > p:first-of-type{
    font-size:1.125rem;
    color:#374151;
}


.image-preview{
    display:flex;
    justify-content:center;
    align-items:center;

    margin:40px auto;

    background:#fff;

    border:1px solid #e5e7eb;

    border-radius:16px;

    padding:20px;
}

.image-preview img{
    display:block;

    max-width:100%;
    max-height:82vh;

    width:auto;
    height:auto;

    border-radius:12px;

    object-fit:contain;
}


.image-nav{
    display:flex;
    align-items:center;
    justify-content:space-between;

    margin:40px 0;
    padding:20px 0;

    border-top:1px solid #e5e7eb;
    border-bottom:1px solid #e5e7eb;
}

.nav-prev,
.nav-next{
    flex:1;
}

.nav-center{
    flex:0 0 auto;
}

.nav-next{
    text-align:right;
}

.image-nav .btn{
    border-radius:10px;
    padding:10px 18px;
    font-weight:500;
    transition:.2s;
}


.static-page{
    max-width:900px;
    margin:40px auto 60px;
}

.static-page-header{
    margin-bottom:30px;
}

.static-page-header h1{
    font-size:40px;
    font-weight:700;
    color:#111827;
    margin:0;
}

.static-page-content{
    font-size:17px;
    line-height:1.8;
    color:#374151;
}

.static-page-content h2{
    font-size:30px;
    margin:40px 0 15px;
    color:#111827;
}

.static-page-content h3{
    font-size:24px;
    margin:30px 0 12px;
    color:#111827;
}

.static-page-content p{
    margin-bottom:18px;
}

.static-page-content ul,
.static-page-content ol{
    margin:20px 0 20px 24px;
}

.static-page-content li{
    margin-bottom:8px;
}

.static-page-content img{
    max-width:100%;
    height:auto;
    border-radius:12px;
    margin:25px 0;
}

.static-page-content a{
    color:#2563eb;
    text-decoration:none;
}

.static-page-content a:hover{
    text-decoration:underline;
}