/* ============================================
   MaistorRemont - Main Stylesheet
   ============================================ */

/* TT Ramillas Font */
@font-face {
  font-family: 'TT Ramillas';
  src: url('../fonts/TTRamillas-Regular.woff2') format('woff2'),
       url('../fonts/TTRamillas-Regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'TT Ramillas';
  src: url('../fonts/TTRamillas-Medium.woff2') format('woff2'),
       url('../fonts/TTRamillas-Medium.woff') format('woff');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'TT Ramillas';
  src: url('../fonts/TTRamillas-Semibold.woff2') format('woff2'),
       url('../fonts/TTRamillas-Semibold.woff') format('woff');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'TT Ramillas';
  src: url('../fonts/TTRamillas-Bold.woff2') format('woff2'),
       url('../fonts/TTRamillas-Bold.woff') format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* CSS Variables - Color Palette */
:root {
  --color-1: #acb2c3;
  --color-2: #8d8b8d;
  --color-3: #526fae;
  --color-4: #676061;
  --color-5: #ffb347;
  --color-6: #30303a;
  
  --primary: #526fae;
  --secondary: #acb2c3;
  --accent: #ffb347;
  --dark-text: #30303a;
  --muted-text: #8d8b8d;
  
  /* Design Tokens */
  --max-w: 1200px;
  --gutter: 20px;
  --color-primary: #526fae;
  --color-accent: #ffb347;
  --color-bg: #acb2c3;
  --text-dark: #30303a;
  --radius-lg: 16px;
  
  /* Legacy support */
  --max-width: 1200px;
  --section-spacing: 90px;
  --border-radius: 8px;
  --transition: all 0.3s ease;
}

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

/* Prevent horizontal overflow from long words (responsive) */
h1, h2, h3, h4, p, li, .section-title p, .main-service-content p, .service-card p {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--dark-text);
  background-color: #ffffff;
  overflow-x: hidden;
}

/* Typography - consistent sizing */
h1 {
  font-size: 2.4em;
  font-weight: 700;
  line-height: 1.2;
  color: var(--dark-text);
  margin-bottom: 1rem;
}

h2 {
  font-size: 2em;
  font-weight: 700;
  line-height: 1.3;
  color: var(--dark-text);
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.75em;
  font-weight: 600;
  line-height: 1.4;
  color: var(--dark-text);
  margin-bottom: 0.75rem;
}

h4 {
  font-size: 20px;
  font-weight: 600;
  color: var(--dark-text);
  margin-bottom: 0.5rem;
}

p {
  font-size: 16px;
  line-height: 1.6;
  color: var(--dark-text);
  margin-bottom: 1em;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--accent);
}

/* Focus states for accessibility (keyboard / screen readers) */
a:focus,
button:focus {
  outline: 3px solid #ffc107;
  outline-offset: 2px;
}

a:focus:not(:focus-visible),
button:focus:not(:focus-visible) {
  outline: none;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid #ffc107;
  outline-offset: 2px;
}

/* Ensure header-cta is not affected by base a tag styles */
a.header-cta {
  background: var(--primary) !important;
  color: #ffffff !important;
  text-decoration: none !important;
}

a.header-cta:hover {
  background: #3d5a8f !important;
  color: #ffffff !important;
}

/* Container */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}

/* Header - Sticky (always visible on scroll) */
header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  padding: 1rem 0;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo img {
  height: 50px;
  width: auto;
  max-width: none;
}

/* Navigation */
nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
  flex-wrap: wrap;
}

nav a {
  color: var(--dark-text);
  font-weight: 500;
  padding: 0.5rem 0;
  position: relative;
}

/* Highlight current nav item and hover */
nav a.active,
nav a:hover {
  color: #E04E39;
  font-weight: bold;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: #E04E39;
  transition: var(--transition);
}

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

/* Language Switcher */
.lang-switcher {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.lang-switcher button {
  background: transparent;
  border: 1px solid var(--color-1);
  padding: 0.4rem 0.8rem;
  border-radius: var(--border-radius);
  cursor: pointer;
  font-size: 14px;
  color: var(--dark-text);
  transition: var(--transition);
}

.lang-switcher button:hover,
.lang-switcher button.active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
}

/* Header CTA Button */
.header-cta {
  background: var(--primary) !important;
  color: #ffffff !important;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none !important;
  transition: var(--transition);
  white-space: nowrap;
  display: inline-block;
}

.header-cta:hover {
  background: #3d5a8f !important;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(82, 111, 174, 0.3);
  color: #ffffff !important;
}

/* Hero Section - Background Image Layout */
.hero {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-image: url('../../images/0-02-05-3137900b5e6a6677cf0710f3cd2f07181d09b314ed750e863543ad62c780110b_c54fe84ad25ea60d.jpg');
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center right;
  z-index: 1;
  filter: blur(6px);
  transform: scale(1.05);
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(48,48,58,0.6) 0%, rgba(48,48,58,0.25) 60%);
  z-index: 2;
}

.hero__content {
  position: relative;
  z-index: 3;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 120px var(--gutter);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 32px;
  align-items: center;
}

.hero__text h1 {
  color: #fff;
  font-size: 48px;
  line-height: 1.05;
  margin-bottom: 18px;
  text-shadow: 0 6px 24px rgba(0,0,0,0.45);
  font-weight: 700;
}

.hero__text p {
  color: #fff;
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 2rem;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
}

.hero__ctas {
  display: flex;
  gap: 1rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.hero__benefits {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.hero__benefits li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-size: 16px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
}

.hero__benefits svg {
  width: 24px;
  height: 24px;
  color: var(--color-accent);
  flex-shrink: 0;
}

.hero__visual {
  position: relative;
  z-index: 2;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.hero__visual img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
  display: block;
  object-fit: cover;
  transform: scale(1.15);
  transform-origin: center right;
}

/* Hero Animations */
.hero__text h1:not(.typewriter-container),
.hero__text p,
.hero__ctas,
.hero__benefits {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

body.loaded .hero__text h1:not(.typewriter-container) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

/* Typewriter container should be visible immediately */
.hero__text h1.typewriter-container {
  opacity: 1;
  transform: translateY(0);
}

body.loaded .hero__text p {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.2s;
}

body.loaded .hero__ctas {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}

body.loaded .hero__benefits {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.4s;
}

/* Typewriter Animation Styles */
.typewriter-container {
  display: inline-block;
  position: relative;
}

.typewriter-char {
  display: inline-block;
  transition: opacity 0.3s ease-out, transform 0.3s ease-out;
  will-change: opacity, transform;
}

.typewriter-word-nowrap {
  display: inline-block;
  white-space: nowrap;
}

.typewriter-word-underlined {
  position: relative;
  padding-bottom: 8px;
  transition: opacity 0.5s ease-in-out;
}

.typewriter-word-underlined::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 13.504px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='235.509' height='13.504' viewBox='0 0 235.509 13.504' preserveAspectRatio='none'%3E%3Cpath d='M163,.383a13.044,13.044,0,0,1,1.517-.072,3.528,3.528,0,0,1,1.237-.134q.618.044,1.237.044a.249.249,0,0,1-.1.178.337.337,0,0,0-.1.266q3.092.088,6.184-.044T178.953.4l-.206-.088a12,12,0,0,0,4.123,0,13.467,13.467,0,0,1,5.772,0q1.443-.178,2.68-.266A5.978,5.978,0,0,1,193.8.4,16.707,16.707,0,0,1,198.01.045q2.164.088,4.844.088-.618.088-.824.134L201.412.4a3.893,3.893,0,0,0,2.061,0,5.413,5.413,0,0,1,1.649-.356q.618.088,1.134.178a9.762,9.762,0,0,0,1.544.09,17,17,0,0,1,3.092-.266q1.649,0,3.5.178,2.886.088,5.875.044t5.875-.222q0,.088.206.088h.412a21.975,21.975,0,0,0,2.577.889A12.458,12.458,0,0,1,232.12,2.18a3.962,3.962,0,0,1,1.031.622A3.349,3.349,0,0,1,234.8,3.825a5.079,5.079,0,0,1,.618,1.111q.412.534-1.031.98-1.031.444-.618.98a2.09,2.09,0,0,1,.206.889q0,.444.825.889.618.8-.206,1.245l-1.237.534q-1.443-.088-2.68-.134a17.255,17.255,0,0,1-2.267-.222,3.128,3.128,0,0,0-.928-.044,3.129,3.129,0,0,1-.928-.044q-2.267-.178-4.432-.266T217.7,9.476q-1.649-.088-2.886-.088a17.343,17.343,0,0,1-2.474-.178q-3.916,0-7.73-.088t-7.73-.266l-12.471-.178q-6.287-.088-12.883-.088h-1.958q-.928,0-1.958.088h-2.061q-1.031,0-2.061-.088-2.68-.088-5.256-.134t-5.256.044h-5.462q-2.577,0-5.462.088-4.535.088-8.76.178t-8.554.088q-2.886.088-5.875.088t-5.875.088q-1.443.088-2.886.134t-3.092.044q-4.741.178-9.791.312t-9.791.312q-2.267.088-4.329.088T78.77,10.1q-4.329.266-8.863.49t-9.276.49q-1.237.088-2.68.134a24.356,24.356,0,0,0-2.683.224q-2.68.178-5.462.312t-5.668.4q-2.474.266-4.741.312t-4.741.044q-1.031-.088-1.958-.134a9.684,9.684,0,0,1-1.958-.312,12.5,12.5,0,0,0-1.443-.312q-.825-.134-1.856-.31-2.886.356-6.39.666t-6.8.845a26.709,26.709,0,0,1-2.886.356,20.758,20.758,0,0,1-9.482-.889Q.232,11.962.026,11.25T1.263,9.917q0-.266.825-.266a13.039,13.039,0,0,0,2.886-.444A17.187,17.187,0,0,1,7.86,8.672q3.092-.266,6.184-.8,1.649-.178,3.3-.312t3.5-.312q4.123-.354,8.039-.712t8.039-.622q9.478-.8,18.758-1.338,2.68-.178,5.153-.356t4.741-.356q2.474-.178,5.05-.356T75.88,3.24h1.34a4.829,4.829,0,0,0,1.34-.178q2.267-.178,4.329-.222t4.329-.134a7.256,7.256,0,0,1,2.267,0,3.459,3.459,0,0,0,1.031-.088,6.009,6.009,0,0,1,2.37-.266,14.745,14.745,0,0,0,2.783-.088q1.649,0,2.474.088a1.308,1.308,0,0,1,.185.011,1.226,1.226,0,0,1,.33-.1,3.656,3.656,0,0,0,.515-.088,4.433,4.433,0,0,1,2.886.266q.412-.088,1.031-.178l1.237-.178q.412,0,1.031.044a5.761,5.761,0,0,0,1.237-.044q2.886-.088,5.772-.044a53.829,53.829,0,0,0,5.772-.222,9.505,9.505,0,0,1,1.34-.088h1.34a4.428,4.428,0,0,1,.821-.258l.825-.178a15.178,15.178,0,0,1,1.855.444,3.028,3.028,0,0,1,1.031-.534,4.039,4.039,0,0,1,1.443-.178,6.158,6.158,0,0,1,1.649.178,5.05,5.05,0,0,0,2.267.268q1.855-.088,3.813-.134T138.13,1.2q1.031,0,2.164-.044t2.37-.044q-.206-.088.412-.534h3.092q.412,0,.309.266t.928,0a5.845,5.845,0,0,1,1.443,0,31.833,31.833,0,0,0,5.359.088,21.471,21.471,0,0,1,6.8.178,5.236,5.236,0,0,0,1.031-.4q.412-.222.825-.4a.694.694,0,0,1,.137.07Z' fill='%23ffb347' transform='translate(0 0.002)'/%3E%3C/svg%3E");
  background-size: 100% 100%;
  background-repeat: no-repeat;
  background-position: center bottom;
  animation: drawUnderline 1s ease-out forwards;
  opacity: 0;
}

@keyframes drawUnderline {
  0% {
    opacity: 0;
    transform: scaleX(0);
    transform-origin: left;
    clip-path: inset(0 100% 0 0);
  }
  100% {
    opacity: 1;
    transform: scaleX(1);
    transform-origin: left;
    clip-path: inset(0 0% 0 0);
  }
}

.typewriter-cursor {
  display: inline-block;
  color: #fff;
  font-weight: 300;
  animation: blink 1s infinite;
  margin-left: 2px;
  opacity: 1;
  transition: opacity 0.5s ease-out;
}

@keyframes blink {
  0%, 50% {
    opacity: 1;
  }
  51%, 100% {
    opacity: 0;
  }
}

/* Ensure typewriter doesn't interfere with initial hero animation */
body.loaded .typewriter-container {
  opacity: 1;
  transform: translateY(0);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  text-align: center;
}

.btn-primary,
.btn--primary {
  background: #E04E39;
  color: #fff;
  border: none;
  padding: 14px 26px;
  border-radius: 10px;
  font-weight: 700;
  display: inline-block;
  text-decoration: none;
  transition: background 0.3s, transform 0.3s;
}

.btn-primary:hover,
.btn--primary:hover {
  background: #c43e30;
  color: #fff !important;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(224, 78, 57, 0.3);
}

.btn--ghost {
  background: transparent;
  color: #fff;
  padding: 14px 26px;
  border-radius: 10px;
  font-weight: 700;
  display: inline-block;
  text-decoration: none;
  border: 2px solid rgba(255, 255, 255, 0.8);
  transition: var(--transition);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #fff;
  color: #ffb347 !important;
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--primary);
  color: #ffffff;
}

.btn-secondary:hover {
  background: var(--color-3);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-outline:hover {
  background: var(--primary);
  color: #ffffff;
}

/* Section spacing and alignment */
section h2,
section h3 {
  margin-top: 1.6em;
  margin-bottom: 0.8em;
}

section p {
  line-height: 1.6;
  margin-bottom: 1em;
}

/* Sections */
section {
  padding: var(--section-spacing) 0;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  font-size: 36px;
  margin-bottom: 1rem;
}

.section-title p {
  color: var(--muted-text);
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto;
}

/* Font Classes - Same as Hero Title */
.section-title.tt-ramillas h2,
.section-title.tt-ramillas p {
  font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.main-service-content.tt-ramillas h2,
.main-service-content.tt-ramillas p {
  font-family: 'Inter', 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Services Grid */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.service-card {
  background: #ffffff;
  border: 1px solid var(--color-1);
  border-radius: var(--border-radius);
  padding: 2rem;
  text-align: center;
  transition: var(--transition);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  border-color: var(--primary);
}

.service-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 1.5rem;
  color: var(--primary);
  stroke: currentColor;
  fill: none;
}

.service-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--border-radius);
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.service-card:hover .service-image {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.service-card h3 {
  font-size: 24px;
  margin-bottom: 1rem;
}

.service-card p {
  color: var(--muted-text);
  font-size: 15px;
}

/* Gallery */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 3rem;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  aspect-ratio: 4/3;
  cursor: pointer;
}

/* Gallery images: use loading="lazy" in HTML; prefer WebP + srcset when available */
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(82, 111, 174, 0.8);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: var(--transition);
}

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

/* Before/After Gallery */
.before-after {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 3rem;
}

.before-after-item {
  position: relative;
}

.before-after-item img {
  width: 100%;
  border-radius: var(--border-radius);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.before-after-label {
  position: absolute;
  top: 20px;
  left: 20px;
  background: var(--primary);
  color: #ffffff;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  font-weight: 600;
}

/* Testimonials */
.testimonials-slider {
  position: relative;
  margin-top: 3rem;
}

.testimonial {
  background: #f8f9fa;
  padding: 2.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  border-left: 4px solid var(--primary);
}

.testimonial-text {
  font-size: 18px;
  font-style: italic;
  color: var(--dark-text);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.testimonial-author {
  font-weight: 600;
  color: var(--primary);
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--dark-text);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-1);
  border-radius: var(--border-radius);
  font-size: 16px;
  font-family: inherit;
  transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(82, 111, 174, 0.1);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.5rem;
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.checkbox-item input[type="checkbox"] {
  width: auto;
}

/* Footer */
footer {
  background: var(--color-6);
  color: #ffffff;
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: #ffffff;
  margin-bottom: 1rem;
}

.footer-section p,
.footer-section a {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 0.5rem;
  display: block;
}

.footer-section a:hover {
  color: var(--primary);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
}

/* Floating WhatsApp Button */
.floating-button {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  z-index: 999;
  transition: var(--transition);
  cursor: pointer;
}

.floating-button:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.floating-button svg {
  width: 32px;
  height: 32px;
  fill: #ffffff;
}

/* Map Container */
.map-container {
  width: 100%;
  height: 500px;
  border-radius: var(--border-radius);
  overflow: hidden;
  margin-top: 2rem;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

#map {
  width: 100%;
  height: 100%;
}

.map-search {
  margin-bottom: 1.5rem;
}

.map-search input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-1);
  border-radius: var(--border-radius);
  font-size: 16px;
}

/* Calendar */
#calendar {
  background: #ffffff;
  border-radius: var(--border-radius);
  padding: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Service Dropdown */
.service-dropdown-item {
  padding: 0.75rem 1rem;
  cursor: pointer;
  border-bottom: 1px solid #eee;
  transition: var(--transition);
}

.service-dropdown-item:hover {
  background: #f8f9fa;
}

.service-dropdown-item:last-child {
  border-bottom: none;
}

/* Service List Items */
.service-item {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem;
  background: white;
  border: 1px solid var(--color-1);
  border-radius: var(--border-radius);
  margin-bottom: 0.75rem;
}

.before-after-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

/* Gallery Slider */
.gallery-slider-wrapper {
  position: relative;
  padding: 0 50px;
}

.gallery-swiper {
  padding-bottom: 50px;
}

.gallery-slide-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  aspect-ratio: 4/3;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.gallery-slide-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.gallery-slide-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.gallery-slide-item:hover img {
  transform: scale(1.1);
}

.gallery-slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 100%);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  opacity: 1;
  transition: var(--transition);
}

.gallery-slide-overlay h3 {
  color: #fff;
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.gallery-label {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.9rem;
}

.gallery-swiper .swiper-button-next,
.gallery-swiper .swiper-button-prev {
  color: var(--primary);
  background: rgba(255, 255, 255, 0.9);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.gallery-swiper .swiper-button-next:hover,
.gallery-swiper .swiper-button-prev:hover {
  background: #fff;
  transform: scale(1.1);
}

.gallery-swiper .swiper-button-next::after,
.gallery-swiper .swiper-button-prev::after {
  font-size: 20px;
  font-weight: 700;
}

.gallery-swiper .swiper-pagination-bullet {
  background: var(--primary);
  opacity: 0.5;
  width: 12px;
  height: 12px;
}

.gallery-swiper .swiper-pagination-bullet-active {
  opacity: 1;
  background: var(--accent);
}

/* Blog Section */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.blog-card {
  background: #ffffff;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.blog-card-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.1);
}

.blog-card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-card-content h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--dark-text);
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.blog-card-content p {
  color: var(--muted-text);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.blog-read-more {
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  display: inline-block;
  margin-top: auto;
}

.blog-read-more:hover {
  color: var(--accent);
  transform: translateX(5px);
}

@media (max-width: 768px) {
  .service-item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
  
  .before-after-gallery {
    grid-template-columns: 1fr;
  }
}

/* Quote Calculator */
.quote-result {
  margin-top: 2rem;
  padding: 2rem;
  background: #f8f9fa;
  border-radius: var(--border-radius);
  border-left: 4px solid var(--primary);
  display: none;
}

.quote-result.active {
  display: block;
}

.quote-result h3 {
  color: var(--primary);
  margin-bottom: 1rem;
}

.quote-result .total-price {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent);
  margin: 1rem 0;
}

/* Breadcrumbs */
.breadcrumbs {
  padding: 1rem 0;
  background: #f8f9fa;
}

.breadcrumbs ul {
  display: flex;
  list-style: none;
  gap: 0.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.breadcrumbs a {
  color: var(--muted-text);
}

.breadcrumbs a:hover {
  color: var(--primary);
}

.breadcrumbs li:not(:last-child)::after {
  content: '/';
  margin-left: 0.5rem;
  color: var(--muted-text);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  background: transparent;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--dark-text);
}

/* Responsive Design - Mobile first fixes: no overflow, clear layout */
@media (max-width: 768px) {
  .container {
    padding: 0 16px;
    max-width: 100%;
  }
  
  header .header-content {
    padding: 0 16px;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    min-height: auto;
  }
  
  .logo {
    flex: 0 0 auto;
    min-width: 0;
  }
  
  .logo img {
    height: 44px;
    max-width: 120px;
    object-fit: contain;
  }
  
  .mobile-menu-toggle {
    display: block;
    flex: 0 0 auto;
    margin-left: auto;
    padding: 0.5rem;
  }
  
  nav {
    order: 4;
    width: 100%;
    flex-basis: 100%;
  }
  
  nav ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    padding: 1rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    margin: 0 -16px;
    border-top: 1px solid rgba(0,0,0,0.08);
    gap: 0;
  }
  
  nav ul.active {
    display: flex;
  }
  
  nav ul li {
    width: 100%;
  }
  
  nav ul li a {
    display: block;
    padding: 0.75rem 0;
    border-bottom: 1px solid #eee;
  }
  
  .lang-switcher {
    order: 3;
    flex: 0 0 auto;
  }
  
  .header-cta {
    order: 5;
    width: 100%;
    text-align: center;
    margin-top: 0.5rem;
    padding: 0.65rem 1rem;
    font-size: 15px;
  }
  
  h1 {
    font-size: 1.75rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  h3 {
    font-size: 1.25rem;
  }
  
  section {
    padding: 2.5rem 0;
  }
  
  .section-title {
    margin-bottom: 2rem;
  }
  
  .section-title h2 {
    font-size: 1.5rem;
  }
  
  .hero__bg {
    background-position: center top;
  }
  
  .hero__content {
    grid-template-columns: 1fr;
    padding: 32px 16px;
    gap: 1.5rem;
  }
  
  .hero__text h1 {
    font-size: 1.75rem;
    line-height: 1.25;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  /* Keep "доказано качество" on one line on larger mobile; allow wrap on very small */
  .hero-title-keep,
  .typewriter-word-nowrap {
    white-space: nowrap;
  }
  .hero__visual {
    max-width: 100%;
    overflow: hidden;
  }
  .hero__visual img {
    transform: none;
    max-width: 100%;
    height: auto;
  }
  .hero__text p {
    font-size: 1rem;
    line-height: 1.5;
  }
  .hero__benefits li {
    font-size: 0.95rem;
  }
  .section-title p {
    font-size: 0.95rem;
    line-height: 1.5;
    padding: 0 0.25rem;
  }
  /* Main service: content first, then image; fix image display */
  .main-service .main-service-content {
    order: 1;
    padding: 0 0.25rem;
  }
  .main-service .main-service-content h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
  }
  .main-service .main-service-content p {
    font-size: 0.95rem;
    line-height: 1.6;
    word-wrap: break-word;
  }
  .main-service .main-service-content ul {
    margin: 1rem 0 !important;
  }
  .main-service .main-service-content ul li {
    font-size: 0.95rem;
    padding: 0.4rem 0 !important;
  }
  .main-service .main-service-image {
    order: 2;
    min-height: 220px;
    max-width: 100%;
  }
  .main-service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    min-height: 220px;
  }
  .service-card {
    padding: 1.25rem;
  }
  .service-card h3 {
    font-size: 1.2rem;
  }
  .service-card p {
    font-size: 0.95rem;
    line-height: 1.5;
  }
  .blog-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
    margin-top: 2rem !important;
  }
  .blog-card-content {
    padding: 1.25rem !important;
  }
  .blog-card-content h3 {
    font-size: 1.1rem;
    line-height: 1.35;
  }
  .blog-card-content p {
    font-size: 0.9rem;
    line-height: 1.5;
  }
  .contact-cta {
    padding: 2.5rem 1rem !important;
  }
  .contact-cta h2 {
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
  }
  .contact-cta p {
    font-size: 0.95rem;
  }
  .contact-cta .btn {
    width: 100%;
    max-width: 280px;
  }
  .testimonial-text {
    font-size: 0.95rem;
    line-height: 1.55;
  }
  .testimonial-card {
    margin: 0 0.5rem;
    padding: 1.5rem 1rem;
  }
  
  .hero__ctas {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .hero__ctas .btn {
    width: 100%;
    text-align: center;
  }
  
  .main-service {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .main-service.reverse {
    direction: ltr;
  }
  
  .benefits-grid {
    grid-template-columns: 1fr;
  }
  
  .services-grid {
    grid-template-columns: 1fr;
  }
  
  .gallery {
    grid-template-columns: 1fr;
  }
  
  .before-after {
    grid-template-columns: 1fr;
  }
  
  .gallery-slider-wrapper {
    padding: 0 16px;
  }
  
  .blog-grid {
    grid-template-columns: 1fr;
  }
  
  .section-spacing {
    padding: 2.5rem 0;
  }
  
  .floating-button {
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
  }
  
  .breadcrumbs ul {
    padding: 0 16px;
    flex-wrap: wrap;
    font-size: 14px;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
  }
  
  .footer-section {
    text-align: center;
  }
  
  .footer-section a,
  .footer-section p {
    margin-bottom: 0.5rem;
  }
  
  .testimonial {
    padding: 1.5rem;
  }
  
  .testimonial-text {
    font-size: 1rem;
  }
  
  /* About / Crew page (za-nas) */
  .about-page-content {
    padding: 0 0.5rem;
    text-align: center;
  }
  .about-stats {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
    margin: 2rem 0 !important;
  }
  .about-stats h3 {
    font-size: 2rem !important;
  }
  .about-cta-box {
    padding: 2rem 1.25rem !important;
    margin: 2rem 0 !important;
  }
  .about-cta-box .btn {
    width: 100%;
    text-align: center;
  }
}

/* Extra small screens: allow hero phrase to wrap so text doesn't overflow */
@media (max-width: 480px) {
  .container {
    padding: 0 12px;
  }
  header .header-content {
    padding: 0 12px;
  }
  .hero__content {
    padding: 24px 12px;
  }
  .hero__text h1 {
    font-size: 1.45rem;
    line-height: 1.3;
  }
  .hero-title-keep,
  .typewriter-word-nowrap {
    white-space: normal;
  }
  .section-title h2 {
    font-size: 1.35rem;
  }
  .main-service .main-service-content h2 {
    font-size: 1.35rem;
  }
  .main-service-image {
    min-height: 200px;
  }
  .main-service-image img {
    min-height: 200px;
  }
  .contact-cta h2 {
    font-size: 1.2rem;
  }
  .footer-section p,
  .footer-section a {
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }
  
  .header-content {
    padding: 0 15px;
  }
  
  .btn {
    padding: 0.75rem 1.5rem;
    font-size: 14px;
  }
}

/* Utility Classes */
.text-center {
  text-align: center;
}

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }

/* Loading Spinner */
.spinner {
  border: 3px solid var(--color-1);
  border-top: 3px solid var(--primary);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 2rem auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Animations */
.fade-up,
.fade-left,
.fade-right,
.fade-in {
  opacity: 0;
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-up {
  transform: translateY(30px);
}

.fade-left {
  transform: translateX(-30px);
}

.fade-right {
  transform: translateX(30px);
}

.fade-in.active,
.fade-up.active,
.fade-left.active,
.fade-right.active {
  opacity: 1;
  transform: translateX(0) translateY(0);
}

/* Why Choose Us - Benefit Cards */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.benefit-card {
  text-align: center;
  padding: 2rem;
  background: #ffffff;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.benefit-icon-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: #ffffff;
}

.benefit-icon-circle svg {
  width: 40px;
  height: 40px;
  stroke: currentColor;
  fill: none;
}

.benefit-card h3 {
  font-size: 22px;
  margin-bottom: 1rem;
}

.benefit-card p {
  color: var(--muted-text);
  font-size: 15px;
}

/* Main Services - 2 Column Layout */
.main-service {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 4rem;
}

.main-service.reverse {
  direction: rtl;
}

.main-service.reverse > * {
  direction: ltr;
}

.main-service-content {
  padding: 2rem 0;
}

.main-service-content h2 {
  font-size: 36px;
  margin-bottom: 1.5rem;
}

.main-service-content p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--dark-text);
  margin-bottom: 2rem;
}

.main-service-image {
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.main-service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 3000;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--border-radius);
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: #ffffff;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  color: var(--dark-text);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Contact CTA Section */
.contact-cta {
  background: linear-gradient(135deg, var(--primary) 0%, var(--color-3) 100%);
  color: #ffffff;
  padding: 4rem 0;
  text-align: center;
}

.contact-cta h2 {
  color: #ffffff;
  font-size: 36px;
  margin-bottom: 1rem;
}

.contact-cta p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
  margin-bottom: 2rem;
}

/* Testimonials Slider */
.testimonials-wrapper {
  position: relative;
  padding: 2rem 0;
}

.testimonial-card {
  background: #ffffff;
  padding: 2.5rem;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  margin: 0 1rem;
  text-align: center;
}

.testimonial-stars {
  color: #FFD700;
  font-size: 20px;
  margin-bottom: 1rem;
}

.testimonial-text {
  font-size: 17px;
  font-style: italic;
  color: var(--dark-text);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.testimonial-author {
  font-weight: 600;
  color: var(--primary);
  font-size: 16px;
}

/* Swiper Customization */
.swiper-pagination-bullet-active {
  background: var(--primary);
}

.swiper-button-next,
.swiper-button-prev {
  color: var(--primary);
}

/* Print Styles */
@media print {
  header,
  footer,
  .floating-button,
  nav {
    display: none;
  }
}

