/* General Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: #f8f8f8;
  color: #333;
  line-height: 1.6;
}

/* Gallery Section */
.gallery-container {
  padding: 20px;
  display: flex;
  justify-content: center;
}

.gallery {
  columns: 4; /* Number of columns */
  column-gap: 15px;
  width: 100%;
  max-width: 1200px;
}

.gallery-item {
  break-inside: avoid; /* Prevents items from breaking across columns */
  margin-bottom: 15px; /* Space between items */
  position: relative;
  width: 100%;
  overflow: hidden;
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0px 8px 12px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
  width: 100%;
  height: auto; /* This is critical for maintaining aspect ratio */
  display: block;
  border-radius: 16px;
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.03);
  opacity: 0.9;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .gallery {
    columns: 3;
  }
}

@media (max-width: 768px) {
  .gallery {
    columns: 2;
    column-gap: 10px;
  }
  
  .gallery-item {
    margin-bottom: 10px;
  }
}

@media (max-width: 480px) {
  .gallery {
    columns: 2;
    column-gap: 8px; /* Slightly tighter spacing for very small screens */
  }
  
  .gallery-item {
    margin-bottom: 8px;
  }
}

/* Navigation Styles */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  padding: 1rem 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.logo-image {
  height: 40px; /* Adjust this value based on your logo size */
  width: auto;
  object-fit: contain;
}

/* Responsive logo */
@media (max-width: 768px) {
  .logo-image {
    height: 32px; /* Slightly smaller on mobile */
  }
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links li a {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: #333;
  position: relative;
  padding: 0.5rem 0;
  transition: color 0.3s ease;
}

.nav-links li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: #333;
  transition: width 0.3s ease;
}

.nav-links li a:hover {
  color: #666;
}

.nav-links li a:hover::after {
  width: 100%;
}

/* Hero Section */
.hero {
  padding: 120px 20px 60px;
  text-align: center;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #333;
  letter-spacing: -0.03em;
}

.hero p {
  font-size: 1.2rem;
  color: #666;
  font-weight: 400;
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
}

/* Animation keyframes */
@keyframes float {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-20px) rotate(5deg);
  }
}

/* Add a subtle rotation animation */
@keyframes rotate {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Add some pastel colored circles in the background */
.doodles-background::before {
  content: '';
  position: absolute;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255,181,232,0.2) 0%, rgba(255,181,232,0) 70%);
  top: -50px;
  left: -50px;
  animation: float 15s ease-in-out infinite;
}

.doodles-background::after {
  content: '';
  position: absolute;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(175,248,219,0.2) 0%, rgba(175,248,219,0) 70%);
  bottom: -50px;
  right: -50px;
  animation: float 12s ease-in-out infinite reverse;
}

/* Responsive styles */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 3rem;
  }
  
  .hero p {
    font-size: 1.2rem;
  }
  
  .doodles-background {
    opacity: 0.4;
  }
}

/* Adjust main padding */
main {
  padding-top: 60px; /* Reduced padding since we removed content from header */
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 3rem 1rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }
}

/* Hamburger menu toggle */
.menu-toggle {
  display: none; /* Hide by default on desktop */
  cursor: pointer;
}

/* Mobile Navigation */
@media (max-width: 768px) {
  .menu-toggle {
    display: block; /* Only show on mobile */
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    padding: 1rem;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  }

  .nav-links.active {
    display: flex;
  }
}

.scroll-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  display: none;
  font-size: 20px;
  transition: all 0.3s ease;
  z-index: 1000;
}

.scroll-to-top:hover {
  background: rgba(0, 0, 0, 0.9);
  transform: translateY(-3px);
}

.scroll-to-top.visible {
  display: block;
}

/* Enhanced Lightbox for Gallery Images */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  justify-content: center;
  align-items: center;
}

#lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.5);
}

.lightbox-close, 
.lightbox-prev, 
.lightbox-next {
  position: absolute;
  background: transparent;
  border: none;
  color: white;
  font-size: 2rem;
  cursor: pointer;
  opacity: 0.8;
  transition: opacity 0.2s;
  z-index: 10000;
}

.lightbox-close:hover, 
.lightbox-prev:hover, 
.lightbox-next:hover {
  opacity: 1;
}

.lightbox-close {
  top: 20px;
  right: 20px;
  font-size: 3rem;
}

.lightbox-prev {
  left: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
}

.lightbox-next {
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .lightbox-close {
    top: 10px;
    right: 10px;
    font-size: 2rem;
  }
  
  .lightbox-prev, 
  .lightbox-next {
    font-size: 2rem;
  }
  
  #lightbox-img {
    max-height: 80vh;
  }
}

/* Explicitly make gallery images clickable */
.gallery-grid .gallery-item img,
.gallery-wrapper .gallery-item img {
  cursor: pointer !important;
}

.filter-container {
  display: flex;
  gap: 10px;
  margin: 40px auto 40px;
  padding: 0 20px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 1200px;
}

.filter-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 20px;
  background-color: #f0f0f0;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  font-weight: 500;
}

.filter-btn:hover {
  background-color: #e0e0e0;
}

.filter-btn.active {
  background-color: #000;
  color: white;
}

/* Make sure gallery items have a smooth transition */
.gallery-item {
  transition: all 0.3s ease;
}

/* Update gallery styles for full-width layout */
.gallery-section {
  width: 100%;
  padding: 0;
  margin: 0;
  overflow: hidden;
}

.gallery-container.full-width {
  padding: 0 24px;
  max-width: 100%;
  margin: 0 auto;
}

.masonry-grid {
  columns: 5;
  column-gap: 24px;
  width: 100%;
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 24px;
  position: relative;
  width: 100%;
  overflow: hidden;
  background-color: #fff;
  border-radius: 0; /* Remove border radius for cleaner look */
  box-shadow: none; /* Remove shadow for cleaner look */
  transition: opacity 0.3s ease;
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.3s ease;
}

/* Hover effect similar to Phopet */
.gallery-item:hover img {
  transform: scale(1.02);
}

/* Responsive columns */
@media (max-width: 2200px) {
  .masonry-grid {
    columns: 5;
  }
}

@media (max-width: 1800px) {
  .masonry-grid {
    columns: 4;
  }
}

@media (max-width: 1400px) {
  .masonry-grid {
    columns: 3;
  }
}

@media (max-width: 1000px) {
  .masonry-grid {
    columns: 2;
  }
  .gallery-container.full-width {
    padding: 0 16px;
  }
}

@media (max-width: 600px) {
  .masonry-grid {
    columns: 1;
  }
  .gallery-container.full-width {
    padding: 0 12px;
  }
}

/* Loading styles */
.gallery-item.loading {
  opacity: 0;
}

.gallery-item.loaded {
  opacity: 1;
}

/* Footer Styles */
footer {
    background-color: #f8f8f8;
    padding: 20px 0;
    text-align: center;
    width: 100%;
    margin-top: 60px;
}

footer p {
    color: #666;
    font-size: 0.9rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.social-icons {
  display: flex;
  gap: 15px;
  margin-top: 15px;
}

.social-icon {
  width: 24px;
  height: 24px;
  transition: opacity 0.3s ease;
}

.social-icon:hover {
  opacity: 0.8;
}

.footer-bottom {
  max-width: 1200px;
  margin: 40px auto 0;
  padding: 20px 20px 0;
  border-top: 1px solid #eee;
  text-align: center;
}

.footer-bottom p {
  color: #666;
  font-size: 0.9rem;
}

/* Responsive Footer */
@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
    text-align: center;
  }

  .footer-section {
    padding: 0 20px;
  }

  .social-icons {
    justify-content: center;
  }
}

.contact-section {
  padding: 120px 20px 60px;
  max-width: 800px;
  margin: 0 auto;
}

.contact-container {
  background: white;
  padding: 40px;
  border-radius: 16px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.contact-section h1 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  text-align: center;
  letter-spacing: -0.03em;
}

.contact-intro {
  text-align: center;
  color: #666;
  margin-bottom: 2rem;
}

.contact-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-group label {
  margin-bottom: 8px;
  font-weight: 500;
  color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #666;
}

.submit-btn {
  grid-column: 1 / -1;
  background: #333;
  color: white;
  padding: 16px 32px;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.submit-btn:hover {
  background: #444;
}

@media (max-width: 768px) {
  .contact-form {
    grid-template-columns: 1fr;
  }
  
  .contact-section {
    padding: 100px 15px 40px;
  }
  
  .contact-container {
    padding: 20px;
  }
}

/* Add these styles for the active navigation state */
.nav-links li a.active {
  color: #000;
  font-weight: 500;
  position: relative;
}

.nav-links li a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: #000;
}

.loading-spinner {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1000;
  background: rgba(255, 255, 255, 0.9);
  padding: 20px;
  border-radius: 50%;
}

.spinner-logo {
  width: 50px; /* Adjust size as needed */
  height: 50px; /* Adjust size as needed */
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0% {
    opacity: 0.6;
    transform: scale(0.95);
  }
  50% {
    opacity: 1;
    transform: scale(1.05);
  }
  100% {
    opacity: 0.6;
    transform: scale(0.95);
  }
}

/* Thank you page styles */
.thank-you-section {
  padding: 120px 20px 60px;
  text-align: center;
  min-height: calc(100vh - 200px);
  display: flex;
  align-items: center;
  justify-content: center;
}

.thank-you-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 40px;
  background: white;
  border-radius: 16px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.thank-you-container h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 600;
}

.thank-you-container p {
  color: #666;
  margin-bottom: 2rem;
}

.back-home {
  display: inline-block;
  padding: 12px 24px;
  background: #333;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.back-home:hover {
  background: #444;
}

/* Add loading state styles */
.gallery-item {
  position: relative;
  background: #f5f5f5; /* Light background while loading */
  transition: opacity 0.3s ease;
}

.gallery-item.loading {
  min-height: 200px; /* Placeholder height while loading */
}

.gallery-item.loading::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.5) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

/* Sentinel element for infinite scroll */
.sentinel {
  width: 100%;
  height: 20px;
  visibility: hidden;
}

/* Gallery section styles */
.gallery-section {
  padding: 0 20px;
  margin: 0 auto;
}

.gallery-container {
  max-width: 1200px;
  margin: 0 auto;
}

.gallery {
  columns: 4;
  column-gap: 15px;
  width: 100%;
  margin-top: 0; /* Ensure no top margin */
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 15px;
  position: relative;
  width: 100%;
  overflow: hidden;
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 16px;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .gallery {
    columns: 3;
  }
}

@media (max-width: 768px) {
  .gallery {
    columns: 2;
    column-gap: 10px;
  }
  
  .gallery-item {
    margin-bottom: 10px;
  }
}

.end-message {
    text-align: center;
    padding: 20px;
    color: #666;
    width: 100%;
    margin-top: 20px;
}

.scroll-sentinel {
    width: 100%;
    height: 1px;
    visibility: hidden;
}

/* Error pages styles */
.error-section {
  min-height: calc(100vh - 140px); /* Account for header and footer */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background-color: #f5f5f5;
}

.error-container {
  background: white;
  padding: 40px;
  border-radius: 16px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  max-width: 400px;
  width: 100%;
  text-align: center;
}

.error-container h1 {
  font-size: 4rem;
  color: #333;
  margin: 0 0 10px 0;
}

.error-container h2 {
  font-size: 2rem;
  color: #666;
  margin: 0 0 20px 0;
}

.error-container p {
  color: #777;
  margin-bottom: 30px;
}

.back-home {
  display: inline-block;
  padding: 12px 24px;
  background: #333;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.back-home:hover {
  background: #444;
}

@media (max-width: 768px) {
  .error-container h1 {
    font-size: 3rem;
  }
  
  .error-container h2 {
    font-size: 1.5rem;
  }
}

/* Add these to your existing styles.css */
.login-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: #f5f5f5;
}

.login-container {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 100%;
    text-align: center;
}

.login-logo {
    width: 80px;
    height: auto;
    margin-bottom: 20px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.login-form input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
}

/* Upload page specific styles */
.upload-section {
    padding-top: 100px;  /* Account for fixed header */
    min-height: calc(100vh - 100px);
    display: flex;
    align-items: flex-start;  /* Changed from center */
    justify-content: center;
    padding: 100px 20px 20px;  /* Added top padding */
}

.upload-container {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    width: 100%;
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.upload-form .form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.upload-form label {
    font-weight: 500;
    color: #333;
}

.upload-form input[type="file"] {
    padding: 10px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    cursor: pointer;
}

.file-requirements {
    font-size: 0.875rem;
    color: #666;
    margin-top: 4px;
}

.upload-form .submit-btn {
    background: #333;
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.upload-form .submit-btn:hover {
    background: #444;
}

.spinner {
    display: inline-block;
    margin-left: 8px;
}

/* Careers Page Styles */
.careers-hero {
  padding: 120px 0 60px;
  background-color: #f2f2f2;
  text-align: center;
}

.careers-hero-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

.careers-hero h1 {
  font-size: 2.5rem;
  margin-bottom: 16px;
  color: #333;
}

.careers-tagline {
  font-size: 1.2rem;
  color: #666;
  font-weight: 300;
  line-height: 1.5;
}

.careers-intro {
  padding: 60px 0;
  background-color: #fff;
}

.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

.intro-text {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #444;
  text-align: center;
}

.careers-openings {
  padding: 60px 0;
  background-color: #f8f8f8;
}

.section-title {
  font-size: 2rem;
  margin-bottom: 40px;
  color: #333;
  text-align: center;
}

.job-opening {
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 30px;
  margin-bottom: 40px;
}

.job-title {
  font-size: 1.5rem;
  color: #333;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid #eee;
}

.job-section {
  margin-bottom: 24px;
}

.job-section h4 {
  font-size: 1.2rem;
  color: #333;
  margin-bottom: 12px;
}

.job-section p {
  color: #555;
  line-height: 1.6;
  margin-bottom: 16px;
}

.job-section ul {
  padding-left: 20px;
  color: #555;
}

.job-section li {
  margin-bottom: 8px;
  line-height: 1.5;
}

.careers-benefits {
  padding: 60px 0;
  background-color: #fff;
}

.benefits-list {
  list-style: none;
  padding: 0;
}

.benefits-list li {
  background-color: #f8f8f8;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
  line-height: 1.5;
  color: #555;
}

.benefits-list li strong {
  color: #333;
}

.careers-apply {
  padding: 60px 0;
  background-color: #f8f8f8;
}

.apply-instructions {
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 30px;
  text-align: center;
}

.apply-instructions p {
  margin-bottom: 16px;
  line-height: 1.6;
  color: #555;
}

.apply-instructions a {
  color: #333;
  font-weight: 500;
  text-decoration: underline;
  transition: color 0.3s ease;
}

.apply-instructions a:hover {
  color: #666;
}

.note {
  font-size: 0.9rem;
  color: #777;
  margin-top: 20px;
}

/* Responsive styles for careers page */
@media (max-width: 768px) {
  .careers-hero {
    padding: 100px 0 40px;
  }
  
  .careers-hero h1 {
    font-size: 2rem;
  }
  
  .careers-tagline {
    font-size: 1rem;
  }
  
  .section-title {
    font-size: 1.7rem;
    margin-bottom: 30px;
  }
  
  .job-title {
    font-size: 1.3rem;
  }
  
  .job-section h4 {
    font-size: 1.1rem;
  }
  
  .job-opening, 
  .apply-instructions {
    padding: 20px;
  }
}

@media (max-width: 480px) {
  .careers-hero h1 {
    font-size: 1.8rem;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
  
  .job-title {
    font-size: 1.2rem;
  }
}

/* Careers Gallery Banner */
.careers-gallery {
  padding: 0 20px;
  margin: 0 0 60px;
  overflow: hidden;
}

.careers-gallery-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.careers-gallery-item {
  width: 100%;
  height: 460px !important; /* Fixed height for all images */
  border-radius: 8px;
  overflow: hidden;
}

.careers-gallery-item img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  border-radius: 8px;
  transition: transform 0.5s ease;
}

.careers-gallery-item img:hover {
  transform: scale(1.05);
}

/* Responsive adjustments */
@media (max-width: 992px) {
  .careers-gallery-item {
    height: 380px !important;
  }
}

@media (max-width: 768px) {
  .careers-gallery-container {
    gap: 10px;
    padding: 0 10px;
  }
  
  .careers-gallery-item {
    height: 320px !important;
  }
}

@media (max-width: 576px) {
  .careers-gallery-container {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .careers-gallery-item {
    height: auto !important;
  }
}

/* Studio Life Section */
.studio-life {
  padding: 60px 0;
  background-color: #f2f2f2;
}

.studio-life-content {
  display: flex;
  align-items: center;
  gap: 40px;
}

.studio-life-image {
  flex: 1;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.studio-life-image img {
  width: 100%;
  height: auto;
  display: block;
}

.studio-life-text {
  flex: 1;
}

.studio-life-text p {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #444;
  text-align: center;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .careers-gallery-container {
    height: 200px; /* Restore taller height as seen in screenshot */
    flex-direction: row; /* Keep horizontal layout */
  }
  
  .careers-gallery-item {
    /* Match container height */
    min-height: 200px;
    margin-bottom: 0;
  }
  
  /* Other responsive styles can remain unchanged */
  .studio-life-content {
    flex-direction: column;
    gap: 20px;
  }
  
  .studio-life-image,
  .studio-life-text {
    flex: none;
    width: 100%;
  }
}

/* Case Study Page Styles */
.case-study-hero {
  padding: 120px 0 60px;
  background-color: #f2f2f2;
}

.case-study-meta {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.case-study-label {
  display: inline-block;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #666;
  margin-bottom: 10px;
}

.case-study-title {
  font-size: 3rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: #222;
}

.case-study-details {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-top: 20px;
}

.detail-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.detail-label {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #666;
  margin-bottom: 5px;
}

.detail-value {
  font-size: 1.1rem;
  font-weight: 500;
  color: #222;
}

.case-study-section {
  padding: 60px 0;
  border-bottom: 1px solid #eee;
}

.case-study-section:last-of-type {
  border-bottom: none;
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
}

.section-title {
  font-size: 1.8rem;
  font-weight: 500;
  margin-bottom: 30px;
  color: #222;
}

.section-content {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #444;
}

.section-content p {
  margin-bottom: 20px;
}

.section-content p:last-child {
  margin-bottom: 0;
}

.challenge-list,
.approach-list,
.outcome-list {
  margin: 20px 0;
  padding-left: 20px;
}

.challenge-list li,
.approach-list li,
.outcome-list li {
  margin-bottom: 10px;
  position: relative;
  padding-left: 15px;
}

.challenge-list li:before,
.approach-list li:before,
.outcome-list li:before {
  content: "•";
  position: absolute;
  left: 0;
  color: #666;
}

.case-study-gallery {
  padding: 60px 0;
  background-color: #f8f8f8;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 40px;
}

.gallery-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.gallery-item.wide {
  grid-column: span 2;
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px 8px 0 0;
}

.gallery-item figcaption {
  padding: 15px;
  font-size: 0.9rem;
  color: #666;
  background-color: white;
  border-radius: 0 0 8px 8px;
}

.testimonial {
  margin: 40px 0;
  padding: 30px;
  background-color: #f8f8f8;
  border-left: 4px solid #333;
  border-radius: 0 8px 8px 0;
}

.testimonial blockquote {
  font-size: 1.1rem;
  font-style: italic;
  line-height: 1.7;
  margin-bottom: 15px;
  color: #444;
}

.testimonial cite {
  font-style: normal;
  font-weight: 500;
  color: #666;
}

.cta-container {
  margin-top: 40px;
  display: flex;
  gap: 20px;
  justify-content: center;
}

.cta-button {
  display: inline-block;
  padding: 12px 30px;
  background-color: #333;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.cta-button:hover {
  background-color: #222;
}

.secondary-button {
  display: inline-block;
  padding: 12px 30px;
  background-color: transparent;
  color: #333;
  text-decoration: none;
  border: 1px solid #333;
  border-radius: 4px;
  font-weight: 500;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.secondary-button:hover {
  background-color: #333;
  color: white;
}

/* Responsive adjustments for case study page */
@media (max-width: 768px) {
  .case-study-hero {
    padding: 100px 0 40px;
  }
  
  .case-study-title {
    font-size: 2.2rem;
  }
  
  .case-study-details {
    flex-direction: column;
    gap: 15px;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .gallery-item.wide {
    grid-column: span 1;
  }
  
  .cta-container {
    flex-direction: column;
    align-items: center;
  }
  
  .cta-button, 
  .secondary-button {
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .case-study-title {
    font-size: 1.8rem;
  }
  
  .case-study-section {
    padding: 40px 0;
  }
  
  .testimonial {
    padding: 20px;
  }
}

/* Case Studies Index Page Styles */
.case-studies-hero {
  padding: 120px 0 60px;
  background-color: #f2f2f2;
  text-align: center;
}

.case-studies-title {
  font-size: 3rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: #222;
}

.case-studies-subtitle {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
  color: #666;
  line-height: 1.6;
}

.case-studies-grid {
  padding: 80px 0;
}

.case-studies-grid .container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  max-width: 1200px;
}

.case-study-card {
  background-color: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.case-study-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.case-study-card-image {
  height: 240px;
  overflow: hidden;
}

.case-study-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.case-study-card:hover .case-study-card-image img {
  transform: scale(1.05);
}

.case-study-card-content {
  padding: 30px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.case-study-card-category {
  display: inline-block;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #666;
  margin-bottom: 10px;
  font-weight: 500;
}

.case-study-card-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: #222;
}

.case-study-card-excerpt {
  font-size: 1rem;
  line-height: 1.6;
  color: #555;
  margin-bottom: 20px;
  flex-grow: 1;
}

.case-study-card-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  font-size: 0.9rem;
  color: #777;
}

.case-study-card-link {
  display: inline-block;
  padding: 10px 0;
  color: #333;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 2px solid #333;
  align-self: flex-start;
  transition: color 0.3s ease, border-color 0.3s ease;
}

.case-study-card-link:hover {
  color: #666;
  border-color: #666;
}

/* Use a more specific selector to override everything */
body .case-studies-grid .container {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 20px !important;
  max-width: 1200px !important;
  margin: 0 auto !important;
  padding: 30px 20px !important;
}

/* Case studies filter styles */
.case-studies-filter {
  text-align: center;
  padding: 0 0 30px;
}

.case-studies-filter .container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.case-studies-filter button {
  background: none;
  border: 1px solid #ddd;
  padding: 8px 16px;
  border-radius: 30px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.case-studies-filter button.active,
.case-studies-filter button:hover {
  background-color: #222;
  color: white;
  border-color: #222;
}

/* Related case studies styles */
.related-case-studies {
  background-color: #f2f2f2;
}

.related-case-studies-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .related-case-studies-container {
    grid-template-columns: 1fr;
  }
  
  .case-studies-filter button {
    font-size: 0.8rem;
    padding: 6px 12px;
  }
}

/* Case Studies Grid Layout */
.case-studies-grid .container {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important; /* Force 2 columns */
  gap: 20px !important; /* Smaller gap for tighter layout */
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px 20px;
}

/* Adjusting image size */
.case-study-card-image {
  height: 180px !important; /* Fixed height for all images */
  overflow: hidden;
}

/* Make card content more compact */
.case-study-card-content {
  padding: 20px; /* Reduced padding */
}

.case-study-card-title {
  font-size: 1.3rem; /* Smaller title */
  margin-bottom: 10px; /* Less space */
}

.case-study-card-excerpt {
  font-size: 0.95rem; /* Slightly smaller text */
  margin-bottom: 15px;
  line-height: 1.5;
}

.case-study-card-meta {
  margin-bottom: 15px;
  font-size: 0.85rem;
}

/* Responsive adjustments for the 2x2 grid */
@media (max-width: 768px) {
  .case-studies-grid .container {
    grid-template-columns: repeat(2, 1fr); /* Keep 2 columns on tablets */
    gap: 15px;
  }
  
  .case-study-card-image {
    height: 150px;
  }
  
  .case-study-card-content {
    padding: 15px;
  }
}

@media (max-width: 576px) {
  .case-studies-grid .container {
    grid-template-columns: 1fr !important; /* Single column only on very small devices */
  }
  
  .case-study-card-image {
    height: 200px !important; /* Slightly taller on mobile for better visibility */
  }
}

/* COMPLETE RESET of case study gallery styles */
.case-study-section,
section.case-study-gallery {
  display: block;
  width: 100%;
  clear: both;
  margin-bottom: 40px;
  padding: 20px 0;
}

.case-study-gallery,
.gallery-grid,
.case-study-gallery > div {
  width: 100%;
  margin: 0 auto;
  padding: 0;
}

/* Apply grid layout to any possible gallery container */
.case-study-gallery .gallery-grid,
.case-study-gallery > div:not(.section-title):not(.container),
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  width: 100%;
  margin-top: 30px;
  margin-bottom: 30px;
}

/* Target gallery items regardless of container structure */
.gallery-item,
.case-study-gallery > div,
.case-study-gallery > figure {
  position: relative;
  width: 100%;
  height: auto;
  margin: 0;
  overflow: hidden;
  border-radius: 8px;
}

/* Target all images in gallery */
.case-study-gallery img,
.gallery-item img,
.case-study-gallery > div > div > img,
.case-study-gallery > div > figure > img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

/* Override any wide settings */
.gallery-item.wide,
.case-study-gallery .wide {
  grid-column: span 1 !important;
}

/* Mobile layout fix */
@media (max-width: 767px) {
  .case-study-gallery .gallery-grid,
  .case-study-gallery > div:not(.section-title):not(.container),
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .case-study-gallery img,
  .gallery-item img,
  .case-study-gallery > div > div > img,
  .case-study-gallery > div > figure > img {
    height: 200px;
  }
}

/* CLEAN SLATE - CASE STUDY GALLERY FIX */
/* Remove ALL previous gallery styling first */

/* Basic section setup */
.case-study-section {
  margin-bottom: 50px;
  width: 100%;
  clear: both;
}

/* Simple 2x2 grid */
.case-study-gallery {
  margin: 30px 0;
}

.case-study-gallery .gallery-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
}

/* Basic image styling */
.case-study-gallery img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 8px;
}

/* Mobile view */
@media (max-width: 767px) {
  .case-study-gallery .gallery-container {
    grid-template-columns: 1fr;
  }
}

/* Basic section structure */
.case-study-section {
  margin: 60px 0;
  width: 100%;
  clear: both;
  display: block;
}

.case-study-section .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.case-study-section .section-title {
  margin-bottom: 30px;
  font-size: 28px;
  font-weight: 600;
}

/* Gallery specific styling */
.gallery-wrapper {
  width: 100%;
  margin: 30px 0;
  padding: 0;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  width: 100%;
}

.gallery-item {
  width: 100%;
  height: auto;
  margin: 0;
  border-radius: 8px;
  overflow: hidden;
}

.gallery-item img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  border-radius: 8px;
}

/* Mobile responsiveness */
@media (max-width: 767px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .gallery-item img {
    height: 200px;
  }
}

.apply-button {
    display: inline-block;
    background-color: #000;
    color: white;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 500;
    border-radius: 4px;
    text-decoration: none;
    transition: background-color 0.3s, transform 0.2s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.apply-button:hover {
    background-color: #333;
    transform: translateY(-2px);
}

/* Styled Apply Section */
.apply-section {
  background-color: #f8f8f8;
  padding: 60px 20px;
  text-align: center;
  margin: 60px 0 0 0;
  border-top: 1px solid #eee;
}

.apply-section h2 {
  font-size: 2.2rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: #000;
}

.apply-section p {
  font-size: 1.2rem;
  color: #666;
  max-width: 700px;
  margin: 0 auto 30px;
  line-height: 1.5;
}

.apply-button {
  display: inline-block;
  background-color: #000;
  color: white;
  padding: 16px 36px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.apply-button:hover {
  background-color: #333;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.apply-button:active {
  transform: translateY(0);
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .apply-section {
    padding: 40px 15px;
  }
  
  .apply-section h2 {
    font-size: 1.8rem;
  }
  
  .apply-section p {
    font-size: 1rem;
  }
  
  .apply-button {
    padding: 14px 28px;
    font-size: 0.9rem;
    width: 80%;
    max-width: 300px;
  }
}

/* RESTORE ORIGINAL PINTEREST-STYLE GALLERY */
.gallery-container {
  padding: 20px;
  display: flex;
  justify-content: center;
}

.gallery {
  columns: 4; /* Number of columns */
  column-gap: 15px;
  width: 100%;
  max-width: 1200px;
}

.gallery-item {
  break-inside: avoid; /* Prevents items from breaking across columns */
  margin-bottom: 15px; /* Space between items */
  position: relative;
  width: 100%;
  overflow: hidden;
  background-color: #fff;
  border-radius: 16px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0px 8px 12px rgba(0, 0, 0, 0.15);
}

.gallery-item img {
  width: 100%;
  height: auto; /* This is critical for maintaining aspect ratio */
  display: block;
  border-radius: 16px;
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.03);
  opacity: 0.9;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .gallery {
    columns: 3;
  }
}

@media (max-width: 768px) {
  .gallery {
    columns: 2;
    column-gap: 10px;
  }
  
  .gallery-item {
    margin-bottom: 10px;
  }
}

@media (max-width: 480px) {
  .gallery {
    columns: 2;
    column-gap: 8px; /* Slightly tighter spacing for very small screens */
  }
  
  .gallery-item {
    margin-bottom: 8px;
  }
}

/* KEEP CAREER PAGE STYLES SEPARATE WITH MORE SPECIFIC SELECTORS */
.careers-gallery-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
}

.careers-gallery-item {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
}

.careers-gallery-item img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.careers-gallery-item img:hover {
  transform: scale(1.05);
}

/* Only affect case study gallery, not main pinterest gallery */
.case-study-gallery .gallery-item {
  width: 100%;
  height: auto;
  margin: 0;
  border-radius: 8px;
  overflow: hidden;
}

.case-study-gallery .gallery-item img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  display: block;
  border-radius: 8px;
}
