/* ======= Base Variables and Settings ======= */
:root {
  /* Primary color scheme - Complementary colors */
  --primary-color: #ff3b3f;
  --primary-dark: #d32f33;
  --primary-light: #ff6b6f;
  
  --complementary-color: #4ca1ff;
  --complementary-dark: #2a7fdb;
  --complementary-light: #7cb8ff;
  
  /* Neutral colors */
  --dark: #252525;
  --light: #f8f8f8;
  --gray: #a3a3a3;
  --gray-light: #e5e5e5;
  --gray-dark: #666666;
  
  /* Typography */
  --title-font: 'Archivo Black', sans-serif;
  --body-font: 'Roboto', sans-serif;
  
  /* Shadows and effects */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.2);
  
  /* Brutalist style properties */
  --brutalist-border: 3px solid var(--dark);
  --brutalist-shadow: 6px 6px 0 var(--dark);
  
  /* Card skew for Warped Grid design */
  --card-skew: -2deg;
  --card-skew-opposite: 2deg;
  
  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ======= Global Styles ======= */
html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body-font);
  color: var(--dark);
  background-color: var(--light);
  overflow-x: hidden;
  line-height: 1.6;
  padding-top: 0 !important; 
}

h1, h2, h3, h4, h5, h6,
.title {
  font-family: var(--title-font);
  font-weight: 700;
  color: var(--dark);
  line-height: 1.2;
}

a {
  color: var(--complementary-dark);
  transition: color var(--transition-fast);
}

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

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

.section {
  padding: 4rem 1rem;
  position: relative;
}

/* For privacy and terms pages */
.privacy-content, 
.terms-content {
  padding-top: 100px;
}

/* Success page specific styles */
.success-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
}

/* ======= Brutalist Design Elements ======= */
.brutalist-title {
  font-family: var(--title-font);
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
  margin-bottom: 2rem;
  display: inline-block;
}

.brutalist-title::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 100%;
  height: 5px;
  background-color: var(--primary-color);
  z-index: -1;
}

.brutalist-button,
.button.is-primary {
  background-color: var(--primary-color);
  color: white;
  border: var(--brutalist-border);
  box-shadow: var(--brutalist-shadow);
  padding: 0.75rem 1.5rem;
  font-weight: bold;
  text-transform: uppercase;
  position: relative;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.brutalist-button:hover,
.button.is-primary:hover {
  transform: translate(2px, 2px);
  box-shadow: 3px 3px 0 var(--dark);
  background-color: var(--primary-dark);
}

.brutalist-button-secondary,
.button.is-outlined {
  background-color: transparent;
  color: var(--light);
  border: var(--brutalist-border);
  box-shadow: var(--brutalist-shadow);
  padding: 0.75rem 1.5rem;
  font-weight: bold;
  text-transform: uppercase;
  position: relative;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.brutalist-button-secondary:hover,
.button.is-outlined:hover {
  transform: translate(2px, 2px);
  box-shadow: 3px 3px 0 var(--dark);
  background-color: rgba(255, 255, 255, 0.1);
}

.brutalist-button-small {
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
  box-shadow: 3px 3px 0 var(--dark);
}

.brutalist-button-small:hover {
  box-shadow: 1px 1px 0 var(--dark);
}

.brutalist-input,
.brutalist-textarea,
.brutalist-select {
  border: 2px solid var(--dark);
  border-radius: 0;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.1);
  transition: box-shadow var(--transition-fast), transform var(--transition-fast);
}

.brutalist-input:focus,
.brutalist-textarea:focus,
.brutalist-select:focus {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.1);
  border-color: var(--primary-color);
  outline: none;
}

/* ======= Warped Grid Design Elements ======= */
.card {
  border: var(--brutalist-border);
  box-shadow: var(--brutalist-shadow);
  border-radius: 0;
  overflow: hidden;
  transform: skew(var(--card-skew));
  transition: transform var(--transition-normal);
  margin-bottom: 2rem;
  background-color: white;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: skew(0deg) scale(1.02);
}

.card-image {
  width: 100%;
  overflow: hidden;
  text-align: center;
}

.card-image img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transform: skew(var(--card-skew-opposite));
  transition: transform var(--transition-normal);
}

.card:hover .card-image img {
  transform: skew(0deg) scale(1.05);
}

.card-content {
  padding: 1.5rem;
  transform: skew(var(--card-skew-opposite));
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card:hover .card-content {
  transform: skew(0deg);
}

/* ======= Header & Navigation ======= */
.header-section {
  position: fixed;
  width: 100%;
  z-index: 100;
  transition: background-color var(--transition-normal);
}

.header-section .navbar {
  padding: 0.5rem 0;
}

.header-section .navbar.is-transparent {
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
}

.header-section .navbar-item {
  color: var(--light);
  font-weight: 500;
}

.header-section .navbar-item:hover {
  color: var(--primary-light);
  background-color: transparent;
}

.header-section .navbar-burger span {
  background-color: var(--light);
}

/* ======= Hero Section ======= */
.hero {
  position: relative;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero .title,
.hero .subtitle,
.hero p {
  color: white;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.hero-body {
  padding: 6rem 1.5rem;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 2;
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  animation: bounce 2s infinite;
  z-index: 2;
}

.mouse {
  width: 26px;
  height: 40px;
  border: 2px solid white;
  border-radius: 13px;
  margin: 0 auto 10px;
  position: relative;
}

.mouse:after {
  content: '';
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 8px;
  background-color: white;
  border-radius: 2px;
  animation: scroll 1.5s infinite;
}

@keyframes scroll {
  0% { opacity: 1; transform: translateX(-50%) translateY(0); }
  100% { opacity: 0; transform: translateX(-50%) translateY(15px); }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
  40% { transform: translateX(-50%) translateY(-10px); }
  60% { transform: translateX(-50%) translateY(-5px); }
}

/* ======= Services Section ======= */
.services-section {
  background-color: var(--light);
}

.service-card .card-image img {
  height: 250px;
}

.progress-container {
  width: 100%;
  height: 10px;
  background-color: var(--gray-light);
  border-radius: 5px;
  margin: 0.5rem 0 1rem;
  position: relative;
}

.progress-bar {
  height: 100%;
  background-color: var(--complementary-color);
  border-radius: 5px;
  position: absolute;
  top: 0;
  left: 0;
  transition: width 1s ease;
}

.progress-text {
  position: absolute;
  top: -20px;
  right: 0;
  font-size: 0.85rem;
  color: var(--complementary-dark);
  font-weight: 500;
}

/* ======= Instructors/Team Section ======= */
.instructors-section {
  background-color: var(--gray-light);
}

.instructor-card .card-image img {
  height: 350px;
  width: 100%;
  object-fit: cover;
}

.instructor-card .tag {
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
}

/* ======= News Section ======= */
.news-section {
  background-color: var(--light);
}

.news-date {
  color: var(--complementary-dark);
  font-weight: 500;
  margin-bottom: 0.5rem;
  display: block;
}

/* ======= External Resources Section ======= */
.external-resources {
  background-color: var(--gray-light);
}

.resource-card {
  text-align: center;
  height: 100%;
}

/* ======= Research Section ======= */
.research-section {
  background-color: var(--light);
}

/* ======= Workshops Section ======= */
.workshops-section {
  background-color: var(--gray-light);
}

.workshop-date {
  color: var(--complementary-dark);
  font-weight: 500;
  margin-bottom: 0.5rem;
  display: block;
}

/* ======= Careers Section ======= */
.careers-section {
  background-color: var(--light);
}

/* ======= Contact Section ======= */
.contact-section {
  background-color: var(--gray-light);
}

.contact-form-card {
  height: 100%;
}

.contact-info-card {
  height: 100%;
}

.contact-item {
  margin-bottom: 1.5rem;
}

.map-container {
  width: 100%;
  height: 0;
  padding-bottom: 75%;
  position: relative;
  overflow: hidden;
}

.map-container img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ======= Footer Section ======= */
.footer-section {
  background-color: var(--dark);
  color: var(--light);
  padding: 4rem 1.5rem 2rem;
}

.footer-section .title {
  color: var(--light);
  position: relative;
  padding-bottom: 0.5rem;
  margin-bottom: 1.25rem;
}

.footer-section .title:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 50px;
  height: 3px;
  background-color: var(--primary-color);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: var(--gray);
  transition: color var(--transition-fast);
}

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

.social-links a {
  color: var(--gray);
  font-weight: 500;
  transition: color var(--transition-fast);
}

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

.certificate {
  display: inline-block;
  text-align: center;
}

.certificate img {
  margin-top: 0.5rem;
  border: 1px solid var(--gray);
}

.copyright {
  color: var(--gray);
  font-size: 0.9rem;
}

/* ======= Media Queries ======= */
@media (max-width: 768px) {
  .section {
    padding: 3rem 1rem;
  }
  
  .card {
    transform: skew(0deg);
  }
  
  .card-content {
    transform: skew(0deg);
  }
  
  .card-image img {
    transform: skew(0deg);
  }
  
  .header-section .navbar-menu {
    background-color: rgba(0, 0, 0, 0.9);
    box-shadow: none;
  }
  
  .header-section .navbar-item {
    color: var(--light);
  }
  
  .brutalist-title {
    font-size: 1.75rem;
  }
  
  .hero-body {
    padding: 4rem 1rem;
  }
}

@media (max-width: 576px) {
  .section {
    padding: 2rem 1rem;
  }
  
  .brutalist-title {
    font-size: 1.5rem;
  }
  
  .brutalist-button,
  .button.is-primary,
  .brutalist-button-secondary,
  .button.is-outlined {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
  
  .card-image img {
    height: 200px;
  }
  
  .instructor-card .card-image img {
    height: 250px;
  }
}

/* ======= Animation and Scroll Effects ======= */
/* Fade in animation */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Create a class for elements we want to animate on scroll */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s ease, transform 1s ease;
}

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

/* Staggered animations for cards */
.animate-card {
  opacity: 0;
  transform: translateY(30px);
}

.animate-card.is-visible {
  animation: fadeIn 0.6s forwards;
}

.animate-card:nth-child(2) {
  animation-delay: 0.2s;
}

.animate-card:nth-child(3) {
  animation-delay: 0.4s;
}

.animate-card:nth-child(4) {
  animation-delay: 0.6s;
}

.animate-card:nth-child(5) {
  animation-delay: 0.8s;
}

.animate-card:nth-child(6) {
  animation-delay: 1s;
}

/* ======= Custom Scroll Bar ======= */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--gray-light);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}