/* The Yarn Remedy - Custom Styles */
:root {
  --primary-green: #2D5016;
  --dark-green: #1a2f0d;
  --light-green: #4a7226;
  --cream: #F8F6F0;
  --soft-pink: #E8D5D1;
  --warm-beige: #E6DDD4;
  --text-dark: #2c2c2c;
  --text-light: #6b6b6b;
  --white: #ffffff;

  --font-script: 'Dancing Script', cursive;
  --font-sans: 'Inter', sans-serif;

  --shadow-soft: 0 4px 20px rgba(45, 80, 22, 0.1);
  --shadow-medium: 0 8px 30px rgba(45, 80, 22, 0.15);
  --shadow-strong: 0 12px 40px rgba(45, 80, 22, 0.2);

  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--cream);
  padding-top: 0;
  margin-top: 0;
}

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

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(248, 246, 240, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  transition: var(--transition);
  margin: 0;
}

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

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

.nav-links {
  display: flex;
  gap: 30px;
}

.nav-link {
  text-decoration: none;
  color: var(--primary-green);
  font-weight: 500;
  font-size: 16px;
  transition: var(--transition);
  position: relative;
}

.nav-link:hover {
  color: var(--light-green);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--light-green);
  transition: var(--transition);
}

.nav-link:hover::after {
  width: 100%;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--cream) 0%, var(--warm-beige) 100%);
  position: relative;
  padding-bottom: 60px;
  margin-top: 0;
  padding-top: 0;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 50%;
  height: 100%;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="yarn" patternUnits="userSpaceOnUse" width="20" height="20"><circle cx="10" cy="10" r="1" fill="%23E8D5D1" opacity="0.3"/></pattern></defs><rect width="100" height="100" fill="url(%23yarn)"/></svg>') repeat;
  opacity: 0.5;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 40px;
  padding-bottom: 40px;
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero-logo-section {
  margin-top: 0;
  margin-bottom: 20px;
}

.hero-logo {
  height: 150px;
  width: auto;
  max-width: 100%;
  filter: drop-shadow(0 10px 30px rgba(45, 80, 22, 0.15));
}

.hero-text {
  max-width: 750px;
  margin-bottom: 30px;
}

.hero-title {
  font-family: var(--font-script);
  font-size: clamp(3rem, 5vw, 4.5rem);
  color: var(--primary-green);
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: 600;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-light);
  margin-bottom: 40px;
  line-height: 1.6;
}

/* Grand Opening Banner */
.grand-opening-banner {
  background: linear-gradient(135deg, var(--primary-green) 0%, var(--dark-green) 100%);
  padding: 25px 0;
  position: relative;
  margin-top: 80px;
  z-index: 100;
  box-shadow: 0 6px 20px rgba(45, 80, 22, 0.4);
}

.grand-opening-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="dots" patternUnits="userSpaceOnUse" width="10" height="10"><circle cx="5" cy="5" r="1" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23dots)"/></svg>') repeat;
  opacity: 0.5;
}

.banner-content {
  text-align: center;
  position: relative;
  z-index: 2;
  padding: 15px 20px;
}

.banner-label {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--soft-pink);
  text-transform: uppercase;
  letter-spacing: 4px;
  margin-bottom: 10px;
}

.banner-title {
  font-family: 'Dancing Script', cursive;
  font-size: clamp(2.5rem, 6vw, 4rem);
  color: var(--white);
  font-weight: 700;
  margin: 0 0 10px;
  line-height: 1.1;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.banner-text {
  font-family: var(--font-sans);
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.95);
  margin: 0;
  letter-spacing: 1px;
  font-weight: 500;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn-primary,
.btn-secondary {
  padding: 15px 30px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
}

.btn-primary {
  background: var(--primary-green);
  color: var(--white);
  box-shadow: var(--shadow-medium);
}

.btn-primary:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
  box-shadow: var(--shadow-strong);
}

.btn-secondary {
  background: transparent;
  color: var(--primary-green);
  border: 2px solid var(--primary-green);
}

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

/* Sections */
.about-section,
.community-section,
.hours-section,
.connect-section {
  padding: 100px 0;
  position: relative;
  background: var(--cream);
  z-index: 10;
}

.section-title {
  font-family: var(--font-script);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  color: var(--primary-green);
  margin-bottom: 30px;
  line-height: 1.2;
  font-weight: 600;
}

.section-title.centered {
  text-align: center;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-light);
  text-align: center;
  max-width: 600px;
  margin: 0 auto 60px;
  line-height: 1.6;
}

/* About Section */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-description {
  font-size: 1.125rem;
  color: var(--text-light);
  margin-bottom: 40px;
  line-height: 1.7;
}

.features {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.feature {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.feature-icon {
  font-size: 2rem;
  min-width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-green);
  border-radius: 50%;
  color: var(--white);
}

.feature h3 {
  color: var(--primary-green);
  font-size: 1.25rem;
  margin-bottom: 8px;
  font-weight: 600;
}

.feature p {
  color: var(--text-light);
  line-height: 1.6;
}

.feature-img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: var(--shadow-medium);
}

/* Hours Section */
.hours-section {
  background: var(--cream);
}

.hours-content {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
}

.hours-subtitle {
  font-size: 1.125rem;
  color: var(--text-light);
  margin-bottom: 15px;
}

.hours-notice {
  font-size: 0.95rem;
  color: var(--primary-green);
  font-weight: 500;
  margin-bottom: 40px;
  padding: 12px 24px;
  background: rgba(45, 80, 22, 0.08);
  border-radius: 8px;
  display: inline-block;
}

.hours-card {
  background: var(--white);
  border-radius: 16px;
  padding: 40px;
  box-shadow: 0 4px 20px rgba(45, 80, 22, 0.1);
  margin-bottom: 40px;
}

.hours-table {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hours-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid rgba(45, 80, 22, 0.1);
}

.hours-row:last-child {
  border-bottom: none;
}

.hours-row.closed {
  opacity: 0.5;
}

.hours-row .day {
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--primary-green);
  text-align: left;
}

.hours-row.closed .day {
  color: var(--text-light);
}

.hours-row .time {
  font-weight: 500;
  color: var(--text-dark);
  font-size: 1rem;
  letter-spacing: 0.3px;
}

.hours-row.closed .time {
  color: var(--text-light);
  font-style: italic;
}

.hours-row .time sup {
  color: var(--light-green);
  font-size: 0.75em;
  margin-left: 2px;
}

.hours-note {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(45, 80, 22, 0.1);
}

.hours-note p {
  font-size: 0.9rem;
  color: var(--text-light);
  margin: 0;
  font-style: italic;
}

.hours-note sup {
  color: var(--light-green);
  font-weight: 600;
}

.first-friday-info {
  background: linear-gradient(135deg, rgba(45, 80, 22, 0.06) 0%, rgba(45, 80, 22, 0.02) 100%);
  padding: 30px;
  border-radius: 12px;
  border: 1px solid rgba(45, 80, 22, 0.1);
  text-align: left;
}

.first-friday-info h3 {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  color: var(--primary-green);
  margin: 0 0 12px 0;
  font-weight: 600;
}

.first-friday-info p {
  margin: 0;
  line-height: 1.7;
  font-size: 1rem;
  color: var(--text-light);
}

/* Connect Section */
.connect-section {
  background: linear-gradient(135deg, var(--primary-green) 0%, var(--dark-green) 100%);
  color: var(--white);
  z-index: 11;
}

.connect-section .section-title {
  color: var(--white);
}

.connect-subtitle {
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  font-size: 1.125rem;
  margin-bottom: 50px;
  line-height: 1.6;
}

.social-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 60px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.social-link {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px 25px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  text-decoration: none;
  color: var(--white);
  transition: var(--transition);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.social-link:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.social-link svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.social-link span {
  font-weight: 500;
  font-size: 16px;
}

.store-info {
  text-align: center;
  background: rgba(255, 255, 255, 0.1);
  padding: 40px;
  border-radius: 20px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.store-info h3 {
  font-family: var(--font-script);
  font-size: 2rem;
  margin-bottom: 20px;
  color: var(--white);
}

.store-info p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.125rem;
  margin-bottom: 10px;
}

/* Classes Section */
.classes-section {
  background: var(--cream);
  padding: 100px 0;
}

.classes-content {
  text-align: center;
}

.loading-message,
.error-message {
  text-align: center;
  padding: 40px 20px;
  font-size: 1.125rem;
  color: var(--text-light);
}

.error-message {
  color: #c53030;
  background: #fed7d7;
  border-radius: 8px;
  padding: 20px;
}

.classes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.class-card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-medium);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

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

.class-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: linear-gradient(135deg, var(--soft-pink) 0%, var(--warm-beige) 100%);
}

.class-info {
  padding: 25px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.class-name {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary-green);
  margin-bottom: 12px;
}

.class-description {
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 20px;
  flex: 1;
}

.class-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-top: 15px;
  border-top: 1px solid rgba(45, 80, 22, 0.1);
}

.class-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-green);
}

.class-duration {
  font-size: 0.95rem;
  color: var(--text-light);
}

.class-book-btn {
  width: 100%;
  padding: 12px 20px;
  background: var(--primary-green);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.class-book-btn:hover {
  background: var(--dark-green);
  transform: translateY(-2px);
}

/* Modal Styles */
.modal {
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.7);
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  background-color: var(--white);
  margin: 5% auto;
  padding: 40px;
  border-radius: 16px;
  width: 90%;
  max-width: 600px;
  position: relative;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-close {
  color: var(--text-light);
  float: right;
  font-size: 32px;
  font-weight: 300;
  line-height: 24px;
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover,
.modal-close:focus {
  color: var(--primary-green);
}

.modal-content h2 {
  font-family: var(--font-script);
  font-size: 2rem;
  color: var(--primary-green);
  margin-bottom: 30px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
  font-size: 0.95rem;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid rgba(45, 80, 22, 0.2);
  border-radius: 8px;
  font-size: 1rem;
  font-family: var(--font-sans);
  transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary-green);
}

.form-section {
  margin: 30px 0;
  padding: 25px;
  background: var(--cream);
  border-radius: 12px;
}

.form-section h3 {
  font-size: 1.25rem;
  color: var(--primary-green);
  margin-bottom: 15px;
  font-weight: 600;
}

#card-container {
  min-height: 100px;
}

.payment-status {
  margin: 20px 0;
  padding: 12px;
  border-radius: 8px;
  font-size: 0.95rem;
  display: none;
}

.payment-status.error {
  background: #fed7d7;
  color: #c53030;
  display: block;
}

.payment-status.success {
  background: #c6f6d5;
  color: #22543d;
  display: block;
}

.success-message {
  text-align: center;
  padding: 40px 20px;
}

.success-message h3 {
  font-family: var(--font-script);
  font-size: 2rem;
  color: var(--primary-green);
  margin-bottom: 15px;
}

.success-message p {
  font-size: 1.125rem;
  color: var(--text-light);
  margin-bottom: 30px;
}

/* Footer */
.footer {
  background: var(--dark-green);
  padding: 40px 0;
  text-align: center;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.footer-logo {
  height: 40px;
  width: auto;
  filter: brightness(0) invert(1);
}

.footer p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
}

.footer-address {
  color: rgba(255, 255, 255, 0.9);
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 5px;
}

.footer-credit {
  margin-top: 10px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .hero-logo {
    height: 150px;
  }

  .hero-logo-section {
    margin-top: 40px;
  }

  .hero-text {
    margin-bottom: 30px;
  }

  .grand-opening-banner {
    padding: 25px 0;
  }

  .banner-label {
    font-size: 0.875rem;
    letter-spacing: 3px;
  }

  .about-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .features {
    margin-top: 20px;
  }

  .feature {
    text-align: center;
    flex-direction: column;
    gap: 15px;
  }

  .hero-buttons {
    justify-content: center;
  }

  .social-links {
    grid-template-columns: 1fr;
  }

  .hours-card {
    padding: 30px 25px;
  }

  .hours-row {
    flex-direction: column;
    gap: 8px;
    padding: 14px 0;
    text-align: center;
  }

  .hours-row .day {
    text-align: center;
  }

  .first-friday-info {
    padding: 25px 20px;
  }

  .classes-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .modal-content {
    width: 95%;
    padding: 30px 20px;
    margin: 10% auto;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  .nav-container {
    padding: 0 15px;
  }

  .hero-logo {
    height: 120px;
  }

  .hero-logo-section {
    margin-top: 30px;
  }

  .grand-opening-banner {
    padding: 20px 0;
  }

  .banner-content {
    padding: 15px 15px;
  }

  .banner-label {
    font-size: 0.8rem;
    letter-spacing: 2px;
  }

  .banner-text {
    font-size: 1rem;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 280px;
  }
}

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

  .banner-decoration {
    animation: none !important;
  }
}

/* Focus styles for keyboard navigation */
.nav-link:focus,
.btn-primary:focus,
.btn-secondary:focus,
.social-link:focus {
  outline: 2px solid var(--light-green);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --primary-green: #1a2f0d;
    --text-light: #333333;
  }
}
