body {
  margin: 0;
  font-family: 'Roboto', sans-serif;
  background: #f3eadf;
  color: #2b1d0e;
  scroll-behavior: smooth;
  transition: background 0.6s ease, color 0.6s ease;
}

/* Announcement Banner */
.announcement-banner {
  background: linear-gradient(135deg, #c0392b 0%, #8e2020 100%);
  color: #fff;
  padding: 15px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: bannerPulse 3s ease-in-out infinite;
  transition: background 0.6s ease;
}
.announcement-banner::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  animation: bannerShine 4s infinite;
}
.announcement-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 15px;
  position: relative;
  z-index: 1;
}
.announcement-icon {
  font-size: 1.5rem;
  animation: iconPulse 1s ease-in-out infinite;
}
.announcement-text {
  font-size: 0.95rem;
  max-width: 600px;
  line-height: 1.4;
}
@keyframes bannerPulse {
  0%, 100% { box-shadow: 0 2px 10px rgba(192,57,43,0.3); }
  50% { box-shadow: 0 2px 20px rgba(192,57,43,0.6); }
}
@keyframes bannerShine {
  0% { left: -100%; }
  50%, 100% { left: 100%; }
}
@keyframes iconPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: rgba(255,255,255,0.9);
  position: sticky;
  top: 0;
  z-index: 100;
  transition: background 0.6s ease, border-color 0.6s ease;
}
header h1 { font-family: 'Great Vibes', cursive; color:#c0392b; font-size:2.5rem; transition: color 0.6s ease;}
header nav a {
  margin-left: 15px;
  font-weight: bold;
  color: #2b1d0e;
}
header nav a:hover { color: #e74c3c; }

.hero {
  position: relative;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
}

.hero-overlay {
  position: absolute; inset:0; background: rgba(0,0,0,0.5);
}
.hero-content {
  position: relative; z-index: 1; color: #fff;
  animation: fadeIn 2s ease-in-out;
}
.hero-content h1 { font-size:3rem; margin:0; }
.hero-content p { font-size:1.2rem; margin:10px 0 20px; }
.hero-buttons button {
  margin:5px; padding:12px 24px;
  border:none; border-radius:10px;
  font-size:1rem; cursor:pointer; transition: all 0.3s;
}
.hero-buttons button:first-child { background:#c0392b; color:#fff; }
.hero-buttons button:first-child:hover { background:#e74c3c; transform:scale(1.05);}
.hero-buttons button:last-child { background: rgba(255,255,255,0.8);}
.hero-buttons button:last-child:hover { background:#fff; transform:scale(1.05); }

/* ===== HERO BACKGROUNDS ===== */

.hero-bg {
  position: absolute;
  inset: 0;
}

.italian-bg {
  background: url('wloskie-tlo.jpg') center/cover no-repeat;
  animation: zoom 20s infinite alternate;
  z-index: 0;
}

.tropical-bg {
  display: none;
  z-index: 0;
  overflow: hidden;
}

.tropical-img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.2s ease;
}

.tropical-img.active {
  opacity: 1;
}

/* Pokazywanie tropikalnego tła tylko w trybie tropical */
body.tropical .italian-bg {
  display: none;
}

body.tropical .tropical-bg {
  display: block;
}


@keyframes zoom {
  0% { transform: scale(1); }
  100% { transform: scale(1.15); }
}
@keyframes fadeIn {
  0% { opacity:0; transform:translateY(20px); }
  100% { opacity:1; transform:translateY(0); }
}

.menu { padding:60px 20px; text-align:center;}
.menu h2 { font-size:2.5rem; margin-bottom:40px; color:#c0392b; }
.pizza-container { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:40px;}
.pizza-wrapper { position: relative; }
.pizza-wrapper img { width:300px; border-radius:15px; box-shadow:0 10px 20px rgba(0,0,0,0.3); }
.steam {
  position:absolute; top:-20px; left:50%; transform:translateX(-50%);
  width:60px; height:60px;
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0) 70%);
  border-radius:50%;
  animation: steamRise 2s infinite;
}
@keyframes steamRise {
  0% { transform: translateX(-50%) translateY(0) scale(1); opacity:0.5;}
  50% { transform: translateX(-50%) translateY(-20px) scale(1.2); opacity:0.7;}
  100% { transform: translateX(-50%) translateY(-40px) scale(1.4); opacity:0;}
}

.pizza-info { max-width:400px; text-align:left;}
.pizza-info h3 { color:#e67e22; }
.pizza-info ul { list-style:none; padding:0; margin:10px 0; }
.pizza-info ul li { margin:5px 0; }

.pizza-info button {
  margin-top:10px; padding:10px 20px;
  border:none; border-radius:10px;
  background:#c0392b; color:#fff; cursor:pointer;
  transition: transform 0.3s;
}
.pizza-info button:hover { transform:scale(1.05); background:#e74c3c; }

.story { background:#2b1d0e; color:#f3eadf; padding:60px 20px; display:flex; justify-content:center; gap:40px; flex-wrap:wrap; transition: background 0.6s ease, color 0.6s ease;}
.person { text-align:center; max-width:250px; }
.person img { width:180px; height:180px; object-fit:cover; border-radius:50%; box-shadow:0 8px 16px rgba(0,0,0,0.2); transition: box-shadow 0.6s ease, border-color 0.6s ease;}
.person h3 { margin-top:10px; color:#e67e22;}

.location { text-align:center; padding:60px 20px; }
.location a { text-decoration:none; color:#c0392b; font-weight:bold; }

footer { text-align:center; padding:20px; background:#1a1108; color:#f3eadf; transition: background 0.6s ease; position: relative; }

.cart-modal {
  display: none;
  position: fixed; inset:0;
  background: rgba(0,0,0,0.6);
  justify-content:center; align-items:center; z-index:200;
}
.cart-content {
  background:#f3eadf; padding:30px; border-radius:20px; text-align:center;
  max-width:350px; width:90%;
}
.cart-content button {
  margin-top:10px; padding:10px 20px; border:none; border-radius:10px; cursor:pointer; font-weight:bold;
}
.cart-content button:first-child { background:#c0392b; color:#fff; }
.cart-content button:last-child { background: rgba(0,0,0,0.1);}
/* Historia Modal */
.story-modal {
  display: none;
  position: fixed;
  inset:0;
  background: rgba(0,0,0,0.7);
  justify-content: center;
  align-items: flex-start;
  overflow-y: auto;
  padding: 60px 20px;
  z-index: 300;
  animation: fadeInModal 0.5s ease forwards;
}
.story-content {
  background: #f3eadf;
  border-radius: 20px;
  max-width: 800px;
  width: 100%;
  padding: 30px 40px;
  position: relative;
  transform: translateY(-50px);
  animation: slideDown 0.5s ease forwards;
}
.story-content h2 { color: #c0392b; margin-top:0; font-size:2rem; }
.story-content .story-text { margin-top:20px; line-height:1.8; font-size:1.1rem; }

.close-btn {
  position: absolute;
  top:15px;
  right:20px;
  background:none;
  border:none;
  font-size:2rem;
  cursor:pointer;
  color:#c0392b;
}
.close-btn:hover { color:#e74c3c; }

@keyframes fadeInModal { from { opacity:0; } to { opacity:1; } }
@keyframes slideDown { from { transform: translateY(-50px); opacity:0; } to { transform: translateY(0); opacity:1; } }

/* Theme Toggle Button */
.theme-toggle {
  background: linear-gradient(135deg, #00b4d8, #0077b6);
  border: 2px solid rgba(255,255,255,0.4);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s ease;
  box-shadow: 0 2px 12px rgba(0,180,216,0.4), inset 0 0 8px rgba(255,255,255,0.2);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}
.theme-toggle::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #00b4d8, #48cae4, #90e0ef, #00b4d8);
  z-index: -1;
  animation: themeGlow 3s linear infinite;
}
.theme-toggle:hover {
  transform: scale(1.15) rotate(15deg);
  box-shadow: 0 4px 20px rgba(0,180,216,0.6), inset 0 0 12px rgba(255,255,255,0.3);
}
.theme-toggle-icon {
  font-size: 1.4rem;
  z-index: 1;
}
@keyframes themeGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ===== TROPICAL THEME ===== */
body.tropical {
  background: linear-gradient(180deg, #e0f7fa 0%, #b2ebf2 30%, #e0f2f1 60%, #fff8e1 100%);
  color: #1a3a3a;
}

body.tropical .announcement-banner {
  background: linear-gradient(135deg, #00897b 0%, #00695c 50%, #004d40 100%);
  animation: tropicalBannerPulse 3s ease-in-out infinite;
}
body.tropical .announcement-banner::before {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
}

body.tropical header {
  background: rgba(224,247,250,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid rgba(0,137,123,0.2);
}
body.tropical header h1 {
  color: #00796b;
  text-shadow: 1px 1px 2px rgba(0,121,107,0.2);
}
body.tropical header nav a { color: #1a3a3a; }
body.tropical header nav a:hover { color: #00897b; }

body.tropical .hero-overlay {
  background: linear-gradient(180deg, rgba(0,77,64,0.3) 0%, rgba(0,105,92,0.4) 50%, rgba(1,87,155,0.3) 100%);
}

body.tropical .menu {
  background: linear-gradient(180deg, rgba(224,247,250,0.6) 0%, rgba(178,235,242,0.4) 100%);
}
body.tropical .menu h2 { color: #00796b; }
body.tropical .pizza-info h3 { color: #e65100; }
body.tropical .pizza-info button {
  background: linear-gradient(135deg, #00897b, #00695c);
}
body.tropical .pizza-info button:hover {
  background: linear-gradient(135deg, #00acc1, #00897b);
}

body.tropical .story {
  background: linear-gradient(135deg, #004d40 0%, #00352e 40%, #01579b 100%);
  color: #e0f7fa;
}
body.tropical .story h2 { color: #e0f7fa; }
body.tropical .person h3 { color: #ffb74d; }
body.tropical .person img {
  box-shadow: 0 8px 24px rgba(0,0,0,0.3), 0 0 15px rgba(0,188,212,0.3);
  border: 3px solid rgba(0,188,212,0.4);
}

body.tropical .location {
  background: linear-gradient(180deg, rgba(178,235,242,0.3) 0%, rgba(255,248,225,0.4) 100%);
}
body.tropical .location a { color: #00796b; }
body.tropical .location a:hover { color: #00acc1; }

body.tropical footer {
  background: linear-gradient(135deg, #004d40, #01579b);
  color: #e0f7fa;
}

body.tropical .cart-content,
body.tropical .story-content {
  background: linear-gradient(135deg, #e0f7fa, #fff8e1);
  color: #1a3a3a;
}
body.tropical .story-content h2 { color: #00796b; }
body.tropical .cart-content button:first-child {
  background: #00897b; color: #fff;
}
body.tropical .close-btn { color: #00796b; }
body.tropical .close-btn:hover { color: #00acc1; }

body.tropical .theme-toggle {
  background: linear-gradient(135deg, #c0392b, #8e2020);
  box-shadow: 0 2px 12px rgba(192,57,43,0.4), inset 0 0 8px rgba(255,255,255,0.2);
}
body.tropical .theme-toggle::before {
  background: conic-gradient(from 0deg, #c0392b, #e74c3c, #e67e22, #c0392b);
}
body.tropical .theme-toggle:hover {
  box-shadow: 0 4px 20px rgba(192,57,43,0.6), inset 0 0 12px rgba(255,255,255,0.3);
}

body.tropical .hero-buttons button:first-child {
  background: linear-gradient(135deg, #00897b, #00695c);
}
body.tropical .hero-buttons button:first-child:hover {
  background: linear-gradient(135deg, #00acc1, #00897b);
}

body.tropical .pizza-wrapper img {
  box-shadow: 0 10px 30px rgba(0,77,64,0.3);
}

.extra-product {
  margin-top: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
}

.square-placeholder {
  width: 300px;
  aspect-ratio: 1 / 1;
  background: #ccc;
  border-radius: 15px;
  box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

/* Widoczność zależna od trybu */
.italian-only {
  display: flex;
}

.tropical-only {
  display: none;
}

body.tropical .italian-only {
  display: none;
}

body.tropical .tropical-only {
  display: flex;
}

@keyframes tropicalBannerPulse {
  0%, 100% { box-shadow: 0 2px 10px rgba(0,137,123,0.3); }
  50% { box-shadow: 0 2px 25px rgba(0,137,123,0.6); }
}

/* Tropical wave decoration */
body.tropical footer::before {
  content: '';
  display: block;
  height: 30px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 30'%3E%3Cpath d='M0 15 Q150 0 300 15 T600 15 T900 15 T1200 15 V30 H0 Z' fill='%23004d40'/%3E%3C/svg%3E") repeat-x;
  background-size: 1200px 30px;
  margin-bottom: -1px;
}

/* -----------------------
   D O D A T K O W E  U S T A W I E N I A
   ----------------------- */

/* --- HERO: zabezpieczenia obrazu - nie zmieniamy kolorów tła --- */
/* Nadpisanie ewentualnych tint: upewnij się, że obrazy pozostają czyste */
.hero-bg, .hero-bg img, .tropical-img {
  -webkit-filter: none !important;
  filter: none !important;
  image-rendering: auto;
  object-position: center center;
}

/* --- TROPICAL IMAGE SLOWER TRANSITION & FULL COVER --- */
.tropical-img {
  left: 0;
  top: 0;
  transition: opacity 1.5s ease; /* wolniejsza, płynniejsza zmiana */
  object-fit: cover;
  object-position: center center;
  z-index: 0;
}

/* Interval i czas zmiany kontrolujemy w JS (teraz 7000ms) */

/* --- SEA WAVE (rozpoczyna z prawego górnego rogu i "wlewa" się) --- */
#seaWaveContainer {
  position: fixed;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 400; /* nad hero, ale pod modals (modale mają z-index 300+ wcześniej) */
  overflow: visible;
}

/* sama fala (SVG) będzie skalowana i zanikać */
.sea-wave {
  position: absolute;
  top: 0;
  right: 0;
  width: 60vmax; /* duży rozmiar, by "wypełnić" ekran przy skali */
  height: 60vmax;
  transform-origin: 100% 0%; /* top-right */
  transform: scale(0) translate(0,0);
  opacity: 0;
  transition: transform 1.2s cubic-bezier(.2,.9,.3,1), opacity 0.6s ease;
  pointer-events: none;
}

/* klasa aktywująca falę (ręczne sterowanie JS) */
.sea-wave.wave-enter {
  transform: scale(1) translate(0, 0);
  opacity: 1;
}
.sea-wave.wave-fill {
  transform: scale(1.15) translate(-6%, 3%);
  opacity: 1;
}
.sea-wave.wave-exit {
  transform: scale(1.4) translate(-10%, 6%);
  opacity: 0;
}

/* --- PIZZA ANIM --- */
#pizzaAnim {
  position: fixed;
  top: 18px;
  right: 18px;
  width: 120px;
  height: 120px;
  z-index: 450;
  pointer-events: none;
  display: none; /* pokazujemy tylko w animacji */
  align-items: center;
  justify-content: center;
}
#pizzaAnimImg {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 15px;
  transform-origin: 50% 50%;
  will-change: transform;
  box-shadow: 0 10px 20px rgba(0,0,0,0.25);
}

/* płynna rotacja: sterujemy czasem animacji z JS */
.pizza-rotating {
  animation-name: pizza-rotate;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  /* animation-duration nadamy z JS, aby móc rampować */
}
@keyframes pizza-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* FLAME (discrete visual overlay, subtelna) */
#pizzaFlame {
  position: absolute;
  bottom: -10%;
  left: 50%;
  transform: translateX(-50%) scale(0);
  width: 120%;
  height: 60%;
  background: radial-gradient(ellipse at center, rgba(255,200,60,0.95) 0%, rgba(255,100,10,0.9) 45%, rgba(255,40,0,0.75) 70%, rgba(0,0,0,0) 100%);
  border-radius: 50% 50% 20% 20%;
  filter: blur(8px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.6s ease, opacity 0.6s ease;
  mix-blend-mode: screen;
  z-index: -1;
}
#pizzaFlame.flame-on {
  transform: translateX(-50%) scale(1.05);
  opacity: 0.95;
}

/* --- PRODUKTY: dopasowanie rozmiarów (takie jak Giuseppe) --- */
.square-placeholder,
.product-image,
.pizza-wrapper img {
  width: 300px;
  height: 300px;
  aspect-ratio: 1/1;
  border-radius: 15px; /* identyczne zaokrąglenie */
  object-fit: cover;
  box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

/* jeśli w placeholderie jest <img>, niech dostosuje się */
.product-image img,
.square-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 15px;
}

/* --- USUNIĘCIE lub OGRANICZENIE "zielonego halo" --- */
/* Usuń duże zielone obwódki nakładane na zdjęcia tła.
   Zamiast tego stosujemy subtelny akcent na sekcjach, bez tintowania hero. */
body.tropical .person img {
  box-shadow: 0 8px 16px rgba(0,0,0,0.25), 0 0 10px rgba(0,188,212,0.12);
  border: 2px solid rgba(0,188,212,0.12); /* znacznie mniej natarczywe */
  z-index: 2;
  position: relative;
}

/* NIE nakładać zielonego gradientu bezpośrednio na hero image */
body.tropical .hero-overlay {
  /* zastępujemy poprzedni, mocno zielony overlay bardziej neutralnym (nie barwi zdjęcia) */
  background: linear-gradient(180deg, rgba(0,0,0,0.18) 0%, rgba(0,0,0,0.18) 100%);
  mix-blend-mode: normal;
}

/* --- drobne responsywne uzupełnienia --- */
@media (max-width: 800px) {
  #pizzaAnim { width: 90px; height: 90px; top: 12px; right: 12px; }
  .square-placeholder, .pizza-wrapper img { width: 200px; height: 200px; }
}

/* Upewnij się, że wszystkie obrazy produktów są identycznej wielkości */
.extra-product img,
.pizza-wrapper img,
.square-placeholder img,
.product-image img {
  width: 300px;
  height: 300px;
  object-fit: cover;
  border-radius: 15px;
  display: block;
}

/* jeśli extra-product używa bezpośrednio <img>, nadaj mu spacing i align */
.extra-product {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: center;
}

/* pizza SVG styl (jeśli SVG ma id pizzaAnimImg, te reguły działają) */
#pizzaAnimImg {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 15px;
  transform-origin: 50% 50%;
}

/* Rotacja - kontrolowana z JS przez zmianę animation-duration */
.pizza-rotating {
  animation-name: pizza-rotate;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}
@keyframes pizza-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* domyślnie: włoski tryb */
.tropical-only {
  display: none;
}

/* gdy tryb tropikalny */
body.tropical .italian-only {
  display: none;
}

body.tropical .tropical-only {
  display: flex; /* albo block jeśli masz inny layout */
}
.water-transition {
  position: fixed;
  top: -200px;
  right: -200px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;

  background:
    radial-gradient(circle at 40% 40%, #6ee7f9 0%, #00b4d8 40%, #0077b6 75%, #023e8a 100%);

  transform: scale(0);
  transition: transform 1.4s cubic-bezier(.2,.8,.2,1),
              opacity 0.6s ease;
  filter: blur(2px);
}

.water-transition.expand {
  transform: scale(8);
}

.water-transition.fade-out {
  opacity: 0;
}
.center-pizza {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 220px;
  height: 220px;
  transform: translate(-50%, -50%) rotate(0deg);
  border-radius: 50%;
  z-index: 9999;

  background:
    radial-gradient(circle at center, #f7d86a 0%, #e8c07a 70%, #c68642 100%);

  box-shadow: 0 0 40px rgba(255,140,0,0.4);
  transition: transform 1.4s cubic-bezier(.2,.8,.2,1);
}

.center-pizza.spin-up {
  transform: translate(-50%, -50%) rotate(1440deg) scale(1.2);
}

.fire-transition {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9998;
  background:
    radial-gradient(circle at center,
      rgba(255,200,0,0.2) 0%,
      rgba(255,80,0,0.4) 30%,
      rgba(200,30,0,0.7) 60%,
      rgba(120,10,0,1) 100%);
  opacity: 0;
  transition: opacity 1s ease;
}

.fire-transition.ignite {
  opacity: 1;
}

.fire-transition.fade-out {
  opacity: 0;
}
