/* 512 EYE - Main Stylesheet */
/* Mobile-First Approach */

/* CSS Variables */
:root {
  --primary-blue: #42A5F5;
  --secondary-blue: #26C6DA;
  --tertiary-blue: #00BCD4;
  --primary-green: #8BC34A;
  --secondary-green: #689F38;
  --dark-text: #333333;
  --subtext: #666666;
  --white: #FFFFFF;
  --shadow-light: 0px 4px 15px rgba(0,0,0,0.08);
  --shadow-medium: 0px 8px 25px rgba(0,0,0,0.12);
  --transition-base: 0.3s ease;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', Arial, sans-serif;
  color: var(--dark-text);
  background-color: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  line-height: 1.2;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p { font-size: 1rem; line-height: 1.7; }

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

/* Container */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Buttons */
.btn-primary {
  display: inline-block;
  padding: 14px 28px;
  background-color: var(--primary-green);
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.btn-primary:hover {
  background-color: var(--secondary-green);
  transform: translateY(-2px);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  display: inline-block;
  padding: 12px 24px;
  background-color: transparent;
  color: var(--primary-blue);
  font-family: 'Poppins', sans-serif;
  font-weight: 500;
  font-size: 1rem;
  border: 2px solid var(--primary-blue);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.btn-secondary:hover {
  background-color: var(--primary-blue);
  color: var(--white);
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--white);
  box-shadow: var(--shadow-light);
  transition: all 0.3s ease;
}

.header.scrolled {
  padding: 10px 0;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
}

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

.logo img {
  height: 50px;
  width: auto;
}

.nav {
  display: none;
}

.nav.active {
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 350px;
  height: 100vh;
  background-color: var(--primary-blue);
  padding: 80px 30px 30px;
  transition: right 0.3s ease;
  z-index: 1001;
}

.nav.active.open {
  right: 0;
}

.nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.nav-list a {
  color: var(--white);
  font-weight: 500;
  font-size: 1.1rem;
  padding: 10px 0;
  display: block;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}

.mobile-menu-btn {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
}

.mobile-menu-btn span {
  width: 25px;
  height: 3px;
  background-color: var(--dark-text);
  transition: all 0.3s ease;
}

.mobile-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--white);
  font-size: 2rem;
  cursor: pointer;
}

/* Hero Section */
.hero {
  display: flex;
  flex-direction: column;
  min-height: 90vh;
}

.hero-image {
  width: 100%;
  height: 300px;
  background: url('../images/hero-clinic-interior.png') center/cover no-repeat;
  position: relative;
}

.hero-content {
  padding: 40px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero h1 {
  color: var(--primary-blue);
  margin-bottom: 15px;
}

.hero-subtext {
  color: var(--subtext);
  font-size: 1.1rem;
  margin-bottom: 25px;
}

.hero-contact {
  font-size: 0.9rem;
  color: var(--subtext);
  margin-bottom: 20px;
}

.hero-contact a {
  color: var(--primary-blue);
  font-weight: 500;
}

/* Section Base */
.section {
  padding: 60px 0;
}

.section-title {
  color: var(--primary-blue);
  text-align: center;
  margin-bottom: 40px;
}

/* Vision Needs Section */
.vision-needs {
  background: linear-gradient(135deg, rgba(66, 165, 245, 0.05), rgba(38, 198, 218, 0.05));
}

.vision-grid {
  display: grid;
  gap: 30px;
}

.vision-card {
  background: var(--white);
  padding: 25px;
  border-radius: 12px;
  box-shadow: var(--shadow-light);
}

/* Services Grid */
.services-grid {
  display: grid;
  gap: 20px;
}

.service-card {
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-light);
  transition: all 0.3s ease;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

.service-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.service-card-content {
  padding: 20px;
}

.service-card h3 {
  color: var(--primary-blue);
  margin-bottom: 10px;
}

/* Why Choose Us */
.why-512eye {
  display: grid;
  gap: 30px;
}

.why-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 12px;
}

.why-content h2 {
  color: var(--primary-blue);
  margin-bottom: 20px;
}

.why-list {
  list-style: none;
}

.why-list li {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 15px;
}

.why-list .icon {
  color: var(--primary-blue);
  font-size: 1.2rem;
  flex-shrink: 0;
}

/* Team Section */
.team-section {
  background-color: rgba(66, 165, 245, 0.05);
}

.team-content {
  display: grid;
  gap: 30px;
  align-items: center;
}

.team-image {
  width: 100%;
  max-width: 400px;
  border-radius: 12px;
  margin: 0 auto;
}

/* Eyewear Carousel */
.eyewear-showcase {
  background-color: var(--dark-text);
  color: var(--white);
  overflow: hidden;
}

.eyewear-showcase h2 {
  color: var(--white);
}

.carousel {
  display: flex;
  gap: 15px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 20px 0;
  -webkit-overflow-scrolling: touch;
}

.carousel-item {
  flex: 0 0 280px;
  scroll-snap-align: start;
}

.carousel-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 12px;
}

/* Testimonials */
.testimonials-grid {
  display: grid;
  gap: 30px;
}

.testimonial-card {
  background: var(--white);
  padding: 25px;
  border-radius: 12px;
  box-shadow: var(--shadow-light);
  border-left: 4px solid var(--primary-blue);
}

.testimonial-quote {
  font-style: italic;
  margin-bottom: 15px;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 15px;
}

.testimonial-author img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
}

.testimonial-name {
  font-weight: 600;
  color: var(--dark-text);
}

.testimonial-role {
  font-size: 0.85rem;
  color: var(--subtext);
}

/* Resources CTA */
.resources-cta {
  background: linear-gradient(135deg, var(--primary-blue), var(--secondary-blue));
  color: var(--white);
}

.resources-cta h2 {
  color: var(--white);
}

.resources-cards {
  display: grid;
  gap: 20px;
}

.resource-card {
  background: rgba(255,255,255,0.15);
  padding: 25px;
  border-radius: 12px;
  text-align: center;
  transition: all 0.3s ease;
}

.resource-card:hover {
  background: rgba(255,255,255,0.25);
  transform: translateY(-3px);
}

/* Blog Section */
.blog-grid {
  display: grid;
  gap: 30px;
}

.blog-card {
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-light);
}

.blog-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.blog-card-content {
  padding: 20px;
}

.blog-card h3 {
  color: var(--primary-blue);
  margin-bottom: 10px;
}

/* Final CTA */
.final-cta {
  background: var(--primary-blue);
  color: var(--white);
  text-align: center;
}

.final-cta h2 {
  color: var(--white);
  margin-bottom: 15px;
}

.final-cta p {
  margin-bottom: 25px;
  opacity: 0.9;
}

/* Location Section */
.location-grid {
  display: grid;
  gap: 30px;
}

.map-container {
  width: 100%;
  height: 300px;
  background: #f0f0f0;
  border-radius: 12px;
  overflow: hidden;
}

.location-info h2 {
  color: var(--primary-blue);
  margin-bottom: 20px;
}

/* Footer */
.footer {
  background: var(--dark-text);
  color: var(--white);
  padding: 50px 0 20px;
}

.footer-grid {
  display: grid;
  gap: 30px;
  margin-bottom: 30px;
}

.footer-logo {
  margin-bottom: 15px;
}

.footer-logo img {
  height: 60px;
}

.footer-mission {
  opacity: 0.8;
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.footer h4 {
  color: var(--primary-green);
  margin-bottom: 15px;
  font-size: 1rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  opacity: 0.8;
  transition: opacity 0.2s;
}

.footer-links a:hover {
  opacity: 1;
}

.footer-contact p {
  opacity: 0.8;
  margin-bottom: 8px;
  font-size: 0.95rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  text-align: center;
  font-size: 0.85rem;
  opacity: 0.6;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}

.animate-fade-in {
  animation: fadeInUp 0.6s ease forwards;
}

.btn-pulse {
  animation: pulse 2s infinite;
}

/* Scroll Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

/* Tablet Styles */
@media (min-width: 768px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2.25rem; }
  
  .hero {
    flex-direction: row;
    min-height: 80vh;
  }
  
  .hero-image {
    width: 50%;
    height: 100%;
    min-height: 600px;
  }
  
  .hero-content {
    width: 50%;
    padding: 60px 40px;
  }
  
  .vision-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .why-512eye {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }
  
  .team-content {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .resources-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .location-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop Styles */
@media (min-width: 1024px) {
  .container {
    max-width: 1200px;
    padding: 0 40px;
  }
  
  h1 { font-size: 3.5rem; }
  h2 { font-size: 2.5rem; }
  
  /* Desktop Header */
  .header-inner {
    padding: 15px 40px;
  }
  
  .nav {
    display: flex;
    align-items: center;
  }
  
  .nav-list {
    flex-direction: row;
    gap: 30px;
  }
  
  .nav-list a {
    color: var(--dark-text);
    font-size: 0.95rem;
    position: relative;
  }
  
  .nav-list a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-blue);
    transition: width 0.3s ease;
  }
  
  .nav-list a:hover::after {
    width: 100%;
  }
  
  .mobile-menu-btn {
    display: none;
  }
  
  .header-cta {
    display: inline-block;
  }
  
  .vision-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
  }
  
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
  }
  
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}
