@import url('https://fonts.googleapis.com/css2?family=Bangers&family=M+PLUS+Rounded+1c:wght@300;400;500;700;800&display=swap');
@import 'browse.css';
@import 'badge.css';

:root {
  --bg-paper: #ffffff;
  /* Colored halftone for more vibrancy */
  --bg-screentone: url('data:image/svg+xml;utf8,<svg width="6" height="6" viewBox="0 0 6 6" xmlns="http://www.w3.org/2000/svg"><g fill="%232e8fff" fill-opacity="0.05"><circle cx="3" cy="3" r="1"/></g></svg>');
  
  --ink-black: #1a1a1a; /* Slightly softer black for better contrast/readability */
  
  /* Vibrant Palette */
  --action-red: #ff0055;     /* Hot Pink/Red */
  --action-yellow: #ffe600;  /* Cyber Yellow */
  --action-cyan: #00f7ff;    /* Electric Cyan */
  --action-purple: #bc13fe;  /* Neon Purple */
  --action-green: #00ff9d;   /* Neon Green */
  
  --speed-blue: #2e8fff;
  --panel-gray: #f8f9fa;
  
  --border-thick: 3px solid var(--ink-black);
  --border-thin: 2px solid var(--ink-black);
  
  /* Hard shadows with vibrant colors */
  --shadow-hard: 4px 4px 0px var(--ink-black);
  --shadow-hover: 2px 2px 0px var(--action-cyan);
  --shadow-card: 5px 5px 0px rgba(0,0,0,0.15);
  
  /* Updated Fonts - Improved Readability */
  --font-heading: 'M PLUS Rounded 1c', sans-serif; /* Changed from Bangers to M PLUS for readability */
  --font-display: 'Bangers', cursive; /* Kept for very large titles/logos only */
  --font-body: 'M PLUS Rounded 1c', sans-serif;
  
  --primary: var(--ink-black);
  --secondary: var(--action-yellow);
  --text-main: var(--ink-black);
  --text-muted: #666666;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  font-weight: 400; /* Regular weight for better readability */
  background-color: var(--bg-paper);
  background-image: var(--bg-screentone);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { text-decoration: none; color: inherit; transition: 0.2s; }
ul { list-style: none; }

/* Typography */
h1, h2, h3, h4, h5, h6 { 
  font-family: var(--font-heading); 
  font-weight: 800; /* Bold but readable */
  letter-spacing: 0.5px; 
  text-transform: uppercase;
  color: var(--ink-black);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }

/* Utilities */
.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 20px; 
    width: 100%;
    box-sizing: border-box;
}
.container-wide { 
    max-width: 1520px; 
    margin: 0 auto; 
    padding: 0 40px; 
    width: 100%;
    box-sizing: border-box;
}
.text-center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.p-20 { padding: 20px; }
.text-vibrant { color: var(--action-purple); }
.text-highlight { background: var(--action-yellow); color: var(--ink-black); padding: 0 5px; }

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px;
  border: var(--border-thick);
  background: white;
  box-shadow: var(--shadow-hard);
  margin: 20px 0;
}
.empty-state-icon {
  font-size: 4rem;
  margin-bottom: 20px;
  color: var(--text-muted);
}
.empty-state-title {
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-size: 2rem;
  margin-bottom: 10px;
}
.empty-state-text {
  margin-bottom: 30px;
  font-size: 1.2rem;
}

/* Image Placeholder */
.img-placeholder {
  width: 100%;
  height: 100%;
  background: var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 3rem;
}

/* Table Components */
.table-thumb {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border: var(--border-thin);
  box-shadow: 2px 2px 0 var(--ink-black);
}

.table-thumb-placeholder {
  width: 50px;
  height: 50px;
  background: var(--ink-black);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  border: var(--border-thin);
}

.listing-title-cell {
  font-weight: bold;
  font-family: var(--font-heading);
  font-size: 1.1em;
}

.listing-anime-cell {
  font-size: 0.8em;
  color: var(--text-muted);
}

/* Pagination Links */
.pagination-links {
  display: flex;
  gap: 5px;
  justify-content: center;
}

.pagination-link {
  padding: 8px 15px;
  border: 2px solid var(--ink-black);
  color: var(--ink-black);
  background: white;
  text-decoration: none;
  font-family: var(--font-heading);
  transition: 0.2s;
  box-shadow: 4px 4px 0 var(--ink-black);
}

.pagination-link:hover {
  transform: translate(-2px, -2px);
  background: var(--action-yellow);
}

.pagination-link.active {
  background: var(--ink-black);
  color: white;
  box-shadow: none;
  transform: translate(2px, 2px);
}

/* Section Title */
.section-title {
  font-family: var(--font-heading);
  text-transform: uppercase;
  transform: skew(-2deg);
  font-size: 2rem;
  margin-bottom: 20px;
}

/* Animations */
.anim-pop { animation: pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
@keyframes pop { 0% { transform: scale(0.9); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* Manga Panel Component - Enhanced */
.manga-panel, .card, .stat-card {
  background: white;
  border: var(--border-thick);
  box-shadow: var(--shadow-hard);
  transition: transform 0.2s, box-shadow 0.2s;
  padding: 20px;
  position: relative;
  overflow: hidden;
}

/* Decorative corner triangle for panels */
.manga-panel::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 20px 20px 0;
  border-color: transparent var(--action-yellow) transparent transparent;
  z-index: 1;
}

.manga-panel:hover, .card:hover, .stat-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0px var(--action-cyan);
  border-color: var(--ink-black);
}

/* Buttons - Vibrant & Readable */
.btn-primary {
  display: inline-block;
  background: var(--ink-black);
  color: white;
  padding: 12px 30px;
  border: 2px solid var(--ink-black);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: 0.2s;
  border-radius: 4px; /* Slight rounded corners for friendliness */
  text-align: center;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.2);
}

.btn-primary:hover {
  background: var(--action-red);
  color: white;
  border-color: var(--ink-black);
  box-shadow: 4px 4px 0 var(--ink-black);
  transform: translate(-2px, -2px) skew(-2deg);
}

.btn-secondary {
  background: white;
  color: var(--ink-black);
  border: 2px solid var(--ink-black);
  padding: 10px 25px;
  font-family: var(--font-heading);
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 3px 3px 0 var(--panel-gray);
  transition: 0.2s;
}

.btn-secondary:hover {
  background: var(--action-yellow);
  box-shadow: 3px 3px 0 var(--ink-black);
  transform: translate(-1px, -1px);
}

/* Forms - Clean & Readable */
.form-control {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #ddd;
  border-radius: 4px;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  background: #fdfdfd;
  transition: 0.2s;
  color: var(--ink-black);
}

.form-control:focus {
  outline: none;
  border-color: var(--ink-black);
  box-shadow: 3px 3px 0 var(--action-cyan);
  background: white;
}

.form-group { margin-bottom: 25px; }
label { font-weight: 700; display: block; margin-bottom: 8px; font-size: 0.95rem; }

/* Form Components */
.form-container {
  max-width: 800px;
  margin: 0 auto;
  padding-top: 40px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

.select-wrapper {
  position: relative;
}

.select-wrapper select {
  appearance: none;
  -webkit-appearance: none;
}

.select-wrapper .fa-chevron-down {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f9f9f9;
  padding: 15px;
  border: 2px solid var(--ink-black);
  margin-bottom: 20px;
}

.checkbox-group input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--ink-black);
  cursor: pointer;
}

.checkbox-group label {
  margin: 0;
  cursor: pointer;
}

.file-input-help {
  display: block;
  margin-top: 5px;
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.9rem;
}

.form-actions {
  display: flex;
  gap: 15px;
  margin-top: 30px;
}

.form-actions .btn-primary { flex: 1; }
.form-actions .btn-secondary { text-decoration: none; text-align: center; display: inline-flex; align-items: center; justify-content: center; }

.readonly-input {
  opacity: 0.7;
  background: #eee;
}
.auth-container {
  max-width: 450px;
  margin: 60px auto;
  padding: 40px;
  background: white;
  border: var(--border-thick);
  box-shadow: 8px 8px 0 var(--action-purple); /* Vibrant Shadow */
  position: relative;
}

/* Global Responsive Fixes */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }
  h3 { font-size: 1.3rem; }
  
  .container { padding: 0 15px; }
  
  .navbar-content {
    flex-direction: column;
    gap: 15px;
  }
  
  .brand-text {
    font-size: 2rem;
  }
  
  .nav-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
  }
  
  .nav-item {
    font-size: 1rem;
    padding: 4px 8px;
  }

  .user-menu {
    border-left: none;
    margin-left: 0;
    padding-left: 0;
    margin-top: 10px;
  }

  /* Responsive Grids */
  .listings-grid.grid-4-cols {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 15px !important;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .footer-col {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .listings-grid.grid-4-cols {
    grid-template-columns: 1fr !important;
  }
  
  .hero-title {
    font-size: 3rem !important;
  }
  
  .hero-search-form {
    flex-direction: column;
  }
  
  .hero-search-btn {
    padding: 12px;
  }
}

/* Navbar */
.navbar {
  background: white;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 4px solid var(--ink-black); /* Thicker border for manga feel */
  padding: 15px 0;
  box-shadow: 0 5px 0 rgba(0,0,0,0.1);
  background-image: var(--bg-screentone);
}

.navbar-bg-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Speed lines effect */
  background: repeating-linear-gradient(90deg, transparent 0, transparent 20px, rgba(0,0,0,0.03) 20px, rgba(0,0,0,0.03) 22px);
  pointer-events: none;
}
 
.navbar-content { display: flex; align-items: center; position: relative; z-index: 1; gap: 16px; }
.navbar .container { max-width: 1440px; padding: 0 30px; }
.navbar-content { justify-content: space-between; }
/* Centered categories row and right actions */
.nav-center-cats {
  flex: 1 1 auto;
  display: flex;
  justify-content: center;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 6px;
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 2px solid var(--ink-black);
  box-shadow: 3px 3px 0 var(--ink-black);
  padding: 4px 8px;
  text-decoration: none;
  position: relative;
}
.user-chip:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 var(--action-cyan);
}
.user-chip-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--ink-black);
  object-fit: cover;
  background: var(--action-cyan);
}
.user-chip-initial {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 2px solid var(--ink-black);
  background: var(--action-yellow);
  font-family: var(--font-heading);
  font-weight: 900;
}
.user-chip-name {
  font-family: var(--font-heading);
  font-weight: 800;
  text-transform: uppercase;
}

.user-chip-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  font-size: 11px;
  line-height: 18px;
  border-radius: 9px;
  background: var(--action-red);
  color: #fff;
  border: 2px solid var(--ink-black);
  text-align: center;
  font-family: var(--font-heading);
  font-weight: 900;
  box-shadow: 2px 2px 0 var(--ink-black);
}

.mobile-menu-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--ink-black);
  font-size: 2rem;
  cursor: pointer;
}

.brand-text { 
  font-family: var(--font-display); 
  font-size: 3rem; 
  line-height: 1;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--ink-black);
  /* Comic style shadow */
  text-shadow: 3px 3px 0 white, 5px 5px 0 var(--ink-black);
  transform: skew(-5deg);
  border-bottom: 3px solid var(--action-yellow);
  padding-bottom: 5px;
}
.brand-text .highlight { color: var(--action-red); }
.brand-logo-img { height: 80px; filter: none; }

.nav-links { display: flex; gap: 20px; align-items: center; }
.nav-item { 
  font-family: var(--font-heading);
  font-size: 1.2rem; 
  font-weight: 800; 
  color: var(--ink-black); 
  text-transform: uppercase;
  position: relative;
  text-decoration: none;
  padding: 5px 10px;
  transition: 0.2s;
  border: 2px solid transparent;
}
.nav-item:hover { 
    color: var(--action-red); 
    background: white;
    border: 2px solid var(--ink-black);
    box-shadow: 3px 3px 0 var(--ink-black);
    transform: rotate(-2deg);
}

/* CTA Button in Nav */
.nav-item.cta {
  background: var(--ink-black);
  color: white;
  padding: 8px 20px;
  border-radius: 0;
  border: 3px solid var(--ink-black);
  transform: skew(-10deg);
  box-shadow: 4px 4px 0 rgba(0,0,0,0.2);
  display: inline-block;
  text-decoration: none;
}
.nav-item.cta span { display: inline-block; transform: skew(10deg); }
.nav-item.cta:hover { 
  background: var(--action-yellow); 
  color: var(--ink-black); 
  box-shadow: 6px 6px 0 var(--ink-black);
  transform: skew(-10deg) translate(-2px, -2px);
}

.nav-item.highlight {
  background: white;
  color: var(--ink-black);
  border: 3px solid var(--ink-black);
  padding: 8px 15px;
  box-shadow: 4px 4px 0 var(--ink-black);
}
.nav-item.highlight:hover {
  background: var(--ink-black);
  color: white;
  box-shadow: 6px 6px 0 var(--action-cyan);
  transform: translate(-2px, -2px);
}

/* Inline Category Chips */
.nav-cat-chip {
  display: inline-block;
  text-decoration: none;
  color: var(--ink-black);
  border: 3px solid var(--ink-black);
  background: #fff;
  padding: 6px 10px;
  text-transform: uppercase;
  font-family: var(--font-heading);
  font-weight: 900;
  transform: skew(-8deg);
  box-shadow: 4px 4px 0 var(--ink-black);
  white-space: nowrap;
}
.nav-cat-chip .chip-text { display: inline-block; transform: skew(8deg); }
.nav-cat-chip:hover { background: var(--action-yellow); }

@media (max-width: 992px) {
  .hero-manga-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-visual-panel {
    display: none; /* Hide complex collage on smaller screens for cleaner hero */
  }

  .hero-search-form {
    margin: 0 auto 30px;
  }


@media (max-width: 768px) {
  .brand-logo-img { height: 72px; }
  .brand-text { font-size: 2.8rem; }
}

  .hero-tags {
    justify-content: center;
  }

  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  /* Hide center categories on small screens (use drawer) */
  .nav-center-cats { display: none; }
}

/* Mobile header controls */
.mobile-icon-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: #fff;
  color: var(--ink-black);
  border: 3px solid var(--ink-black);
  border-radius: 10px;
  box-shadow: 3px 3px 0 var(--ink-black);
  position: relative;
  /* Manga sticker look (no rotate to keep hitbox true) */
  background-image: radial-gradient(#e5e7eb 1px, transparent 1px);
  background-size: 6px 6px;
  /* Strictly no movement on tap */
  transition: background-color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none;
}
.mobile-icon-btn i {
  font-size: 1.15rem;
}
.mobile-icon-btn:hover { background-color: #fff7c2; }
.mobile-icon-btn:active { box-shadow: 3px 3px 0 var(--ink-black); }
/* Remove previous bubble tail if any */
.mobile-icon-btn::after { display: none !important; }

@media (max-width: 768px) {
  .mobile-icon-btn { display: flex; }
  .navbar-content { justify-content: center; position: relative; min-height: 56px; }
  .navbar .brand { 
    display: inline-block;
    flex: 0 0 auto !important; 
    margin: 0 auto !important; 
  }
  .brand-logo-img { display: block; margin: 0 auto; }
  .mobile-menu-btn {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2002;
  }
  .mobile-search-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2002;
  }
  .nav-actions { display: none; }
}

/* Drawer icon refinement */
.drawer-menu-list .drawer-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
}
.drawer-menu-list .drawer-menu-item i {
  width: 18px;
  min-width: 18px;
  text-align: center;
  font-size: 0.95rem;
  color: var(--ink-black);
  opacity: 0.9;
}
.drawer-menu-list .drawer-menu-item:hover i {
  opacity: 1;
}

@media (max-width: 768px) {
  .navbar-content {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 10px 15px !important;
    flex-wrap: nowrap !important;
  }

  .brand {
    margin-bottom: 0 !important;
    flex: 1;
  }

 .mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ink-black);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 3px 3px 0 var(--pop-cyan);
    transition: all 0.2s ease;
    margin-left: 15px;
    flex-shrink: 0;
  }

  .mobile-menu-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 1px 1px 0 var(--pop-cyan);
  }

  .brand-logo-img { max-height: 44px; }

  .brand-text {
    font-size: 1.2rem;
  }
}

/* New User Profile Header Styles */
.nav-user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 5px 15px 5px 5px;
  border: 3px solid var(--ink-black);
  border-radius: 50px;
  background: white;
  box-shadow: 4px 4px 0 var(--ink-black);
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-decoration: none;
  color: var(--ink-black);
  margin-left: 10px;
}

.nav-user-profile:hover {
  transform: translate(-3px, -3px) rotate(2deg);
  box-shadow: 7px 7px 0 var(--action-purple);
  background: var(--panel-gray);
}

.nav-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--ink-black);
}

.nav-user-avatar-placeholder {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--action-yellow);
  border: 2px solid var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--ink-black);
}

.nav-user-info {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.nav-user-name {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1rem;
  text-transform: uppercase;
}

.nav-user-role {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
}

.nav-logout-btn {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--action-red);
    color: white;
    border: 2px solid var(--ink-black);
    border-radius: 50%;
    margin-left: 5px;
    transition: 0.2s;
    box-shadow: 2px 2px 0 var(--ink-black);
}

.nav-logout-btn:hover {
    transform: scale(1.1);
    background: var(--ink-black);
    box-shadow: 3px 3px 0 var(--ink-black);
}

.user-menu {
  display: flex;
  align-items: center;
  margin-left: 10px;
  padding-left: 15px;
  border-left: 2px solid #eee;
}

/* Mobile Menu */
.mobile-menu-overlay {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.8);
  z-index: 2000;
  display: none;
  opacity: 0;
  transition: opacity 0.3s;
}
.mobile-menu-overlay.active {
  display: flex;
  opacity: 1;
}
.mobile-menu-content {
  background: white;
  width: 80%;
  max-width: 320px;
  height: 100%;
  padding: 40px;
  transform: translateX(-100%) skew(-5deg);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-right: 5px solid var(--action-red);
  box-shadow: 10px 0 30px rgba(0,0,0,0.5);
  overflow-y: auto;
}
.mobile-menu-overlay.active .mobile-menu-content {
  transform: translateX(0) skew(0);
}
.mobile-menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 2rem;
  color: var(--ink-black);
  cursor: pointer;
  background: none;
  border: none;
}
.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 40px;
}
.mobile-nav-item {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--ink-black);
  text-transform: uppercase;
  text-decoration: none;
  padding-bottom: 10px;
  border-bottom: 2px solid #eee;
}
.mobile-nav-item:hover {
  color: var(--action-red);
  padding-left: 10px;
  border-color: var(--action-red);
}

/* Footer */
.footer {
  background: var(--ink-black);
  color: white;
  border-top: 5px solid var(--action-red);
  padding: 60px 0 20px;
  position: relative;
  overflow: hidden;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
  position: relative;
  z-index: 1;
}
.footer-col h3, .footer-col h4 {
  margin-bottom: 20px;
  color: white;
  text-transform: uppercase;
}
.footer-col h4 {
  font-size: 1.5rem;
  color: var(--action-red);
  background: black;
  display: inline-block;
  padding: 0 5px;
  transform: skew(-5deg);
  border: 1px solid var(--action-red);
}
.footer-link {
  color: white;
  text-decoration: none;
  font-size: 1.1rem;
  transition: 0.2s;
  display: block;
  margin-bottom: 10px;
}
.footer-link:hover {
  padding-left: 5px;
  color: var(--action-red);
}
.footer-social-link {
  width: 40px;
  height: 40px;
  background: white;
  color: var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  border: 2px solid white;
  transition: 0.2s;
  box-shadow: 3px 3px 0 #000;
  text-decoration: none;
}
.footer-social-link:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 var(--action-cyan);
}

/* Main Content */
.main-content {
  min-height: 80vh;
  padding-bottom: 60px;
}

/* Utility Classes */
.rotate-neg-1 { transform: rotate(-1deg); }
.rotate-neg-2 { transform: rotate(-2deg); }
.skew-neg-5 { transform: skew(-5deg); }
.text-stroke-2 { -webkit-text-stroke: 2px var(--ink-black); }
.text-stroke-1 { -webkit-text-stroke: 1px var(--ink-black); }
.mx-auto { margin-left: auto; margin-right: auto; }
.max-w-600 { max-width: 600px; }
.pt-100 { padding-top: 100px; }
.pb-100 { padding-bottom: 100px; }
.p-40 { padding: 40px; }
.px-20 { padding-left: 20px; padding-right: 20px; }
.text-6xl { font-size: 6rem; }
.border-bottom-thick { border-bottom: var(--border-thick); }
.inline-block { display: inline-block; }

/* Color Utilities */
.bg-action-cyan { background: var(--action-cyan); }
.bg-action-yellow { background: var(--action-yellow); }
.bg-action-green { background: var(--action-green); }
.bg-action-purple { background: var(--action-purple); }
.text-action-cyan { color: var(--action-cyan); }
.text-action-yellow { color: var(--action-yellow); }
.text-action-green { color: var(--action-green); }
.text-action-purple { color: var(--action-purple); }
.text-ink-black { color: var(--ink-black); }
.text-white { color: white; }

/* Hero Section - Manga Style */
.hero-manga-section {
  position: relative;
  background: white;
  padding: 60px 0 80px;
  overflow: hidden;
  border-bottom: var(--border-thick);
}

.hero-bg-pattern {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-image: 
    radial-gradient(circle, var(--action-cyan) 1px, transparent 1px),
    linear-gradient(45deg, rgba(255,230,0,0.1) 25%, transparent 25%, transparent 75%, rgba(255,230,0,0.1) 75%, rgba(255,230,0,0.1));
  background-size: 20px 20px, 40px 40px;
  opacity: 0.6;
}

.hero-manga-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  position: relative;
  z-index: 2;
  align-items: center;
}

.hero-text-panel {
  position: relative;
}

.hero-badge {
  display: inline-block;
  background: var(--ink-black);
  color: var(--action-yellow);
  font-family: var(--font-heading);
  font-weight: 800;
  padding: 5px 15px;
  transform: skew(-10deg);
  margin-bottom: 15px;
  border: 2px solid var(--action-yellow);
  box-shadow: 4px 4px 0 rgba(0,0,0,0.2);
}

.hero-title {
  font-family: var(--font-display);
  font-size: 5rem;
  line-height: 0.9;
  margin-bottom: 20px;
  color: var(--ink-black);
}

.text-outline {
  -webkit-text-stroke: 3px var(--ink-black);
  color: white;
  text-shadow: 5px 5px 0 var(--ink-black);
}

.text-highlight {
  color: var(--action-red);
  text-shadow: 4px 4px 0 var(--ink-black);
  background: var(--action-yellow);
  display: inline-block;
  padding: 0 10px;
  transform: skew(-5deg) rotate(-2deg);
  border: 3px solid var(--ink-black);
}

.hero-subtitle {
  font-size: 1.3rem;
  font-weight: 600;
  max-width: 90%;
  margin-bottom: 30px;
  background: white;
  padding: 10px;
  border: 2px solid var(--ink-black);
  box-shadow: 4px 4px 0 var(--ink-black);
}

/* Hero Search */
.hero-search-form {
  display: flex;
  gap: 10px;
  max-width: 500px;
  margin-bottom: 30px;
}

.search-input-wrapper {
  flex: 1;
  position: relative;
}

.search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.hero-search-input {
  width: 100%;
  padding: 15px 15px 15px 45px;
  font-size: 1.1rem;
  border: 3px solid var(--ink-black);
  font-family: var(--font-heading);
  transition: 0.2s;
}

.hero-search-input:focus {
  outline: none;
  box-shadow: 5px 5px 0 var(--action-cyan);
  transform: translate(-2px, -2px);
}

.hero-search-btn {
  background: var(--ink-black);
  color: white;
  border: 3px solid var(--ink-black);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.2rem;
  padding: 0 25px;
  cursor: pointer;
  transition: 0.2s;
}

.hero-search-btn:hover {
  background: var(--action-red);
  box-shadow: 4px 4px 0 var(--ink-black);
  transform: translate(-2px, -2px);
}

.hero-tags {
  font-family: var(--font-heading);
  font-weight: 700;
  display: flex;
  gap: 10px;
  align-items: center;
}

.hero-tags a {
  color: var(--action-blue);
  text-decoration: underline;
}

.hero-tags a:hover {
  color: var(--action-red);
  background: var(--action-yellow);
}

/* Grid System Updates */
.listings-grid.grid-4-cols {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1200px) {
  .listings-grid.grid-4-cols {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .listings-grid.grid-4-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .listings-grid.grid-4-cols {
    grid-template-columns: 1fr;
  }
}

/* Pagination Styles */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: white;
    border: 2px solid var(--ink-black);
    color: var(--ink-black);
    font-weight: 700;
    text-decoration: none;
    box-shadow: 2px 2px 0 var(--ink-black);
    transition: 0.2s;
}

.page-link:hover {
    transform: translate(-2px, -2px);
    box-shadow: 4px 4px 0 var(--action-cyan);
    background: var(--action-yellow);
}

.page-link.active {
    background: var(--action-red);
    color: white;
    box-shadow: inset 2px 2px 0 rgba(0,0,0,0.2);
    transform: translate(2px, 2px);
}

/* Browse Page Sidebar */
.browse-container {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 30px;
    padding: 30px 0;
}

@media (max-width: 900px) {
    .browse-container {
        grid-template-columns: 1fr;
    }
    
    .filter-sidebar {
        margin-bottom: 30px;
    }
}

.filter-sidebar {
    background: white;
    border: 3px solid var(--ink-black);
    padding: 20px;
    box-shadow: 8px 8px 0 var(--ink-black);
    align-self: start;
}

.filter-group {
    margin-bottom: 25px;
    border-bottom: 2px dashed #eee;
    padding-bottom: 20px;
}

.filter-group:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.filter-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    cursor: pointer;
}

.filter-checkbox input {
    width: 18px;
    height: 18px;
    border: 2px solid var(--ink-black);
    accent-color: var(--action-red);
}

/* Visual Panel */
.hero-visual-panel {
  position: relative;
  height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Collage Hero */
.hero-collage {
  position: relative;
  width: 100%;
  height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.collage-panel {
  position: absolute;
  background: white;
  border: 4px solid var(--ink-black);
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 6px 6px 0 var(--ink-black);
  transition: 0.3s;
  z-index: 5;
  width: 140px;
  height: 140px;
}

.collage-panel:hover {
  transform: scale(1.1) rotate(0deg) !important;
  z-index: 20;
  box-shadow: 10px 10px 0 var(--action-red);
}

.panel-icon {
  font-size: 3rem;
  margin-bottom: 10px;
  color: var(--ink-black);
}

.panel-text {
  font-family: var(--font-heading);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 1rem;
}

/* Specific Panel Styling */
.panel-figures {
  top: 20px;
  left: 20px;
  transform: rotate(-5deg);
  background: var(--action-yellow);
}

.panel-manga {
  top: 100px;
  right: 20px;
  transform: rotate(10deg);
  background: var(--action-cyan);
}

.panel-cosplay {
  bottom: 20px;
  left: 80px;
  transform: rotate(-3deg);
  background: var(--action-purple);
  color: white;
}
.panel-cosplay .panel-icon { color: white; }

/* Floating Kanji */
.floating-kanji {
  position: absolute;
  font-family: var(--font-display); /* Or a JP font if available */
  font-weight: 900;
  font-size: 4rem;
  color: var(--ink-black);
  text-shadow: 3px 3px 0 white;
  pointer-events: none;
  z-index: 2;
}

.k-1 { top: 0; right: 80px; transform: rotate(15deg); color: var(--action-red); }
.k-2 { bottom: 40px; right: 0; transform: rotate(-15deg); color: var(--ink-black); -webkit-text-stroke: 1px white; }

/* Central Badge */
.hero-circle-badge {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) rotate(-10deg);
  width: 120px; height: 120px;
  background: var(--action-red);
  color: white;
  border-radius: 50%;
  border: 4px solid var(--ink-black);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 5px 5px 0 rgba(0,0,0,0.2);
  z-index: 10;
  animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
  0% { transform: translate(-50%, -50%) rotate(-10deg) scale(1); }
  50% { transform: translate(-50%, -50%) rotate(-10deg) scale(1.1); }
  100% { transform: translate(-50%, -50%) rotate(-10deg) scale(1); }
}

.hero-circle-badge span {
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 2rem;
  line-height: 1;
}

.hero-circle-badge small {
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 1px;
}

/* Responsive Collage */
@media (max-width: 768px) {
    .collage-panel {
        width: 100px; height: 100px;
        padding: 10px;
    }
    .panel-icon { font-size: 2rem; }
    .panel-text { font-size: 0.8rem; }
    
    .panel-figures { left: 0; top: 20px; }
    .panel-manga { right: 0; top: 60px; }
    .panel-cosplay { bottom: 20px; left: 30%; }
    
    .hero-circle-badge {
        width: 90px; height: 90px;
    }
    .hero-circle-badge span { font-size: 1.5rem; }
}

/* Decorative Shapes */
.hero-shape-circle {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 450px; height: 450px;
  background: var(--action-yellow);
  border-radius: 50%;
  border: 4px solid var(--ink-black);
  z-index: 1;
}

.hero-shape-dots {
  position: absolute;
  bottom: -20px; left: -20px;
  width: 100px; height: 100px;
  background-image: radial-gradient(var(--ink-black) 20%, transparent 20%);
  background-size: 10px 10px;
  z-index: 0;
}

/* SFX Text */
.hero-sfx {
  position: absolute;
  font-family: 'M PLUS Rounded 1c', sans-serif; /* Fallback if font fails */
  font-weight: 900;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink-black);
  z-index: 1;
  pointer-events: none;
  opacity: 0.15;
}

.sfx-1 {
  font-size: 12rem;
  right: -50px;
  top: 20px;
  transform: rotate(20deg);
}

.sfx-2 {
  font-size: 8rem;
  left: -20px;
  bottom: 20px;
  transform: rotate(-10deg);
}

/* Responsive */
@media (max-width: 768px) {
  .hero-manga-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-title { font-size: 3rem; }
  
  .hero-search-form {
    margin: 0 auto 30px;
  }
  
  .hero-tags {
    justify-content: center;
  }
  
  .hero-visual-panel {
    height: 300px;
    margin-top: 20px;
  }
  
  .hero-shape-circle {
    width: 280px; height: 280px;
  }
  
  .hero-image-frame {
    width: 240px; height: 240px;
  }
}
.hero-section {
  position: relative;
  background-color: var(--ink-black);
  /* Anime Figurine Background Image */
  background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.8)), url('https://images.unsplash.com/photo-1607604276583-eef5d076aa5f?q=80&w=1974&auto=format&fit=crop');
  background-size: cover;
  background-position: center;
  color: white;
  padding: 100px 0;
  overflow: hidden;
  border-bottom: 5px solid var(--action-red);
}


.featured-card.rotate-left { transform: rotate(-1deg); }
.featured-card.rotate-right { transform: rotate(1deg); }
.featured-card.rotate-left:hover { transform: rotate(-1deg) translate(-4px, -4px); }
.featured-card.rotate-right:hover { transform: rotate(1deg) translate(-4px, -4px); }

.featured-img-container {
  width: 40%;
  position: relative;
  border-right: 4px solid var(--ink-black);
  overflow: hidden;
}

.featured-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.featured-card:hover .featured-img-container img {
  transform: scale(1.1);
}

.featured-badge {
  position: absolute;
  top: 10px;
  left: -30px;
  background: var(--action-red);
  color: white;
  font-family: var(--font-heading);
  padding: 5px 30px;
  transform: rotate(-45deg);
  font-size: 0.9rem;
  border: 2px solid white;
  box-shadow: 2px 2px 0 rgba(0,0,0,0.5);
}

.featured-info {
  width: 60%;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: radial-gradient(circle at center, transparent 0%, transparent 20%, #fafafa 21%, #fafafa 100%);
  background-size: 10px 10px;
}

.featured-info h3 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 5px;
  line-height: 1.1;
  text-transform: uppercase;
}

.featured-anime {
  font-family: var(--font-body);
  font-weight: bold;
  color: var(--action-purple);
  margin-bottom: 15px;
  font-size: 1rem;
}

.featured-price {
  font-size: 2rem;
  font-weight: 900;
  color: var(--ink-black);
  background: var(--action-yellow);
  display: inline-block;
  padding: 5px 15px;
  transform: skew(-5deg);
  border: 3px solid var(--ink-black);
  align-self: flex-start;
}

/* Mobile Adjustments for Featured */
@media (max-width: 600px) {
  .featured-card {
    flex-direction: column;
  }
  .featured-img-container {
    width: 100%;
    height: 200px;
    border-right: none;
    border-bottom: 4px solid var(--ink-black);
  }
  .featured-info {
    width: 100%;
  }
  .section-title {
    font-size: 1.8rem;
  }
}

.hero-bg-lines {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-conic-gradient(from 0deg, transparent 0deg 10deg, rgba(255,255,255,0.05) 10deg 20deg);
  pointer-events: none;
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
}
.hero-title {
  font-family: var(--font-heading);
  font-size: 5rem;
  text-transform: uppercase;
  transform: skew(-3deg);
  /* High Visibility Text Styles */
  color: #fff;
  text-shadow: 
    4px 4px 0 #000,
    -1px -1px 0 #000,  
    1px -1px 0 #000,
    -1px 1px 0 #000,
    1px 1px 0 #000;
  margin-bottom: 20px;
  letter-spacing: 2px;
}
.hero-subtitle {
  font-size: 1.6rem;
  margin-bottom: 40px;
  font-family: var(--font-body);
  background: var(--action-yellow);
  color: var(--ink-black);
  display: inline-block;
  padding: 10px 25px;
  transform: skew(-3deg);
  border: 3px solid var(--ink-black);
  box-shadow: 6px 6px 0 rgba(0,0,0,0.5);
  font-weight: 900;
  text-transform: uppercase;
}
.search-bar-container {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
}
.search-input {
  flex: 1;
  padding: 15px;
  border: 3px solid white;
  background: transparent;
  color: white;
  font-family: var(--font-body);
  font-size: 1.1rem;
  border-radius: 0;
}
.search-input::placeholder { color: rgba(255,255,255,0.7); }
.search-btn {
  background: var(--action-yellow);
  color: var(--ink-black);
  border: 3px solid white;
  padding: 0 25px;
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-size: 1.2rem;
  cursor: pointer;
  transition: transform 0.2s;
}
.search-btn:hover { transform: scale(1.05); background: white; }

/* Filters Bar */
.filters-bar {
  margin-bottom: 30px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.filter-chip {
  padding: 8px 20px;
  border: 2px solid var(--ink-black);
  text-decoration: none;
  color: var(--ink-black);
  font-family: var(--font-heading);
  text-transform: uppercase;
  background: white;
  transition: 0.2s;
  box-shadow: 3px 3px 0 var(--ink-black);
}
.filter-chip.active, .filter-chip:hover {
  background: var(--ink-black);
  color: white;
  transform: translate(2px, 2px);
  box-shadow: none;
}

/* Listings Grid */
.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
}
.listing-card {
  display: block;
  background: white;
  border: var(--border-thick);
  box-shadow: var(--shadow-hard);
  transition: transform 0.2s;
  text-decoration: none;
  color: inherit;
  position: relative;
}
.listing-card:hover {
  transform: translate(-3px, -3px);
  box-shadow: 6px 6px 0 var(--action-cyan);
}
.card-img-container {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-bottom: var(--border-thick);
}
.card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.listing-card:hover .card-img { transform: scale(1.05); }
.card-category {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--action-yellow);
  color: black;
  padding: 5px 10px;
  font-family: var(--font-heading);
  font-weight: bold;
  border: 2px solid black;
  box-shadow: 2px 2px 0 black;
  text-transform: uppercase;
  font-size: 0.8rem;
}
.card-body { padding: 15px; }
.card-title {
  margin: 0 0 10px 0;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  line-height: 1.2;
  height: 2.4em;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.card-anime {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.card-location {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.card-location i {
  color: var(--action-red);
}
.card-price {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: bold;
  font-family: var(--font-heading);
  font-size: 1.3rem;
  color: var(--ink-black);
}

/* Admin Layout */
.admin-layout {
  display: flex;
  min-height: 100vh;
}
.admin-sidebar {
  width: 260px;
  background: var(--ink-black);
  color: white;
  display: flex;
  flex-direction: column;
  padding: 20px;
  border-right: 5px solid var(--action-red);
  flex-shrink: 0;
}
.admin-nav {
  display: flex;
  flex-direction: column;
  gap: 15px;
}
.admin-nav-item {
  padding: 12px 15px;
  color: white;
  background: transparent;
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  text-transform: uppercase;
  border: 2px solid transparent;
  transition: 0.2s;
  display: flex;
  align-items: center;
  gap: 10px;
}
.admin-nav-item.active {
  color: var(--ink-black);
  background: white;
  border-color: white;
  box-shadow: 4px 4px 0 var(--action-red);
  transform: translate(-2px, -2px);
}
.admin-nav-item:not(.active):hover {
  border-color: white;
  transform: translate(2px, 0);
}
.admin-nav-item.logout-btn {
  color: white;
  background: var(--action-red);
  justify-content: center;
  border: 2px solid var(--action-red);
}
.admin-nav-item.logout-btn:hover {
  background: white;
  color: var(--action-red);
  box-shadow: 3px 3px 0 var(--ink-black);
}
.admin-content {
  flex: 1;
  background: #f4f4f4;
  padding: 40px;
  overflow-y: auto;
  background-image: radial-gradient(#000 1px, transparent 1px);
  background-size: 20px 20px;
  background-color: #f8f8f8;
}

/* Alerts */
.alert {
  padding: 15px;
  margin-bottom: 20px;
  border: 2px solid var(--ink-black);
  font-weight: 700;
  box-shadow: 4px 4px 0 rgba(0,0,0,0.1);
}
.alert-success { background: var(--action-green); color: var(--ink-black); }
.alert-error { background: var(--action-red); color: white; }
.alert-info { background: var(--action-cyan); color: var(--ink-black); }

/* Table Styles */
.table-responsive {
  overflow-x: auto;
  margin-bottom: 20px;
}

table, .data-table { 
  width: 100%; 
  border-collapse: collapse; 
  background: white; 
  border: var(--border-thin);
}

th { 
  text-align: left; 
  padding: 15px; 
  background: var(--ink-black); 
  color: white; 
  font-family: var(--font-heading); 
  text-transform: uppercase; 
  border-bottom: var(--border-thick);
  letter-spacing: 1px;
}

td { 
  padding: 15px; 
  border-bottom: 1px solid #ddd; 
  font-family: var(--font-body);
  vertical-align: middle;
}

tr:last-child td { border-bottom: none; }

tr:hover td { 
  background: #fff9c4; /* Light yellow hover */
  color: var(--ink-black);
}

.status-badge {
  display: inline-block;
  padding: 5px 10px;
  border-radius: 4px;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  text-transform: uppercase;
  border: 2px solid var(--ink-black);
  font-weight: bold;
}

.status-active { background: var(--action-green); color: var(--ink-black); box-shadow: 2px 2px 0 rgba(0,0,0,0.1); }
.status-sold { background: var(--action-red); color: white; box-shadow: 2px 2px 0 rgba(0,0,0,0.1); }

.action-btn-group {
  display: flex;
  gap: 10px;
}

.btn-icon {
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--ink-black);
  color: var(--ink-black);
  text-decoration: none;
  transition: 0.2s;
  background: white;
}

.btn-icon:hover {
  background: var(--ink-black);
  color: white;
  transform: translate(-2px, -2px);
  box-shadow: 2px 2px 0 var(--action-cyan);
}

/* Flexbox Utilities */
.d-flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-5 { gap: 5px; }
.gap-10 { gap: 10px; }
.gap-15 { gap: 15px; }
.gap-20 { gap: 20px; }
.gap-30 { gap: 30px; }

/* Sizing & Spacing */
.w-100 { width: 100%; }
.h-100 { height: 100%; }
.m-auto { margin: 0 auto; }
.mb-5 { margin-bottom: 5px; }
.mb-10 { margin-bottom: 10px; }
.mb-15 { margin-bottom: 15px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }
.mt-5 { margin-top: 5px; }
.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.p-10 { padding: 10px; }
.p-30 { padding: 30px; }
.pb-5 { padding-bottom: 5px; }
.pb-10 { padding-bottom: 10px; }

.col-span-2 { grid-column: span 2; }
.text-sm { font-size: 0.9rem; }
.text-base { font-size: 1rem; }
.text-xl { font-size: 1.5rem; }
.text-2xl { font-size: 2rem; }
.text-3xl { font-size: 3rem; }

/* Text Utilities */
.text-lg { font-size: 1.2rem; }
.text-xl { font-size: 1.5rem; }
.text-2xl { font-size: 2rem; }
.text-3xl { font-size: 3rem; }
.text-center { text-align: center; }
.uppercase { text-transform: uppercase; }
.font-heading { font-family: var(--font-heading); }
.font-bold { font-weight: bold; }
.text-red { color: var(--action-red); }
.text-white { color: white; }
.text-shadow { text-shadow: 3px 3px 0 rgba(0,0,0,0.1); }
.lh-1-6 { line-height: 1.6; }

/* Visual Utilities */
.relative { position: relative; }
.absolute { position: absolute; }
.z-1 { z-index: 1; }
.border-none { border: none; }
.rounded-circle { border-radius: 50%; }
.object-cover { object-fit: cover; }
.skew-neg-2 { transform: skew(-2deg); }
.border-bottom-thin { border-bottom: var(--border-thin); }
.status-badge {
  padding: 4px 8px;
  border: 2px solid var(--ink-black);
  font-weight: bold;
  font-size: 0.8em;
  color: white;
  text-transform: uppercase;
  box-shadow: 2px 2px 0 rgba(0,0,0,0.2);
}
.status-active { background: var(--action-green); }
.status-sold { background: var(--action-yellow); color: var(--ink-black); }
.status-inactive { background: var(--action-red); }

.bg-white { background: white; }
.bg-black { background: var(--ink-black); }
.bg-cyan { background: var(--action-cyan); }
.bg-yellow { background: var(--action-yellow); }
.bg-red { background: var(--action-red); }
.bg-green { background: var(--action-green); }
.bg-purple { background: var(--action-purple); }

.text-cyan { color: var(--action-cyan); }
.text-yellow { color: var(--action-yellow); }
.text-green { color: var(--action-green); }
.text-purple { color: var(--action-purple); }
.text-muted { color: var(--text-muted); }

/* Dashboard Specific */
.profile-image {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
  border: var(--border-thick);
  box-shadow: 3px 3px 0 var(--ink-black);
}

.profile-placeholder {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--ink-black);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5em;
  font-weight: bold;
  margin: 0 auto 15px auto;
  border: var(--border-thick);
  box-shadow: 3px 3px 0 rgba(0,0,0,0.2);
}

.message-item {
  border: var(--border-thick);
  padding: 20px;
  background: #f9f9f9;
  box-shadow: 4px 4px 0 var(--ink-black);
  position: relative;
}

.message-tail {
  position: absolute;
  top: -10px;
  left: 20px;
  width: 20px;
  height: 20px;
  background: #f9f9f9;
  border-left: var(--border-thick);
  border-top: var(--border-thick);
  transform: rotate(45deg);
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

@media (max-width: 900px) {
  .dashboard-grid { grid-template-columns: 1fr !important; }
  .dashboard-grid > div { grid-column: span 1 !important; }
}

.btn-icon.edit:hover { background: var(--action-yellow); }
.btn-icon.delete:hover { background: var(--action-red); color: white; }

/* New Utilities for Listing View */
.p-10 { padding: 10px; }
.mb-15 { margin-bottom: 15px; }
.w-100 { width: 100%; }

.gallery-placeholder {
  background: var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  height: 100%;
  min-height: 300px;
}
.gallery-placeholder-icon { font-size: 4rem; }
.text-highlight-icon { color: var(--action-yellow); }

.action-stack {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 40px;
}

.login-prompt-text { margin: 0; font-size: 1.1rem; }
.login-link { color: var(--action-red); font-weight: bold; text-decoration: underline; }

/* Admin Header */
.admin-header {
  margin-bottom: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: var(--border-thin);
  padding-bottom: 15px;
}

/* Hero Content */
.hero-content { position: relative; z-index: 1; text-align: center; }
.arrow-diagonal { transform: rotate(-45deg); }
.btn-load-more { display: inline-block; width: auto; padding: 15px 40px; }

/* Settings Page */
.settings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
}
.settings-title {
  font-family: var(--font-heading);
  text-transform: uppercase;
  transform: skew(-2deg);
  font-size: 2rem;
}
.settings-panel {
  max-width: 800px;
  background: white;
  padding: 30px;
  border: var(--border-thick);
  box-shadow: var(--shadow-hard);
}
.settings-section-title {
  margin-top: 40px;
  margin-bottom: 20px;
  border-bottom: var(--border-thick);
  padding-bottom: 10px;
  font-size: 1.5rem;
}
.settings-section-title.first { margin-top: 0; margin-bottom: 20px; }

.settings-row { margin-bottom: 20px; }

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 20px;
  padding: 15px;
  border: var(--border-thin);
  background: #f9f9f9;
}
.checkbox-input { width: 20px; height: 20px; cursor: pointer; accent-color: var(--ink-black); }
.checkbox-label { margin: 0; cursor: pointer; }

.file-input-pad { padding: 10px; }


/* Table Specifics */
.cell-id {
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--ink-black);
}

.cell-price {
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--ink-black); /* Changed to black for consistency, or could be red */
  font-size: 1.1rem;
}

.action-btn-group form {
  margin: 0;
}

/* User Table Cell */
.user-cell-wrapper {
  display: flex;
  align-items: center;
  gap: 15px;
}

.user-avatar-small {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: var(--border-thin);
  box-shadow: 2px 2px 0 var(--ink-black);
}

.user-avatar-placeholder {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--ink-black);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  border: var(--border-thin);
  box-shadow: 2px 2px 0 var(--text-muted);
}

.user-name {
  font-weight: bold;
  font-family: var(--font-heading);
}

.user-email {
  font-size: 0.8em;
  color: var(--text-muted);
}

/* Pagination Container */
.pagination-container {
  margin-top: 20px;
  display: flex;
  justify-content: center;
}

/* Admin Dashboard */
.admin-dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 20px;
}

.icon-box {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  border: var(--border-thin);
  box-shadow: 3px 3px 0 rgba(0,0,0,0.2);
}

.stat-label {
  font-family: var(--font-heading);
  text-transform: uppercase;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 2rem;
  line-height: 1;
}

/* Charts Section */
.charts-section {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
}

.chart-header, .panel-header {
  margin-bottom: 20px;
  border-bottom: var(--border-thin);
  padding-bottom: 10px;
}

.quick-actions-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.btn-action {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px;
  background: white;
  border: var(--border-thin);
  color: var(--ink-black);
  text-decoration: none;
  font-family: var(--font-heading);
  text-transform: uppercase;
  transition: 0.2s;
}

.btn-action:hover {
  background: var(--ink-black);
  color: white;
  box-shadow: 4px 4px 0 rgba(0,0,0,0.2);
  transform: translate(-2px, -2px);
}

/* Product View */
.product-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
}

.product-gallery {
  position: relative;
}

.gallery-main-image {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  cursor: zoom-in;
  border: 2px solid var(--ink-black);
}

.gallery-thumbs {
  display: flex;
  gap: 10px;
  margin-top: 10px;
  overflow-x: auto;
  padding-bottom: 5px;
}

.gallery-thumb {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border: 2px solid var(--ink-black);
  cursor: pointer;
  transition: 0.2s;
}

.gallery-thumb.active {
  border-color: var(--action-red);
  transform: scale(0.95);
}

.product-category-badge {
  display: inline-block;
  font-weight: bold;
  font-family: var(--font-heading);
  border: 2px solid var(--ink-black);
  box-shadow: 3px 3px 0 var(--ink-black);
  margin-bottom: 15px;
  text-transform: uppercase;
  font-size: 0.9rem;
  padding: 5px 10px;
  background: var(--action-yellow);
  color: var(--ink-black);
}

.product-title {
  margin-bottom: 10px;
  text-transform: uppercase;
  transform: skew(-1deg);
  text-shadow: 2px 2px 0 white;
  font-family: var(--font-heading);
}

.product-anime {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 20px;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 10px;
}

.product-price {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--ink-black);
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: var(--border-thin);
}

.product-location {
  font-size: 1.1rem;
  color: var(--ink-black);
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  margin-top: -15px; /* Pull it closer to price */
}
.product-location i {
  color: var(--action-red);
}

.seller-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  margin-bottom: 30px;
}

.seller-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--ink-black);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.5rem;
  background: var(--ink-black);
  color: white;
}

.seller-details h4 { margin: 0; font-size: 1.2rem; }
.seller-details p { margin: 0; font-size: 0.9rem; color: var(--text-muted); }

.contact-btn {
  display: block;
  text-align: center;
  text-decoration: none;
  margin-bottom: 15px;
  padding: 12px;
  border-radius: 4px;
  font-family: var(--font-heading);
  font-weight: bold;
  border: 2px solid var(--ink-black);
  transition: 0.2s;
  cursor: pointer;
  text-transform: uppercase;
}

.contact-btn.whatsapp {
  background: #25D366;
  color: white;
  border-color: #128C7E;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
}

.contact-btn.whatsapp:hover {
  background: #128C7E;
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 rgba(0,0,0,0.2);
}

.contact-btn.reveal {
  background: white;
  color: var(--ink-black);
  box-shadow: 3px 3px 0 var(--panel-gray);
}

.contact-btn.reveal:hover {
  background: var(--action-yellow);
  box-shadow: 3px 3px 0 var(--ink-black);
}

.contact-btn.hidden {
  background: #e0e0e0;
  color: var(--text-muted);
  border-color: #ccc;
  cursor: not-allowed;
  box-shadow: none;
}

.message-panel {
  margin-bottom: 30px;
  background: #f9f9f9;
}

.login-prompt {
  margin-bottom: 30px;
  padding: 20px;
  border: 2px dashed var(--ink-black);
  text-align: center;
  background: #f9f9f9;
}

.description-panel {
  color: var(--ink-black);
  line-height: 1.8;
  font-size: 1.1rem;
}

.description-title {
  margin-top: 0;
  margin-bottom: 20px;
  border-bottom: 2px solid #eee;
  padding-bottom: 10px;
}
@media (max-width: 900px) {
  /* Layout */
  .nav-links { display: none; }
  .mobile-menu-btn { display: block; }
  
  /* Admin Layout - Improved for Mobile */
  .admin-layout { flex-direction: column; }
  .admin-sidebar { 
    width: 100%; 
    height: auto; 
    border-right: none; 
    border-bottom: 5px solid var(--action-red); 
    padding: 10px;
  }
  
  .admin-nav {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 5px;
    gap: 10px;
  }
  
  .admin-nav-item {
    white-space: nowrap;
    font-size: 0.9rem;
    padding: 8px 12px;
    flex-shrink: 0;
  }
  
  .admin-content {
    padding: 20px;
  }

  .charts-section { grid-template-columns: 1fr; }
  
  /* Components */
  .listings-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: 3rem; }
  
  /* Dashboard */
  .dashboard-grid { grid-template-columns: 1fr !important; }
  .col-span-2 { grid-column: span 1 !important; }
}

/* Chat Conversation */
.chat-container {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-height: 600px;
  overflow-y: auto;
  padding: 20px;
  background: #f5f5f5;
  border: var(--border-thin);
  margin-bottom: 20px;
}

.chat-bubble {
  max-width: 80%;
  padding: 15px;
  border-radius: 10px;
  position: relative;
  border: 2px solid var(--ink-black);
  box-shadow: 3px 3px 0 rgba(0,0,0,0.1);
  line-height: 1.5;
}

.chat-bubble.sent {
  align-self: flex-end;
  background: var(--action-cyan);
  color: var(--ink-black);
  border-bottom-right-radius: 0;
}

.chat-bubble.received {
  align-self: flex-start;
  background: white;
  color: var(--ink-black);
  border-bottom-left-radius: 0;
}

.chat-meta {
  font-size: 0.75rem;
  margin-top: 5px;
  opacity: 0.7;
  text-align: right;
  font-weight: bold;
}

.chat-bubble.received .chat-meta { text-align: left; }

/* Dashboard Tabs */
.dashboard-tabs {
  display: flex;
  gap: 10px;
  border-bottom: var(--border-thick);
  margin-bottom: 30px;
  overflow-x: auto;
  padding-bottom: 0;
}

.tab-btn {
  padding: 12px 25px;
  background: white;
  border: var(--border-thin);
  border-bottom: none;
  font-family: var(--font-heading);
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s;
  text-transform: uppercase;
  font-size: 1rem;
  border-radius: 8px 8px 0 0;
  margin-bottom: -3px; /* Overlap border */
  position: relative;
  z-index: 1;
}

.tab-btn:hover {
  background: #f0f0f0;
}

.tab-btn.active {
  background: var(--action-yellow);
  border: var(--border-thick);
  border-bottom: 3px solid var(--action-yellow); /* Hide bottom border */
  z-index: 2;
  transform: translateY(-2px);
  box-shadow: 2px -2px 0 var(--ink-black);
}

.tab-content {
  position: relative;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.3s ease;
}

.tab-pane.active {
  display: block;
}

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

@media (max-width: 600px) {
  .listings-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 2rem; }
  .footer-grid { grid-template-columns: 1fr; }
  
  .search-bar-container { flex-direction: column; }
  .search-btn { width: 100%; }
  
  .auth-container { padding: 20px; margin: 30px auto; }
  .hero-section { padding: 40px 0; }
}
