/* ==========================================================================
   CSS SYSTEM - TALLERES METÁLICOS FERNÁNDEZ (TMF)
   Premium Steel-Blue Design System & Utility Classes
   ========================================================================== */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&display=swap');

/* Design Tokens & Theme Variables */
:root {
  /* Color Palette (Steel-Blue Concept) */
  --hue-primary: 218; /* Navy Blue */
  --hue-accent: 224;  /* Cobalto / Electric Blue */
  
  --primary-100: hsl(var(--hue-primary), 60%, 94%);
  --primary-200: hsl(var(--hue-primary), 50%, 85%);
  --primary-500: hsl(var(--hue-primary), 55%, 35%);
  --primary-600: hsl(var(--hue-primary), 60%, 24%);
  --primary-800: hsl(var(--hue-primary), 65%, 15%);
  --primary-900: hsl(var(--hue-primary), 70%, 10%);

  --accent-400: hsl(var(--hue-accent), 85%, 60%);
  --accent-500: hsl(var(--hue-accent), 90%, 50%);
  --accent-600: hsl(var(--hue-accent), 95%, 40%);

  --steel-100: hsl(210, 20%, 96%);
  --steel-200: hsl(210, 16%, 90%);
  --steel-300: hsl(210, 14%, 80%);
  --steel-500: hsl(210, 10%, 55%);
  --steel-700: hsl(210, 9%, 35%);
  --steel-850: hsl(210, 11%, 18%);
  
  /* Semantic Variables (Light Mode Default) */
  --bg-body: var(--steel-100);
  --bg-card: #ffffff;
  --bg-header: rgba(255, 255, 255, 0.8);
  --bg-footer: var(--primary-900);
  
  --text-main: var(--primary-900);
  --text-muted: var(--steel-700);
  --text-inverse: #ffffff;
  --text-accent: var(--accent-500);
  
  --border-color: var(--steel-200);
  --shadow-sm: 0 2px 4px rgba(15, 32, 66, 0.04);
  --shadow-md: 0 8px 24px rgba(15, 32, 66, 0.08);
  --shadow-lg: 0 16px 40px rgba(15, 32, 66, 0.12);
  
  --font-headings: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  
  --header-height: 100px;
  --max-width: 1200px;
}

/* Dark Mode Overrides (Automatic & class-based) */
@media (prefers-color-scheme: dark) {
  :root {
    --bg-body: var(--primary-900);
    --bg-card: var(--steel-850);
    --bg-header: rgba(15, 32, 66, 0.85);
    
    --text-main: var(--steel-100);
    --text-muted: var(--steel-300);
    --text-inverse: var(--primary-900);
    
    --border-color: rgba(255, 255, 255, 0.08);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.4);
  }
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--transition-normal), color var(--transition-normal);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headings);
  font-weight: 700;
  line-height: 1.25;
  color: var(--text-main);
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

ul {
  list-style: none;
}

/* ==========================================================================
   LAYOUT STRUCTURE
   ========================================================================== */

.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

.section {
  padding: 5rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}

.section-title {
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background-color: var(--accent-500);
  border-radius: 2px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0.75rem auto 0;
}

/* ==========================================================================
   HEADER & NAVIGATION (Logo Enlarged)
   ========================================================================== */

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background-color: var(--bg-header);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 100;
  transition: background-color var(--transition-normal), height var(--transition-normal);
}

.header.scrolled {
  height: 80px;
  box-shadow: var(--shadow-sm);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo-link {
  display: flex;
  align-items: center;
  padding: 0.25rem 0;
}

.logo-img {
  height: 80px;
  width: auto;
  transition: height var(--transition-normal);
}

.header.scrolled .logo-img {
  height: 64px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.5rem 0;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent-500);
  transition: width var(--transition-fast);
}

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

.nav-link:hover,
.nav-link.active {
  color: var(--accent-500);
}

.btn-nav-call {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--primary-600);
  color: white;
  padding: 0.6rem 1.2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background-color var(--transition-fast), transform var(--transition-fast);
}

.btn-nav-call:hover {
  background-color: var(--accent-500);
  transform: translateY(-2px);
  color: white;
}

.btn-nav-call svg {
  fill: currentColor;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.hamburger-line {
  display: block;
  width: 24px;
  height: 2.5px;
  margin: 5px 0;
  background-color: var(--text-main);
  transition: transform var(--transition-normal), opacity var(--transition-normal);
}

/* ==========================================================================
   HERO SECTION (Reverted to Full-screen image and lateral gradient overlay)
   ========================================================================== */

.hero {
  position: relative;
  height: 100vh;
  min-height: 650px;
  display: flex;
  align-items: center;
  background: url('../assets/images/taller.jpg') center/cover no-repeat;
  color: white;
  padding-top: var(--header-height);
  overflow: hidden;
}

.hero-overlay-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* Dark on the left for text readability, very transparent on the right to show the storefront */
  background: linear-gradient(90deg, rgba(15, 32, 66, 0.95) 0%, rgba(15, 32, 66, 0.7) 45%, rgba(15, 32, 66, 0.25) 100%);
  z-index: 1;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 650px;
  width: 100%;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.8s forwards var(--transition-normal);
}

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

.hero-tag {
  display: inline-block;
  background-color: rgba(37, 99, 235, 0.25);
  color: var(--accent-400);
  border: 1px solid rgba(37, 99, 235, 0.4);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  color: white;
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.hero-title span {
  color: var(--accent-400);
  background: linear-gradient(to right, #60a5fa, #2563eb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 2.5rem;
  color: var(--steel-200);
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-primary {
  background-color: var(--accent-500);
  color: white;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
  background-color: var(--accent-600);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-secondary {
  background-color: rgba(255, 255, 255, 0.15);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(4px);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.25);
  border-color: white;
  transform: translateY(-2px);
}

/* ==========================================================================
   SERVICES SECTION (With updated paths)
   ========================================================================== */

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

.service-card {
  position: relative;
  background-color: var(--primary-800);
  border-radius: 12px;
  padding: 3rem 2.25rem 2.25rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  z-index: 1;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  z-index: -2;
  transition: transform var(--transition-slow);
}

.service-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(15, 32, 66, 0.4) 0%, rgba(15, 32, 66, 0.9) 100%);
  z-index: -1;
  transition: background var(--transition-normal);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(37, 99, 235, 0.4);
}

.service-card:hover::before {
  transform: scale(1.1);
}

.service-card:hover .service-card-overlay {
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.45) 0%, rgba(15, 32, 66, 0.95) 100%);
}

.service-card-content {
  color: white;
}

.service-card .service-title {
  font-size: 1.4rem;
  color: white;
  margin-bottom: 0.75rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.service-card .service-desc {
  color: var(--steel-200);
  font-size: 0.95rem;
  line-height: 1.5;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

/* Background image paths updated to categories subfolders */
.service-card.bg-estructuras::before {
  background-image: url('../assets/images/taller.jpg');
}
.service-card.bg-barandillas::before {
  background-image: url('../assets/images/cerramientos/terraza2.jpg');
}
.service-card.bg-escaleras::before {
  background-image: url('../assets/images/escaleras/escalera3.jpg');
}
.service-card.bg-cerramientos::before {
  background-image: url('../assets/images/cerramientos/cierre2.jpg');
}
.service-card.bg-rejas::before {
  background-image: url('../assets/images/rejas/reja1.jpg');
}
.service-card.bg-mobiliario::before {
  background-image: url('../assets/images/otros/botellas.jpg');
}

/* ==========================================================================
   PORTFOLIO GALLERY
   ========================================================================== */

.carousel-container {
  position: relative;
  width: 100%;
}

.carousel-track-wrapper {
  overflow: hidden;
  width: 100%;
  border-radius: 12px;
}

.carousel-track {
  display: flex;
  gap: 1.5rem;
  transition: transform var(--transition-normal) ease-in-out;
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  width: 100%;
}

/* Desktop sizing: 3 slides visible */
@media (min-width: 992px) {
  .carousel-slide {
    flex: 0 0 calc((100% - (1.5rem * 2)) / 3);
  }
}

/* Tablet sizing: 2 slides visible */
@media (min-width: 600px) and (max-width: 991px) {
  .carousel-slide {
    flex: 0 0 calc((100% - 1.5rem) / 2);
  }
}

.gallery-item {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  background-color: var(--bg-card);
  aspect-ratio: 4 / 3;
  cursor: pointer;
  border: 1px solid var(--border-color);
  width: 100%;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.gallery-item:hover {
  transform: scale(1.02) translateY(-4px);
  box-shadow: var(--shadow-md);
}

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

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

.gallery-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, rgba(15, 32, 66, 0.9) 0%, rgba(15, 32, 66, 0.4) 60%, rgba(15, 32, 66, 0) 100%);
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  transition: opacity var(--transition-normal);
}

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

.gallery-title {
  color: white;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.gallery-category {
  color: var(--accent-400);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.gallery-zoom-icon {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  opacity: 0;
  transform: scale(0.8);
  transition: opacity var(--transition-normal), transform var(--transition-normal);
}

.gallery-item:hover .gallery-zoom-icon {
  opacity: 1;
  transform: scale(1);
}

.gallery-zoom-icon svg {
  fill: currentColor;
}

/* Carousel Buttons */
.carousel-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  z-index: 10;
  transition: background-color var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
}

.carousel-nav-btn:hover {
  background-color: var(--accent-500);
  color: white;
  border-color: var(--accent-500);
  transform: translateY(-50%) scale(1.05);
}

.carousel-nav-prev {
  left: -23px;
}

.carousel-nav-next {
  right: -23px;
}

.carousel-nav-btn svg {
  fill: currentColor;
}

/* Hide navigation arrows on small screens and use swipe */
@media (max-width: 768px) {
  .carousel-nav-btn {
    display: none;
  }
}

/* Indicators (dots) */
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--steel-300);
  border: none;
  cursor: pointer;
  transition: background-color var(--transition-fast), width var(--transition-fast), border-radius var(--transition-fast);
}

.carousel-dot:hover {
  background-color: var(--steel-500);
}

.carousel-dot.active {
  width: 24px;
  border-radius: 5px;
  background-color: var(--accent-500);
}

/* ==========================================================================
   ABOUT US SECTION
   ========================================================================== */

.about-row {
  display: flex;
  align-items: center;
  gap: 4rem;
  margin-bottom: 4rem;
}

.about-col-content {
  flex: 1.2;
}

.about-col-img {
  flex: 0.8;
  position: relative;
}

.about-image-wrapper {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  aspect-ratio: 4 / 3;
}

.about-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-image-deco {
  position: absolute;
  bottom: -15px;
  right: -15px;
  width: 100%;
  height: 100%;
  border: 3px solid var(--accent-500);
  border-radius: 12px;
  z-index: -1;
}

.about-lead {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
  color: var(--accent-500);
}

.about-text {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.feature-item {
  display: flex;
  gap: 1rem;
}

.feature-icon {
  color: var(--accent-500);
  flex-shrink: 0;
}

.feature-icon svg {
  fill: currentColor;
}

.feature-title {
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ==========================================================================
   BUDGET CALLOUT SECTION (PRESUPUESTO)
   ========================================================================== */

.budget-callout {
  background: linear-gradient(135deg, var(--primary-800) 0%, var(--primary-600) 100%);
  color: white;
  border-radius: 16px;
  padding: 4rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.05);
  box-shadow: var(--shadow-lg);
}

.budget-callout::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -20%;
  width: 80%;
  height: 200%;
  background: radial-gradient(circle, rgba(37,99,235,0.15) 0%, transparent 70%);
  z-index: 1;
}

.budget-content {
  position: relative;
  z-index: 2;
  max-width: 650px;
  margin: 0 auto;
}

.budget-title {
  color: white;
  font-size: 2.25rem;
  margin-bottom: 1rem;
}

.budget-desc {
  color: var(--steel-200);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

/* ==========================================================================
   CONTACT SECTION
   ========================================================================== */

.contact-row {
  display: flex;
  gap: 3.5rem;
  align-items: flex-start;
}

.contact-info {
  flex: 0.8;
}

.contact-form-wrapper {
  flex: 1.2;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow-md);
}

.contact-info-title {
  font-size: 1.6rem;
  margin-bottom: 1.5rem;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.contact-info-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.contact-info-icon {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background-color: var(--primary-100);
  color: var(--accent-500);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-info-icon svg {
  fill: currentColor;
}

.contact-info-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 0.15rem;
}

.contact-info-value {
  font-size: 1rem;
  font-weight: 500;
}

.contact-map-card {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  aspect-ratio: 16 / 9;
}

.contact-map-iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* Contact Form */
.form-group {
  margin-bottom: 1.25rem;
}

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

.form-control {
  width: 100%;
  background-color: var(--bg-body);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 0.8rem 1rem;
  transition: all var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-500);
  background-color: var(--bg-card);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

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

/* GDPR Checkbox styling */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

.form-check-input {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  margin-top: 0.2rem;
  accent-color: var(--accent-500);
}

.form-check-label {
  font-size: 0.825rem;
  color: var(--text-muted);
  line-height: 1.4;
  cursor: pointer;
}

.form-check-label button {
  background: none;
  border: none;
  color: var(--accent-500);
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}

.form-check-label button:hover {
  color: var(--accent-600);
}

.gdpr-info-box {
  background-color: var(--steel-100);
  border-left: 3px solid var(--steel-500);
  padding: 0.85rem 1rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 1.5rem;
  transition: background-color var(--transition-normal);
}

@media (prefers-color-scheme: dark) {
  .gdpr-info-box {
    background-color: rgba(255, 255, 255, 0.03);
    border-left-color: var(--steel-700);
  }
}

.form-feedback {
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: 0.35rem;
  display: none;
}

.form-feedback.error {
  color: #EF4444;
  display: block;
}

.form-control.is-invalid {
  border-color: #EF4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.form-status {
  padding: 1rem;
  border-radius: 6px;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  display: none;
}

.form-status.success {
  background-color: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: #10B981;
  display: block;
}

.form-status.error {
  background-color: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #EF4444;
  display: block;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

.footer {
  background-color: var(--bg-footer);
  color: var(--steel-300);
  padding: 4rem 0 2rem;
  font-size: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.footer-col-about {
  flex: 1.5;
  max-width: 400px;
}

.footer-col-links {
  flex: 1;
  min-width: 150px;
}

.footer-col-legal {
  flex: 1;
  min-width: 180px;
}

.footer-logo-link {
  display: flex;
  align-items: center;
  margin-bottom: 1.25rem;
}

.footer-logo-img {
  width: 260px;
  height: auto;
  max-width: 100%;
  filter: brightness(0) invert(1);
}

.footer-about-text {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--steel-500);
}

.footer-title {
  color: white;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  position: relative;
}

.footer-title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 30px;
  height: 2px;
  background-color: var(--accent-500);
}

.footer-links-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-link:hover {
  color: white;
}

.footer-legal-btn {
  background: none;
  border: none;
  color: inherit;
  font-size: inherit;
  cursor: pointer;
  padding: 0;
  text-align: left;
  transition: color var(--transition-fast);
}

.footer-legal-btn:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--steel-700);
}

/* ==========================================================================
   PORTFOLIO LIGHTBOX MODAL
   ========================================================================== */

.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(15, 32, 66, 0.95);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

.lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-content-wrapper {
  position: relative;
  max-width: 90%;
  max-height: 85%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-img {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.1);
  transform: scale(0.95);
  transition: transform var(--transition-normal);
}

.lightbox.active .lightbox-img {
  transform: scale(1);
}

.lightbox-caption {
  color: white;
  margin-top: 1rem;
  text-align: center;
}

.lightbox-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: white;
}

.lightbox-category {
  font-size: 0.85rem;
  color: var(--accent-400);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 0.25rem;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: none;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  opacity: 0.8;
  transition: opacity var(--transition-fast);
}

.lightbox-close:hover {
  opacity: 1;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.2);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  cursor: pointer;
  transition: all var(--transition-fast);
  user-select: none;
}

.lightbox-nav:hover {
  background: var(--accent-500);
  border-color: var(--accent-500);
}

.lightbox-prev {
  left: -70px;
}

.lightbox-next {
  right: -70px;
}

.lightbox-nav svg {
  fill: currentColor;
}

/* ==========================================================================
   LEGAL MODAL SYSTEM (Aviso Legal y Privacidad)
   ========================================================================== */

.legal-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(15, 32, 66, 0.6);
  backdrop-filter: blur(4px);
  z-index: 199;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

.legal-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.legal-modal-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  width: 90%;
  max-width: 750px;
  max-height: 80vh;
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: translateY(20px);
  transition: transform var(--transition-normal);
}

.legal-modal.active .legal-modal-card {
  transform: translateY(0);
}

.legal-modal-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.legal-modal-title {
  font-size: 1.5rem;
  font-weight: 700;
}

.legal-modal-close {
  background: none;
  border: none;
  font-size: 1.75rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 1;
}

.legal-modal-close:hover {
  color: var(--text-main);
}

.legal-modal-body {
  padding: 2rem;
  overflow-y: auto;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-muted);
}

.legal-modal-body h3 {
  font-size: 1.15rem;
  color: var(--text-main);
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

.legal-modal-body h3:first-of-type {
  margin-top: 0;
}

.legal-modal-body p {
  margin-bottom: 1rem;
}

.legal-modal-body ul {
  list-style: disc;
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.legal-modal-body ul li {
  margin-bottom: 0.25rem;
}

/* ==========================================================================
   MEDIA QUERIES (RESPONSIVE STYLES)
   ========================================================================== */

@media (max-width: 992px) {
  .hero {
    text-align: center;
  }
  .hero-content {
    max-width: 650px;
    margin: 0 auto;
  }
  .hero-actions {
    justify-content: center;
  }
  .about-row {
    flex-direction: column;
    gap: 2.5rem;
  }
  .about-col-img {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
  }
  .contact-row {
    flex-direction: column;
    gap: 3rem;
  }
  .contact-info, .contact-form-wrapper {
    width: 100%;
  }
  .lightbox-prev {
    left: 10px;
    z-index: 10;
  }
  .lightbox-next {
    right: 10px;
    z-index: 10;
  }
}

@media (max-width: 768px) {
  :root {
    --header-height: 80px;
  }
  
  .nav-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    background-color: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    flex-direction: column;
    padding: 2rem 0;
    gap: 1.5rem;
    box-shadow: var(--shadow-md);
    transform: translateY(-110%);
    opacity: 0;
    pointer-events: none;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
    z-index: 99;
  }
  
  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  
  .nav-toggle {
    display: block;
  }
  
  /* Hamburger state active */
  .nav-toggle.active .hamburger-line:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
  }
  .nav-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
  }
  .nav-toggle.active .hamburger-line:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
  }
  
  .hero-title {
    font-size: 2.75rem;
  }
  .hero-desc {
    font-size: 1.1rem;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-row {
    flex-direction: column;
    gap: 2rem;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2.25rem;
  }
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .btn {
    width: 100%;
  }
  .contact-form-wrapper {
    padding: 1.5rem;
  }
}

/* ==========================================================================
   QA & ACCESSIBILITY ADDITIONS (UI/UX AUDIT REFINE)
   ========================================================================== */

/* Custom high-contrast focus indicators for keyboard navigation */
:focus-visible {
  outline: 3px solid var(--accent-400);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Hardening mobile tap targets for accessibility */
.nav-toggle {
  min-width: 44px;
  min-height: 44px;
}

/* Improve header logo contrast on dark theme backgrounds */
@media (prefers-color-scheme: dark) {
  .logo-img {
    filter: brightness(0) invert(1);
  }
}

/* Prevent carousel navigation arrow overflow on narrow viewports */
@media (max-width: 1240px) {
  .carousel-nav-prev {
    left: 10px;
  }
  .carousel-nav-next {
    right: 10px;
  }
}

