/* style.css */

:root {
  --font-primary: "Inter", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue",
    sans-serif;
  --font-secondary: "Roboto Slab", serif;

  /* Light Theme */
  --color-background: #f9fafb;
  --color-surface: #ffffff;
  --color-text-primary: #1f2937;
  --color-text-secondary: #4b5563;
  --color-border: #e5e7eb;
  --color-primary: #2563eb;
  --color-primary-hover: #1d4ed8;
  --color-primary-text: #ffffff;
  --color-shadow: rgba(0, 0, 0, 0.05);
  --color-icon: #6b7280;
  --color-success: #10b981;
  --color-success-bg: #d1fae5;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-background: #111827;
    --color-surface: #1f2937;
    --color-text-primary: #f9fafb;
    --color-text-secondary: #9ca3af;
    --color-border: #374151;
    --color-primary: #3b82f6;
    --color-primary-hover: #60a5fa;
    --color-primary-text: #ffffff;
    --color-shadow: rgba(0, 0, 0, 0.2);
    --color-icon: #9ca3af;
    --color-success: #34d399;
    --color-success-bg: #064e3b;
  }
}

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

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

body {
  font-family: var(--font-primary);
  background-color: var(--color-background);
  color: var(--color-text-primary);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text-primary);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
}

h4 {
  font-size: 1.1rem;
  font-weight: 600;
}

p {
  margin-bottom: 1.25rem;
  color: var(--color-text-secondary);
  font-size: clamp(1rem, 1.5vw, 1.1rem);
}

p:last-child {
  margin-bottom: 0;
}

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

a:hover {
  color: var(--color-primary-hover);
  text-decoration: underline;
}

ul {
  list-style: none;
}

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

/* --- Layout & Container --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: 6rem 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem auto;
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-header p {
  font-size: 1.2rem;
  color: var(--color-text-secondary);
}

/* --- Header & Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 1.5rem 0;
  transition: background-color 0.3s ease, padding 0.3s ease,
    box-shadow 0.3s ease;
}

.site-header.scrolled {
  background-color: var(--color-surface);
  box-shadow: 0 4px 6px -1px var(--color-shadow);
  padding: 1rem 0;
}

.main-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--color-text-primary);
  text-decoration: none;
}

.logo:hover {
  text-decoration: none;
  color: var(--color-primary);
}

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

.nav-links a {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  text-decoration: none;
  position: relative;
  padding: 0.5rem 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-primary);
  transition: width 0.3s ease;
}

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

.nav-links a:hover {
  color: var(--color-text-primary);
  text-decoration: none;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

.mobile-menu-toggle svg {
  width: 28px;
  height: 28px;
  stroke: var(--color-text-primary);
}

/* --- Buttons --- */
.button-primary,
.button-large {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  background-color: var(--color-primary);
  color: var(--color-primary-text);
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  border: 2px solid transparent;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.button-primary:hover,
.button-large:hover {
  background-color: var(--color-primary-hover);
  color: var(--color-primary-text);
  text-decoration: none;
  transform: translateY(-2px);
}

.button-large {
  font-size: 1.1rem;
  padding: 1rem 2.5rem;
}

/* --- Hero Section --- */
.hero-section {
  padding-top: 10rem;
  padding-bottom: 8rem;
  background-color: var(--color-surface);
}

.hero-section .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-content {
  max-width: 600px;
}

.hero-content h1 {
  margin-bottom: 1.5rem;
}

.hero-content .subtitle {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

.hero-image img {
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px var(--color-shadow);
}

/* --- Solutions Section --- */
.solutions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
}

.solution-card {
  background-color: var(--color-surface);
  padding: 2.5rem;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.solution-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 15px -3px var(--color-shadow);
}

.solution-card .card-icon {
  margin: 0 auto 1.5rem auto;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-background);
}

.solution-card .card-icon svg {
  width: 32px;
  height: 32px;
  stroke: var(--color-primary);
}

.solution-card h3 {
  margin-bottom: 1rem;
}

/* --- How It Works Section --- */
.how-it-works-section {
  background-color: var(--color-surface);
}

.steps-container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  position: relative;
}

.step {
  text-align: center;
  flex: 1;
  max-width: 300px;
  padding: 0 1rem;
  position: relative;
  z-index: 2;
}

.step-number {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: var(--color-background);
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 auto 1.5rem auto;
  transition: background-color 0.3s, color 0.3s;
}

.step:hover .step-number {
  background-color: var(--color-primary);
  color: var(--color-primary-text);
}

.step h3 {
  margin-bottom: 0.5rem;
}

.step-connector {
  display: none; /* Hide connector by default, handled by JS or media queries */
}

@media (min-width: 768px) {
  .steps-container {
    position: relative;
  }
  .step-connector {
    display: block;
    position: absolute;
    top: 30px;
    left: 25%;
    right: 25%;
    height: 2px;
    background: repeating-linear-gradient(
      90deg,
      var(--color-border),
      var(--color-border) 10px,
      transparent 10px,
      transparent 20px
    );
    z-index: 1;
  }
}

/* --- Features Section (Tabs) --- */
.tabs-container {
  max-width: 900px;
  margin: 0 auto;
}

.tabs-nav {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.tab-link {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  background: none;
  border: 2px solid var(--color-border);
  border-radius: 50px;
  cursor: pointer;
  color: var(--color-text-secondary);
  transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.tab-link:hover {
  background-color: var(--color-background);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.tab-link.active {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-primary-text);
}

.tab-content {
  display: none;
  padding: 2rem;
  background-color: var(--color-surface);
  border-radius: 12px;
  border: 1px solid var(--color-border);
  animation: fadeIn 0.5s ease-in-out;
}

.tab-content.active {
  display: block;
}

.tab-content h3 {
  margin-bottom: 1.5rem;
}

.tab-content ul {
  list-style: none;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.tab-content ul li {
  position: relative;
  margin-bottom: 1rem;
  padding-left: 1.75rem;
}

.tab-content ul li::before {
  content: "✔";
  position: absolute;
  left: 0;
  top: 2px;
  color: var(--color-success);
  font-weight: bold;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Case Study Section --- */
.case-study-section {
  background-color: var(--color-surface);
}

.case-study-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.case-study-text .eyebrow {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

.case-study-text h2 {
  margin-bottom: 2rem;
}

blockquote {
  font-size: 1.2rem;
  font-style: italic;
  color: var(--color-text-primary);
  padding-left: 2rem;
  border-left: 4px solid var(--color-primary);
  margin: 2rem 0;
}

.case-study-image img {
  border-radius: 12px;
}

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

.testimonial-card {
  background-color: var(--color-surface);
  padding: 2rem;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-card p {
  font-size: 1.1rem;
  flex-grow: 1;
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.testimonial-author {
  border-top: 1px solid var(--color-border);
  padding-top: 1.5rem;
}

.author-name {
  font-weight: 700;
  display: block;
}

.author-title {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
}

/* --- FAQ Section (Accordion) --- */
.faq-section {
  background-color: var(--color-surface);
}

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

.accordion-item {
  border-bottom: 1px solid var(--color-border);
}

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

.accordion-header {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 1.75rem 1rem;
  cursor: pointer;
  font-size: 1.2rem;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--color-text-primary);
  transition: background-color 0.2s;
}

.accordion-header:hover {
  background-color: var(--color-background);
}

.accordion-header svg {
  width: 24px;
  height: 24px;
  stroke: var(--color-icon);
  transition: transform 0.4s cubic-bezier(0.25, 0.1, 0.25, 1);
  flex-shrink: 0;
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.25, 0.1, 0.25, 1),
    padding 0.4s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.accordion-content p {
  padding: 0 1rem 1.75rem 1rem;
  line-height: 1.8;
}

.accordion-item.active .accordion-header svg {
  transform: rotate(180deg);
}

.accordion-item.active .accordion-content {
  max-height: 500px; /* Adjust as needed */
}

.faq-link-wrapper {
  text-align: center;
  margin-top: 3rem;
}

.link-arrow {
  font-size: 1.1rem;
  font-weight: 600;
}

/* --- CTA Section --- */
.cta-section {
  background-color: var(--color-primary);
  color: var(--color-primary-text);
  text-align: center;
}

.cta-section h2,
.cta-section p {
  color: var(--color-primary-text);
}

.cta-section h2 {
  margin-bottom: 1rem;
}

.cta-section p {
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 3rem;
  opacity: 0.9;
}

.registration-form-container {
  max-width: 700px;
  margin: 0 auto;
}

#quick-registration-form .form-row {
  display: flex;
  gap: 1rem;
}

#quick-registration-form input {
  flex-grow: 1;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--color-border);
  font-size: 1rem;
  background-color: var(--color-surface);
  color: var(--color-text-primary);
}

#quick-registration-form input:focus {
  outline: none;
  border-color: var(--color-primary-hover);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}

#quick-registration-form button {
  background-color: var(--color-surface);
  color: var(--color-primary);
  border: none;
}

#quick-registration-form button:hover {
  background-color: #e5e7eb;
}

.form-terms {
  font-size: 0.9rem;
  margin-top: 1rem;
  opacity: 0.8;
}

.form-terms a {
  color: var(--color-primary-text);
  text-decoration: underline;
}

#form-success-message {
  background-color: var(--color-surface);
  color: var(--color-text-primary);
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
}

#form-success-message h3 {
  color: var(--color-success);
  margin-bottom: 0.5rem;
}

/* --- Footer --- */
.site-footer {
  background-color: var(--color-surface);
  padding: 5rem 0 2rem 0;
  color: var(--color-text-secondary);
  border-top: 1px solid var(--color-border);
}

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

.footer-column h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--color-text-primary);
  margin-bottom: 1.5rem;
}

.footer-column.about p {
  margin-top: 1.5rem;
}

.footer-column ul li {
  margin-bottom: 0.75rem;
}

.footer-column ul a {
  color: var(--color-text-secondary);
}

.footer-column ul a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

.footer-column.contact address {
  font-style: normal;
  line-height: 1.8;
}

.footer-column.contact p {
  margin-top: 1rem;
}

.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding-top: 2rem;
  text-align: center;
  font-size: 0.9rem;
}

/* --- Animations on Scroll --- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Cookie Banner --- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: var(--color-surface);
  color: var(--color-text-primary);
  padding: 1.5rem 2rem;
  box-shadow: 0 -2px 10px var(--color-shadow);
  z-index: 2000;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  transform: translateY(100%);
  animation: slideInUp 0.5s forwards;
}

.cookie-banner.hidden {
  animation: slideOutDown 0.5s forwards;
}

.cookie-banner p {
  margin: 0;
  font-size: 0.9rem;
}

.cookie-banner button {
  padding: 0.6rem 1.2rem;
  flex-shrink: 0;
}

@keyframes slideInUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes slideOutDown {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(100%);
  }
}

/* --- Media Queries for Responsiveness --- */

/* --- Laptops and Desktops --- */
@media (max-width: 1200px) {
  .container {
    padding: 0 1.5rem;
  }
}

/* --- Tablets --- */
@media (max-width: 992px) {
  h1 {
    font-size: 2.8rem;
  }
  h2 {
    font-size: 2.2rem;
  }
  section {
    padding: 4rem 0;
  }

  .hero-section {
    padding-top: 8rem;
  }

  .hero-section .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-image {
    grid-row: 1;
    margin-bottom: 3rem;
  }

  .hero-content {
    margin: 0 auto;
  }

  .case-study-content {
    grid-template-columns: 1fr;
  }

  .case-study-image {
    grid-row: 1;
    margin-bottom: 2rem;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }
  .footer-column.about {
    grid-column: 1 / 3;
  }
}

/* --- Large Mobiles and Small Tablets --- */
@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    width: 80%;
    height: 100vh;
    background-color: var(--color-surface);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.25, 0.1, 0.25, 1);
    box-shadow: -5px 0 15px var(--color-shadow);
  }

  .nav-links.nav-open {
    transform: translateX(0);
  }

  .nav-links a {
    font-size: 1.2rem;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .main-navigation .button-primary {
    display: none; /* Hide in nav bar, show in mobile menu if desired */
  }

  .steps-container {
    flex-direction: column;
    align-items: center;
    gap: 3rem;
  }

  .step-connector {
    display: none;
  }

  #quick-registration-form .form-row {
    flex-direction: column;
  }

  .cookie-banner {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
}

/* --- Small Mobiles --- */
@media (max-width: 576px) {
  .container {
    padding: 0 1rem;
  }

  h1 {
    font-size: 2.2rem;
  }
  h2 {
    font-size: 1.8rem;
  }

  .tabs-nav {
    flex-direction: column;
    gap: 0.5rem;
  }

  .tab-link {
    width: 100%;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-column ul {
    padding: 0;
  }
}
