/* Enhanced Hero Section */
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.hero-section {
  background: linear-gradient(135deg, #FFF9E6 0%, #FFE8B3 50%, #FFD88A 100%);
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  overflow: hidden;
  padding-top: 50px;
}
/* Animated background patterns */
.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(255, 193, 7, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255, 152, 0, 0.1) 0%, transparent 50%);
  animation: backgroundPulse 15s ease-in-out infinite;
  pointer-events: none;
}

@keyframes backgroundPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.6; }
}

/* Enhanced header */
.hero-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 15px 35px;
  z-index: 100;
  position: relative;
  transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.95);
  padding: 8px 12px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(255, 152, 0, 0.2);
  border: 2px solid #ffb300;
}

.admin-toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #e65100;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  cursor: pointer;
}

.admin-toggle-label input {
  width: 18px;
  height: 18px;
  accent-color: #ff9800;
  border-radius: 4px;
  cursor: pointer;
}

.small-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.95);
  padding: 10px 15px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(255, 152, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.small-logo:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 152, 0, 0.3);
}


@keyframes buzz {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  25% { transform: translateY(-4px) rotate(5deg); }
  50% { transform: translateY(0px) rotate(0deg); }
  75% { transform: translateY(-4px) rotate(-5deg); }
}

.logo-small-text {
  font-size: 12px;
  font-weight: bold;
  color: #FF9800;
  line-height: 1.1;
  text-transform: lowercase;
  font-family: Arial, sans-serif;
}

/* Content wrapper with stagger animations */
.hero-content-wrapper {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 40px 80px 80px 80px;
  max-width: 1400px;
  margin: 0 auto;
  position: relative;
  gap: 120px;
}

.hero-left {
  flex: 0 0 auto;
  max-width: 600px;
  width: fit-content;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  opacity: 0;
  transform: translateX(-60px) scale(0.9);
  transition: opacity 1s cubic-bezier(0.34, 1.56, 0.64, 1),
              transform 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-left.visible {
  opacity: 1;
  transform: translateX(0) scale(1);
}

/* Enhanced title with gradient */
.hero-big-title {
  font-size: clamp(44px, 12vw, 190px);
  font-weight: bold;
  background: linear-gradient(135deg, #FF9800 0%, #F57C00 50%, #E65100 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0 0 40px 0;
  line-height: 1.1;
  font-family: "Georgia", serif;
  letter-spacing: 8px;
  word-spacing: 16px;
  position: relative;
  filter: drop-shadow(2px 2px 4px rgba(255, 152, 0, 0.15));
  padding-bottom: 10px;
  opacity: 0;
  transform: translateY(120px) scale(0.9);
  transition: opacity 1.2s cubic-bezier(0.34, 1.56, 0.64, 1) 0.2s,
              transform 1.2s cubic-bezier(0.34, 1.56, 0.64, 1) 0.2s;
}

.hero-left.visible .hero-big-title {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hero-big-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: min(500px, 72vw);
  height: 8px;
  background: linear-gradient(90deg, #FF9800, transparent);
  border-radius: 4px;
  animation: expandWidth 1s ease-out 1.5s both;
}

@keyframes expandWidth {
  from { width: 0; }
  to { width: min(500px, 72vw); }
}

/* Enhanced button */
.order-btn {
  background: linear-gradient(135deg, #FF9800 0%, #F57C00 100%);
  color: white;
  border: none;
  padding: 22px 70px;
  border-radius: 50px;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(255, 152, 0, 0.4);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  margin-bottom: 20px;
  display: block;
  width: 100%;
  letter-spacing: 1px;
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(60px) scale(0.95);
}

.hero-left.visible .order-btn {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s,
              transform 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s,
              all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.order-btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.order-btn:hover::before {
  width: 300px;
  height: 300px;
}

/* Mobile-only: make the home hero image square without affecting other images */
@media (max-width: 600px) {
  /* Make both the home title and the hero image share a single mobile width
     so the image appears exactly as wide as the title. */
  :root {
    --hero-mobile-width: min(94vw, 520px);
  }

  .hero-section#home .hero-big-title {
    max-width: var(--hero-mobile-width);
    width: var(--hero-mobile-width);
    box-sizing: border-box;
  }

  /* Target the hero image inside the home section only */
  #home .hero-right .image-frame,
  .hero-section#home .hero-right .image-frame {
    width: var(--hero-mobile-width) !important;
    height: auto !important;
    max-width: var(--hero-mobile-width) !important;
    padding: 0 !important;
    margin: 0 auto !important;
  }

  #home .hero-right .image-frame img,
  .hero-section#home .hero-right .image-frame img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4 / 5 !important; /* a bit taller than wide */
    object-fit: cover !important;
    display: block;
    transform: scale(1.08); /* slightly larger for presence */
    border-radius: 8px;
  }
}

.order-btn:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 10px 30px rgba(255, 152, 0, 0.5);
}

.order-btn:active {
  transform: translateY(-2px) scale(1.02);
}

/* Enhanced auth links */
.auth-links {
  color: #D2691E;
  font-size: 18px;
  margin-top: 20px;
  letter-spacing: 0.5px;
  width: 100%;
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
}

.hero-left.visible .auth-links {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s,
              transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s;
}

.auth-links a {
  color: #D2691E;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 600;
  position: relative;
}

.auth-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #FF9800;
  transition: width 0.3s ease;
}

.auth-links a:hover::after {
  width: 100%;
}

.auth-links a:hover {
  color: #FF9800;
  transform: translateY(-2px);
}

.header-logout {
  display: none;
  padding: 8px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.95);
  color: #e65100;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border: 2px solid #ffb300;
  box-shadow: 0 4px 15px rgba(255, 152, 0, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.header-logout:hover {
  color: #FF9800;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(255, 152, 0, 0.3);
}

.welcome-msg {
  display: none;
  color: #FF9800;
  font-weight: bold;
  margin-top: 20px;
}

/* Enhanced right side */
.hero-right {
  flex: 0 0 auto;
  width: 600px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  margin-left: auto;
  opacity: 0;
  transform: translateX(60px) scale(0.9);
  transition: opacity 1s cubic-bezier(0.34, 1.56, 0.64, 1),
              transform 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-right.visible {
  opacity: 1;
  transform: translateX(0) scale(1);
}

.image-frame {
  position: relative;
  z-index: 5;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(255, 152, 0, 0.3);
  width: 600px;
  height: 600px;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  border: 5px solid white;
}

.image-frame::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255, 152, 0, 0.1), transparent);
  z-index: 1;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.image-frame:hover::before {
  opacity: 1;
}

.image-frame:hover {
  transform: translateY(-10px) rotate(-2deg) scale(1.02);
  box-shadow: 0 30px 80px rgba(255, 152, 0, 0.4);
}

.image-frame img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.image-frame:hover img {
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 1200px) {
  .hero-big-title {
    font-size: 130px;
  }
  
  .hero-content-wrapper {
    padding: 30px 40px 60px 40px;
  }
  
}

@media (max-width: 768px) {
  .hero-content-wrapper {
    flex-direction: column;
    padding: 16px 18px 24px;
    gap: 12px;
    min-height: calc(100vh - 60px);
    justify-content: center;
  }

  /* Show image but place it above the title */
  .hero-right {
    display: flex !important;
    order: -1;
    width: 100% !important;
    justify-content: center;
    margin-left: 0;
  }

  .image-frame {
    width: min(72vw, 300px) !important;
    height: min(72vw, 300px) !important;
    border-radius: 16px !important;
    border: 4px solid white !important;
    box-shadow: 0 12px 36px rgba(255, 152, 0, 0.28) !important;
  }

  .image-frame img {
    transform: none !important;
  }

  .image-frame:hover,
  .image-frame:hover img {
    transform: none !important;
  }

  .hero-left, .hero-right {
    max-width: 100%;
  }

  .hero-left {
    align-items: center;
    text-align: center;
  }

  .hero-big-title {
    font-size: 88px;
    letter-spacing: 3px;
    word-spacing: 6px;
    margin-bottom: 20px;
  }

  .hero-big-title::after {
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    max-width: 260px;
  }

  .order-btn {
    width: 100%;
    max-width: 360px;
  }

  .auth-links {
    margin-top: 10px;
    font-size: 16px;
  }
}

/* Mobile adjustments for the image frame so the frame fits the image exactly
   and the image is slightly larger for better presence on small screens. */
@media (max-width: 600px) {
  .image-frame {
    width: min(86vw, 380px) !important;
    height: auto !important;
    max-width: 380px;
    border-radius: 12px !important;
    border: 4px solid white !important;
    box-shadow: 0 18px 50px rgba(255, 152, 0, 0.25) !important;
    padding: 0 !important;
  }

  /* Make the img fill the frame and be a touch larger */
  .image-frame img {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
    object-fit: cover !important;
    display: block !important;
    transform: scale(1.03); /* slightly larger */
  }

  /* Remove hover transform on mobile to avoid shifting */
  .image-frame:hover,
  .image-frame:hover img {
    transform: none !important;
    box-shadow: 0 18px 50px rgba(255, 152, 0, 0.25) !important;
  }
}

/* Mobile: home hero image becomes a fading background — home section only */
@media (max-width: 768px) {
  .hero-section#home {
    background-image:
      linear-gradient(to bottom,
        rgba(255, 249, 230, 0) 0%,
        rgba(255, 249, 230, 0) 30%,
        rgba(255, 232, 179, 0.7) 65%,
        rgba(255, 216, 138, 1) 100%),
      url('./Home-images/home-img.png');
    background-size: cover, cover;
    background-position: center top, center top;
    background-repeat: no-repeat, no-repeat;
  }

  /* Hide the image frame — the image is now the background */
  .hero-section#home .hero-right {
    display: none !important;
  }
}
