/* ============== Global styles for Gaelta Automations website ============== */
/* Author: 乂 丂 卂 丨 尸 卄 / Gaelta Agency */

/* ========== Root Variables ========== */
:root {
  /* Surfaces */
  --color-black:                    #000000;
  --color-bg:                       #0c0c0c;
  --color-surface:                  #131313;
  --color-surface-2:                #1a1a1a; /* Border on hover */
  --color-surface-offset:           #212121;
  --color-divider:                  #282828;
  --color-border:                   #333333;
  --color-surface-dynamic:          #4d4d4d;
  --color-border-pale:              #666666;
  --color-border-subtle:    oklch(from #666666 l c h / 0.07); /* Border */

  /* Text */
  --color-white:                    #ffffff;
  --color-text:                     #e6e6e6; /* #f2f2f2 */
  --color-text-muted:               #a7a7a7; /* #a7a7a7,#7c7c7c */
  --color-text-muted-2:             #646464; /* #7c7c7c */
  --color-text-faint:               #494949; /* #585858 */
  --color-text-inverse:             #0c0c0c;

  /* Primary accent — Terra Ember (muted red-orange) */
  --color-primary:                  #ff6900; /*#e39600;*/
  --color-primary-hover:            #f54900; /*#ffa701;*/
  --color-primary-active:           #e45e00; /*#c98506;*/
  --color-primary-highlight:        #662a00; /*#583d0b;*/
  --color-primary-bgr:              #1e1713; /*#1c180f;*/
  --color-primary-glow:     oklch(from #ff6900 a l c h / 0.12); /*#e39600*/

  /* Secondary accent */
  --color-accent:                   #5681a6;
  --color-accent-hover:             #6d8eaf;
  --color-accent-active:            #4a6d89;
  --color-accent-highlight:         #20272e;
  --color-accent-glow:     oklch(from #5681a6 l c h / 0.12);

  /* Semantic */
  --color-success:   #4a8c3f;
  --color-warning:   #b87a20;
  --color-error:     #c0394f;

  /* Radius */
  --radius-sm:   0.25rem;
  --radius-md:   0.5rem;
  --radius-lg:   0.75rem;
  --radius-xl:   1rem;
  --radius-2xl:  1.5rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow:        400ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Shadows */
  --shadow-sm:  0 1px 3px oklch(0 0 0 / 0.4);
  --shadow-md:  0 4px 16px oklch(0 0 0 / 0.5);
  --shadow-lg:  0 12px 40px oklch(0 0 0 / 0.6);

  /* Type scale */
  --text-xs:   clamp(0.75rem,  0.7rem  + 0.25vw, 0.875rem);
  --text-sm:   clamp(0.875rem, 0.8rem  + 0.35vw, 1rem);
  --text-base: clamp(1rem,     0.95rem + 0.25vw, 1.125rem);
  --text-lg:   clamp(1.125rem, 1rem    + 0.75vw, 1.5rem);
  --text-xl:   clamp(1.5rem,   1.2rem  + 1.25vw, 2.25rem);
  --text-2xl:  clamp(2rem,     1.2rem  + 2.5vw,  3.5rem);
  --text-3xl:  clamp(2.5rem,   1rem    + 4vw,    5rem);
  --text-hero: clamp(3rem,     0.5rem  + 7vw,    7.5rem);

  /* Spacing */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Fonts */
  --font-display: 'Cabinet Grotesk', 'Helvetica Neue', sans-serif;
  --font-body:    'DM Sans', 'Helvetica Neue', sans-serif;

  /* Content widths */
  --content-narrow:  640px;  
  --content-default: 1120px;
  --content-wide:    1200px;
}

/* BASE */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; scroll-behavior: smooth; }
body { min-height: 100dvh; font-family: var(--font-body); font-size: var(--text-base); color: var(--color-text); background: var(--color-bg); line-height: 1.6; overflow-x: hidden; }
h1,h2,h3,h4 { font-family: var(--font-display); text-wrap: balance; line-height: 1.08; font-weight: 800; }
p { text-wrap: pretty; }
img { display: block; max-width: 100%; }
button { cursor: pointer; font: inherit; color: inherit; }
a { text-decoration: none; color: inherit; }
:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 3px; border-radius: var(--radius-sm); }

/* ===================== LAYOUT & UTILITY CLASSES ===================== */

/* LAYOUT */
.container { max-width: var(--content-default); margin-inline: auto; padding-inline: var(--space-6); }.section { margin-bottom: var(--space-16); }
.section-title { font-size: var(--text-sm); font-family: var(--font-body); text-transform: uppercase; letter-spacing: 0.1em; color: var(--color-text-faint); margin-bottom: var(--space-8);}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-6); }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: var(--space-4); }

/* SURFACE LAYERS */
.surface-stack { display: flex; flex-direction: column; gap: var(--space-2); }
.layer { padding: var(--space-4) var(--space-6); border-radius: var(--radius-lg); display: flex; justify-content: space-between; align-items: center; }
.layer-label { font-size: var(--text-xs); font-family: var(--font-body); color: var(--color-text-muted); }
.l-bg      { background: var(--color-bg); border: 1px solid var(--color-border); }
.l-surf    { background: var(--color-surface); }
.l-surf2   { background: var(--color-surface-2); }
.l-offset  { background: var(--color-surface-offset); }
.l-offset2 { background: var(--color-surface-offset-2); }
.l-dynamic { background: var(--color-surface-dynamic); }

/* TYPE */
.type-specimen { display: flex; flex-direction: column; gap: var(--space-5); }
.type-row { display: flex; align-items: baseline; gap: var(--space-6); }
.type-meta { font-size: var(--text-xs); color: var(--color-text-faint); min-width: 200px; font-family: var(--font-body); }

/* CONTRAST GRID */
.contrast-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-3); }
.contrast-cell { padding: var(--space-4) var(--space-5); border-radius: var(--radius-md); border: 1px solid var(--color-border); }
.contrast-cell small { font-size: var(--text-xs); display: block; margin-top: var(--space-1); }

/* COMPONENTS */
.btn {  display: inline-flex; align-items: center; gap: var(--space-2); padding: 0.30rem 1.5rem; border-radius: var(--radius-full); font-size: var(--text-sm); font-family: var(--font-body); font-weight: 700; cursor: pointer; border: none; transition: all var(--transition-interactive); }
.btn-cta { background: var(--color-primary); color: var(--color-text); }
.btn-cta:hover { background: var(--color-primary-hover); }
.btn-cta-accent { background: var(--color-accent); color: #fff; }
.btn-cta-accent:hover { background: var(--color-accent-hover); box-shadow: 0 0 0 3px var(--color-accent-highlight); }
.btn-primary {background: oklch(from var(--color-black) l c h / 1); color: var(--color-text-muted); border: 1px solid oklch(from var(--color-surface-2 ) l c h / 0.8);; border-radius: var(--radius-full); box-shadow: none; transform: translateY(0);}
.btn-primary:hover {color: var(--color-text); background: oklch(from var(--color-primary-active) l c h / 1); border-color: oklch(from var(--color-primary) l c h / 0); box-shadow: 0 0 0 3px oklch(from var(--color-primary) l c h / 0);}
.btn-primary:active {transform: translateY(0);}
.btn-primary i,
.btn-primary svg {width: 14px; height: 14px;}
.btn-primary-accent {background: oklch(from var(--color-accent) l c h / 0.07); color: var(--color-accent); border: 1px solid oklch(from var(--color-accent) l c h / 0.0); box-shadow: none; transform: translateY(0);}
.btn-primary-accent:hover {background: oklch(from var(--color-accent) l c h / 0.18); border-color: oklch(from var(--color-accent) l c h / 0.0); box-shadow: 0 0 0 3px oklch(from var(--color-accent) l c h / 0.12); transform: translateY(-1px);}
.btn-primary-accent:active {transform: translateY(0);}
.btn-primary-accent i,
.btn-primary-accent svg {width: 14px; height: 14px;}
.btn-secondary { background: var(--color-text-faint); color: var(--color-black); border: 1px solid oklch(from var(--color-primary-glow) l c h / 0.2); }
.btn-secondary:hover { background: var(--color-primary-glow); border-color: var(--color-primary-hover); }
.btn-secondary-accent { background: transparent; color: var(--color-accent); border: 1px solid oklch(from var(--color-accent) l c h / 0.7); }
.btn-secondary-accent:hover { background: oklch(from var(--color-accent) l c h / 0.12); border-color: var(--color-accent-hover); }
.btn-ghost { background: transparent; color: var(--color-primary); }
.btn-ghost:hover { background: var(--color-primary-highlight); }
.btn-ghost-accent { background: transparent; color: var(--color-accent); }
.btn-ghost-accent:hover { background: var(--color-accent-highlight); }
.btn-light { background: transparent; color: var(--color-text-muted); border: 1px solid oklch(from var(--color-text-muted) l c h / 0.2); }
.btn-light:hover { background: var(--color-text-glow); border-color: oklch(from var(--color-text-muted) l c h / 0.7); }
.btn-outline { background: transparent; color: var(--color-text); border: 1px solid oklch(from var(--color-text ) l c h / 1); }
.btn-outline:hover {color: var(--color-text); background: oklch(from var(--color-primary-hover) l c h / 1.0) ; border-color: oklch(from var(--color-primary) l c h / 1); }

/* CARDS */
.card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-xl); padding: var(--space-6); box-shadow: var(--shadow-sm); }
.card:hover { box-shadow: var(--shadow-md); border-color: var(--color-surface-offset-2); }
.card h3 { font-size: var(--text-lg); margin-bottom: var(--space-3); }
.card p { font-size: var(--text-base); color: var(--color-text-muted); }

/* FORM */
.form-group { display: flex; flex-direction: column; gap: var(--space-2); }
.form-label { font-size: var(--text-sm); font-weight: 500; color: var(--color-text-muted); }
.form-input { background: var(--color-surface-2); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 0.625rem 0.875rem; font-size: var(--text-base); color: var(--color-text); outline: none; }
.form-input:focus { border-color: var(--color-primary); box-shadow: 0 0 0 3px var(--color-primary-highlight); }
.form-input::placeholder { color: var(--color-text-faint); }

.divider { border: none; border-top: 1px solid var(--color-divider); margin-block: var(--space-6); }

/* ICON BOX */
.icon-box { width: 2rem; height: 2rem; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; background: var(--color-primary-highlight); }
.icon-box svg { width: 16px; height: 16px; stroke: var(--color-primary); stroke-width: 2; fill: none; }
.icon-box-accent { background: var(--color-accent-highlight); }
.icon-box-accent svg { stroke: var(--color-accent); }
.icon-box-secondary { background: var(--color-surface-2); }
.icon-box-secondary svg { stroke: var(--color-text-muted); }

/* ACCENT SWATCH */
.swatches { display: flex; gap: var(--space-3); flex-wrap: wrap; }
.swatch { width: 80px; height: 80px; border-radius: var(--radius-md); display: flex; align-items: flex-end; padding: var(--space-2); font-size: var(--text-xs); font-weight: 600; }

/* ===================== BADGES ===================== */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.8rem;
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.05em;
  line-height: 1.4;
  white-space: nowrap;
  text-transform: uppercase;
}

.badge--primary {
  background: var(--color-primary);
  color: var(--color-black);
  border-radius: var(--radius-sm);
  letter-spacing: 0.01em;
  padding: 0rem 0.6rem;
  align-self: flex-start;
}

.badge--secondary {
  background: var(--color-surface);
  color: var(--color-text-muted);
  border-radius: var(--radius-sm);
  letter-spacing: 0.01em;
  padding: 0.2rem 0.6rem;
  align-self: flex-start;
}

.badge--accent {
  background: oklch(from var(--color-accent-glow ) l c h / 0.07);
  color: var(--color-accent);
  border: 1px solid oklch(from var(--color-accent-glow ) l c h / 0);
}

/* ===================== NAV ===================== */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: 68px;
  display: flex;
  align-items: center;
  background: oklch(from var(--color-black) l c h / 1);
  border: 1px solid oklch(from var(--color-surface-2 ) l c h / 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--content-default); margin-inline: auto;
  padding-inline: clamp(var(--space-5), 5vw, var(--space-6));
  gap: var(--space-8);
  width: 100%;
}
.nav-logo-img { width: 180px;}
.nav-links { display: flex; align-items: center; gap: var(--space-6); list-style: none; }
.nav-links a {
  font-size: var(--text-sm); color: var(--color-text);
  transition: color var(--transition-interactive); font-weight: 500;
}

.nav-logo-mobile-img {
  width: 30px;
}

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

.nav-mobile-toggle { display: none; background: none; border: none; color: var(--color-text-muted); padding: var(--space-2); }

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.4rem 1.25rem;
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-primary);
  border: 1px solid oklch(from var(--color-primary) l c h / 0.25);
  border-radius: var(--radius-sm);
  background: transparent;
  transition: all var(--transition-interactive);
  white-space: nowrap;
}
.nav-cta:hover {
  color: #fff;
  background: var(--color-primary);
  border-color: var(--color-primary);
}

/* ===================== MEGA MENU ===================== */

/* --- Dropdown trigger --- */
.nav-item-has-dropdown {
  position: relative;
}

.nav-link-dropdown {
  background: none;
  border: none;
  color: var(--color-text);
  font-size: var(--text-sm);
  font-weight: 500;
  padding: 8px 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  transition: color 0.18s ease;
}

.nav-link-dropdown:hover {
  color: var(--color-primary);
}

.nav-link-dropdown:hover svg {
  color: var(--color-primary);
}

.nav-link-dropdown[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.nav-link-dropdown svg {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--color-text);
}

/* --- Desktop mega menu panel --- */
.nav-mega-menu {
  position: absolute;
  top: calc(100% + 13px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-surface);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border-radius: 0px;
  padding: 24px;
  min-width: 720px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), 
              visibility 0.25s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateX(-50%) translateY(-8px);
  z-index: 100;
}

.nav-mega-menu[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.nav-mega-menu-inner {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.nav-mega-menu-column {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nav-mega-menu-title {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-primary);
  margin: 0 0 8px 0;
  padding: 0 12px;
}

.nav-mega-menu-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-links .nav-mega-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease;
}

.nav-links .nav-mega-menu-item:hover {
  color: var(--color-text);
  background: oklch(from white l c h / 0.03);
}

.nav-mega-menu-item.is-active {
  color: var(--color-text-muted);
  border-radius: 0;
}

.nav-mega-menu-item svg,
.nav-mega-menu-item i {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--color-surface-dynamic);
  transition: color 0.18s ease;
}

.nav-mega-menu-item:hover svg,
.nav-mega-menu-item:hover i {
  color: var(--color-primary);
}

.nav-mega-menu-item.is-active svg,
.nav-mega-menu-item.is-active i {
  color: var(--color-primary);
}


/* ========== Mega menu sub-items ========== */

.nav-mega-menu-item-has-sub {
  position: relative;
}

.nav-mega-menu-item--parent {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-mega-submenu {
  position: absolute;
  left: 0;
  top: 100%;
  background: var(--color-surface-2);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border-radius: 0px;
  padding: 0;
  width: 100%;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.2s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(-4px);
  z-index: 110;
}

.nav-mega-menu-item-has-sub:hover > .nav-mega-menu-item--parent {
  background: oklch(from white l c h / 0.03);
}

.nav-mega-menu-item-has-sub:hover .nav-mega-submenu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.nav-mega-submenu .nav-mega-menu-item {
  background: var(--color-surface-offset-2);
}

/* ========== Mobile sub-items ========== */

.nav-mobile-item-has-sub {
  display: flex;
  flex-direction: column;
}

.nav-mobile-submenu {
  list-style: none;
  padding: 0 0 0 12px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-mobile-submenu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  color: var(--color-text-muted-2);
  font-size: var(--text-sm);
  font-weight: 400;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.18s ease;
}

.nav-mobile-submenu a i,
.nav-mobile-submenu a svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--color-surface-offset-2);
}

.nav-mobile-submenu a:hover {
  background: var(--color-surface-offset-2);
}

/* ===================== MOBILE MENU ===================== */

.nav-mobile-overlay {
  display: none;
  position: fixed;
  width: 100vw;
  height: 100dvh;
  min-height: 100dvh;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--color-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
              visibility 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.nav-mobile-overlay[aria-hidden="false"] {
  display: block;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.nav-mobile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border-subtle);
}

.nav-mobile-close {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.18s ease;
}

.nav-mobile-close:hover {
  color: var(--color-text);
}

.nav-mobile-links {
  list-style: none;
  padding: 24px 20px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-mobile-link {
  display: block;
  padding: 14px 16px;
  color: var(--color-text);
  font-size: var(--text-base);
  font-weight: 500;
  text-decoration: none;
  border-radius: 8px;
  transition: background 0.18s ease;
}

.nav-mobile-link:hover {
  background: var(--color-surface);
}

/* --- Mobile accordion --- */
.nav-mobile-item-accordion {
  border-radius: 8px;
  overflow: hidden;
}

.nav-mobile-accordion-trigger {
  width: 100%;
  background: none;
  border: none;
  color: var(--color-text);
  font-size: var(--text-base);
  font-weight: 500;
  padding: 14px 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
  border-radius: 8px;
  transition: background 0.18s ease;
}

.nav-mobile-accordion-trigger:hover {
  background: var(--color-surface);
}

.nav-mobile-accordion-trigger svg {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-mobile-accordion-trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.nav-mobile-accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-mobile-accordion-content[aria-hidden="false"] {
  max-height: 1000px;
}

.nav-mobile-accordion-section {
  padding: 16px 16px 8px 16px;
}

.nav-mobile-accordion-section h4 {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  margin: 0 0 12px 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.nav-mobile-accordion-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-mobile-accordion-section a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  color: var(--color-text);
  font-size: var(--text-sm);
  font-weight: 400;
  text-decoration: none;
  border-radius: 6px;
  transition: background 0.18s ease;
}

.nav-mobile-accordion-section a i,
.nav-mobile-accordion-section a svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--color-border);
}

.nav-mobile-accordion-section a:hover {
  background: var(--color-surface);
}

.nav-mobile-overlay .nav-cta {
  margin: 0 20px 32px 20px;
}

/* Hide desktop mega menu on mobile */
@media (max-width: 768px) {
  .nav-mega-menu {
    display: none;
  }
}

/* Hide mobile overlay on desktop */
@media (min-width: 769px) {
  .nav-mobile-overlay {
    display: none;
  }
}


/* ===================== FOOTER ===================== */
footer {
  background: var(--color-black);
  padding-block: clamp(var(--space-12), 6vw, var(--space-20)) var(--space-8);
  border-top: 1px solid var(--color-surface-2);
}
.footer-inner {
  display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: var(--space-12); margin-bottom: var(--space-12);
}

.footer-logo { display: flex; align-items: center; gap: var(--space-1); margin-bottom: var(--space-5); }
.footer-logo-name { font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; letter-spacing: -0.01em; color: var(--color-primary); }
.footer-tagline { font-size: var(--text-sm); color: var(--color-text-muted-2); line-height: 1.65; max-width: 32ch; margin-bottom: var(--space-6); }
.footer-social {
  display: flex; align-items: center; gap: var(--space-3);
  margin-bottom: var(--space-6); flex-wrap: wrap;
}
.footer-logo-img {
  max-width: 130px;
}
.footer-social a {
  width: 36px; height: 36px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--color-text-muted-2);
  border-radius: var(--radius-full);
  background: var(--color-surface);
  transition: color var(--transition-interactive), border-color var(--transition-interactive), transform var(--transition-interactive), background var(--transition-interactive);
}
.footer-social a:hover {
  color: var(--color-text-muted);
  border-color: oklch(from var(--color-text) l c h / 0.18);
  background: var(--color-surface-offset);
  transform: translateY(-1px);
}
.footer-social svg {
  width: 16px; height: 16px;
  stroke-width: 1.9;
}

.footer-contact { display: flex; flex-direction: column; gap: var(--space-2); }
.footer-contact a, .footer-contact span {
  font-size: var(--text-sm); color: var(--color-text-muted-2);
  transition: color var(--transition-interactive);
}
.footer-contact a:hover { color: var(--color-text); }
.footer-col-title {
  font-size: var(--text-xs); font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--color-text-muted); margin-bottom: var(--space-5);
}
.footer-links { display: flex; flex-direction: column; gap: var(--space-3); }
.footer-links a {
  font-size: var(--text-sm); color: var(--color-text-faint);
  transition: color var(--transition-interactive);
}
.footer-links a:hover { color: var(--color-text); }
.footer-bottom {
  border-top: 1px solid var(--color-border-subtle);
  padding-top: var(--space-6);
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); flex-wrap: wrap;
}
.footer-copy { font-size: var(--text-xs); color: var(--color-text-faint); }

/* ===================== ANIMATIONS ===================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
@supports (animation-timeline: scroll()) {
  .fade-in {
    opacity: 0;
    animation: revealFade linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 60%;
  }
}
@keyframes revealFade { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ===================== MOBILE ===================== */
@media (max-width: 1000px) {
  .nav-links, .nav-cta { display: none; }
  .nav-mobile-toggle { display: flex; }
  .benefits-header, .process-header, .about-inner, .pain-item { grid-template-columns: 1fr; gap: var(--space-6); }
  .bento-card--wide, .bento-card--featured { grid-column: span 12; }
  .bento-card--medium, .bento-card--third, .bento-card--half { grid-column: span 6; }
    .process-grid { grid-template-columns: 1fr 1fr; }
  .testimonials-grid { grid-template-columns: 1fr; }
  .testimonial-card--featured { grid-column: span 1; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: var(--space-8); }
  .about-meta { grid-template-columns: repeat(2, 1fr); gap: var(--space-6); }
  .btn-primary, .btn-secondary, .btn-cta, .btn-primary-accent, .btn-secondary-accent, .btn-cta-accent { width: 100%; justify-content: center; }

}
@media (max-width: 640px) {
  .nav-links, .nav-cta { display: none; }
  .nav-mobile-toggle { display: flex; }
  .bento { grid-template-columns: 1fr; }
  .bento-card--wide, .bento-card--medium, .bento-card--featured,
  .bento-card--third, .bento-card--half { grid-column: span 1; }
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .btn-primary, .btn-secondary, .btn-cta, .btn-primary-accent, .btn-secondary-accent, .btn-cta-accent { width: 100%; justify-content: center; }
  .process-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .about-meta { grid-template-columns: repeat(2, 1fr); gap: var(--space-4); }
  .cta-actions { flex-direction: column; align-items: stretch; }
  .cta-actions .btn-primary, .cta-actions .btn-outline { width: 100%; justify-content: center; }
}

/* ===================== BACK TO TOP ===================== */

.back-to-top-section {
  background: var(--color-bg);

}

.back-to-top-wrapper {
  max-width: var(--content-default);
  margin-inline: auto;
  padding-inline: var(--space-3);
  padding-block: var(--space-3);
  text-align: right;
}

.back-to-top {
  display: inline-flex;
  font-size: var(--text-base);
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text);
  transition: color var(--transition-interactive);
}

.back-to-top:hover {
  color: var(--color-text);
}