/* ==========================================================================
   SARAGISMONDI.COM — Global Stylesheet
   Variables · Reset · Typography · Nav · Footer · Utilities · Buttons
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. DESIGN TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Colors */
  --background-primary:          #2c3036;
  --background-secondary:        #282C33;
  --background-tertiary-light:   rgba(99, 108, 113, 0.1);
  --color-light-grey:            #ABB2BF;
  --color-purple:                #5F2DF1;
  --color-pink:                  #C778DD;
  --color-accent:                #64FFDA;
  --color-orange:                #FF6B6B;
  --color-yellow:                #FFE66D;
  --color-green:                 #4ECDC4;
  --color-white:                 #FFFFFF;
  --color-dark:                  #1A1E23;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, var(--color-purple) 0%, var(--color-pink) 100%);
  --gradient-accent:  linear-gradient(135deg, var(--color-accent) 0%, var(--color-green) 100%);
  --gradient-warm:    linear-gradient(135deg, var(--color-orange) 0%, var(--color-yellow) 100%);

  /* Typography */
  --font-mono:    "Fira Code", monospace;
  --font-sans:    "Inter", sans-serif;
  --font-display: "Poppins", sans-serif;

  /* Shadows */
  --shadow-soft:   0 4px 20px rgba(0, 0, 0, 0.1);
  --shadow-strong: 0 8px 30px rgba(95, 45, 241, 0.2);
  --text-shadow:   2px 2px 4px rgba(0, 0, 0, 0.2);

  /* Layout */
  --container-max: 1200px;
  --nav-height:    72px;
  --section-padding: 5rem 2rem;

  /* Transitions */
  --transition-fast:   0.2s ease;
  --transition-base:   0.3s ease;
  --transition-slow:   0.5s ease;

  /* Border radius */
  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   20px;
  --radius-pill: 50px;
}

/* --------------------------------------------------------------------------
   2. RESET & BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font-mono);
  color: var(--color-light-grey);
  background-color: var(--background-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font: inherit;
}

/* --------------------------------------------------------------------------
   3. TYPOGRAPHY
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--color-white);
  line-height: 1.1;
}

p {
  font-family: var(--font-sans);
  color: var(--color-light-grey);
  line-height: 1.7;
}

.highlight {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --------------------------------------------------------------------------
   4. LAYOUT UTILITIES
   -------------------------------------------------------------------------- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: var(--section-padding);
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 1rem;
}

.section-subtitle {
  font-family: var(--font-sans);
  font-size: 1.1rem;
  color: var(--color-light-grey);
  max-width: 600px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   5. BUTTONS
   -------------------------------------------------------------------------- */
.btn-primary {
  display: inline-block;
  background: var(--gradient-primary);
  color: var(--color-white);
  padding: 0.9rem 2rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left var(--transition-slow);
}

.btn-primary:hover::before { left: 100%; }

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(95, 45, 241, 0.4);
}

.btn-secondary {
  display: inline-block;
  color: var(--color-accent);
  padding: 0.9rem 2rem;
  border: 2px solid var(--color-accent);
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition-base);
  background: transparent;
}

.btn-secondary:hover {
  background: var(--color-accent);
  color: var(--background-primary);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(100, 255, 218, 0.3);
}

.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #25D366;
  color: #fff;
  padding: 0.9rem 2rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.2);
}

.btn-whatsapp:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.btn-email {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--color-pink);
  padding: 0.9rem 2rem;
  border: 2px solid var(--color-pink);
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition-base);
  background: transparent;
}

.btn-email:hover {
  background: var(--color-pink);
  color: var(--background-primary);
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(199, 120, 221, 0.3);
}

.btn-email svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* --------------------------------------------------------------------------
   6. NAVIGATION
   -------------------------------------------------------------------------- */
.nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2rem;
  height: var(--nav-height);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(44, 48, 54, 0.85);
  border-bottom: 1px solid rgba(95, 45, 241, 0.1);
}

.logo {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--color-white);
  text-decoration: none;
}

.logo::before {
  content: '< ';
  color: var(--color-purple);
  animation: pulse 2s infinite;
}

.logo::after {
  content: ' />';
  color: var(--color-purple);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.6; }
}

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

.nav-list li a {
  color: var(--color-light-grey);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  transition: color var(--transition-base), transform var(--transition-base);
  padding: 0.6rem!important;
}

.nav-list li a::before {
  color: var(--color-purple);
  margin-right: 0.4rem;
  font-size: 0.75rem;
}

.nav-list li:nth-child(1) a::before { content: '01.'; }
.nav-list li:nth-child(2) a::before { content: '02.'; }
.nav-list li:nth-child(3) a::before { content: '03.'; }
.nav-list li:nth-child(4) a::before { content: '04.'; }
.nav-list li:nth-child(5) a::before { content: '05.'; }
.nav-list li:nth-child(6) a::before { content: '06.'; }
.nav-list li:nth-child(7) a::before { content: '07.'; }

.nav-list li a:hover,
.nav-list li a.active {
  color: var(--color-accent);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #25D366;
  color: #fff !important;
  padding: 0.5rem 1.2rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  margin-left: 1rem;
}

.nav-cta::before { display: none !important; content: none !important; }

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.35);
  color: #fff !important;
}

.nav-cta svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  flex-shrink: 0;
}

/* Hamburger */
.nav-icon {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
  padding: 6px;
  background: none;
  border: none;
}

.nav-icon span {
  width: 24px;
  height: 2px;
  background: var(--color-purple);
  border-radius: 2px;
  transition: var(--transition-base);
  display: block;
}

.nav-icon.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-icon.open span:nth-child(2) { opacity: 0; }
.nav-icon.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   7. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--background-secondary);
  border-top: 1px solid rgba(95, 45, 241, 0.1);
  padding: 3rem 2rem 1.5rem;
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: start;
  gap: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(99, 108, 113, 0.15);
}

.footer-brand .logo {
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.footer-brand p {
  font-size: 0.85rem;
  max-width: 220px;
  line-height: 1.5;
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  align-items: center;
}

.footer-nav a {
  color: var(--color-light-grey);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  transition: color var(--transition-base);
}

.footer-nav a:hover { color: var(--color-accent); }

.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-items: flex-end;
}

.footer-contact a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-light-grey);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  transition: color var(--transition-base);
}

.footer-contact a:hover { color: var(--color-accent); }

.footer-contact svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
}

.footer-bottom {
  max-width: var(--container-max);
  margin: 1.5rem auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer-bottom p {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: rgba(171, 178, 191, 0.5);
}

.footer-bottom span { color: var(--color-pink); }

/* --------------------------------------------------------------------------
   8. SKILL TAGS
   -------------------------------------------------------------------------- */
.skill-tag {
  background: rgba(95, 45, 241, 0.1);
  border: 1px solid var(--color-purple);
  color: #987af0;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-lg);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  transition: all var(--transition-base);
  display: inline-block;
}

.skill-tag:hover {
  background: var(--color-purple);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-strong);
}

/* --------------------------------------------------------------------------
   9. CTA BANNER (shared across pages)
   -------------------------------------------------------------------------- */
.cta-banner {
  background: linear-gradient(135deg, rgba(95,45,241,0.15) 0%, rgba(199,120,221,0.1) 100%);
  border: 1px solid rgba(95, 45, 241, 0.25);
  border-radius: var(--radius-md);
  padding: 3.5rem 2rem;
  text-align: center;
  margin: 4rem auto;
  max-width: var(--container-max);
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(95,45,241,0.1) 0%, transparent 70%);
  pointer-events: none;
}

.cta-banner h2 {
  font-size: 2rem;
  margin-bottom: 0.75rem;
}

.cta-banner p {
  font-size: 1rem;
  margin-bottom: 2rem;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

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

/* --------------------------------------------------------------------------
   10. PAGE HERO (inner pages)
   -------------------------------------------------------------------------- */
.page-hero {
  padding: 4rem 2rem 3rem;
  text-align: center;
  position: relative;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 50%; transform: translateX(-50%);
  width: 600px; height: 300px;
  background: radial-gradient(ellipse, rgba(95,45,241,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.page-hero .breadcrumb {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--color-purple);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.page-hero .breadcrumb a {
  color: var(--color-light-grey);
  transition: color var(--transition-base);
}

.page-hero .breadcrumb a:hover { color: var(--color-accent); }

.page-hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.page-hero p {
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   11. SHARED KEYFRAMES
   -------------------------------------------------------------------------- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

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

@keyframes blink {
  0%, 50%   { border-color: var(--color-accent); }
  51%, 100% { border-color: transparent; }
}

/* --------------------------------------------------------------------------
   12. RESPONSIVE — NAVIGATION & FOOTER
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .nav-list {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: rgba(40, 44, 51, 0.98);
    flex-direction: column;
    padding: 1.5rem 2rem;
    gap: 1rem;
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(95, 45, 241, 0.15);
  }

  .nav-list.active { display: flex; }
  .nav-icon { display: flex; }

  .nav-cta {
    margin-left: 0;
    width: 100%;
    justify-content: center;
  }

  .page-hero h1 { font-size: 2.2rem; }

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

  .footer-brand p { max-width: 100%; }

  .footer-nav {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
  }

  .footer-contact { align-items: center; }
  .footer-bottom { justify-content: center; text-align: center; }
  .cta-banner h2 { font-size: 1.6rem; }
}

@media (max-width: 480px) {
  .container { padding: 0 1rem; }
  .section { padding: 3rem 1rem; }
  .section-title { font-size: 1.8rem; }
  .page-hero { padding: 3rem 1rem 2rem; }
  .page-hero h1 { font-size: 1.8rem; }
}

/* --------------------------------------------------------------------------
   13. ACCESSIBILITY
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
