/*
Theme Name: Alps Workshop Theme
Theme URI: https://alpsworkshop.ca
Author: Alps Workshop
Description: A custom modern theme for Alps Workshop featuring responsive design, vibrant colors, and WooCommerce support.
Version: 1.0.0
*/

:root {
  --primary-color: #a28569; /* Mountain Brown */
  --primary-hover: #8f745a;
  --secondary-color: #617090; /* Exact Logo Slate Blue */
  --background-light: #f8fafc;
  --text-main: #334155;
  --text-muted: #64748b;
  --bg-white: #ffffff;
  --border-color: #e2e8f0;
  --radius: 8px;
  --transition: all 0.3s ease;
  --font-family: 'Inter', sans-serif;
}

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

body {
  font-family: var(--font-family) !important;
  color: var(--text-main);
  background-color: var(--background-light) !important;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

/* ============ */
/* Header       */
/* ============ */
.site-header {
  background: var(--secondary-color);
  padding: 1rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--secondary-color);
}
.site-title a { color: inherit; }
.site-title a:hover { color: var(--primary-color); }

.main-navigation ul {
  display: flex;
  list-style: none !important;
  gap: 1.5rem;
  margin: 0 !important;
  padding: 0 !important;
}
.main-navigation li {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}
.main-navigation li::before {
  content: none !important;
  display: none !important;
}
.main-navigation a {
  color: #e2e8f0;
  font-weight: 700;
  font-size: 0.95rem;
}
.main-navigation a:hover,
.main-navigation .current-menu-item a {
  color: var(--primary-color);
  text-decoration: none;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  padding: 0.5rem;
  margin-left: auto; /* Force to the right */
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
  .main-navigation {
    display: none;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--secondary-color);
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  }
  .main-navigation.toggled {
    display: block;
    z-index: 100;
  }
  .main-navigation ul {
    flex-direction: column;
    gap: 1rem;
  }
  .site-header {
    flex-wrap: nowrap;
    position: relative;
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .site-title {
    flex: 0 1 auto;
    min-width: 0;
  }
  .site-title img {
    max-width: 100%;
    height: auto;
  }
}

/* ============ */
/* Hero         */
/* ============ */
.hero-section {
  text-align: center;
  padding: 8rem 1rem;
  background: linear-gradient(rgba(15, 23, 42, 0.8), rgba(15, 23, 42, 0.8)), url('images/hero.png') center/cover no-repeat;
  color: white;
}

.hero-headline {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
  color: #ffffff;
}

.hero-subheadline {
  font-size: 1.25rem;
  color: #cbd5e1;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.hero-cta {
  display: inline-block;
  background-color: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: 0 4px 14px 0 rgba(59, 130, 246, 0.39);
}
.hero-cta:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  color: white;
}

/* ============ */
/* Page Content */
/* ============ */
.page-container {
  max-width: 1200px;
  margin: 3rem auto;
  padding: 0 1rem;
}

.page-title {
  font-size: 2.5rem;
  color: var(--secondary-color);
  margin-bottom: 1.5rem;
  text-align: center;
}

.page-content {
  background: var(--bg-white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.page-content p {
  line-height: 2;
  margin-bottom: 1.5rem;
}

.page-content li {
  line-height: 2;
  margin-bottom: 0.5rem;
}

.grid-2-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

/* ============ */
/* Footer       */
/* ============ */
.site-footer {
  background: var(--secondary-color);
  color: white;
  text-align: center;
  padding: 2rem;
  margin-top: 4rem;
}

/* ============ */
/* Forms        */
/* ============ */
input[type="text"], input[type="email"], textarea, select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  margin-bottom: 1rem;
  font-family: inherit;
  font-size: 1rem;
}

input[type="submit"] {
  background-color: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 600;
}
input[type="submit"]:hover {
  background-color: var(--primary-hover);
}

.wpcf7 {
  margin-bottom: 3.5rem;
}


/* ============================== */
/* Packages Page                  */
/* ============================== */

.packages-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.package-card {
  background: var(--bg-white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  transition: var(--transition);
  overflow: visible;
}
.package-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px -12px rgba(59, 130, 246, 0.15);
}

.package-card--popular {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 1px var(--primary-color), 0 8px 24px -8px rgba(59, 130, 246, 0.2);
}

.package-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary-color);
  color: white;
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.package-name {
  color: var(--secondary-color);
  font-size: 1.15rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.5rem;
}

.package-price {
  text-align: center;
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary-color);
  margin-bottom: 0.25rem;
}

.package-desc {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.package-features {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 1.5rem 0 !important;
  flex-grow: 1;
}

.package-features li {
  position: relative;
  padding-left: 1.5rem !important;
  margin-bottom: 0.5rem !important;
  font-size: 0.9rem;
  color: var(--text-main);
  list-style: none !important;
  line-height: 1.5;
}
.package-features li::before {
  content: '✓' !important;
  position: absolute !important;
  left: 0 !important;
  color: #22c55e !important;
  font-weight: 700 !important;
  display: inline !important;
}

.package-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Buttons */
.btn-buy,
.btn-quote {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem !important;
  border-radius: var(--radius) !important;
  font-weight: 600 !important;
  font-size: 0.95rem !important;
  cursor: pointer;
  border: none;
  font-family: var(--font-family) !important;
  transition: var(--transition);
  text-decoration: none !important;
  line-height: 1.4;
  width: 100%;
  text-align: center;
}

.btn-buy {
  background: var(--primary-color) !important;
  color: white !important;
}
.btn-buy:hover {
  background: var(--primary-hover) !important;
  transform: translateY(-1px);
  color: white !important;
}

.btn-quote {
  background: transparent !important;
  color: var(--primary-color) !important;
  border: 2px solid var(--primary-color) !important;
}
.btn-quote:hover {
  background: var(--primary-color) !important;
  color: white !important;
}

/* Addons Banner */
.addons-banner {
  margin-top: 2rem;
  padding: 1.5rem 2rem;
  background: linear-gradient(135deg, #eff6ff, #f5f3ff);
  border-radius: 12px;
  text-align: center;
  font-size: 1rem;
}
.addons-banner a { font-weight: 700; }

/* ============================== */
/* Cart & Quote Inline Section    */
/* ============================== */

.cart-quote-section {
  margin-top: 3rem;
  padding: 2.5rem;
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 10px 30px -8px rgba(0, 0, 0, 0.08);
  animation: fadeSlideUp 0.4s ease;
}

@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.cart-quote-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 1.5rem;
}

.inline-panel {
  padding: 1.5rem;
  background: var(--background-light);
  border-radius: var(--radius);
}

.inline-panel-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--secondary-color);
  font-size: 1.1rem;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--border-color);
}

.inline-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
.inline-table th {
  text-align: left;
  padding: 0.5rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-muted);
  font-weight: 600;
}
.inline-table td {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid var(--border-color);
}

.btn-remove {
  background: none;
  border: none;
  color: #ef4444;
  font-size: 1.25rem;
  cursor: pointer;
  font-weight: bold;
  line-height: 1;
  transition: var(--transition);
}
.btn-remove:hover {
  color: #dc2626;
  transform: scale(1.2);
}

.empty-msg {
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.9rem;
}

/* Spinner */
.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}


/* ============================== */
/* WooCommerce Overrides          */
/* ============================== */

/* Reset WC styles on our custom pages */
body.woocommerce-page .page-container,
body.woocommerce-cart .page-container {
  width: 100% !important;
  max-width: 1200px !important;
  margin: 3rem auto !important;
  padding: 0 1rem !important;
}

/* Override WooCommerce product styles */
.woocommerce ul.products li.product {
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: var(--transition);
}
.woocommerce ul.products li.product:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.woocommerce a.button,
.woocommerce button.button {
  background-color: var(--primary-color) !important;
  color: white !important;
  border-radius: var(--radius) !important;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover {
  background-color: var(--primary-hover) !important;
}

/* Fix WooCommerce notices on our pages */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  border-top-color: var(--primary-color) !important;
}


/* ============ */
/* Responsive   */
/* ============ */
@media (max-width: 1024px) {
  .packages-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 768px) {
  .hero-headline { font-size: 2rem; }
  .hero-section { padding: 5rem 1rem; }
  .grid-2-col { grid-template-columns: 1fr; }

  .packages-grid { grid-template-columns: 1fr !important; }
  .cart-quote-grid { grid-template-columns: 1fr !important; }
  .page-title { font-size: 1.8rem; }
}

/* ============================== */
/* Portfolio Components           */
/* ============================== */

.portfolio-carousel {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  gap: 1.5rem;
  padding: 1rem 2rem 2rem 2rem; /* padding for shadow space */
  margin-left: -2rem; /* offset padding */
  margin-right: -2rem; /* offset padding */
}

.portfolio-carousel::-webkit-scrollbar {
  display: none;
}
.portfolio-carousel {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

.carousel-card {
  flex: 0 0 85%; /* Shows a bit of the next card */
  max-width: 400px;
  scroll-snap-align: center;
}

@media (min-width: 768px) {
  .portfolio-carousel {
    padding: 1rem 5% 2rem 5%;
    margin-left: -5%;
    margin-right: -5%;
  }
  .carousel-card {
    flex: 0 0 45%;
    max-width: none;
    scroll-snap-align: start;
  }
}

@media (min-width: 1024px) {
  .carousel-card {
    flex: 0 0 30%;
  }
}

.portfolio-grid-2col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.portfolio-grid-3col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.portfolio-card {
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--border-color);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.portfolio-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  border-color: var(--primary-color);
}

.portfolio-image-placeholder {
  background: #e2e8f0;
  border-radius: var(--radius);
  height: 180px;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.portfolio-card h3 {
  font-size: 1.25rem;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.portfolio-card .industry-tag {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  flex-grow: 1;
}

.portfolio-card .btn-outline {
  display: inline-block;
  text-align: center;
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition);
}

.portfolio-card .btn-outline:hover {
  background: var(--primary-color);
  color: white;
}

.callout-box {
  background: #f1f5f9;
  border-left: 4px solid var(--primary-color);
  padding: 1.5rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 3rem;
}

.callout-box h4 {
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  font-weight: 700;
}

.callout-box p {
  color: var(--text-main);
  margin-bottom: 0;
  line-height: 1.6;
}

/* ============================== */
/* FAQ Section (AEO/GEO)          */
/* ============================== */

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

.faq-item {
  background: var(--bg-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  margin-bottom: 1rem;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.faq-question {
  padding: 1.25rem 1.5rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--secondary-color);
  cursor: pointer;
  list-style: none; /* Remove default arrow in newer browsers */
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
}

.faq-question::-webkit-details-marker {
  display: none; /* Remove default arrow in Safari */
}

.faq-question::after {
  content: "+";
  font-size: 1.5rem;
  color: var(--primary-color);
  transition: transform 0.3s ease;
}

.faq-item[open] .faq-question::after {
  content: "−";
}

.faq-answer {
  padding: 0 1.5rem 1.5rem 1.5rem;
  color: var(--text-main);
  line-height: 1.7;
}

.faq-answer p {
  margin-bottom: 0;
}
