/* CSS Variables */
:root {
  --primary: #000000;
  --primary-foreground: #FFFFFF;
  --secondary: #8b5cf6;
  --secondary-foreground: #FFFFFF;
  --accent: #16a34a;
  --accent-foreground: #111827;
  --background: #FFFFFF;
  --foreground: #111827;
  --card: #FFFFFF;
  --card-foreground: #111827;
  --border: #E5E7EB;
  --input: #E5E7EB;
  --ring: #000000;
  --muted: #F3F4F6;
  --muted-foreground: #6B7280;
  --font-family: 'Open Sans', sans-serif;
  --radius: 0.5rem;
}

/* Global Styles */
* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  line-height: 1.6;
  color: var(--foreground);
  background: var(--background);
  margin: 0;
  padding: 0;
  overflow-wrap: break-word;
}

/* Hidden Utility */
.hidden {
  display: none !important;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 1rem 0;
  font-weight: 600;
  line-height: 1.3;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin: 0 0 1rem 0;
}

/* Links */
a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.text-primary { color: var(--primary); }
.text-muted { color: var(--muted-foreground); }
.text-lg { font-size: 1.125rem; }
.text-sm { font-size: 0.875rem; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }
.mb-4 { margin-bottom: 1rem; }

/* Buttons */
.btn-primary, .btn-outline, .btn-outline-white, .btn-link {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 500;
  text-align: center;
  transition: all 0.3s ease;
  border: 2px solid;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-foreground);
  border-color: var(--primary);
}

.btn-primary:hover {
  background: var(--secondary);
  border-color: var(--secondary);
  color: var(--secondary-foreground);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.btn-outline:hover {
  background: var(--primary);
  color: var(--primary-foreground);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.btn-outline:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-outline-white {
  background: transparent;
  color: #fff;
  border-color: #fff;
}

.btn-outline-white:hover {
  background: #fff;
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(255, 255, 255, 0.2);
}

.btn-link {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  padding: 0.75rem 0;
  box-shadow: none;
  text-decoration: underline;
}

.btn-link:hover {
  color: #fff;
  transform: none;
  box-shadow: none;
}

/* Grid Layouts */
.grid-2, .grid-3 {
  display: grid;
  gap: 2rem;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 768px) {
  .grid-2, .grid-3 {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* Header & Navigation */
.header {
  background: var(--background);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.navbar {
  padding: 1rem 0;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand .logo-img {
  height: 40px;
  width: auto;
}

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

.nav-links a {
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--secondary);
}

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

.krimolaste-top_mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--background);
  border-bottom: 1px solid var(--border);
  padding: 1rem;
  flex-direction: column;
  gap: 1rem;
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .krimolaste-top_mobile-menu-toggle {
    display: block;
  }
  
  .krimolaste-top_mobile-menu:not(.hidden) {
    display: flex;
  }
}

/* Hero Section */
.hero {
  background: var(--primary);
  color: #fff;
  padding: 4rem 0;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.hero-subtitle {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  .9;
}

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

@media (max-width: 768px) {
  .hero {
    padding: 3rem 0;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 1.125rem;
  }
  
  .hero-actions {
    flex-direction: column;
    align-items: center;
  }
}

/* Page Header */
.page-header {
  padding: 3rem 0;
  text-align: center;
  background: var(--muted);
}

.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.page-header p {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 600px;
  margin: 0 auto;
}

/* Sections */
section {
  padding: 3rem 0;
}

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

/* Icons */
.icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  margin-bottom: 1rem;
  flex-shrink: 0;
}

.icon-sm { width: 1rem; height: 1rem; }
.icon-md { width: 1.5rem; height: 1.5rem; }
.icon-lg { width: 2rem; height: 2rem; }
.icon-xl { width: 3rem; height: 3rem; }

/* Cards */
.service-card, .feature-card, .pricing-card, .team-card, .achievement-card, .value-card, .faq-card, .contact-option, .included-item, .stat-item, .process-step, .logo-item, .contact-info-item, .timeline-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.service-card:hover, .feature-card:hover, .pricing-card:hover, .team-card:hover, .achievement-card:hover, .value-card:hover, .faq-card:hover, .contact-option:hover, .included-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.pricing-card.featured {
  position: relative;
  border-color: var(--primary);
  transform: scale(1.02);
}

.popular-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: var(--accent-foreground);
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
}

/* Lists */
.feature-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
  text-align: left;
}

.feature-list li {
  padding: 0.5rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.feature-icon {
  color: var(--accent);
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
}

.values-list {
  list-style: none;
  padding: 0;
  text-align: left;
}

.values-list li {
  margin-bottom: 0.5rem;
}

/* Forms */
.form-input {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--input);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--ring);
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

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

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.krimolaste-top_contact-form {
  max-width: 600px;
  margin: 0 auto;
}

.success-message {
  background: #f0f9f0;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin-top: 2rem;
}

.success-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.success-icon {
  color: var(--accent);
  width: 3rem;
  height: 3rem;
}

/* Service Sections */
.service-section {
  padding: 3rem 0;
}

.service-content {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 3rem;
  align-items: center;
}

.service-content.reverse {
  grid-template-columns: 1fr auto;
}

.service-content.reverse .service-icon {
  order: 2;
}

.service-content.reverse .service-text {
  order: 1;
}

.service-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.service-text {
  text-align: left;
}

@media (max-width: 768px) {
  .service-content,
  .service-content.reverse {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .service-content.reverse .service-icon,
  .service-content.reverse .service-text {
    order: unset;
  }
}

/* Timeline */
.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border);
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.timeline-item:nth-child(odd) {
  flex-direction: row;
}

.timeline-item:nth-child(even) {
  flex-direction: row-reverse;
}

.timeline-marker {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  z-index: 1;
}

.timeline-year {
  background: var(--primary);
  color: var(--primary-foreground);
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.timeline-icon {
  background: var(--background);
  border: 2px solid var(--primary);
  border-radius: 50%;
  padding: 0.5rem;
  color: var(--primary);
}

.timeline-content {
  flex: 1;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

@media (max-width: 768px) {
  .timeline::before {
    left: 1rem;
  }
  
  .timeline-item,
  .timeline-item:nth-child(even) {
    flex-direction: row;
    margin-left: 2rem;
  }
  
  .timeline-marker {
    position: absolute;
    left: -2rem;
  }
  
  .timeline-content {
    margin-left: 1rem;
  }
}

/* Stats */
.stats-counter {
  background: var(--muted);
}

.stat-item {
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.stat-label {
  color: var(--muted-foreground);
  font-weight: 500;
}

/* Process Steps */
.process-step {
  position: relative;
  text-align: center;
}

.step-number {
  position: absolute;
  top: -10px;
  right: -10px;
  background: var(--accent);
  color: var(--accent-foreground);
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
}

/* Newsletter */
.newsletter {
  background: var(--muted);
  text-align: center;
}

.newsletter-content {
  max-width: 600px;
  margin: 0 auto;
}

.newsletter-form {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

@media (max-width: 768px) {
  .newsletter-form {
    flex-direction: column;
  }
}

/* Partner Logos */
.partner-logos {
  text-align: center;
}

.logo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.logo-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

@media (max-width: 768px) {
  .logo-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Team */
.team-avatar {
  margin-bottom: 1.5rem;
}

.avatar-icon {
  width: 5rem;
  height: 5rem;
  color: var(--muted-foreground);
}

.team-role {
  color: var(--muted-foreground);
  font-weight: 500;
  margin-bottom: 1rem;
}

.team-description {
  text-align: left;
  flex-grow: 1;
}

/* FAQ */
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 1rem;
  overflow: hidden;
}

.faq-question {
  padding: 1.5rem;
  background: var(--card);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background-color 0.3s ease;
}

.faq-question:hover {
  background: var(--muted);
}

.faq-question h3 {
  margin: 0;
  font-size: 1.125rem;
}

.faq-icon {
  transition: transform 0.3s ease;
  flex-shrink: 0;
  margin-left: 1rem;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 1.5rem;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item.active .faq-answer {
  padding: 1.5rem;
  max-height: 500px;
}

.faq-answer ul, .faq-answer ol {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.faq-answer li {
  margin-bottom: 0.5rem;
}

/* Contact */
.contact-info-bar {
  background: var(--muted);
}

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

.business-hours {
  background: var(--muted);
  text-align: center;
}

.business-hours-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  max-width: 600px;
  margin: 0 auto;
}

.hours-info {
  text-align: left;
}

.hours-note {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  margin-top: 1rem;
}

@media (max-width: 768px) {
  .business-hours-content {
    flex-direction: column;
    text-align: center;
  }
  
  .hours-info {
    text-align: center;
  }
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.pricing-features {
  margin: 2rem 0;
  text-align: left;
  flex-grow: 1;
}

.pricing-features h4 {
  margin-bottom: 1rem;
  font-size: 1rem;
}

.pricing-ideal {
  margin: 1.5rem 0;
  padding: 1rem;
  background: var(--muted);
  border-radius: var(--radius);
  text-align: left;
}

.pricing-ideal h4 {
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.pricing-ideal p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted-foreground);
}

@media (max-width: 768px) {
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  
  .pricing-card.featured {
    transform: none;
  }
}

/* Cookie Table */
.cookie-table {
  margin: 2rem 0;
  overflow-x: auto;
}

.cookie-table table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--border);
}

.cookie-table th,
.cookie-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.cookie-table th {
  background: var(--muted);
  font-weight: 600;
}

/* Legal Content */
.legal-content {
  padding: 2rem 0;
}

.legal-document {
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.7;
}

.legal-document h2 {
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.legal-document h3 {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.legal-document ul {
  margin: 1rem 0;
  padding-left: 2rem;
}

.legal-document li {
  margin-bottom: 0.5rem;
}

/* CTA Section */
.cta {
  background: var(--primary);
  color: #fff;
  text-align: center;
  padding: 4rem 0;
}

.cta-content {
  max-width: 800px;
  margin: 0 auto;
}

.cta h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.cta p {
  font-size: 1.125rem;
  margin-bottom: 2rem;
  .9;
}

.cta-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .cta {
    padding: 3rem 0;
  }
  
  .cta h2 {
    font-size: 2rem;
  }
  
  .cta-actions {
    flex-direction: column;
    align-items: center;
  }
}

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

.footer a {
  color: rgba(255, 255, 255, 0.85);
}

.footer a:hover {
  color: #fff;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-column h4 {
  margin-bottom: 1rem;
  color: #fff;
}

.footer-logo {
  height: 40px;
  width: auto;
  margin-bottom: 1rem;
}

.footer-tagline {
  font-size: 0.875rem;
  .8;
}

.footer-links-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

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

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.875rem;
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  text-align: center;
  font-size: 0.875rem;
  .8;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .footer-links-group {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Cookie Banner & Modal */
.krimolaste-top_cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--background);
  border-top: 1px solid var(--border);
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  padding: 1rem 0;
}

.krimolaste-top_cookie-banner-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}

.krimolaste-top_cookie-banner-text {
  flex: 1;
}

.krimolaste-top_cookie-banner-actions {
  display: flex;
  gap: 1rem;
  flex-shrink: 0;
}

.krimolaste-top_cookie-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.krimolaste-top_cookie-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  cursor: pointer;
}

.krimolaste-top_cookie-modal-content {
  position: relative;
  background: var(--background);
  border-radius: var(--radius);
  padding: 2rem;
  max-width: 500px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
}

.cookie-toggles {
  margin: 1.5rem 0;
}

.krimolaste-top_cookie-toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.krimolaste-top_cookie-toggle-row:last-child {
  border-bottom: none;
}

.krimolaste-top_cookie-modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
}

@media (max-width: 768px) {
  .krimolaste-top_cookie-banner-inner {
    flex-direction: column;
    text-align: center;
  }
  
  .krimolaste-top_cookie-banner-actions {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .krimolaste-top_cookie-modal-actions {
    flex-direction: column;
  }
}

/* Animation Classes */
.animate-slide-in-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.animate-slide-in-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.animate-in {
  opacity: 1;
  transform: translateX(0);
}

/* Animation target elements */
.service-card,
.feature-card,
.pricing-card,
.team-card,
.achievement-card,
.value-card,
.faq-card,
.contact-option,
.included-item,
.stat-item,
.process-step,
.logo-item,
.timeline-item {
  
  transform: translateX(-40px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .container {
    padding: 0 2rem;
  }
}

@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  
  section {
    padding: 2rem 0;
  }
  
  .section-title {
    margin-bottom: 2rem;
  }
  
  .icon-box {
    width: 3rem;
    height: 3rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }
  
  .hero-title {
    font-size: 1.75rem;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
}

/* === BASELINE SAFETY CSS (injected by engine) === */

/* Ensure .hidden works consistently even with ID-specific overrides */
.hidden { display: none !important; }

/* Prevent content overflow breaking layout */
img, video, iframe { max-width: 100%; height: auto; }
* { box-sizing: border-box; }

/* Ensure container has responsive padding */
.container { width: 100%; max-width: 1200px; margin-left: auto; margin-right: auto; padding-left: 1rem; padding-right: 1rem; }

/* Prevent flex/grid children from overflowing */
.grid-2, .grid-3, .grid-4 { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Responsive grid fallbacks */
@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}
@media (min-width: 769px) and (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* Ensure forms don't break layout */
.form-input, input[type="text"], input[type="email"], input[type="tel"], textarea, select {
  width: 100%;
  max-width: 100%;
}

/* Success message styling */
.success-message {
  margin-top: 1rem;
  padding: 1rem;
  background: #ecfdf5;
  border: 1px solid #6ee7b7;
  border-radius: 0.5rem;
  color: #065f46;
  text-align: center;
}

/* Stacking context for hero sections — prevents z-index:-1 children from going behind the page */
.hero, .hero-section, .page-header, .cta, .cta-section { isolation: isolate; position: relative; }

/* Desktop nav injected by engine — show on desktop, hide on mobile */
.nav-menu { display: flex; align-items: center; gap: 1.5rem; }
.nav-menu .nav-link { text-decoration: none; color: var(--foreground, #1f2937); font-weight: 500; font-size: 0.95rem; transition: color 0.2s; }
.nav-menu .nav-link:hover { color: var(--primary, #2563eb); }
@media (max-width: 768px) {
  .nav-menu { display: none !important; }
}

/* Fixed header body padding safety */
body { min-height: 100vh; }

/* Prevent long words breaking layout */
h1, h2, h3, h4, p, li, td, th { overflow-wrap: break-word; word-wrap: break-word; }

/* === END BASELINE SAFETY CSS === */

/* Cookie banner visibility rules */
#krimolaste-top_cookie-banner.hidden, #cookie-consent-banner.hidden { display: none !important; }
#krimolaste-top_cookie-banner:not(.hidden), #cookie-consent-banner:not(.hidden) { display: block !important; }
#krimolaste-top_cookie-modal.hidden { display: none !important; }
.hidden { display: none !important; }
