/* ModelsBlock Global CSS Stylesheet */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* Basic Resets */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Outfit', sans-serif;
  background-color: #f9fafb;
  color: #111827;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex-grow: 1;
}

/* Typography links */
a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

/* Button Reset */
button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

/* ==========================================
   Global Header & Navbar (Sleek Glassmorphic)
   ========================================== */
header.site-header {
  background-color: rgba(255, 255, 255, 0.9);
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #f3f4f6;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 800;
  font-size: 1.25rem;
  color: #111827;
}

.logo-wrapper img {
  height: 2rem;
  width: 2rem;
  object-fit: contain;
}

.logo-wrapper span {
  letter-spacing: -0.025em;
}

/* Desktop Links */
.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.desktop-nav a.nav-link {
  color: #4b5563;
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0.25rem 0.5rem;
}

.desktop-nav a.nav-link:hover {
  color: #4f46e5;
}

.cart-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: #fff;
  background-color: #4f46e5;
  border-radius: 0.5rem;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  transition: all 0.2s ease;
}

.cart-btn:hover {
  background-color: #4338ca;
  box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.1), 0 2px 4px -1px rgba(79, 70, 229, 0.06);
}

.cart-btn svg {
  width: 1rem;
  height: 1rem;
}

/* Mobile Toggle Hamburger */
.hamburger-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.375rem;
  transition: background-color 0.2s;
}

.hamburger-toggle:hover {
  background-color: #f3f4f6;
}

.hamburger-line {
  display: block;
  width: 1.25rem;
  height: 2px;
  background-color: #374151;
  transition: all 0.3s ease;
}

.hamburger-line:not(:last-child) {
  margin-bottom: 4px;
}

/* Mobile Nav Menu */
.mobile-nav-menu {
  display: none;
  background-color: #fff;
  border-top: 1px solid #f3f4f6;
  padding: 0.75rem 1rem;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.mobile-nav-links a {
  padding: 0.625rem 0.75rem;
  color: #374151;
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 0.375rem;
}

.mobile-nav-links a:hover {
  background-color: #eef2ff;
  color: #4f46e5;
}

.mobile-nav-links .mobile-cart-btn {
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  padding: 0.625rem 1rem;
  font-weight: 700;
  color: #fff;
  background-color: #4f46e5;
  border-radius: 0.5rem;
  text-align: center;
}

.mobile-nav-links .mobile-cart-btn:hover {
  background-color: #4338ca;
}

/* Show classes */
.mobile-nav-menu.show {
  display: block;
}

@media (max-width: 768px) {
  .desktop-nav {
    display: none;
  }
  .hamburger-toggle {
    display: flex;
  }
}

/* ==========================================
   Global Search Form Banner
   ========================================== */
.search-banner {
  background-color: #fff;
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem 1rem;
}

.search-container {
  max-width: 1280px;
  margin: 0 auto;
}

.search-form-wrapper {
  max-width: 48rem;
  margin: 0 auto;
  position: relative;
}

.search-input-group {
  display: flex;
  border: 1px solid #d1d5db;
  border-radius: 0.75rem;
  overflow: hidden;
  background-color: #fff;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
  transition: all 0.2s;
}

.search-input-group:focus-within {
  border-color: #4f46e5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.search-icon-prefix {
  display: flex;
  align-items: center;
  padding-left: 1rem;
  color: #9ca3af;
}

.search-icon-prefix svg {
  width: 1.25rem;
  height: 1.25rem;
}

.search-input {
  width: 100%;
  border: none;
  outline: none;
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #111827;
}

.search-input::placeholder {
  color: #9ca3af;
}

.search-submit-btn {
  background-color: #111827;
  color: #fff;
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0 1.25rem;
  transition: background-color 0.2s;
}

.search-submit-btn:hover {
  background-color: #1f2937;
}

/* ==========================================
   Global Layout Structure (Two Column / Sidebar)
   ========================================== */
.two-column-layout {
  max-width: 1280px;
  margin: 1.5rem auto 3rem;
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .two-column-layout {
    flex-direction: row;
  }
  .main-column {
    width: 75%;
  }
  .sidebar-column {
    width: 25%;
  }
}

.sidebar-box {
  background-color: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.25rem;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  margin-bottom: 1.5rem;
}

.sidebar-box h3 {
  font-size: 1rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f3f4f6;
}

/* Explorer categories links */
.sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sidebar-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #4b5563;
  border-radius: 0.5rem;
  transition: all 0.2s;
}

.sidebar-link:hover {
  background-color: #f5f3ff;
  color: #4f46e5;
}

.sidebar-link svg {
  width: 1rem;
  height: 1rem;
  color: #9ca3af;
  transition: color 0.2s;
}

.sidebar-link:hover svg {
  color: #4f46e5;
}

/* ==========================================
   Popular Tags Cloud
   ========================================== */
.tags-cloud {
  padding: 1.25rem;
}

.tags-title {
  font-size: 1rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f3f4f6;
}

.tags-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
}

.tag-badge {
  display: inline-block;
  padding: 0.25rem 0.625rem;
  background-color: #f3f4f6;
  color: #4b5563;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 0.375rem;
  transition: all 0.2s;
}

.tag-badge:hover {
  background-color: #eef2ff;
  color: #4f46e5;
}

/* ==========================================
   Global Footer
   ========================================== */
footer.site-footer {
  background-color: #fff;
  border-top: 1px solid #e5e7eb;
  padding: 2.5rem 1rem 1.5rem;
  margin-top: auto;
}

.footer-content {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 1.5rem;
}

@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: #111827;
}

.footer-logo img {
  height: 1.5rem;
  width: 1.5rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  justify-content: center;
}

.footer-link {
  font-size: 0.8125rem;
  color: #6b7280;
}

.footer-link:hover {
  color: #4f46e5;
}

.footer-bottom {
  max-width: 1280px;
  margin: 1.5rem auto 0;
  text-align: center;
  font-size: 0.75rem;
  color: #9ca3af;
}

/* ==========================================
   Cookie Consent Card
   ========================================== */
.cookie-card {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 2rem);
  max-width: 42rem;
  background-color: #111827;
  color: #fff;
  padding: 1rem 1.5rem;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  transition: transform 0.3s ease-in-out;
}

.cookie-card.translate-y-full {
  transform: translateX(-50%) translateY(200%);
}

@media (min-width: 640px) {
  .cookie-card.translate-y-full {
    transform: translateY(200%);
  }
}

@media (min-width: 640px) {
  .cookie-card {
    flex-direction: row;
    transform: none;
    left: 1.5rem;
    width: auto;
  }
}

.cookie-text {
  font-size: 0.8125rem;
  color: #d1d5db;
  text-align: center;
}

@media (min-width: 640px) {
  .cookie-text {
    text-align: left;
  }
}

.cookie-text a {
  color: #818cf8;
  text-decoration: underline;
}

.cookie-btn {
  background-color: #3b82f6;
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 0.5rem 1.25rem;
  border-radius: 0.5rem;
  white-space: nowrap;
  transition: background-color 0.2s;
}

.cookie-btn:hover {
  background-color: #2563eb;
}

/* ==========================================
   Utility Grid / Flex Layouts
   ========================================== */
.hidden {
  display: none !important;
}

/* Spin animation loader */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Back to Top Button */
#back-to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 40;
  width: 2.5rem;
  height: 2.5rem;
  background-color: #4f46e5;
  color: #fff;
  border-radius: 50%;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
}

#back-to-top.show {
  opacity: 1;
  pointer-events: auto;
}

#back-to-top:hover {
  background-color: #4338ca;
  transform: translateY(-2px);
}

#back-to-top svg {
  width: 1.25rem;
  height: 1.25rem;
}

/* ==========================================
   Model Card & Grid Styles
   ========================================== */
.model-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 0.5rem;
}

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

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

.model-card {
  background-color: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  cursor: pointer;
  height: fit-content;
}

.model-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  transform: translateY(-2px);
}

.model-card-img-wrapper {
  position: relative;
  width: 100%;
  height: 11rem;
  background-color: #f9fafb;
  overflow: hidden;
}

.model-card-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.model-card:hover .model-card-img-wrapper img {
  transform: scale(1.05);
}

.model-card-badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.125rem 0.5rem;
  border-radius: 9999px;
}

.model-card-badge.free {
  background-color: #dcfce7;
  color: #15803d;
}

.model-card-badge.paid {
  background-color: #fef3c7;
  color: #b45309;
}

.model-card-body {
  padding: 0.75rem;
}

.model-card-body h5 {
  font-size: 0.875rem;
  font-weight: 600;
  color: #111827;
  line-height: 1.375;
  transition: color 0.2s;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.model-card:hover .model-card-body h5 {
  color: #4f46e5;
}

.model-card-meta {
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.model-card-filetype {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.125rem 0.5rem;
  background-color: #eef2ff;
  color: #4f46e5;
  border-radius: 9999px;
  text-transform: uppercase;
}

.model-card-unit {
  font-size: 0.75rem;
  color: #9ca3af;
}


