/* Google Fonts - Handwriting & Sans */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Nanum+Pen+Script&family=Permanent+Marker&family=Patrick+Hand&display=swap');

/* Base Variables */
:root {
  --color-paper-bg: #fdfbf7;
  --color-ink: #1a1a1a;
  --color-ink-light: #525252;
  --color-highlight: rgba(255, 241, 53, 0.3);
  --color-highlight-blue: rgba(100, 200, 255, 0.2);
  --color-border: #e4e4e7;
  /* much lighter border */
  --color-border-dark: #2a2a2a;

  --font-handwriting-en: 'Permanent Marker', cursive;
  --font-handwriting-kr: 'Nanum Pen Script', cursive;
  --font-body: 'Inter', sans-serif;
  /* Clean sans-serif */
  --font-accent: 'Patrick Hand', cursive;
}

body.v4-page {
  background-color: var(--color-paper-bg);
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
  color: var(--color-ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

/* Typography */
.v4-page h1,
.v4-page h2,
.v4-page h3 {
  letter-spacing: -0.02em;
}

.t-handwriting {
  font-family: var(--font-handwriting-en);
}

.v4-page:lang(ko) .t-handwriting {
  font-family: var(--font-handwriting-kr);
}

/* Sophisticated Cards */
.sketched-box {
  border: 1px solid rgba(0, 0, 0, 0.08);
  /* Subtle border */
  border-radius: 12px;
  background: white;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  /* Soft shadow */
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sketched-box:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
}

/* Refined Buttons */
.btn-sketch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--color-border-dark);
  border-radius: 8px;
  /* Clean radius */
  font-family: var(--font-accent);
  /* Keep accent font for buttons */
  font-weight: 600;
  font-size: 1.125rem;
  color: var(--color-ink);
  background: white;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 2px 2px 0 var(--color-border-dark);
  /* Hard shadow for retro feel */
}

.btn-sketch:hover {
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 var(--color-border-dark);
}

.btn-sketch.primary {
  background: var(--color-ink);
  color: white;
  border-color: var(--color-ink);
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
}

.btn-sketch.primary:hover {
  background: #000;
  transform: translate(-1px, -1px);
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.25);
}

/* Highlighting Effect - Neater */
.highlight-marker {
  position: relative;
  display: inline-block;
  z-index: 1;
}

.highlight-marker::after {
  content: '';
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: 2px;
  height: 35%;
  background-color: var(--color-highlight);
  z-index: -1;
  transform: rotate(-0.5deg);
  border-radius: 2px;
}

/* Reduced Animation */
@keyframes scribble {
  0% {
    transform: rotate(0deg);
  }

  25% {
    transform: rotate(0.5deg);
  }

  75% {
    transform: rotate(-0.5deg);
  }

  100% {
    transform: rotate(0deg);
  }
}

.animate-scribble:hover {
  animation: scribble 0.4s ease-in-out infinite;
}

/* v5 Bento Grid */
.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  gap: 2rem;
}

@media (min-width: 768px) {
  .features-grid {
    grid-template-columns: 1fr 1fr;
  }
}