/* ===================================
   Daerim Warehouse - Custom CSS
   Vintage Industrial Cafe Style
   =================================== */

/* ===================================
   CSS Variables
   =================================== */
:root {
  --warehouse-brown: #8B4513;
  --warehouse-cream: #F5E6D3;
  --warehouse-dark: #2C2C2C;
  --warehouse-rust: #A0522D;
  --warehouse-sand: #D2B48C;
}

/* ===================================
   Base Styles
   =================================== */
html {
  scroll-behavior: smooth;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Selection */
::selection {
  background-color: var(--warehouse-brown);
  color: var(--warehouse-cream);
}

/* ===================================
   Grunge Texture Overlay
   =================================== */
.grunge-texture {
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  pointer-events: none;
}

/* Vintage Filter */
.vintage-filter {
  background: linear-gradient(
    to bottom,
    rgba(139, 69, 19, 0.1) 0%,
    rgba(245, 230, 211, 0.05) 50%,
    rgba(139, 69, 19, 0.15) 100%
  );
  mix-blend-mode: multiply;
  pointer-events: none;
}

/* Vintage Photo Effect */
.vintage-photo {
  filter: sepia(20%) contrast(1.1) brightness(0.95);
  transition: filter 0.3s ease;
}

.vintage-photo:hover {
  filter: sepia(0%) contrast(1) brightness(1);
}

/* ===================================
   Navigation
   =================================== */
.nav-link {
  color: var(--warehouse-dark);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 0;
  position: relative;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--warehouse-brown);
  transition: width 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--warehouse-brown);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* ===================================
   Menu Cards
   =================================== */
.menu-card {
  background: var(--warehouse-cream);
  border: 1px solid rgba(139, 69, 19, 0.2);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.menu-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(44, 44, 44, 0.1);
}

/* Menu Item Cards */
.menu-item-card {
  position: relative;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(139, 69, 19, 0.15);
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.menu-item-card:hover {
  background: rgba(255, 255, 255, 0.8);
  border-color: var(--warehouse-brown);
}

.menu-item-card.featured {
  background: rgba(245, 230, 211, 0.8);
  border-color: var(--warehouse-rust);
}

.menu-item-card-dark {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(210, 180, 140, 0.2);
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.menu-item-card-dark:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--warehouse-sand);
}

/* Menu Tabs */
.menu-tab {
  color: var(--warehouse-dark);
  opacity: 0.6;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 0.5rem 1rem;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
}

.menu-tab:hover,
.menu-tab.active {
  opacity: 1;
  color: var(--warehouse-brown);
  border-bottom-color: var(--warehouse-brown);
}

/* ===================================
   Gallery
   =================================== */
.gallery-tab {
  color: var(--warehouse-dark);
  opacity: 0.6;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  padding: 0.5rem 1rem;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
}

.gallery-tab:hover,
.gallery-tab.active {
  opacity: 1;
  color: var(--warehouse-brown);
  border-bottom-color: var(--warehouse-brown);
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  grid-auto-rows: 200px;
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 150px;
  }
}

.gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  filter: sepia(10%);
}

.gallery-item:hover img {
  transform: scale(1.05);
  filter: sepia(0%);
}

.gallery-item-tall {
  grid-row: span 2;
}

.gallery-item-wide {
  grid-column: span 2;
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(44, 44, 44, 0.7) 0%, transparent 60%);
  display: flex;
  align-items: flex-end;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-overlay span {
  color: var(--warehouse-cream);
}

/* Instagram Grid */
.insta-item {
  display: block;
  overflow: hidden;
}

.insta-item img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 0.3s ease;
  filter: sepia(10%);
}

.insta-item:hover img {
  transform: scale(1.05);
  filter: sepia(0%);
}

.insta-grid-item {
  display: block;
  position: relative;
  overflow: hidden;
}

.insta-grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  filter: sepia(10%);
}

.insta-grid-item:hover img {
  transform: scale(1.05);
  filter: sepia(0%);
}

.insta-grid-overlay {
  position: absolute;
  inset: 0;
  background: rgba(139, 69, 19, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.insta-grid-item:hover .insta-grid-overlay {
  opacity: 1;
}

/* ===================================
   Contact Page
   =================================== */
.contact-info-card {
  text-align: center;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(139, 69, 19, 0.15);
  transition: all 0.3s ease;
}

.contact-info-card:hover {
  background: rgba(255, 255, 255, 0.8);
  border-color: var(--warehouse-brown);
}

.direction-card {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(139, 69, 19, 0.15);
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.direction-card:hover {
  background: rgba(255, 255, 255, 0.8);
}

.reservation-card {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(139, 69, 19, 0.15);
  padding: 2rem;
  text-align: center;
}

/* Contact Form Inputs */
.contact-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(210, 180, 140, 0.3);
  padding: 1rem;
  color: var(--warehouse-cream);
  font-size: 0.875rem;
  transition: all 0.3s ease;
}

.contact-input:focus {
  outline: none;
  border-color: var(--warehouse-sand);
  background: rgba(255, 255, 255, 0.15);
}

.contact-input::placeholder {
  color: rgba(245, 230, 211, 0.5);
}

/* FAQ */
.faq-item {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(139, 69, 19, 0.15);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 1.5rem;
  text-align: left;
  font-weight: 500;
  color: var(--warehouse-dark);
  transition: all 0.3s ease;
}

.faq-question:hover {
  background: rgba(139, 69, 19, 0.05);
}

.faq-question i {
  transition: transform 0.3s ease;
  color: var(--warehouse-brown);
}

.faq-item.active .faq-question i {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
  max-height: 200px;
}

.faq-answer p {
  padding: 0 1.5rem 1.25rem;
  color: rgba(44, 44, 44, 0.7);
  font-size: 0.875rem;
  line-height: 1.6;
}

/* ===================================
   Prose Custom
   =================================== */
.prose-custom p {
  color: rgba(44, 44, 44, 0.8);
  line-height: 1.8;
}

/* ===================================
   Animations
   =================================== */
@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

/* Scroll reveal fade */
[data-aos="fade-up"] {
  opacity: 0;
  transform: translateY(20px);
  transition-property: opacity, transform;
}

[data-aos="fade-up"].aos-animate {
  opacity: 1;
  transform: translateY(0);
}

/* ===================================
   Lightbox
   =================================== */
#lightbox {
  backdrop-filter: blur(4px);
}

#lightbox img {
  animation: lightbox-in 0.3s ease;
}

@keyframes lightbox-in {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ===================================
   Responsive
   =================================== */
@media (max-width: 768px) {
  .gallery-item-tall,
  .gallery-item-wide {
    grid-row: span 1;
    grid-column: span 1;
  }
}

/* ===================================
   Scrollbar
   =================================== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--warehouse-cream);
}

::-webkit-scrollbar-thumb {
  background: var(--warehouse-brown);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--warehouse-rust);
}

/* ===================================
   Page Transitions
   =================================== */
.page-transition {
  opacity: 0;
  animation: page-fade-in 0.5s ease forwards;
}

@keyframes page-fade-in {
  to {
    opacity: 1;
  }
}

/* ===================================
   Loading State
   =================================== */
.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}
