/* ========================================
   Acupuntura Mejillas Barcelona
   Modern, mobile-first stylesheet
   ======================================== */

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

:root {
  --gold: #d4a843;
  --gold-light: #f0d890;
  --gold-bg: #fdf8ec;
  --dark: #1a1a1a;
  --text: #333;
  --text-light: #666;
  --white: #fff;
  --gray-light: #f5f5f5;
  --gray-border: #e0e0e0;
  --max-width: 1200px;
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Roboto, -apple-system, BlinkMacSystemFont, Helvetica, Arial, sans-serif;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
}

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

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

a:hover {
  color: var(--dark);
}

h1, h2, h3, h4 {
  line-height: 1.3;
  color: var(--dark);
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* --- Skip Link --- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  background: var(--gold);
  color: var(--white);
  padding: 0.5rem 1rem;
  z-index: 1000;
  font-weight: 600;
}

.skip-link:focus {
  top: 0;
  color: var(--white);
}

/* --- Header / Nav --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 2px solid var(--gold);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.nav-logo {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  white-space: nowrap;
}

.nav-logo:hover {
  color: var(--gold);
}

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

.nav-menu a {
  display: block;
  padding: 0.5rem 0.85rem;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  border-radius: 6px;
  transition: background var(--transition), color var(--transition);
}

.nav-menu a:hover,
.nav-menu a.active {
  color: var(--gold);
  background: var(--gold-bg);
}

/* Dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown > a::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: 6px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  min-width: 220px;
  padding: 0.5rem 0;
  list-style: none;
  z-index: 50;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
  display: block;
}

.dropdown-menu a {
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
  border-radius: 0;
}

/* CTA button in nav */
.nav-cta a {
  background: var(--gold);
  color: var(--white) !important;
  border-radius: 24px;
  padding: 0.5rem 1.25rem;
  font-weight: 600;
}

.nav-cta a:hover {
  background: var(--dark);
  color: var(--white) !important;
}

/* Hamburger */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile nav */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: 1rem;
    border-top: 1px solid var(--gray-border);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    gap: 0;
  }

  .nav-menu.open {
    display: flex;
  }

  .nav-menu a {
    padding: 0.75rem 1rem;
    width: 100%;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    padding-left: 1rem;
  }

  .nav-dropdown:hover .dropdown-menu,
  .nav-dropdown:focus-within .dropdown-menu {
    display: none;
  }

  .nav-dropdown.open .dropdown-menu {
    display: block;
  }

  .nav-cta {
    margin-top: 0.5rem;
  }

  .nav-cta a {
    display: block;
    text-align: center;
  }

  .nav-toggle.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  .nav-toggle.open span:nth-child(2) {
    opacity: 0;
  }
  .nav-toggle.open span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }
}

/* --- Hero --- */
.hero {
  position: relative;
  background: linear-gradient(135deg, var(--gold-bg) 0%, var(--white) 100%);
  overflow: hidden;
  padding: 4rem 1.25rem;
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  color: var(--dark);
}

.hero-text .subtitle {
  font-size: 1.2rem;
  color: var(--gold);
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero-text p {
  font-size: 1.05rem;
  color: var(--text-light);
  margin-bottom: 2rem;
}

.hero-image {
  position: relative;
}

.hero-image img {
  border-radius: 16px;
  box-shadow: 0 16px 48px rgba(0,0,0,0.12);
}

.btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  border-radius: 30px;
  font-weight: 600;
  font-size: 1rem;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
  text-align: center;
}

.btn-primary {
  background: var(--gold);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--gold);
  color: var(--gold);
}

.btn-outline:hover {
  background: var(--gold);
  color: var(--white);
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .hero {
    padding: 2.5rem 1.25rem;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }

  .hero-text h1 {
    font-size: 1.8rem;
  }

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

  .hero-image {
    order: -1;
    max-width: 300px;
    margin: 0 auto;
  }
}

/* --- Section base --- */
.section {
  padding: 5rem 1.25rem;
}

.section-alt {
  background: var(--gray-light);
}

.section-gold {
  background: var(--gold-bg);
}

.section-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 1rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-light);
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto 3rem;
}

@media (max-width: 768px) {
  .section {
    padding: 3rem 1.25rem;
  }

  .section-title {
    font-size: 1.6rem;
  }
}

/* --- Services Cards --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.service-card {
  background: var(--white);
  border-radius: 12px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  transition: transform var(--transition), box-shadow var(--transition);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.1);
}

.service-card img {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border-radius: 50%;
  margin: 0 auto 1.25rem;
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.service-card p {
  font-size: 0.95rem;
  color: var(--text-light);
  margin-bottom: 1.25rem;
}

.service-card .btn {
  font-size: 0.9rem;
  padding: 0.6rem 1.5rem;
}

@media (max-width: 768px) {
  .services-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
  }
}

/* --- Books Section --- */
.books-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.book-card {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  background: var(--white);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.book-card img {
  width: 140px;
  flex-shrink: 0;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.book-info h3 {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--gold);
}

.book-info p {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-bottom: 1rem;
}

.book-quotes {
  list-style: none;
  padding: 0;
  margin-bottom: 1rem;
}

.book-quotes li {
  font-size: 0.85rem;
  color: var(--text-light);
  padding: 0.15rem 0;
  font-style: italic;
}

@media (max-width: 768px) {
  .books-grid {
    grid-template-columns: 1fr;
  }

  .book-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* --- About Section --- */
.about-inner {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 3rem;
  align-items: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.about-image img {
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.about-text h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.about-text p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

@media (max-width: 768px) {
  .about-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-image {
    max-width: 250px;
    margin: 0 auto;
  }
}

/* --- Testimonials --- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.testimonial-card {
  background: var(--white);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  position: relative;
}

.testimonial-card::before {
  content: '\201C';
  position: absolute;
  top: 0.5rem;
  left: 1rem;
  font-size: 4rem;
  color: var(--gold-light);
  font-family: Georgia, serif;
  line-height: 1;
}

.testimonial-card p {
  font-style: italic;
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: 1rem;
  padding-top: 1.5rem;
}

.testimonial-card .author {
  font-weight: 700;
  color: var(--dark);
  font-style: normal;
  font-size: 0.95rem;
}

@media (max-width: 768px) {
  .testimonials-grid {
    grid-template-columns: 1fr;
  }
}

/* --- Contact Section --- */
.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.contact-info h2 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.contact-detail {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.contact-icon {
  width: 20px;
  flex-shrink: 0;
  text-align: center;
  font-weight: 700;
  color: var(--gold);
  font-size: 1.1rem;
  line-height: 1.6;
}

.contact-detail a {
  color: var(--text);
}

.contact-detail a:hover {
  color: var(--gold);
}

.contact-map {
  margin-top: 1.5rem;
}

.contact-map img {
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.contact-form {
  background: var(--white);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.contact-form h3 {
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--text);
}

.form-group label .required {
  color: #c00;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--gray-border);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color var(--transition);
  background: var(--gray-light);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: var(--white);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.form-privacy {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  font-size: 0.85rem;
  color: var(--text-light);
}

.form-privacy input[type="checkbox"] {
  margin-top: 0.3rem;
  accent-color: var(--gold);
}

.form-note {
  font-size: 0.8rem;
  color: var(--text-light);
  margin-bottom: 1rem;
}

.btn-submit {
  width: 100%;
  padding: 0.9rem;
  font-size: 1rem;
}

@media (max-width: 768px) {
  .contact-inner {
    grid-template-columns: 1fr;
  }
}

/* --- Footer --- */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,0.7);
  padding: 2rem 1.25rem;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  font-size: 0.85rem;
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-copy {
  font-size: 0.85rem;
}

@media (max-width: 768px) {
  .footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

/* --- Service Detail Page --- */
.page-hero {
  background: linear-gradient(135deg, var(--gold-bg) 0%, var(--white) 100%);
  padding: 4rem 1.25rem;
}

.page-hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.page-hero-text h1 {
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
}

.page-hero-text p {
  font-size: 1.05rem;
  color: var(--text-light);
  margin-bottom: 1rem;
  line-height: 1.8;
}

.page-hero-image img {
  border-radius: 12px;
  box-shadow: 0 12px 36px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
  .page-hero {
    padding: 2.5rem 1.25rem;
  }

  .page-hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .page-hero-text h1 {
    font-size: 1.7rem;
  }

  .page-hero-image {
    order: -1;
    max-width: 350px;
    margin: 0 auto;
  }
}

/* Pathologies / highlights box */
.pathologies {
  background: var(--gold-bg);
  border-left: 4px solid var(--gold);
  border-radius: 0 8px 8px 0;
  padding: 1.5rem 2rem;
  margin-top: 1.5rem;
}

.pathologies h2 {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--gold);
}

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

/* --- Legal Pages --- */
.legal-page {
  padding: 3rem 1.25rem 5rem;
}

.legal-content {
  max-width: 800px;
  margin: 0 auto;
}

.legal-content h1 {
  font-size: 2rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--gold);
}

.legal-content h2 {
  font-size: 1.3rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--gold);
}

.legal-content p {
  margin-bottom: 1rem;
  color: var(--text-light);
  font-size: 0.95rem;
}

.legal-content ul {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

.legal-content li {
  margin-bottom: 0.5rem;
  color: var(--text-light);
  font-size: 0.95rem;
}

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}

.legal-content th,
.legal-content td {
  padding: 0.75rem 1rem;
  border: 1px solid var(--gray-border);
  text-align: left;
  vertical-align: top;
}

.legal-content th {
  background: var(--gold-bg);
  font-weight: 600;
  color: var(--dark);
  width: 30%;
}

.legal-content td {
  color: var(--text-light);
}

@media (max-width: 768px) {
  .legal-content h1 {
    font-size: 1.5rem;
  }

  .legal-content table {
    font-size: 0.8rem;
  }

  .legal-content th,
  .legal-content td {
    padding: 0.5rem;
  }
}

/* --- EU Banner --- */
.eu-banner {
  background: var(--gray-light);
  border-top: 1px solid var(--gray-border);
  padding: 1.5rem 1.25rem;
  text-align: center;
}

.eu-banner p {
  font-size: 0.75rem;
  color: var(--text-light);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* --- Utilities --- */
.text-center {
  text-align: center;
}

.mt-2 {
  margin-top: 2rem;
}

/* --- WhatsApp Floating Button --- */
.whatsapp-float {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 56px;
  height: 56px;
  background-color: #25d366;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  z-index: 1000;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.whatsapp-float:active {
  transform: scale(0.95);
}
