:root {
  --black: #000000;
  --red: #ff1a1a;
  --white: #ffffff;
  --gray: #1a1a1a;
  --dark-gray: #0f0f0f;
}

/* =========================
GLOBALNE STYLE
========================= */
html {
  font-size: 125%;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--black);
  color: var(--white);
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

/* =========================
NAVBAR
========================= */
#navbar {
  position: fixed;
  top: 0;
  width: 100%;
  max-width: 100%;
  background: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  padding: 15px 0;
  border-bottom: 1px solid rgba(255, 26, 26, 0.2);
  transition: all 0.3s ease;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
}

.logo-img {
  max-width: 180px;
  height: auto;
  filter: brightness(1.1);
  animation: float 4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 30px;
  transition: transform 0.4s ease;
}

.nav-link {
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: color 0.3s;
}

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

.nav-link:hover {
  color: var(--red);
}

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

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 10px;
}

.bar {
  width: 25px;
  height: 3px;
  background: var(--white);
  margin: 3px 0;
  transition: 0.3s;
}

/* =========================
HERO
========================= */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 100px 20px 50px;
  position: relative;
  overflow: hidden;
  text-align: center;
  max-width: 100%;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(255,26,26,0.1), transparent);
  z-index: 1;
}

.hero-content {
  max-width: 700px;
  width: 100%;
  z-index: 2;
  animation: fadeInUp 1s ease-out;
}

.hero-content h1 {
  font-family: 'Orbitron', sans-serif;
  font-size: 3.5rem;
  margin-bottom: 20px;
  color: var(--red);
  text-shadow: 0 0 20px rgba(255,26,26,0.5);
}

.hero-content p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  opacity: 0.9;
}

.btn-primary {
  display: inline-block;
  background: var(--red);
  color: white;
  padding: 14px 32px;
  border: none;
  border-radius: 50px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s;
  box-shadow: 0 5px 15px rgba(255,26,26,0.4);
}

.btn-primary:hover {
  background: #e60000;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255,26,26,0.6);
}

.hero-car {
  margin-top: 40px;
  max-width: 500px;
  width: 100%;
  z-index: 1;
}

.hero-car img {
  width: 100%;
  max-width: 100%;
  border-radius: 15px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.8);
  animation: fadeInRight 1.2s ease-out;
}

/* =========================
SEKCJA O NAS
========================= */
.about {
  padding: 100px 0;
  background: var(--dark-gray);
}

.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
  max-width: 100%;
}

.about-text p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #ddd;
}

.about-text p strong {
  color: var(--red);
}

.about-highlights {
  margin-top: 25px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.highlight {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  color: #ccc;
}

.highlight i {
  color: var(--red);
  font-size: 1.3rem;
}

.about-image img {
  width: 100%;
  max-width: 100%;
  border-radius: 15px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.6);
  transition: transform 0.4s ease;
}

.about-image img:hover {
  transform: scale(1.03);
}

/* =========================
SEKCJE OGÓLNE
========================= */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
  box-sizing: border-box;
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  font-family: 'Orbitron', sans-serif;
  color: var(--red);
  position: relative;
}

.section-title::after {
  content: '';
  width: 80px;
  height: 4px;
  background: var(--red);
  display: block;
  margin: 15px auto 0;
  border-radius: 2px;
}

/* =========================
USŁUGI
========================= */
.services {
  padding: 100px 0;
  background: var(--dark-gray);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.service-card {
  background: var(--gray);
  padding: 30px;
  border-radius: 15px;
  text-align: center;
  border: 1px solid rgba(255,26,26,0.1);
  transition: all 0.3s;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(255,26,26,0.2);
  border-color: var(--red);
}

.service-card i {
  font-size: 2.5rem;
  color: var(--red);
  margin-bottom: 20px;
}

.service-card h3 {
  margin-bottom: 15px;
  font-size: 1.4rem;
}

/* =========================
GALERIA
========================= */
.gallery {
  padding: 100px 0;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 15px;
}

.gallery-grid img {
  width: 100%;
  max-width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 10px;
  transition: all 0.3s;
  cursor: pointer;
  border: 2px solid transparent;
}

.gallery-grid img:hover {
  transform: scale(1.05);
  border-color: var(--red);
  box-shadow: 0 10px 20px rgba(255,26,26,0.3);
}

/* =========================
KONTAKT
========================= */
.contact {
  padding: 100px 0;
  background: var(--dark-gray);
  overflow-x: hidden; /* Prevent horizontal overflow */
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  max-width: 100%; /* Ensure no overflow */
}

.contact-info {
  max-width: 100%; /* Prevent overflow */
}

.info-item {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  font-size: 1.1rem;
}

.info-item i {
  color: var(--red);
  font-size: 1.5rem;
  margin-right: 15px;
  width: 30px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 15px;
  margin-bottom: 15px;
  background: var(--gray);
  border: 1px solid rgba(255,26,26,0.3);
  border-radius: 8px;
  color: white;
  font-size: 1rem;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #aaa;
}

.contact-form button {
  width: 100%;
}

.map-container {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  border-radius: 10px;
  margin-bottom: 20px;
}

.map-container iframe {
  width: 100% !important; /* Override inline width */
  max-width: 100%;
  height: 450px;
  border: 0;
  display: block;
}

/* =========================
STOPKA
========================= */
footer {
  padding: 30px 0;
  text-align: center;
  background: var(--gray);
  font-size: 0.9rem;
  border-top: 1px solid rgba(255,26,26,0.2);
}

/* =========================
LPG CALCULATOR
========================= */
.lpg-calculator {
  background: var(--dark-gray);
  padding: 100px 0;
}

.calculator-box {
  background: var(--gray);
  padding: 40px;
  border-radius: 15px;
  border: 1px solid rgba(255,26,26,0.15);
  box-shadow: 0 10px 25px rgba(0,0,0,0.4);
}

.inputs-column {
  display: flex;
  flex-direction: column;
  gap: 25px;
  margin-bottom: 40px;
}

.input-group label {
  display: block;
  margin-bottom: 10px;
  font-weight: 500;
}

.input-group input[type="range"] {
  width: 100%;
  accent-color: var(--red);
}

.input-group select {
  width: 100%;
  background: var(--black);
  border: 1px solid rgba(255,26,26,0.3);
  color: var(--white);
  padding: 10px;
  border-radius: 8px;
  font-size: 1rem;
}

.live-value {
  color: var(--red);
  font-weight: 600;
}

.results-box {
  background: var(--black);
  border-radius: 15px;
  padding: 30px;
  margin-top: 30px;
  text-align: center;
  border: 1px solid rgba(255,26,26,0.2);
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 15px;
  margin-bottom: 30px;
}

.results-grid div {
  background: var(--gray);
  padding: 15px;
  border-radius: 10px;
  border: 1px solid rgba(255,26,26,0.1);
}

.chart-container {
  width: 100%;
  max-width: 100%;
  height: 300px;
  position: relative;
}

#calculate-btn {
  display: block;
  margin: 10px auto 0;
}

/* =========================
SOCIAL LINKS
========================= */
.social-links {
  padding-top: 40px;
  margin-top: 20px;
  display: flex;
  gap: 15px;
  justify-content: center; /* Center buttons */
  flex-wrap: wrap;
  max-width: 100%;
  overflow-x: hidden;
}

.social-icon {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f8f8f8;
  border-radius: 50px;
  padding: 10px 20px;
  text-decoration: none;
  color: #333;
  font-weight: 500;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  opacity: 0;
  animation: fadeInUp 0.8s forwards;
  min-width: 120px; /* Touch-friendly */
}

.social-icon:nth-child(1) { animation-delay: 0.1s; }
.social-icon:nth-child(2) { animation-delay: 0.3s; }

.social-icon i {
  font-size: 1.5rem;
  transition: transform 0.3s ease;
}

.social-icon:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.social-icon:hover i {
  transform: rotate(15deg) scale(1.1);
}

.facebook {
  background: linear-gradient(135deg, #1877f2, #3b5998);
  color: #fff;
}

.maps {
  background: linear-gradient(135deg, #34a853, #4285f4);
  color: #fff;
  max-width: 100%;
}

/* =========================
ANIMACJE
========================= */
@keyframes fadeInUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInRight {
  from { opacity: 0; transform: translateX(50px); }
  to { opacity: 1; transform: translateX(0); }
}

/* =========================
MEDIA QUERIES
========================= */
@media (max-width: 1200px) {
  .container { max-width: 100%; padding: 0 15px; }
  .nav-container { max-width: 100%; padding: 0 15px; }
  .hero-content { max-width: 90%; }
  .hero-car { max-width: 90%; }
  .hero-car img { max-width: 100%; }
}

@media (max-width: 992px) {
  .hero-content h1 { font-size: clamp(2.2rem, 6vw, 2.8rem); }
  .hero-car img { max-width: 350px; }
  .about-content { grid-template-columns: 1fr; text-align: center; }
  .contact-content { grid-template-columns: 1fr; } /* Stack earlier */
  .section-title { font-size: clamp(1.8rem, 5vw, 2.2rem); }
  .map-container iframe { height: 350px; }
}

@media (max-width: 768px) {
  .hamburger { display: flex; padding: 10px; }
  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.98);
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    transform: translateY(-150%);
    max-width: 100%;
  }
  .nav-menu.active { transform: translateY(0); }
  .nav-link { padding: 10px 0; font-size: clamp(1rem, 3vw, 1.1rem); }
  .hero { padding: 80px 15px 40px; min-height: 80vh; }
  .hero-car { max-width: 90%; }
  .hero-car img { max-width: 100%; }
  .about { padding: 80px 15px; }
  .about-image { order: -1; margin-bottom: 20px; }
  .about-highlights { align-items: center; }
  .services { padding: 80px 15px; }
  .services-grid { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
  .gallery { padding: 80px 15px; }
  .gallery-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
  .contact { padding: 80px 15px; }
  .lpg-calculator { padding: 80px 15px; }
  .map-container iframe { height: 300px; }
}

@media (max-width: 600px) {
  html { font-size: 110%; }
  body { padding-top: 70px; }
  .logo-img { max-width: 140px; }
  .hero-content h1 { font-size: clamp(1.8rem, 5vw, 2.2rem); }
  .hero-content p { font-size: clamp(0.9rem, 3vw, 1rem); }
  .btn-primary { padding: 12px 24px; font-size: clamp(0.9rem, 2.5vw, 1rem); }
  .hero-car img { max-width: 300px; }
  .gallery-grid img { height: 160px; }
  .services-grid { grid-template-columns: 1fr; }
  .results-grid { grid-template-columns: 1fr; }
  .calculator-box { padding: 30px; }
  .map-container iframe { height: 250px; }
}

@media (max-width: 480px) {
  html { font-size: 100%; }
  .hero-content h1 { font-size: clamp(1.6rem, 4vw, 1.8rem); }
  .section-title { font-size: clamp(1.6rem, 4vw, 2rem); }
  .hero-car img { max-width: 250px; }
  .gallery-grid { grid-template-columns: 1fr; }
  .calculator-box { padding: 25px; }
  .map-container iframe { height: 200px; }
}

@media (max-width: 360px) {
  .hero-content h1 { font-size: clamp(1.4rem, 4vw, 1.6rem); }
  .btn-primary { padding: 10px 20px; font-size: clamp(0.8rem, 2.5vw, 0.9rem); }
  .hero-car img { max-width: 200px; }
  .map-container iframe { height: 180px; }
}