@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap');

/* --- System Design Tokens --- */
:root {
  --primary-wine: #58111A;
  --primary-wine-dark: #360A0F;
  --primary-wine-light: #7E1C29;
  --accent-gold: #C5A880;
  --accent-gold-light: #DFD3C3;
  --accent-gold-dark: #A58860;
  --bg-cream: #FAF7F2;
  --bg-dark: #160D0F;
  --bg-dark-card: #221517;
  --text-dark: #2B1B1E;
  --text-light: #FFFFFF;
  --text-muted: #8E7A7D;
  --text-gold: #C5A880;

  --font-serif: 'Cormorant Garamond', serif;
  --font-sans: 'Inter', sans-serif;

  --transition-smooth: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.3s ease;

  --container-width: 1200px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-cream);
  color: var(--text-dark);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-serif);
  font-weight: 500;
}

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

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

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
  background: var(--primary-wine);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-gold);
}

/* --- General Components --- */
.btn-premium {
  display: inline-block;
  padding: 14px 32px;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 1px solid var(--accent-gold);
  background: transparent;
  color: var(--accent-gold);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  z-index: 1;
  transition: var(--transition-smooth);
}

.btn-premium::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--accent-gold);
  z-index: -1;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-premium:hover {
  color: var(--bg-dark);
  border-color: var(--accent-gold);
}

.btn-premium:hover::before {
  transform: scaleX(1);
  transform-origin: left;
}

.btn-premium.solid {
  background-color: var(--accent-gold);
  color: var(--bg-dark);
}

.btn-premium.solid:hover {
  background-color: transparent;
  color: #FFFFFF;
  border-color: #FFFFFF;
}

/* --- Navigation Header --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 10px 0;
  background-color: #D0302D;
  transition: var(--transition-smooth);
}

.header.scrolled {
  background-color: #D0302D;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(197, 168, 128, 0.15);
  padding: 15px 0;
}

.header .container {
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 40px;
}

.logo {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  letter-spacing: 3px;
  color: var(--text-light);
  font-weight: 400;
}

.logo span {
  font-size: 0.8rem;
  font-family: var(--font-sans);
  letter-spacing: 5px;
  display: block;
  color: var(--accent-gold);
  line-height: 1;
  margin-top: 2px;
}

.header-logo-img {
  height: 40px;
  width: auto;
  display: block;
}

.nav-menu {
  display: flex;
  gap: 40px;
  list-style: none;
}

.nav-link {
  color: var(--text-light);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.8;
  position: relative;
  padding: 5px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background-color: var(--accent-gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s ease;
}

.nav-link:hover {
  opacity: 1;
  color: var(--accent-gold);
}

.nav-link:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 1.5rem;
  cursor: pointer;
}

/* --- Hero Section --- */
.hero {
  position: relative;
  height: 100vh;
  min-height: 650px;
  display: flex;
  align-items: center;
  color: var(--text-light);
  background-color: var(--bg-dark);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.05);
  animation: heroZoom 20s infinite alternate ease-in-out;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  background: radial-gradient(circle at center, rgba(30, 18, 20, 0.4) 0%, rgba(22, 13, 15, 0.9) 100%);
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 40px;
  text-align: center;
}

.hero-kicker {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 5px;
  color: var(--accent-gold);
  margin-bottom: 25px;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1s forwards 0.2s;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.15;
  margin-bottom: 25px;
  font-weight: 300;
  letter-spacing: 1px;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1s forwards 0.4s;
}

.hero-bajada {
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 2vw, 1.6rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.5;
  max-width: 700px;
  margin: 0 auto 40px auto;
  color: rgba(255, 255, 255, 0.9);
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1s forwards 0.6s;
}

.hero-actions {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 1s forwards 0.8s;
}

.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 0.7rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  animation: bounce 2s infinite;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background-color: var(--accent-gold);
}

/* --- Section Layout --- */
.section {
  padding: 120px 0;
  position: relative;
}

.section-dark {
  background-color: var(--bg-dark);
  color: var(--text-light);
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 40px;
}

.section-header {
  max-width: 700px;
  margin-bottom: 80px;
}

.section-kicker {
  font-family: var(--font-sans);
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 4px;
  color: var(--accent-gold);
  margin-bottom: 15px;
  display: block;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 3rem);
  line-height: 1.2;
  margin-bottom: 20px;
}

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

.section-header.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

/* --- History Section --- */
.history-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.history-text p {
  font-size: 1.05rem;
  color: var(--text-dark);
  margin-bottom: 30px;
  line-height: 1.8;
  opacity: 0.9;
}

.history-text p.highlight {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  line-height: 1.5;
  color: var(--primary-wine);
  border-left: 2px solid var(--accent-gold);
  padding-left: 20px;
  margin-bottom: 35px;
}

.history-img-frame {
  position: relative;
  padding-bottom: 110%;
  /* Golden ratio aspect */
  overflow: hidden;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(197, 168, 128, 0.3);
}

.history-img-frame img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.history-img-frame:hover img {
  transform: scale(1.05);
}

.history-img-accent {
  position: absolute;
  top: -20px;
  right: -20px;
  width: 100px;
  height: 100px;
  border-top: 1px solid var(--accent-gold);
  border-right: 1px solid var(--accent-gold);
  z-index: -1;
  pointer-events: none;
}

/* --- Portfolio Showcase (Interactive Section) --- */
.showcase-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 80px;
  align-items: center;
}

.wine-visualizer {
  position: relative;
  height: 550px;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: var(--bg-dark-card);
  border: 1px solid rgba(197, 168, 128, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

.wine-visualizer::before {
  content: '';
  position: absolute;
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(88, 17, 26, 0.3) 0%, rgba(22, 13, 15, 0) 70%);
  z-index: 1;
}

.visualizer-img {
  max-height: 480px;
  z-index: 2;
  transition: var(--transition-smooth);
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5));
}

.visualizer-img.switching {
  opacity: 0;
  transform: translateY(30px) scale(0.9);
}

.wine-selector {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.selector-option {
  background: transparent;
  border: none;
  border-left: 2px solid rgba(255, 255, 255, 0.1);
  padding: 15px 0 15px 25px;
  text-align: left;
  cursor: pointer;
  color: var(--text-light);
  transition: var(--transition-smooth);
  outline: none;
}

.selector-option:hover {
  border-color: rgba(197, 168, 128, 0.5);
  padding-left: 30px;
}

.selector-option.active {
  border-color: var(--accent-gold);
  padding-left: 30px;
  background: linear-gradient(90deg, rgba(88, 17, 26, 0.15) 0%, rgba(22, 13, 15, 0) 100%);
}

.option-tag {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-bottom: 5px;
  display: block;
}

.option-name {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 400;
  margin-bottom: 10px;
}

.option-desc {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
  max-width: 450px;
  height: 0;
  opacity: 0;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.selector-option.active .option-desc {
  height: auto;
  opacity: 1;
  margin-top: 10px;
}

/* --- Call To Action (CTA) --- */
.cta {
  position: relative;
  text-align: center;
  background-color: var(--bg-cream);
  overflow: hidden;
}

.cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 10% 20%, rgba(88, 17, 26, 0.03) 0%, rgba(255, 255, 255, 0) 80%);
}

.cta-content {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.cta-tagline {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 300;
  font-style: italic;
  color: var(--primary-wine);
  margin-bottom: 40px;
  line-height: 1.4;
}

/* --- Social Media & Footer --- */
.social-card {
  max-width: 600px;
  margin: 60px auto 0 auto;
  background-color: var(--text-light);
  border: 1px solid rgba(197, 168, 128, 0.2);
  border-radius: 4px;
  padding: 40px;
  box-shadow: 0 20px 40px rgba(88, 17, 26, 0.02);
  text-align: left;
  position: relative;
}

.social-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #F0ECE3;
  padding-bottom: 15px;
}

.social-brand {
  display: flex;
  align-items: center;
  gap: 15px;
}

.social-brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--primary-wine);
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: bold;
}

.social-brand-info h4 {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
}

.social-brand-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.social-icon {
  color: #1877F2;
  /* Facebook Blue */
  font-size: 1.2rem;
}

.social-text {
  font-size: 0.95rem;
  color: var(--text-dark);
  line-height: 1.6;
}

.footer {
  background-color: var(--bg-dark);
  color: var(--text-muted);
  padding: 60px 0 40px 0;
  border-top: 1px solid rgba(197, 168, 128, 0.1);
  font-size: 0.8rem;
  letter-spacing: 1px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 30px;
  margin-bottom: 40px;
}

.footer-logo {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--text-light);
  letter-spacing: 2px;
}

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

.footer-link:hover {
  color: var(--accent-gold);
}

.footer-bottom {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 30px;
  color: rgba(255, 255, 255, 0.3);
}

/* --- Scroll Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* --- Keyframes --- */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes heroZoom {
  0% {
    transform: scale(1.05);
  }

  100% {
    transform: scale(1.12);
  }
}

@keyframes bounce {

  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translate(-50%, 0);
  }

  40% {
    transform: translate(-50%, -10px);
  }

  60% {
    transform: translate(-50%, -5px);
  }
}

/* --- Responsive Adjustments --- */
@media (max-width: 992px) {
  .history-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .history-img-frame {
    padding-bottom: 75%;
    order: -1;
  }

  .showcase-layout {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .wine-visualizer {
    height: 450px;
  }

  .visualizer-img {
    max-height: 380px;
  }
}

@media (max-width: 768px) {
  .header .container {
    padding: 0 10px;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    height: 100vh;
    background-color: var(--bg-dark);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 30px;
    z-index: 99;
    transition: var(--transition-smooth);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-link {
    font-size: 1.1rem;
  }

  .nav-toggle {
    display: block;
    z-index: 100;
  }

  .section {
    padding: 80px 0;
  }

  .container {
    padding: 0 20px;
  }

  .footer-grid {
    flex-direction: column;
    text-align: center;
  }

  .footer-nav {
    flex-direction: column;
    gap: 15px;
  }
}

/* --- Custom Cursor --- */
.custom-cursor,
.custom-cursor-follower {
  display: none;
}

@media (pointer: fine) {
  body, a, button, [role="button"], .selector-option {
    cursor: none;
  }

  .custom-cursor {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 8px;
    height: 8px;
    background-color: var(--accent-gold);
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, background-color 0.3s, opacity 0.3s;
    opacity: 0;
  }

  .custom-cursor-follower {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 32px;
    height: 32px;
    border: 1px solid var(--accent-gold);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, border-color 0.3s, background-color 0.3s, opacity 0.3s;
    opacity: 0;
  }

  /* Hover active state */
  .custom-cursor.hovered {
    width: 0;
    height: 0;
  }

  .custom-cursor-follower.hovered {
    width: 48px;
    height: 48px;
    background-color: rgba(197, 168, 128, 0.15);
    border-color: var(--accent-gold);
  }

  .custom-cursor-follower.hovered-wine {
    width: 60px;
    height: 60px;
    background-color: rgba(255, 255, 255, 0.2);
    border-color: #FFFFFF;
  }
}