/* ===================================
   CKG - Comercial Kayros Group
   Design System & Styles
   =================================== */

/* --- CSS Variables --- */
:root {
  /* Brand Colors */
  --color-primary: #AB6F45;
  --color-primary-dark: #8A5A38;
  --color-primary-light: #C4896A;
  --color-secondary: #1E876E;
  --color-secondary-dark: #166B57;
  --color-secondary-light: #2AA88A;

  /* Neutral Colors */
  --text-dark: #424242;
  --text-light: #6B7280;
  --bg-light: #F8F9FA;
  --bg-white: #FFFFFF;
  --bg-dark: #1A1A2E;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  --gradient-secondary: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-dark) 100%);
  --gradient-hero: linear-gradient(135deg, rgba(30, 135, 110, 0.9) 0%, rgba(171, 111, 69, 0.85) 100%);

  /* Typography */
  --font-main: 'Open Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 2rem;
  --font-size-4xl: 2.5rem;
  --font-size-5xl: 3.5rem;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Layout */
  --container-max: 1200px;
  --border-radius: 12px;
  --border-radius-lg: 20px;

  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
  --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.15);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  margin-top: 0 !important;
}

body {
  font-family: var(--font-main);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--bg-white);
  overflow-x: hidden;
  margin: 0;
  padding: 0;
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* WordPress Admin Bar Fix */
body.admin-bar .header {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar .header {
    top: 46px;
  }
}

/* Remove any WordPress theme margins */
.ckg-landing-page,
.ckg-landing-page body {
  margin: 0 !important;
  padding: 0 !important;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

ul,
ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* --- Typography --- */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-dark);
}

h1 {
  font-size: var(--font-size-5xl);
}

h2 {
  font-size: var(--font-size-4xl);
}

h3 {
  font-size: var(--font-size-2xl);
}

h4 {
  font-size: var(--font-size-xl);
}

p {
  margin-bottom: var(--space-md);
}

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.section {
  padding: var(--space-4xl) 0;
}

.section--alt {
  background-color: var(--bg-light);
}

.section--dark {
  background-color: var(--bg-dark);
  color: var(--bg-white);
}

/* --- Flexbox Utilities --- */
.flex {
  display: flex;
}

.flex-center {
  display: flex;
  justify-content: center;
  align-items: center;
}

.flex-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.flex-column {
  flex-direction: column;
}

.flex-wrap {
  flex-wrap: wrap;
}

.gap-sm {
  gap: var(--space-sm);
}

.gap-md {
  gap: var(--space-md);
}

.gap-lg {
  gap: var(--space-lg);
}

.gap-xl {
  gap: var(--space-xl);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-size: var(--font-size-base);
  font-weight: 600;
  border-radius: var(--border-radius);
  transition: all var(--transition-base);
  cursor: pointer;
}

.btn--primary {
  background: var(--gradient-primary);
  color: var(--bg-white);
  box-shadow: var(--shadow-md);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--secondary {
  background: var(--gradient-secondary);
  color: var(--bg-white);
  box-shadow: var(--shadow-md);
}

.btn--secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--outline {
  background: transparent;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

.btn--outline:hover {
  background: var(--color-primary);
  color: var(--bg-white);
}

.btn--white {
  background: var(--bg-white);
  color: var(--color-secondary);
  box-shadow: var(--shadow-md);
}

.btn--white:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn--lg {
  padding: var(--space-lg) var(--space-2xl);
  font-size: var(--font-size-lg);
}

/* --- Header & Navigation --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: var(--space-md) 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.header--transparent {
  background: transparent;
  box-shadow: none;
}

.header--scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow-md);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav__logo {
  height: 45px;
  width: auto;
}

.nav__menu {
  display: flex;
  gap: var(--space-xl);
  align-items: center;
}

.nav__link {
  font-weight: 500;
  color: var(--text-dark);
  position: relative;
  padding: var(--space-sm) 0;
}

.header--transparent .nav__link {
  color: var(--bg-white);
}

.header--scrolled .nav__link {
  color: var(--text-dark);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--transition-base);
}

.nav__link:hover::after,
.nav__link--active::after {
  width: 100%;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: var(--space-sm);
}

.nav__toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.header--transparent .nav__toggle span {
  background: var(--bg-white);
}

/* --- Hero Section --- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  /* Dynamic viewport height for mobile */
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  display: flex;
  align-items: center;
  overflow: hidden;
}

/* Hero Background Image - Fullscreen & Responsive */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  /* Shorthand for top/right/bottom/left: 0 */
  width: 100vw;
  height: 100%;
  background-image: url('../images/hero-bg.webp');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  z-index: 0;
}

/* Center focus on mobile */
@media (max-width: 768px) {
  .hero::before {
    background-position: center center;
  }

  .hero {
    margin-left: 0;
    width: 100%;
  }
}

/* Gradient Overlay - Ensures text readability */
.hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg,
      rgba(26, 26, 46, 0.88) 0%,
      rgba(30, 135, 110, 0.75) 40%,
      rgba(171, 111, 69, 0.65) 100%);
  z-index: 1;
}

/* Alternative: Image element for more control */
.hero__bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 2;
  max-width: 700px;
  color: var(--bg-white);
  padding-top: 80px;
  /* Account for fixed header */
}

.hero__tagline {
  display: inline-block;
  padding: var(--space-sm) var(--space-md);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border-radius: 50px;
  font-size: var(--font-size-sm);
  font-weight: 600;
  margin-bottom: var(--space-lg);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero__title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  margin-bottom: var(--space-lg);
  color: var(--bg-white);
  line-height: 1.1;
}

.hero__title span {
  color: var(--color-primary-light);
}

.hero__subtitle {
  font-size: var(--font-size-xl);
  opacity: 0.95;
  margin-bottom: var(--space-2xl);
  line-height: 1.6;
}

.hero__actions {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.hero__scroll {
  position: absolute;
  bottom: var(--space-2xl);
  left: 50%;
  transform: translateX(-50%);
  color: var(--bg-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  animation: bounce 2s infinite;
  z-index: 2;
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  40% {
    transform: translateX(-50%) translateY(-10px);
  }

  60% {
    transform: translateX(-50%) translateY(-5px);
  }
}

/* --- Decorative Elements --- */
.hero__decoration {
  position: absolute;
  right: -100px;
  top: 50%;
  transform: translateY(-50%);
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(171, 111, 69, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  z-index: 1;
}

/* --- Solutions Section --- */
.solutions {
  background: var(--bg-light);
}

.solutions__header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto var(--space-3xl);
}

.solutions__subtitle {
  color: var(--color-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-md);
}

.solutions__title {
  margin-bottom: var(--space-md);
}

.solutions__desc {
  color: var(--text-light);
  font-size: var(--font-size-lg);
}

.solutions__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-xl);
}

.solution-card {
  background: var(--bg-white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.solution-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-secondary);
  transform: scaleX(0);
  transition: transform var(--transition-base);
}

.solution-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
}

.solution-card:hover::before {
  transform: scaleX(1);
}

.solution-card__icon {
  width: 70px;
  height: 70px;
  border-radius: var(--border-radius);
  background: var(--gradient-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  font-size: 2rem;
}

.solution-card:nth-child(2) .solution-card__icon {
  background: var(--gradient-primary);
}

.solution-card:nth-child(3) .solution-card__icon {
  background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%);
}

.solution-card__title {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-md);
}

.solution-card__desc {
  color: var(--text-light);
  margin-bottom: var(--space-lg);
}

.solution-card__link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--color-secondary);
  font-weight: 600;
  transition: gap var(--transition-base);
}

.solution-card__link:hover {
  gap: var(--space-md);
}

/* --- Method Section --- */
.method {
  position: relative;
  background: linear-gradient(180deg, var(--bg-white) 0%, var(--bg-light) 100%);
}

.method__header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto var(--space-3xl);
}

.method__subtitle {
  color: var(--color-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-md);
}

.method__steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
  position: relative;
}

.method__steps::before {
  content: '';
  position: absolute;
  top: 50px;
  left: 15%;
  right: 15%;
  height: 3px;
  background: linear-gradient(90deg, var(--color-secondary), var(--color-primary));
  z-index: 0;
}

.method-step {
  text-align: center;
  position: relative;
  z-index: 1;
}

.method-step__number {
  width: 100px;
  height: 100px;
  margin: 0 auto var(--space-lg);
  border-radius: 50%;
  background: var(--bg-white);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-3xl);
  font-weight: 800;
  color: var(--color-secondary);
  position: relative;
  transition: all var(--transition-base);
}

.method-step:nth-child(2) .method-step__number {
  color: var(--color-primary);
}

.method-step:nth-child(3) .method-step__number {
  background: var(--gradient-secondary);
  color: var(--bg-white);
}

.method-step:hover .method-step__number {
  transform: scale(1.1);
  box-shadow: var(--shadow-xl);
}

.method-step__title {
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-sm);
}

.method-step__desc {
  color: var(--text-light);
  max-width: 280px;
  margin: 0 auto;
}

/* --- Contact Section --- */
.contact {
  background: var(--bg-dark);
  color: var(--bg-white);
  position: relative;
  overflow: hidden;
}

.contact::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(30, 135, 110, 0.2) 0%, transparent 70%);
  border-radius: 50%;
}

.contact__wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3xl);
  align-items: center;
}

.contact__content h2 {
  color: var(--bg-white);
  margin-bottom: var(--space-lg);
}

.contact__content p {
  color: rgba(255, 255, 255, 0.8);
  font-size: var(--font-size-lg);
  margin-bottom: var(--space-xl);
}

.contact__features {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.contact__feature {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.contact__feature-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.contact__form-wrapper {
  background: var(--bg-white);
  border-radius: var(--border-radius-lg);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-xl);
}

.contact__form h3 {
  color: var(--text-dark);
  margin-bottom: var(--space-xl);
  text-align: center;
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-group label {
  display: block;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: var(--space-sm);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: var(--space-md);
  border: 2px solid var(--bg-light);
  border-radius: var(--border-radius);
  font-size: var(--font-size-base);
  font-family: inherit;
  transition: border-color var(--transition-fast);
  background: var(--bg-light);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-secondary);
  background: var(--bg-white);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
}

.contact__form .btn {
  width: 100%;
  margin-top: var(--space-md);
}

/* --- Footer --- */
.footer {
  background: #0D0D1A;
  color: rgba(255, 255, 255, 0.7);
  padding: var(--space-3xl) 0 var(--space-lg);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer__brand {
  max-width: 300px;
}

.footer__logo {
  height: 50px;
  margin-bottom: var(--space-lg);
}

.footer__desc {
  font-size: var(--font-size-sm);
  line-height: 1.8;
  margin-bottom: var(--space-lg);
}

.footer__social {
  display: flex;
  gap: var(--space-md);
}

.footer__social a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.footer__social a:hover {
  background: var(--color-secondary);
  transform: translateY(-3px);
}

.footer__column h4 {
  color: var(--bg-white);
  font-size: var(--font-size-base);
  margin-bottom: var(--space-lg);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer__links a,
.footer__links li {
  font-size: var(--font-size-sm);
  transition: color var(--transition-fast);
}

.footer__links a:hover {
  color: var(--color-secondary);
}

/* Footer contact items with aligned icons */
.footer__contact .footer__links li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}

.footer__icon {
  flex-shrink: 0;
  width: 1.2em;
  text-align: center;
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--space-lg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--font-size-sm);
}

/* --- WhatsApp Button --- */
.whatsapp-btn {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  transition: all var(--transition-base);
  animation: pulse 2s infinite;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-xl);
}

.whatsapp-btn svg {
  width: 32px;
  height: 32px;
  fill: white;
}

@keyframes pulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.4);
  }

  50% {
    box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
  }
}

/* --- Animations --- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.slide-in-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.6s ease-out;
}

.slide-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.slide-in-right {
  opacity: 0;
  transform: translateX(50px);
  transition: all 0.6s ease-out;
}

.slide-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .method__steps::before {
    display: none;
  }

  .method__steps {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }

  .contact__wrapper {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --font-size-5xl: 2.5rem;
    --font-size-4xl: 2rem;
    --font-size-3xl: 1.5rem;
  }

  .nav__menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 350px;
    height: 100vh;
    background: var(--bg-white);
    flex-direction: column;
    justify-content: center;
    gap: var(--space-xl);
    box-shadow: var(--shadow-xl);
    transition: right var(--transition-base);
  }

  .nav__menu.active {
    right: 0;
  }

  .nav__menu .nav__link {
    color: var(--text-dark);
  }

  .nav__toggle {
    display: flex;
    z-index: 1001;
  }

  .hero__actions {
    flex-direction: column;
  }

  .hero__actions .btn {
    width: 100%;
  }

  .solutions__grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer__brand {
    max-width: 100%;
  }

  .footer__social {
    justify-content: center;
  }

  .footer__bottom {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }

  .whatsapp-btn {
    bottom: var(--space-lg);
    right: var(--space-lg);
    width: 55px;
    height: 55px;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-md);
  }

  .section {
    padding: var(--space-3xl) 0;
  }

  .solution-card {
    padding: var(--space-xl);
  }

  .contact__form-wrapper {
    padding: var(--space-xl);
  }
}