/* 
 * Mie Ayam Pak De Vespa - Custom Styles
 * WordPress Theme: Custom styles to complement Tailwind CSS
 * Purpose: Brand colors, custom fonts, and WordPress-specific overrides
 */

/* ===========================
   CSS Custom Properties
   =========================== */
:root {
  /* Brand Colors - From Figma Design */
  --color-red-primary: #BE1E2D;
  /* Red accent for CTAs and highlights */
  --color-cream-bg: #F5F1E5;
  /* Light cream background */
  --color-cream-light: #F5F1E5;
  /* Lighter cream for text on dark backgrounds */
  --color-cream-dark: #EDD7AA;
  /* Darker cream for hero text */
  --color-footer-taupe: #B4A594;
  /* Taupe/sand color for footer */
  --color-text-dark: #2D2D2D;
  --color-red-hover: #9A1823;
  --color-signature-teal: #124C4A;
  /* Teal color for "Signature" text */
  --color-menu-bg: #F7EFD8;
  --color-menu-dish-bg: #FFFBF0;
  /* Light beige background for menu section */
  --color-footer-bg: #B6A995;
  /* Taupe/brown footer background */
}

/* Custom utility classes */
.text-signature-teal {
  color: var(--color-signature-teal);
}

.bg-menu-section {
  background-color: var(--color-menu-bg);
}

.bg-menu-dish {
  background-color: var(--color-menu-dish-bg);
}

.bg-footer {
  background-color: var(--color-footer-bg);
}

/* ===========================
   Font Family Declarations
   =========================== */
.font-playfair {
  font-family: 'Playfair Display', serif;
}

.font-dancing {
  font-family: 'Dancing Script', cursive;
}

.font-inter {
  font-family: 'Inter', sans-serif;
}

/* ===========================
   Custom Tailwind Extensions
   =========================== */
/* These extend Tailwind's utility classes with our brand colors */

.bg-red-primary {
  background-color: var(--color-red-primary);
}

.text-red-primary {
  color: var(--color-red-primary);
}

.bg-cream-bg {
  background-color: var(--color-cream-bg);
}

.text-cream-light {
  color: var(--color-cream-light);
}

.text-cream-dark {
  color: var(--color-cream-dark);
}

.text-cream-regular {
  color: var(--color-menu-dish-bg);
}

.bg-footer-taupe {
  background-color: var(--color-footer-taupe);
}

.text-gray-900 {
  color: var(--color-text-dark);
}

.hover\:bg-red-700:hover {
  background-color: var(--color-red-hover);
}

/* ===========================
   Smooth Scrolling
   =========================== */
/* Enables smooth scroll for anchor links (Beranda, Menu, Kontak) */
html {
  scroll-behavior: smooth;
}

/* ===========================
   WordPress-Specific Overrides
   =========================== */

/* WordPress Admin Bar Spacing - Prevents header overlap when logged in */
body.admin-bar header {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar header {
    top: 46px;
  }
}

/* WordPress Image Alignment Classes */
.alignleft {
  float: left;
  margin-right: 1.5rem;
  margin-bottom: 1rem;
}

.alignright {
  float: right;
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.aligncenter {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* ===========================
   Performance Optimizations
   =========================== */

/* Prevent FOUC (Flash of Unstyled Content) */
body {
  opacity: 1;
  transition: opacity 0.3s ease-in;
}

/* ===========================
   Accessibility Enhancements
   =========================== */

/* Focus Visible for Keyboard Navigation */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-red-primary);
  outline-offset: 2px;
}

/* Skip to Content Link - For Screen Readers */
.skip-to-content {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--color-red-primary);
  color: white;
  padding: 8px;
  text-decoration: none;
  z-index: 100;
}

.skip-to-content:focus {
  top: 0;
}

/* ===========================
   Print Styles
   =========================== */
@media print {

  header,
  footer {
    display: none;
  }

  body {
    font-size: 12pt;
    color: black;
    background: white;
  }
}

/* ===========================
   Custom Animations
   =========================== */

/* Fade In Animation for Sections */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.6s ease-out;
}

/* ===========================
   Responsive Typography
   =========================== */

/* Ensure text remains readable on all devices */
@media screen and (max-width: 640px) {
  h1 {
    font-size: 2rem;
    line-height: 1.2;
  }

  h2 {
    font-size: 1.75rem;
    line-height: 1.3;
  }

  h3 {
    font-size: 1.5rem;
    line-height: 1.4;
  }
}

/* ===========================
   WordPress Gutenberg Support
   =========================== */

/* If using Gutenberg blocks in the future */
.wp-block-image img {
  height: auto;
}

.wp-block-image.alignfull {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
}

/* ===========================
   Mobile Menu Styles
   =========================== */

/* For future JavaScript implementation of mobile menu */

.mobile-menu a {
  color: var(--color-cream-light);
  font-size: 1.5rem;
  text-decoration: none;
}

.mobile-menu a:hover {
  color: var(--color-red-primary);
}

@media screen and (min-width: 1280px) {
  .map-bottom {
    margin-bottom: -130px;
  }
}