/* style.css */

/*--------------------------------------------------------------
# CSS Variables
--------------------------------------------------------------*/
:root {
  --font-primary: 'Raleway', sans-serif;
  --font-secondary: 'Open Sans', sans-serif;

  /* Split-Complementary Color Scheme (Base Blue) */
  --color-primary: #0D6EFD; /* Bootstrap Blue - Primary actions, links */
  --color-primary-darker: #0B5ED7;
  --color-primary-lighter: #cfe2ff;

  --color-accent1: #FD7E14; /* Orange - Secondary actions, highlights */
  --color-accent1-darker: #E86A04;
  --color-accent1-lighter: #FFE8D6;

  --color-accent2: #6F42C1; /* Purple - Tertiary accents, alternative highlights */
  --color-accent2-darker: #59359a;
  --color-accent2-lighter: #e2d9f3;

  --color-success: #198754;
  --color-info: #0DCAF0;
  --color-warning: #FFC107;
  --color-danger: #DC3545;

  --color-text-strong: #222222; /* For main headings */
  --color-text-dark: #343A40;   /* For body text, subheadings */
  --color-text-light: #FFFFFF;
  --color-text-muted: #6c757d;

  --color-bg-light: #FFFFFF;
  --color-bg-medium: #F8F9FA; /* Light gray for section alternation */
  --color-bg-dark: #212529;   /* For footer or dark sections */
  --color-bg-hero-overlay: rgba(0, 0, 0, 0.55); /* Slightly darker overlay */
  --color-bg-card: var(--color-bg-light);

  --border-color: #dee2e6;
  --border-radius-sm: 0.25rem;
  --border-radius-md: 0.5rem; /* Standard border radius */
  --border-radius-lg: 0.8rem;
  --border-radius-pill: 50rem;

  --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
  --shadow-md: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);

  --transition-speed: 0.3s;
  --transition-easing: ease-in-out;

  --navbar-height: 70px; /* Approximate navbar height for padding adjustments */
  --padding-top-content: 100px; /* For pages like privacy, terms */
}

/*--------------------------------------------------------------
# General Styles
--------------------------------------------------------------*/
body {
  font-family: var(--font-secondary);
  color: var(--color-text-dark);
  background-color: var(--color-bg-light);
  line-height: 1.7;
  font-size: 1rem;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-speed) var(--transition-easing);
}

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

/* Headings */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-primary);
  font-weight: 700;
  color: var(--color-text-strong);
  margin-top: 0;
  margin-bottom: 0.75rem; /* Adjusted from bootstrap's 0.5rem for more space */
}
/* Ensure consistent heading color from HTML is applied if not overridden by Bootstrap */
h1, h2, h3, h4, h5, h6 { color: var(--color-text-strong) !important; }


.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  position: relative;
  text-align: center;
  color: var(--color-text-strong);
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.section-title::after {
  content: '';
  position: absolute;
  display: block;
  width: 60px;
  height: 3px;
  background: var(--color-primary);
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  border-radius: var(--border-radius-pill);
}

section {
  padding: 60px 0;
  overflow: hidden; /* For scroll animations and potential skewed elements */
}

.bg-light { /* Bootstrap's .bg-light */
  background-color: var(--color-bg-medium) !important;
}
.navbar-collapse{
  background: #fff;
}
/*--------------------------------------------------------------
# Global Button Styles
--------------------------------------------------------------*/
.btn {
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 0.75rem 1.75rem; /* Slightly larger padding */
  border-radius: var(--border-radius-pill); /* Modern pill shape */
  transition: all var(--transition-speed) var(--transition-easing);
  box-shadow: var(--shadow-sm);
  border-width: 2px;
  line-height: 1.5;
}

.btn:hover, .btn:focus {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.btn:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.btn-primary {
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-text-light);
}
.btn-primary:hover, .btn-primary:focus {
  background-color: var(--color-primary-darker);
  border-color: var(--color-primary-darker);
  color: var(--color-text-light);
}

.btn-secondary { /* Custom or Bootstrap override */
  background-color: var(--color-accent1);
  border-color: var(--color-accent1);
  color: var(--color-text-light);
}
.btn-secondary:hover, .btn-secondary:focus {
  background-color: var(--color-accent1-darker);
  border-color: var(--color-accent1-darker);
  color: var(--color-text-light);
}

.btn-outline-primary {
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn-outline-primary:hover, .btn-outline-primary:focus {
  background-color: var(--color-primary);
  color: var(--color-text-light);
}

.btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.1rem;
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
}

/* 'Read More' links - style for .btn.btn-sm.btn-outline-primary */
.card .btn-sm.btn-outline-primary {
  font-weight: 700;
}
.card .btn-sm.btn-outline-primary::after {
  content: " \2192"; /* Right arrow */
  transition: transform var(--transition-speed) var(--transition-easing);
  display: inline-block;
}
.card .btn-sm.btn-outline-primary:hover::after {
  transform: translateX(4px);
}

/*--------------------------------------------------------------
# Forms (General styling for inputs)
--------------------------------------------------------------*/
.form-control, .form-select {
    border-radius: var(--border-radius-md);
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    transition: border-color var(--transition-speed) var(--transition-easing), box-shadow var(--transition-speed) var(--transition-easing);
    font-size: 0.95rem;
}
.form-control:focus, .form-select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 0.25rem rgba(var(--color-primary), 0.25); /* Use RGB if var() doesn't work in rgba directly */
    /* box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25); Fallback */
}
label.form-label {
    font-weight: 600;
    color: var(--color-text-dark);
    margin-bottom: 0.5rem;
}

/*--------------------------------------------------------------
# Header / Navbar
--------------------------------------------------------------*/
.navbar {
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
  height: var(--navbar-height);
}

.navbar-brand {
  font-family: var(--font-primary);
  font-weight: 800 !important; /* from HTML */
  font-size: 1.8rem !important; /* from HTML */
  color: var(--color-primary) !important; /* from HTML */
}

.navbar .nav-link {
  font-family: var(--font-primary);
  font-weight: 600;
  color: var(--color-text-dark);
  padding: 0.5rem 1rem;
  transition: color var(--transition-speed) var(--transition-easing);
  position: relative;
}

.navbar .nav-link:hover,
.navbar .nav-link.active {
  color: var(--color-primary);
}

.navbar .nav-link::before { /* Underline effect for hover/active */
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--color-primary);
  visibility: hidden;
  transition: all var(--transition-speed) var(--transition-easing);
}

.navbar .nav-link:hover::before,
.navbar .nav-link.active::before {
  visibility: visible;
  width: 70%;
}

.navbar-toggler {
  border-color: rgba(0,0,0,0.1);
}
.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(0, 0, 0, 0.55)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Ensure content isn't hidden by sticky header */
body:has(header.sticky-top) {
  /* padding-top: var(--navbar-height); */
}


/*--------------------------------------------------------------
# Hero Section
--------------------------------------------------------------*/
#hero {
  width: 100%;
  /* vh-100 is in HTML, controls height */
  background-size: cover !important; /* from prompt */
  background-position: center !important;
  background-repeat: no-repeat !important; /* from prompt */
  position: relative;
}

/* text-overlay class is already in HTML style block, provides gradient and text color */
#hero .text-overlay h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: var(--color-text-light) !important; /* Reinforce from prompt */
}

#hero .text-overlay p {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  color: var(--color-text-light) !important; /* Reinforce from prompt */
}

@media (max-width: 768px) {
  #hero .text-overlay h1 {
    font-size: 2.5rem;
  }
  #hero .text-overlay p {
    font-size: 1.1rem;
  }
}

/*--------------------------------------------------------------
# Card Styles
--------------------------------------------------------------*/
.card {
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-speed) var(--transition-easing), box-shadow var(--transition-speed) var(--transition-easing);
  background-color: var(--color-bg-card);
  display: flex; /* For STROGO requirement */
  flex-direction: column; /* For STROGO requirement */
  /* align-items: center; /* STROGO - centers whole card content block, might not be desired for text */
}

.card:hover {
  transform: translateY(-5px) scale(1.02); /* Morphing: subtle scale */
  box-shadow: var(--shadow-lg);
}

.card-image, .image-container { /* This is the container for the image inside the card */
  width: 100%;
  overflow: hidden;
  border-top-left-radius: var(--border-radius-md); /* Match card radius if image is at top */
  border-top-right-radius: var(--border-radius-md);
  display: flex; /* Centers image if it's smaller, though object-fit should handle */
  align-items: center;
  justify-content: center;
}
.card-image.img-container-h250, .image-container.img-container-h250 { height: 250px; }
.card-image.img-container-h300, .image-container.img-container-h300 { height: 300px; }

.card-image img, .image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* STROGO requirement */
  transition: transform var(--transition-speed) var(--transition-easing);
}

.card:hover .card-image img, .card:hover .image-container img {
  transform: scale(1.05); /* Zoom effect on image hover */
}

.card-body {
  padding: 1.5rem;
  flex-grow: 1; /* Allows card bodies to take available space in flex column */
  display: flex;
  flex-direction: column;
}
.card-body > *:last-child {
    margin-top: auto; /* Pushes the last element (e.g., button) to the bottom */
}


.card-title { /* Already styled by h5, but can add specifics */
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--color-text-strong) !important;
}
/* Ensure card text has good contrast if card bg changes */
.card .card-text {
  color: var(--color-text-dark);
  font-size: 0.95rem;
}
.card .card-text.text-muted {
  color: var(--color-text-muted) !important;
}

/* Centering content within cards (text primarily) */
.card.text-center .card-body,
.card .text-center { /* If a utility class is used inside card-body */
    text-align: center;
}
/* STROGO: if all card content must be centered */
/* .card { align-items: center; } */ /* This centers the .card-image and .card-body containers */
/* .card-body { text-align: center; } */ /* This centers text inside card-body */
/* Per prompt, HTML uses .text-center on some cards for team members, this is good. */

/* Warped Grids elements for card containers - example for a section with cards */
.warped-grid-cards .row > [class*="col-"] {
  /* For staggered effect if desired, use with caution */
  /* &:nth-child(even) { margin-top: 2rem; } */
}

/* Glassmorphism card variant */
.card-glass {
  background: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.17);
}
.card-glass .card-title, .card-glass .card-text {
    color: var(--color-text-dark); /* Ensure readability */
}

/*--------------------------------------------------------------
# Specific Sections
--------------------------------------------------------------*/

/* History (Trayectoria) & Innovation */
#trayectoria img, #innovacion img {
  border-radius: var(--border-radius-lg);
}
#trayectoria h3, #innovacion h3 {
    text-align: left !important; /* Override global center for these specific headings */
    margin-bottom: 1rem;
    color: var(--color-text-strong) !important;
}

/* Our Process (Proceso) */
#proceso .card {
  border: none; /* remove default card border for a flatter design */
  background-color: var(--color-bg-light); /* Ensure contrast if #proceso is .bg-light */
  box-shadow: var(--shadow-md);
}
#proceso .card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px); /* Keep hover consistent */
}
#proceso .card-title {
  color: var(--color-primary) !important; /* Use primary color for process step titles */
  font-size: 1.4rem;
}

/* Statistics (Resultados) */
#resultados .progress {
  height: 30px !important; /* from HTML */
  border-radius: var(--border-radius-pill);
  box-shadow: var(--shadow-sm) inset;
  margin-bottom: 0.5rem;
}
#resultados .progress-bar {
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  border-radius: var(--border-radius-pill); /* Ensure inner bar is also rounded */
  text-shadow: 1px 1px 1px rgba(0,0,0,0.2);
}
#resultados h4 { /* Text above progress bar */
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--color-text-dark) !important;
}
#resultados .progress-bar.bg-warning { /* Bootstrap specific */
    color: var(--color-text-dark) !important; /* Ensure text visible on yellow */
}

/* Awards (Reconocimientos) & Case Studies (Casos Exito) */
/* These use standard card styling, which should be fine */

/* Resources Section */
#recursos .list-group-item {
  border-radius: var(--border-radius-md);
  margin-bottom: 0.75rem;
  border-width: 1px;
  border-color: var(--border-color);
  transition: all var(--transition-speed) var(--transition-easing);
  padding: 1rem 1.25rem;
}
#recursos .list-group-item:hover {
  background-color: var(--color-primary-lighter);
  color: var(--color-primary-darker);
  transform: translateX(5px);
  border-left: 4px solid var(--color-primary);
}
#recursos .list-group-item .badge {
  font-size: 0.75rem;
  padding: 0.4em 0.7em;
}

/* Team (Equipo / Instructors) */
#equipo .card {
    background-color: transparent; /* if section is .bg-light */
    border: none;
    box-shadow: none;
}
#equipo .card:hover {
    transform: translateY(-5px) scale(1.02);
    /* box-shadow: var(--shadow-md); /* Add shadow on hover for team cards if desired */
}
#equipo .card-image, #equipo .image-container {
    border-radius: 50%; /* Circular images for team members */
    width: 180px; /* Fixed size for circle */
    height: 180px;
    margin: 0 auto 1rem auto; /* Center the image container */
    box-shadow: var(--shadow-md);
}
#equipo .card-image img, #equipo .image-container img {
    border-radius: 50%;
}
#equipo .card-body {
    text-align: center; /* Center text for team members */
}
#equipo .card-title {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}
#equipo .card-text.text-muted {
    font-size: 0.9rem;
    color: var(--color-primary) !important; /* Accent color for role */
    font-weight: 600;
}

/* Press Section (Prensa) */
#prensa .blockquote {
  border-left: 4px solid var(--color-primary);
  padding: 1.5rem;
  border-radius: var(--border-radius-md);
  transition: box-shadow var(--transition-speed) var(--transition-easing);
  font-size: 1.05rem;
}
#prensa .blockquote:hover {
  box-shadow: var(--shadow-md);
}
#prensa .blockquote-footer {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}
#prensa .blockquote p {
    color: var(--color-text-dark);
}

/* Events Section (Eventos) */
#eventos .card {
  box-shadow: var(--shadow-md);
}
#eventos .card-title {
  color: var(--color-primary) !important; /* Match process title color */
}
#eventos .card-subtitle {
  font-size: 0.9rem;
  font-weight: 600;
}

/* Contact Section (Contacto) */
#contacto {
  /* background: linear-gradient(135deg, var(--color-primary-lighter) 0%, var(--color-accent1-lighter) 100%); */
  /* Or a subtle pattern */
}
#contacto .form-control {
    background-color: var(--color-bg-light); /* ensure contrast if section has bg */
}


/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
.footer { /* Assuming a class 'footer' might be used, or style 'footer' tag */
  background-color: var(--color-bg-dark);
  color: var(--color-text-muted); /* Muted by default */
  padding-top: 3rem;
  padding-bottom: 1rem;
  font-size: 0.9rem;
}

.footer h5 {
  font-family: var(--font-primary);
  color: var(--color-text-light) !important; /* From HTML */
  font-weight: 700;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
  font-size: 1.1rem;
}

.footer p, .footer a {
  color: var(--color-text-muted) !important; /* From HTML */
}

.footer a:hover {
  color: var(--color-primary-lighter) !important;
  text-decoration: underline;
}

.footer .mt-3 a { /* Social media text links */
  margin-right: 1rem; /* From HTML */
  font-weight: 500;
  transition: color var(--transition-speed) var(--transition-easing);
  font-size: 0.95rem;
}
.footer .mt-3 a:last-child {
  margin-right: 0;
}
.footer .mt-3 a:hover {
  color: var(--color-text-light) !important;
}

.footer .text-center.pt-4 { /* Copyright text */
  border-top: 1px solid #444 !important; /* From HTML */
  color: var(--color-text-muted) !important; /* From HTML */
  padding-top: 1.5rem !important;
  margin-top: 1.5rem;
}


/*--------------------------------------------------------------
# Specific Page Styles
--------------------------------------------------------------*/
/* success.html */
.page-success-container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  background-color: var(--color-bg-medium);
}
.page-success-container h1 {
  color: var(--color-success);
  font-size: 3rem;
  margin-bottom: 1rem;
}
.page-success-container p {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
}
.page-success-container .btn {
    margin-top: 1rem;
}

/* privacy.html, terms.html */
.page-legal-content {
  padding-top: var(--padding-top-content); /* Ensure content below fixed/sticky header */
  padding-bottom: 3rem;
}
.page-legal-content h1 {
    margin-bottom: 2rem;
    font-size: 2.5rem;
}
.page-legal-content h2 {
    font-size: 1.8rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}
.page-legal-content p, .page-legal-content li {
    line-height: 1.8;
    margin-bottom: 1rem;
}


/*--------------------------------------------------------------
# Modals (Bootstrap) - minor enhancements
--------------------------------------------------------------*/
.modal-content {
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-lg);
  border: none;
}
.modal-header {
  border-bottom: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
}
.modal-header .modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-text-strong) !important; /* From HTML */
}
.modal-body {
  padding: 1.5rem;
  line-height: 1.8;
}
.modal-body img {
    border-radius: var(--border-radius-md);
    margin-bottom: 1.5rem;
}
.modal-footer {
  border-top: 1px solid var(--border-color);
  padding: 1rem 1.5rem;
}
.modal-dialog.modal-dialog-centered { /* Ensure vertical centering works well */
    align-items: center;
}
/* Glassmorphism for modals if desired - add .modal-glass to .modal-content */
/* .modal-content.modal-glass { ... } */


/*--------------------------------------------------------------
# Utility Classes
--------------------------------------------------------------*/
.text-primary { color: var(--color-primary) !important; }
.text-accent1 { color: var(--color-accent1) !important; }
.text-accent2 { color: var(--color-accent2) !important; }

.bg-primary-light { background-color: var(--color-primary-lighter) !important; }
.bg-accent1-light { background-color: var(--color-accent1-lighter) !important; }

/* Responsive text size for hero could be a utility */
.hero-text-responsive h1 { font-size: calc(1.5rem + 3vw); }
.hero-text-responsive p { font-size: calc(0.9rem + 0.5vw); }


/* Warped Grid Elements - Example */
.skewed-section-divider {
    position: relative;
    padding: 80px 0; /* Adjust padding */
}
.skewed-section-divider::before {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 100%; /* Cover the original section space */
    background: var(--color-bg-medium); /* Or a gradient */
    z-index: -1;
}
.top-skew::before {
    top: -50px; /* Adjust based on skew amount and desired overlap */
    transform: skewY(-2deg); /* Example skew */
    transform-origin: top left;
}
.bottom-skew::before {
    bottom: -50px; /* Adjust */
    transform: skewY(2deg); /* Example skew */
    transform-origin: bottom left;
}
/* Apply like <section class="skewed-section-divider top-skew"> */

/*--------------------------------------------------------------
# Animations & ScrollReveal (ScrollReveal is JS based)
--------------------------------------------------------------*/
/* Basic fade-in for elements that might not be covered by ScrollReveal or for initial load */
.fade-in {
  animation: fadeInAnimation ease 1s;
  animation-iteration-count: 1;
  animation-fill-mode: forwards;
}
@keyframes fadeInAnimation {
  0% { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Ensure ScrollReveal elements are initially hidden if JS is slow */
[data-sr-id] {
  visibility: hidden;
}

/*--------------------------------------------------------------
# Media Queries for Responsiveness (Bootstrap handles most)
--------------------------------------------------------------*/
@media (max-width: 992px) {
  .section-title {
    font-size: 2rem;
  }
  #hero .text-overlay h1 { font-size: 2.8rem; } /* Adjusted from above */
  #hero .text-overlay p { font-size: 1.1rem; } /* Adjusted from above */
  .page-legal-content { padding-top: calc(var(--navbar-height) + 20px); } /* Adjust if navbar height changes on mobile */
}

@media (max-width: 768px) {
  h1, .h1 { font-size: 2.2rem; }
  h2, .h2 { font-size: 1.8rem; }
  .section-title { font-size: 1.8rem; margin-bottom: 1rem; padding-bottom: 0.8rem;}
  .section-title::after { width: 50px; height: 2px; }
  section { padding: 40px 0; }
  .btn { padding: 0.6rem 1.25rem; font-size: 0.9rem; }
  .btn-lg { padding: 0.8rem 2rem; font-size: 1rem; }
  #equipo .card-image, #equipo .image-container { width: 150px; height: 150px; }
}

@media (max-width: 576px) {
  .navbar-brand { font-size: 1.5rem !important; }
  #hero .text-overlay h1 { font-size: 2rem; }
  #hero .text-overlay p { font-size: 1rem; }
}