@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;700&family=Poppins:wght@400;600&display=swap');

/*
 * style.css
 *
 * This stylesheet defines the visual appearance of the replicated MemoryCherish
 * homepage. A warm, inviting color palette and generous spacing aim to
 * communicate trust and professionalism while maintaining readability. The
 * layout uses responsive flexbox and grid patterns to gracefully adapt to
 * smaller screens.
 */

/*
 * Colour palette adapted for CV PhotoRestoration.
 *
 * We lean on cool blues and warm oranges from the brand manual to
 * convey professionalism and nostalgia. A clean white backdrop keeps
 * content legible while brown accents add a vintage touch.
 */
:root {
  --color-bg: #ffffff;            /* Clean white background for clarity */
  --color-light: #f7f6f3;         /* Soft beige panels for contrast */
  --color-primary: #4c7a94;       /* Blue‑gray for headings and accents */
  --color-accent: #f47d20;        /* Warm orange for calls to action */
  --color-text: #000000;          /* Black for maximum readability */
  --color-secondary: #c18953;     /* Light wood brown for secondary text */
}

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

body {
  font-family: 'Poppins', sans-serif;
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
}

/* Use elegant serif for headings */
h1, h2, h3, h4, h5 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 700;
}

/* Containers provide consistent horizontal padding and center alignment */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Top bar styling */
.top-bar {
  background-color: var(--color-light);
  font-size: 0.85rem;
  border-bottom: 1px solid #e0dcd6;
}

.top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  color: var(--color-secondary);
}
.top-bar strong {
  color: var(--color-accent);
}

/* Header & Navigation */
.header {
  background-color: var(--color-light);
  border-bottom: 1px solid #e0dcd6;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  flex-wrap: wrap;
}

.logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary);
}

.nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 25px;
}

.nav-menu li {
  position: relative;
}
.nav-menu a {
  text-decoration: none;
  color: var(--color-text);
  font-weight: 500;
  transition: color 0.2s;
}
.nav-menu li:hover > a {
  color: var(--color-accent);
}

/* Dropdown menus */
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--color-light);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  padding: 10px 0;
  border-radius: 4px;
}
.dropdown:hover .dropdown-menu {
  display: block;
}
.dropdown-menu li {
  padding: 5px 20px;
  white-space: nowrap;
}
.dropdown-menu li a {
  color: var(--color-text);
}
.dropdown-menu li:hover a {
  color: var(--color-accent);
}

/* Call to action buttons */
/* CTA buttons and links */
.cta {
  display: inline-block;
  background-color: var(--color-accent);
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.3s;
}
.cta.large {
  padding: 14px 28px;
  font-size: 1.1rem;
}
/* Hover state for CTA links and buttons */
.cta:hover {
  background-color: #d55d42;
  color: #ffffff;
}

/* Section helper class to unify vertical spacing */
.section {
  padding: 60px 0;
}

/* Hero Section */
.hero {
  background-color: var(--color-light);
}
.hero-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
}
.hero-text {
  flex: 1 1 500px;
}
.hero-text h1 {
  font-size: 2.5rem;
  line-height: 1.2;
  color: var(--color-primary);
  margin-bottom: 20px;
}
.hero-text p {
  margin-bottom: 20px;
  font-size: 1.1rem;
}
.hero-bullets {
  list-style: none;
  margin-bottom: 25px;
}
.hero-bullets li {
  padding-left: 25px;
  position: relative;
  margin-bottom: 10px;
}
.hero-bullets li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--color-accent);
  font-weight: bold;
}
.hero-image {
  flex: 1 1 400px;
  display: flex;
  justify-content: center;
}
.hero-image img {
  max-width: 100%;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* -------------------------------------------------------------------------
 * Before & After Slider
 *
 * Allows users to compare a damaged photo with its restored version by
 * dragging a slider. The restored image sits on top of the original and
 * its visible width is controlled via JavaScript.
 */
.before-after .ba-wrapper {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
}
.before-after .ba-wrapper .ba-img {
  display: block;
  width: 100%;
  height: auto;
}
.before-after .ba-wrapper .ba-after {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 50%; /* default overlay width */
  overflow: hidden;
  z-index: 1;
}
.before-after .ba-wrapper .ba-after .ba-img {
  width: 100%;
  height: auto;
}
.ba-slider {
  margin-top: 20px;
  width: 100%;
}

/* Static before & after grid */
.before-after-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: center;
  margin-top: 30px;
}
.before-after-grid .ba-item {
  flex: 1 1 300px;
  text-align: center;
}
.before-after-grid .ba-item img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  margin-bottom: 10px;
}
.before-after-grid .ba-item p {
  font-weight: 600;
  color: var(--color-primary);
}

/* Steps Section */
.steps {
  background-color: var(--color-bg);
  text-align: center;
}
.steps h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 40px;
}
.step-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: space-between;
}
.step {
  flex: 1 1 300px;
  text-align: center;
}
.circle {
  width: 50px;
  height: 50px;
  line-height: 50px;
  border-radius: 50%;
  background-color: var(--color-accent);
  color: #ffffff;
  margin: 0 auto 15px auto;
  font-weight: bold;
  font-size: 1.2rem;
}
.step h3 {
  font-size: 1.2rem;
  color: var(--color-primary);
  margin-bottom: 10px;
}
.step p {
  font-size: 0.95rem;
  color: var(--color-text);
}

/* Preserve Section */
.preserve {
  background-color: var(--color-light);
  text-align: center;
}
.preserve h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 20px;
}
.preserve p {
  margin-bottom: 20px;
  font-size: 1.05rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}
.preserve-bullets {
  list-style: none;
  display: inline-block;
  text-align: left;
}
.preserve-bullets li {
  padding-left: 25px;
  position: relative;
  margin-bottom: 10px;
  font-size: 0.95rem;
}
.preserve-bullets li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-accent);
}

/* Good Hands Section */
.good-hands {
  background-color: var(--color-bg);
  text-align: center;
}
.good-hands h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 20px;
}
.good-hands p {
  font-size: 1.05rem;
  max-width: 800px;
  margin: 0 auto 25px auto;
}
.good-hands button {
  margin-top: 10px;
}

/* Audience Section */
.audience {
  background-color: var(--color-light);
}
.audience h2 {
  text-align: center;
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 40px;
}
.audience-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
}
.audience-card {
  flex: 1 1 300px;
  background-color: var(--color-bg);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.05);
}
.audience-card h3 {
  font-size: 1.3rem;
  color: var(--color-primary);
  margin-bottom: 10px;
}
.audience-card p {
  font-size: 0.95rem;
}

/* Why Choose Section */
.why-choose {
  background-color: var(--color-bg);
}
.why-choose h2 {
  text-align: center;
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 30px;
}
.comparison {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: center;
}
.comparison .column {
  flex: 1 1 300px;
  background-color: var(--color-light);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.05);
}
.comparison .column h3 {
  font-size: 1.4rem;
  color: var(--color-primary);
  margin-bottom: 15px;
}
.comparison ul {
  list-style: none;
}
.comparison li {
  position: relative;
  padding-left: 25px;
  margin-bottom: 10px;
  font-size: 0.95rem;
}
.comparison li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-accent);
}

/* Gallery Section */
.gallery {
  background-color: var(--color-light);
  text-align: center;
}
.gallery h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 30px;
}
.gallery-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center;
}
.gallery-item {
  flex: 1 1 300px;
}
.gallery-item img {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}
.gallery-item p {
  margin-top: 10px;
  font-size: 0.9rem;
  color: var(--color-secondary);
}
.gallery button {
  margin-top: 20px;
}

/* FAQ Section */
.faq {
  background-color: var(--color-bg);
}
.faq h2 {
  text-align: center;
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 30px;
}
.faq-item {
  margin-bottom: 15px;
}
.faq-item .question {
  width: 100%;
  text-align: left;
  background-color: var(--color-light);
  border: none;
  padding: 15px 20px;
  font-size: 1rem;
  cursor: pointer;
  border-radius: 6px;
  color: var(--color-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-item .question::after {
  content: '+';
  font-size: 1.2rem;
  color: var(--color-accent);
}
.faq-item.open .question::after {
  content: '-';
}
.faq-item .answer {
  display: none;
  padding: 15px 20px;
  background-color: #ffffff;
  border-radius: 0 0 6px 6px;
  border: 1px solid #e0dcd6;
  border-top: none;
  font-size: 0.95rem;
  color: var(--color-text);
}
.faq-item.open .answer {
  display: block;
}

/* Guarantee Section */
.guarantee {
  background-color: var(--color-light);
  text-align: center;
  padding: 60px 20px;
}
.guarantee h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 20px;
}
.guarantee p {
  font-size: 1.05rem;
  margin-bottom: 20px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* CTA Banner */
.cta-banner {
  background-color: var(--color-bg);
  text-align: center;
  padding: 60px 20px;
}
.cta-banner h2 {
  font-size: 2rem;
  color: var(--color-primary);
  margin-bottom: 20px;
}
.cta-banner p {
  font-size: 1.05rem;
  margin-bottom: 20px;
}
.cta-banner ul {
  list-style: none;
  display: inline-block;
  text-align: left;
  margin-bottom: 20px;
}
.cta-banner li {
  padding-left: 25px;
  position: relative;
  margin-bottom: 10px;
  font-size: 0.95rem;
}
.cta-banner li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--color-accent);
}
.cta-banner .cta.large {
  margin-top: 10px;
}

/* Footer */
footer {
  background-color: var(--color-light);
  padding-top: 40px;
  color: var(--color-secondary);
}
.footer-container {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: space-between;
}
.footer-about {
  flex: 1 1 300px;
}
.footer-about p {
  font-size: 0.9rem;
  margin-bottom: 20px;
}
.social a {
  display: inline-block;
  margin-right: 10px;
  background-color: var(--color-accent);
  color: #ffffff;
  width: 32px;
  height: 32px;
  line-height: 32px;
  text-align: center;
  border-radius: 50%;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background-color 0.3s;
}
.social a:hover {
  background-color: #d55d42;
}
.footer-links {
  flex: 2 1 500px;
  display: flex;
  gap: 40px;
}
.link-column h4 {
  font-size: 1rem;
  color: var(--color-primary);
  margin-bottom: 10px;
}
.link-column ul {
  list-style: none;
}
.link-column li {
  margin-bottom: 5px;
}
.link-column a {
  color: var(--color-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}
.link-column a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  background-color: var(--color-bg);
  margin-top: 30px;
  padding: 10px 0;
  border-top: 1px solid #e0dcd6;
}
.bottom-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.bottom-container p {
  font-size: 0.85rem;
}
.bottom-container a {
  color: var(--color-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s;
}
.bottom-container a:hover {
  color: var(--color-accent);
}

/* Responsive rules for small screens */
@media (max-width: 768px) {
  .hero-container {
    flex-direction: column;
    text-align: center;
  }
  .hero-text {
    order: 2;
  }
  .hero-image {
    order: 1;
  }
  .step-grid,
  .comparison,
  .gallery-grid {
    flex-direction: column;
  }
  .footer-container {
    flex-direction: column;
  }
  .footer-links {
    flex-direction: column;
  }
  .nav-menu {
    gap: 15px;
    flex-wrap: wrap;
  }
  .nav-container {
    flex-direction: column;
    gap: 20px;
  }
}