/* Modern CSS Design System for ELKRON S.p.A. Website */

/* 1. Theme Configuration & Variables */
:root {
  /* Brand color (Elkron red) */
  --color-primary: #E30613;
  --color-primary-hover: #b8050e;
  --color-primary-glow: rgba(227, 6, 19, 0.35);
  --color-success: #10b981;
  --color-warning: #f59e0b;
  --color-error: #ef4444;
  /* Accent palette repointed to brand red: the design originally used a sky-blue
     accent for nav underlines, buttons, links and highlights. Mapping these
     variables to red makes the whole UI use Elkron red as the secondary color
     without touching every individual rule. */
  --color-link-blue: #E30613;
  --color-link-blue-hover: #b8050e;
  --color-link-blue-glow: rgba(227, 6, 19, 0.22);

  /* Fonts */
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --transition-speed: 0.3s;
  --transition-bezier: cubic-bezier(0.4, 0, 0.2, 1);
  --border-radius: 12px;

  /* Light theme — white background with red accent */
  --color-bg: #ffffff;
  /* White page background */
  --color-bg-alt: #f5f6f8;
  /* Light gray for panels / alt surfaces */
  --color-card-bg: #ffffff;
  /* Solid white cards */
  --color-card-border: #e6e8eb;
  /* Soft gray card border */
  --color-text: #1a1d23;
  /* Near-black body text */
  --color-text-muted: #5f6b7a;
  /* Muted slate-gray text */
  --color-border: #e6e8eb;
  /* Soft gray border */
  --color-shadow: rgba(15, 23, 42, 0.08);
  --color-glow: rgba(227, 6, 19, 0.12);
  /* Subtle red glow */
  --color-code-bg: #f3f4f6;
  --color-input-bg: #ffffff;
}

/* 2. Global Resets & Typography */
::selection {
  background-color: var(--color-link-blue-glow);
  color: #ffffff;
}

/* General Link Styling (excluding buttons, nav items, and logo links) */
a:not(.btn):not(.nav-item):not(.mobile-nav-item):not(.logo-link) {
  color: var(--color-link-blue);
  transition: color var(--transition-speed);
}

a:not(.btn):not(.nav-item):not(.mobile-nav-item):not(.logo-link):hover {
  color: var(--color-link-blue-hover);
  text-decoration: underline;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color var(--transition-speed) var(--transition-bezier),
    color var(--transition-speed) var(--transition-bezier);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-speed);
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* Scrollbar customization */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-alt);
}

::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-text-muted);
}

/* 3. Header & Navigation */
.app-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  background-color: rgba(255, 255, 255, 0.85);
  /* White semi-transparent */
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-card-border);
  z-index: 100;
  display: flex;
  align-items: center;
  box-shadow: 0 4px 30px var(--color-shadow);
}

.header-container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-link {
  display: flex;
  align-items: center;
}

.urmet-logo-svg {
  height: 34px;
  width: auto;
}

.nav-menu {
  display: flex;
  gap: 2rem;
}

.nav-item {
  font-size: 0.95rem;
  font-weight: 500;
  padding: 0.5rem 0.2rem;
  color: var(--color-text-muted);
  position: relative;
}

.nav-item:hover,
.nav-item.active {
  color: var(--color-text);
}

.nav-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-link-blue);
  transition: width var(--transition-speed) var(--transition-bezier);
  box-shadow: 0 0 10px var(--color-link-blue-glow);
}

.nav-item:hover::after,
.nav-item.active::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.action-btn {
  background: none;
  border: 1px solid var(--color-card-border);
  padding: 0.6rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-card-bg);
  box-shadow: 0 2px 10px var(--color-shadow);
  transition: all var(--transition-speed) var(--transition-bezier);
}

.action-btn:hover {
  border-color: var(--color-primary);
  transform: translateY(-2px);
}

.lang-btn {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.lang-btn .active-lang {
  color: var(--color-link-blue);
}

.lang-btn .inactive-lang {
  color: var(--color-text-muted);
}

.mobile-toggle-btn {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: none;
  border: none;
  cursor: pointer;
}

.mobile-toggle-btn span {
  width: 100%;
  height: 2px;
  background-color: var(--color-text);
  border-radius: 2px;
  transition: all var(--transition-speed);
}

/* Mobile Nav Dropdown */
.mobile-menu-overlay {
  position: fixed;
  top: 80px;
  left: 0;
  width: 100%;
  background-color: var(--color-bg);
  border-bottom: 1px solid var(--color-card-border);
  z-index: 99;
  display: none;
  padding: 1.5rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  animation: slideDown 0.3s var(--transition-bezier);
}

.mobile-menu-overlay.open {
  display: block;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-nav-item {
  font-size: 1.1rem;
  font-weight: 500;
  padding: 0.8rem 1rem;
  border-radius: 6px;
  color: var(--color-text-muted);
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
  color: var(--color-text);
  background-color: var(--color-card-bg);
  border-left: 3px solid var(--color-link-blue);
}

/* 4. Disclaimer Banner */
.disclaimer-banner {
  position: relative;
  margin-top: 100px;
  margin-left: auto;
  margin-right: auto;
  width: calc(100% - 4rem);
  max-width: 1400px;
  background: linear-gradient(135deg, rgba(227, 6, 19, 0.08) 0%, rgba(245, 158, 11, 0.08) 100%);
  border: 1px solid rgba(227, 6, 19, 0.25);
  border-radius: var(--border-radius);
  padding: 1.25rem 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  display: flex;
  animation: pulseDisclaimer 4s infinite alternate, fadeIn 0.5s ease-out;
  z-index: 10;
}

.disclaimer-content {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  width: 100%;
}

.disclaimer-icon {
  color: var(--color-primary);
  flex-shrink: 0;
  display: flex;
  margin-top: 0.25rem;
}

.disclaimer-text-box h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.25rem;
  letter-spacing: 0.02em;
}

.disclaimer-text-box p {
  font-size: 0.95rem;
  color: var(--color-text);
  opacity: 0.9;
}

.disclaimer-close-btn {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  font-size: 1.2rem;
  padding: 0.2rem;
  align-self: flex-start;
  margin-left: auto;
  transition: color var(--transition-speed);
}

.disclaimer-close-btn:hover {
  color: var(--color-primary);
}

/* 5. Base Layout Units */
.main-content {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
  min-height: calc(100vh - 200px);
}

.page-section {
  display: none;
  animation: fadeIn 0.4s var(--transition-bezier);
}

.page-section.active {
  display: block;
}

.section-header {
  margin-bottom: 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 1rem;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 1rem;
}

.section-header h2 {
  font-size: 2.2rem;
  position: relative;
}

.section-header h2::after {
  content: '';
  position: absolute;
  bottom: -1rem;
  left: 0;
  width: 80px;
  height: 3px;
  background-color: var(--color-link-blue);
}

.section-lead {
  color: var(--color-text-muted);
  font-size: 1.1rem;
  margin-top: 0.5rem;
  max-width: 800px;
}

/* Cards & Elements */
.glass-card {
  background-color: var(--color-card-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--color-card-border);
  border-radius: var(--border-radius);
  padding: 2rem;
  box-shadow: 0 10px 30px var(--color-shadow);
  transition: transform var(--transition-speed) var(--transition-bezier),
    border-color var(--transition-speed) var(--transition-bezier),
    box-shadow var(--transition-speed) var(--transition-bezier);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-speed) var(--transition-bezier);
  border: none;
  font-family: var(--font-body);
}

.btn-primary {
  background-color: var(--color-link-blue);
  color: #ffffff;
  box-shadow: 0 4px 15px var(--color-link-blue-glow);
}

.btn-primary:hover {
  background-color: var(--color-link-blue-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--color-link-blue-glow);
}

.btn-secondary {
  background-color: rgba(227, 6, 19, 0.08);
  border: 1px solid var(--color-link-blue);
  color: var(--color-link-blue);
}

.btn-secondary:hover {
  background-color: rgba(227, 6, 19, 0.16);
  border-color: var(--color-link-blue-hover);
  color: var(--color-link-blue-hover);
  transform: translateY(-2px);
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text);
}

input[type="text"],
input[type="email"],
select,
textarea {
  background-color: var(--color-input-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  outline: none;
  font-size: 0.95rem;
  transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
}

input[type="text"]:focus,
input[type="email"]:focus,
select:focus,
textarea:focus {
  border-color: var(--color-link-blue);
  box-shadow: 0 0 0 3px var(--color-link-blue-glow);
}

/* 6. Home Section Specifics */
#section-home.active {
  position: relative;
  min-height: calc(100vh - 280px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-radius: var(--border-radius);
  overflow: hidden;
  padding: 4rem 2rem;
  background: radial-gradient(circle at center, rgba(227, 6, 19, 0.03) 0%, transparent 70%);
}

#section-home::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('../images/medea_background.jpg');
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.12;
  /* slightly visible background watermark */
  z-index: 0;
  pointer-events: none;
}

#section-home>* {
  position: relative;
  z-index: 1;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(227, 6, 19, 0.3);
  box-shadow: 0 15px 40px var(--color-glow);
}

.card-icon {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  background-color: var(--color-primary);
  /* red tile so the white SVG icons read on a light page */
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  border: 1px solid var(--color-primary);
}

.feature-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.feature-card p {
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  min-height: 80px;
}

.card-link {
  font-weight: 600;
  color: var(--color-link-blue);
  display: inline-block;
}

.card-link:hover {
  color: var(--color-link-blue-hover);
  text-decoration: underline;
}

/* 7. Products Section Specifics */
.bq-badge-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid var(--color-border);
  background-color: var(--color-card-bg);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.status-dot.green {
  background-color: var(--color-success);
  box-shadow: 0 0 10px var(--color-success);
}

.status-dot.orange {
  background-color: var(--color-warning);
  box-shadow: 0 0 10px var(--color-warning);
}

.search-block {
  margin-bottom: 1.5rem;
  padding: 1.5rem;
}

.search-form {
  display: flex;
  gap: 1rem;
}

.input-container {
  flex-grow: 1;
  position: relative;
}

.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted);
}

.input-container input {
  width: 100%;
  padding-left: 3rem;
}

/* Developer Console Panel */
.developer-log-panel {
  margin-bottom: 2rem;
  padding: 0;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--color-border);
}

.developer-log-panel .panel-header {
  background-color: var(--color-bg-alt);
  padding: 0.8rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--color-border);
}

.developer-log-panel h4 {
  font-size: 0.85rem;
  font-family: monospace;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
}

.panel-toggle-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text-muted);
  font-size: 0.75rem;
  transition: transform 0.2s;
}

.developer-log-panel.collapsed .panel-body {
  display: none;
}

.developer-log-panel.collapsed .panel-toggle-btn {
  transform: rotate(-90deg);
}

.developer-log-panel .panel-body {
  padding: 1rem 1.5rem;
  background-color: var(--color-code-bg);
}

.sql-code-block {
  font-family: Consolas, Monaco, 'Andale Mono', monospace;
  font-size: 0.85rem;
  color: #a5f3fc;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-all;
  max-height: 150px;
}

.query-stats-row {
  margin-top: 0.75rem;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--color-border);
  display: flex;
  gap: 2rem;
  font-size: 0.75rem;
  font-family: monospace;
  color: var(--color-text-muted);
}

/* Results grid */
.results-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.search-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 4rem 2rem;
  color: var(--color-text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.product-card .card-thumb {
  height: 180px;
  background-color: var(--color-bg-alt);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  border: 1px solid var(--color-border);
  overflow: hidden;
  padding: 1rem;
}

.product-card h4 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
  min-height: 48px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card .prod-code {
  font-size: 0.8rem;
  font-family: monospace;
  background-color: var(--color-border);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  width: fit-content;
  margin-bottom: 0.75rem;
  color: var(--color-text-muted);
}

.product-card .prod-desc {
  color: var(--color-text-muted);
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card .card-footer {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.product-card .prod-price {
  font-weight: 700;
  font-size: 1.1rem;
}

/* Modal Overlay details */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeIn 0.3s;
}

.modal-overlay.open {
  display: flex;
}

.modal-card {
  width: 100%;
  max-width: 900px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  padding: 3rem;
  animation: scaleIn 0.3s var(--transition-bezier);
}

.modal-close-btn {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-text-muted);
  transition: color var(--transition-speed);
}

.modal-close-btn:hover {
  color: var(--color-primary);
}

.modal-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2.5rem;
}

.modal-img-col {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.modal-img-container {
  height: 280px;
  background-color: var(--color-bg-alt);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  padding: 1.5rem;
}

.modal-info-col {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.modal-info-col h3 {
  font-size: 1.8rem;
  color: var(--color-text);
}

.info-badge-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.info-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.3rem 0.75rem;
  border-radius: 4px;
  background-color: var(--color-border);
}

.info-badge.brand {
  background-color: var(--color-primary-glow);
  border: 1px solid rgba(227, 6, 19, 0.3);
  color: var(--color-text);
}

.modal-desc {
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

.modal-specs-table {
  width: 100%;
  border-collapse: collapse;
}

.modal-specs-table tr {
  border-bottom: 1px solid var(--color-border);
}

.modal-specs-table td {
  padding: 0.5rem 0;
  font-size: 0.85rem;
}

.modal-specs-table td:first-child {
  font-weight: 600;
  color: var(--color-text);
  width: 35%;
}

.modal-price-stock {
  display: flex;
  justify-content: space-between;
  padding: 1rem;
  background-color: var(--color-bg-alt);
  border-radius: 8px;
  border: 1px solid var(--color-border);
}

/* Spinner */
.loader-container {
  display: none;
  justify-content: center;
  padding: 4rem;
}

.glowing-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(227, 6, 19, 0.12);
  border-radius: 50%;
  border-top-color: var(--color-link-blue);
  animation: spin 1s linear infinite, glowPulse 2s infinite ease-in-out;
}

/* 8. Product Manuals (inside product detail modal) */
.modal-manual-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  margin-bottom: 0.6rem;
  background-color: rgba(255, 255, 255, 0.02);
}

.modal-manual-icon {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  border: 1px solid var(--color-border);
  border-radius: 8px;
}

.modal-manual-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex-grow: 1;
}

.modal-manual-title {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.3;
}

.modal-manual-summary {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.modal-manual-download {
  flex-shrink: 0;
  gap: 0.4rem;
  white-space: nowrap;
}

/* 9. Configurator Section Specifics */
.configurator-wrapper {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.steps-progress-bar {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin-bottom: 1rem;
  padding: 0 1rem;
}

.progress-line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-border);
  transform: translateY(-50%);
  z-index: 1;
}

#config-progress-line {
  background-color: var(--color-primary);
  width: 0%;
  transition: width 0.4s ease;
  box-shadow: 0 0 8px var(--color-primary-glow);
}

.step-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--color-bg-alt);
  border: 2px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.85rem;
  z-index: 2;
  transition: all 0.3s;
}

.step-dot.active {
  border-color: var(--color-primary);
  background-color: var(--color-primary);
  color: #ffffff;
  box-shadow: 0 0 12px var(--color-primary-glow);
}

.step-dot.completed {
  border-color: var(--color-primary);
  background-color: var(--color-bg);
  color: var(--color-primary);
}

.configurator-body {
  min-height: 380px;
}

.config-step-panel {
  display: none;
  animation: fadeIn 0.4s var(--transition-bezier);
}

.config-step-panel.active {
  display: block;
}

.config-step-panel h3 {
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
}

.choices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.choice-card {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 2rem;
  border-radius: var(--border-radius);
  border: 2px solid var(--color-card-border);
  background-color: var(--color-card-bg);
  transition: all var(--transition-speed) var(--transition-bezier);
}

.choice-card:hover {
  border-color: var(--color-border);
  transform: translateY(-4px);
}

.choice-card.selected {
  border-color: var(--color-primary);
  background-color: rgba(227, 6, 19, 0.02);
  box-shadow: 0 0 20px var(--color-glow);
}

.choice-svg-panel {
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.choice-card h4 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.choice-card p {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}

.choice-price {
  margin-top: auto;
  font-weight: 700;
  color: var(--color-primary);
  font-size: 1.1rem;
}

.configurator-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

/* Step 5 Summary */
.summary-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 2rem;
}

.summary-details h4 {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 0.5rem;
}

.summary-spec-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.summary-spec-item span:first-child {
  font-weight: 600;
}

.summary-bom-panel {
  padding: 1.5rem;
}

.bom-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 2rem;
}

.bom-table th,
.bom-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
  font-size: 0.85rem;
}

.bom-table th {
  font-weight: 700;
  color: var(--color-text-muted);
  background-color: var(--color-bg-alt);
}

.bom-total-price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary);
}

.text-right {
  text-align: right !important;
}

.bom-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

/* 10. Contacts Section Specifics */
.contacts-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2.5rem;
}

.contact-form-panel {
  position: relative;
}

.contact-form-panel h3,
.contact-info-panel h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 0.5rem;
}

.error-msg {
  color: var(--color-error);
  font-size: 0.75rem;
  margin-top: 0.25rem;
  min-height: 1rem;
}

.form-success-banner {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-card-bg);
  backdrop-filter: blur(16px);
  border-radius: var(--border-radius);
  z-index: 10;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 3rem;
  text-align: center;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--color-success);
  animation: fadeIn 0.4s;
}

.form-success-banner svg {
  color: var(--color-success);
  width: 64px;
  height: 64px;
}

.office-select {
  width: 100%;
  margin-bottom: 1.5rem;
}

.office-details-card {
  background-color: var(--color-bg-alt);
  border-radius: 8px;
  padding: 1.5rem;
  border: 1px solid var(--color-border);
  margin-bottom: 1.5rem;
}

.office-details-card h4 {
  font-size: 1.2rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.office-detail-row {
  display: flex;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
}

.office-detail-row span:first-child {
  font-weight: 600;
  width: 100px;
  flex-shrink: 0;
}

.italy-map-placeholder {
  height: 250px;
  background-color: var(--color-bg-alt);
  border-radius: 8px;
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.italy-map-svg {
  height: 100%;
  width: auto;
}

.map-glow-ring {
  fill: var(--color-primary-glow);
  opacity: 0.3;
  animation: ringPulse 2s infinite;
  transform-origin: center;
}

/* 11. Footer */
.app-footer {
  background-color: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  padding: 3rem 2rem;
  margin-top: 5rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.footer-container {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-corporate-info {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  opacity: 0.7;
}

.footer-info a {
  color: var(--color-link-blue);
  text-decoration: none;
  transition: opacity var(--transition-speed);
}

.footer-info a:hover {
  text-decoration: underline;
  opacity: 0.8;
}

.footer-code-tag {
  font-family: monospace;
  background-color: var(--color-border);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

/* 12. Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-20px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

@keyframes glowPulse {

  0%,
  100% {
    box-shadow: 0 0 10px rgba(227, 6, 19, 0.2);
  }

  50% {
    box-shadow: 0 0 25px rgba(227, 6, 19, 0.45);
  }
}

@keyframes ringPulse {
  0% {
    r: 5px;
    opacity: 0.8;
  }

  100% {
    r: 15px;
    opacity: 0;
  }
}

@keyframes pulseDisclaimer {
  0% {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border-color: rgba(227, 6, 19, 0.25);
  }

  100% {
    box-shadow: 0 10px 35px rgba(227, 6, 19, 0.08);
    border-color: rgba(227, 6, 19, 0.45);
  }
}

/* 13. Responsive Media Queries */
@media (max-width: 1024px) {
  .hero-block h1 {
    font-size: 2.8rem;
  }

  .summary-layout {
    grid-template-columns: 1fr;
  }

  .contacts-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none;
  }

  .mobile-toggle-btn {
    display: flex;
  }

  .header-container {
    padding: 0 1rem;
  }

  .disclaimer-banner {
    width: calc(100% - 2rem);
    padding: 1rem;
  }

  .main-content {
    padding: 1rem;
  }

  .hero-block {
    flex-direction: column;
    text-align: center;
    padding: 3rem 1.5rem;
    gap: 2rem;
  }

  .hero-block h1 {
    font-size: 2.2rem;
  }

  .modal-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .modal-card {
    padding: 1.5rem;
  }

  .search-form {
    flex-direction: column;
  }

  .bom-actions {
    flex-direction: column;
  }

  .bom-actions button {
    width: 100%;
  }

  .footer-container {
    flex-direction: column;
    text-align: center;
  }
}

/* Image styles for products and modals */
.product-card .card-thumb img,
.modal-img-container img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 4px;
}

/* 8. Certifications Section Specifics */
.certifications-intro {
  margin-bottom: 3rem;
  text-align: center;
  padding: 3.5rem 2rem;
}

.certifications-intro h3 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  color: var(--color-link-blue);
  font-family: var(--font-display);
}

.certifications-intro p {
  max-width: 900px;
  margin: 0 auto 1.5rem;
  color: var(--color-text-muted);
  line-height: 1.7;
  font-size: 1.05rem;
}

.certifications-intro strong {
  font-size: 1.15rem;
  color: var(--color-text);
  display: block;
  margin-top: 1.5rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.certifications-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2rem;
  margin-bottom: 3.5rem;
}

.cert-doc-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.cert-doc-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.cert-doc-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.iso-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.iso-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: center;
  padding: 2.5rem 2rem;
}

.iso-card-icon-wrapper {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.iso-card h4 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.iso-card p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  min-height: 120px;
}

/* ==========================================================================
   NEWS SECTION
   ========================================================================== */
.news-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 900px;
  margin: 2rem auto;
}

.news-card {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 2.5rem;
  background-color: var(--color-card-bg);
  border: 1px solid var(--color-card-border);
  border-radius: var(--border-radius);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 10px 30px var(--color-shadow);
  transition: transform var(--transition-speed) var(--transition-bezier),
              border-color var(--transition-speed) var(--transition-bezier),
              box-shadow var(--transition-speed) var(--transition-bezier);
}

.news-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-link-blue);
  box-shadow: 0 15px 40px var(--color-glow);
}

.news-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px dashed var(--color-border);
  padding-bottom: 0.75rem;
}

.news-date {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  font-weight: 500;
  font-family: monospace;
}

.news-badge {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
}

.news-badge.badge-warning {
  background-color: rgba(245, 158, 11, 0.15);
  border: 1px solid var(--color-warning);
  color: var(--color-warning);
}

.news-card-title {
  font-size: 1.8rem;
  color: var(--color-text);
  line-height: 1.3;
}

.news-card-preview {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.news-card-details {
  border-top: 1px solid var(--color-border);
  padding-top: 1.25rem;
  margin-top: 0.5rem;
}

.news-read-more {
  list-style: none;
  cursor: pointer;
  outline: none;
  font-weight: 600;
  color: var(--color-link-blue);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  user-select: none;
  transition: color var(--transition-speed);
}

.news-read-more::-webkit-details-marker {
  display: none;
}

.news-read-more:hover {
  color: var(--color-link-blue-hover);
}

.news-read-more::after {
  content: '→';
  display: inline-block;
  transition: transform var(--transition-speed) var(--transition-bezier);
}

.news-card-details[open] .news-read-more::after {
  transform: rotate(90deg);
}

.news-full-content {
  margin-top: 1.5rem;
  font-size: 1rem;
  color: var(--color-text);
  line-height: 1.7;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.news-full-content p {
  margin-bottom: 0.5rem;
}

.news-full-content strong {
  color: var(--color-text);
}

.news-full-content a {
  color: var(--color-link-blue);
  text-decoration: none;
  border-bottom: 1px dashed var(--color-link-blue);
  transition: all var(--transition-speed);
}

.news-full-content a:hover {
  color: var(--color-link-blue-hover);
  border-bottom-style: solid;
}

@media (max-width: 768px) {
  .news-card {
    padding: 1.75rem;
  }
  .news-card-title {
    font-size: 1.5rem;
  }
}