:root {
  --bg-1: #fff1e6;
  --bg-2: #e7f5ff;
  --bg-3: #f3f0ff;
  --ink: #1f1b16;
  --ink-soft: #5f5a56;
  --primary: #ff4d6d;
  --primary-strong: #ff2e57;
  --secondary: #845ef7;
  --accent: #3bc9db;
  --sun: #ffd43b;
  --mint: #63e6be;
  --card: #ffffff;
  --shadow-xl: 0 28px 60px rgba(31, 36, 60, 0.18);
  --shadow-lg: 0 18px 40px rgba(31, 36, 60, 0.14);
  --shadow-md: 0 12px 28px rgba(31, 36, 60, 0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --grid-gap: 24px;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body.theme-playful {
  font-family: "Sora", "Trebuchet MS", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 15% 20%, var(--bg-2), transparent 45%),
    radial-gradient(circle at 80% 10%, var(--bg-3), transparent 45%),
    linear-gradient(135deg, var(--bg-1) 0%, #fff 35%, #fdf7ff 70%, #eff9ff 100%);
  min-height: 100%;
  position: relative;
}

body.theme-playful::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(circle at 12px 12px, rgba(255, 77, 109, 0.1) 2px, transparent 2px),
    radial-gradient(circle at 48px 48px, rgba(132, 94, 247, 0.1) 2px, transparent 2px),
    radial-gradient(circle at 80px 20px, rgba(59, 201, 219, 0.1) 2px, transparent 2px);
  background-size: 96px 96px;
  opacity: 0.9;
  pointer-events: none;
  z-index: -1;
}

h1, h2, h3, h4, h5 {
  font-family: "Bungee", "Impact", sans-serif;
  letter-spacing: 0.5px;
}

.site-frame {
  position: relative;
}

.site-main {
  animation: popIn 0.7s ease-out;
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.main-nav {
  background: #fff;
  border-radius: 0 0 32px 32px;
  border-bottom: 5px solid transparent;
  border-image: linear-gradient(90deg, var(--sun), var(--primary), var(--secondary)) 1;
  box-shadow: var(--shadow-md);
}

.navbar-brand {
  color: var(--secondary) !important;
  font-weight: 700;
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo {
  height: 42px;
  width: auto;
  display: block;
}

.nav-link {
  color: var(--ink-soft) !important;
  font-weight: 600;
  transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link:focus {
  color: var(--primary) !important;
  transform: translateY(-1px);
}

.section {
  margin-bottom: 48px;
}

.section-title {
  font-size: 2.1rem;
  text-align: left;
  margin-bottom: 18px;
  position: relative;
  display: inline-block;
  padding: 0 14px 10px 0;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 8px;
  background: linear-gradient(90deg, var(--sun), var(--mint));
  border-radius: 99px;
  opacity: 0.6;
}

.section-subtitle {
  margin-top: 6px;
  color: var(--ink-soft);
  font-weight: 500;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--grid-gap);
  padding: 36px 32px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(255, 212, 59, 0.2), rgba(255, 77, 109, 0.12));
  border: 3px solid rgba(255, 77, 109, 0.2);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.7) 0%, transparent 45%),
    radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.5) 0%, transparent 50%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.2) 0, rgba(255, 255, 255, 0.2) 10px, transparent 10px, transparent 20px);
  pointer-events: none;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  font-weight: 700;
  color: var(--primary);
  box-shadow: var(--shadow-md);
  margin-bottom: 16px;
}

.hero h1 {
  font-size: clamp(2.2rem, 3vw, 3.4rem);
  margin-bottom: 16px;
}

.hero p {
  color: var(--ink-soft);
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.hero-palette {
  display: flex;
  gap: 10px;
  align-items: center;
}

.palette-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: var(--shadow-md);
}

.dot-sun { background: var(--sun); }
.dot-primary { background: var(--primary); }
.dot-secondary { background: var(--secondary); }
.dot-mint { background: var(--mint); }
.dot-accent { background: var(--accent); }

.hero-visual {
  position: relative;
  min-height: 240px;
}

.contact-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin: 16px 0 20px;
}

.highlight-card {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: #fff;
  border: 2px solid rgba(255, 77, 109, 0.2);
  font-weight: 600;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-md);
}

.auth-intro {
  margin-bottom: 16px;
  text-align: center;
}

.hero-card {
  position: absolute;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  color: var(--ink);
  font-weight: 700;
  box-shadow: var(--shadow-xl);
}

.hero-card span {
  display: block;
  font-size: 0.85rem;
  color: rgba(0, 0, 0, 0.6);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero-card strong {
  display: block;
  font-size: 1.1rem;
  margin-top: 6px;
}

.hero-card.card-a {
  background: linear-gradient(135deg, #fff, rgba(255, 212, 59, 0.6));
  transform: rotate(-4deg);
  top: 10px;
  left: 10px;
}

.hero-card.card-b {
  background: linear-gradient(135deg, #fff, rgba(132, 94, 247, 0.35));
  transform: rotate(3deg);
  top: 90px;
  right: 10px;
}

.hero-card.card-c {
  background: linear-gradient(135deg, #fff, rgba(99, 230, 190, 0.45));
  transform: rotate(-2deg);
  bottom: 10px;
  left: 35px;
}

.stationery-carousel {
  position: relative;
}

.stationery-carousel::before {
  content: "";
  position: absolute;
  inset: -12px;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 10% 20%, rgba(255, 212, 59, 0.3) 0%, transparent 35%),
    radial-gradient(circle at 90% 10%, rgba(59, 201, 219, 0.3) 0%, transparent 40%),
    radial-gradient(circle at 85% 85%, rgba(99, 230, 190, 0.25) 0%, transparent 45%),
    radial-gradient(circle at 15% 85%, rgba(255, 77, 109, 0.25) 0%, transparent 40%);
  z-index: 0;
  pointer-events: none;
}

.stationery-carousel .carousel-inner {
  position: relative;
  z-index: 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 4px solid rgba(255, 255, 255, 0.8);
}

.stationery-carousel .carousel-caption {
  background: rgba(28, 28, 28, 0.7);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
}

.slider-image {
  height: 400px;
  object-fit: cover;
}

.hero-card-blank {
  background: linear-gradient(135deg, rgba(255, 212, 59, 0.25), rgba(132, 94, 247, 0.2));
  border-radius: var(--radius-lg);
  border: 2px dashed rgba(255, 77, 109, 0.4);
  position: relative;
  overflow: hidden;
}

.hero-card-blank::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 30%, rgba(255, 255, 255, 0.6) 0%, transparent 40%),
    radial-gradient(circle at 85% 20%, rgba(255, 255, 255, 0.5) 0%, transparent 45%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 0, rgba(255, 255, 255, 0.15) 8px, transparent 8px, transparent 16px);
  pointer-events: none;
}

.hero-card-blank > * {
  position: relative;
  z-index: 1;
}

.product-grid {
  margin-top: 12px;
}

.card {
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px) rotate(-0.3deg);
  box-shadow: var(--shadow-lg);
}

.product-card {
  position: relative;
  overflow: hidden;
}

.product-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.55) 100%);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.product-card:hover::after {
  opacity: 1;
}

.product-card .card-body {
  padding: 18px 18px 6px;
}

.product-card .card-title a {
  color: var(--ink);
}

.product-image {
  height: 250px;
  object-fit: cover;
}

.card-footer {
  background: transparent;
  border-top: none;
  padding: 16px 18px 20px;
}

.price-tag {
  color: var(--ink-soft);
  font-weight: 600;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  border: 2px dashed rgba(0, 0, 0, 0.08);
  margin-right: 8px;
  margin-bottom: 10px;
}

.tag-new {
  background: rgba(255, 212, 59, 0.35);
  color: #7a4d00;
}

.tag-stock {
  background: rgba(99, 230, 190, 0.28);
  color: #1c4d46;
}

.tag-loved {
  background: rgba(132, 94, 247, 0.2);
  color: #4131b9;
}

.product-meta {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  margin-top: 16px;
}

.meta-card {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: #fff;
  border: 2px solid rgba(132, 94, 247, 0.15);
  font-weight: 600;
  color: var(--ink-soft);
  display: flex;
  gap: 8px;
  align-items: center;
  box-shadow: var(--shadow-md);
}

.btn {
  border-radius: 999px;
  font-weight: 700;
  padding: 10px 18px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--sun));
  border: none;
  color: #1f1b16;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover,
.btn-primary:focus {
  background: linear-gradient(135deg, var(--sun), var(--primary));
  color: #1f1b16;
}

.btn-outline-primary {
  border: 2px solid var(--secondary);
  color: var(--secondary);
  background: #fff;
}

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

.btn-success {
  background: linear-gradient(135deg, var(--mint), var(--accent));
  border: none;
  color: #173b3a;
}

.btn-secondary {
  border-radius: 999px;
  font-weight: 600;
}

.form-control,
.form-select,
textarea {
  border-radius: var(--radius-sm);
  border: 2px solid rgba(132, 94, 247, 0.18);
  box-shadow: none;
  padding: 12px 14px;
}

.language-select {
  min-width: 140px;
  padding-right: 2.5rem;
  background-position: right 0.75rem center;
  background-size: 12px 12px;
  line-height: 1.4;
}

.form-control:focus,
.form-select:focus,
textarea:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 0.2rem rgba(132, 94, 247, 0.2);
}

.breadcrumb {
  background: rgba(255, 255, 255, 0.8);
  border-radius: 999px;
  padding: 10px 16px;
  box-shadow: var(--shadow-md);
}

.product-main-image {
  width: 100%;
  max-height: 520px;
  object-fit: contain;
  background: #fff;
  border-radius: var(--radius-md);
  padding: 12px;
  box-shadow: var(--shadow-md);
}

.product-thumbs img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  cursor: pointer;
  border-radius: 12px;
  border: 2px solid transparent;
  transition: border 0.2s ease, transform 0.2s ease;
}

.product-thumbs img:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

hr {
  border-top: 2px dashed rgba(255, 77, 109, 0.3);
  opacity: 1;
}

.form-card,
.about-card,
.login-card {
  border-radius: var(--radius-md);
  border: 2px solid rgba(255, 77, 109, 0.15);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-md);
}

.login-card .card-header {
  background: linear-gradient(135deg, var(--secondary), var(--accent));
  color: #fff;
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.site-footer {
  background: rgba(255, 255, 255, 0.9);
  border-top: 3px dashed rgba(255, 77, 109, 0.3);
  color: var(--ink-soft);
}

.footer-brand-title {
  font-family: "Bungee", "Impact", sans-serif;
  font-size: 1.4rem;
  color: var(--secondary);
}

.footer-text {
  color: var(--ink-soft);
  font-weight: 500;
  margin-bottom: 12px;
}

.footer-title {
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 12px;
}

.footer-logo {
  height: 52px;
  width: auto;
  display: block;
}

.footer-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  display: inline-flex;
  margin-bottom: 8px;
  transition: color 0.2s ease;
}

.footer-links a:hover,
.footer-links a:focus {
  color: var(--primary);
}

.footer-palette {
  display: flex;
  gap: 10px;
  align-items: center;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 77, 109, 0.2);
  color: var(--ink-soft);
  font-weight: 500;
}

@media (max-width: 768px) {
  .hero {
    padding: 26px 20px;
  }

  .hero-visual {
    min-height: 200px;
  }

  .hero-card {
    position: relative;
    transform: none;
    margin-bottom: 12px;
  }

  .hero-card.card-a,
  .hero-card.card-b,
  .hero-card.card-c {
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
  }

  .slider-image {
    height: 280px;
  }

  .section-title {
    font-size: 1.7rem;
  }
}
