/* =========================
   RESET & BASE
========================= */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Cormorant Garamond", serif;
  background-color: #f3eee8;
  color: #1f1f1f;
  /* EZ szabályozza az egész oldal sorközét */
  line-height: 1.1;

  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
}

a {
  text-decoration: none;
  color: inherit;
}

button,
input,
textarea {
  font: inherit;
}

button {
    min-width: 180px;

    padding: 16px 28px;

    border: none;

    border-radius: 999px;

    background: #7ba547;

    color: white;

    font-size: 1rem;
    font-weight: 600;

    cursor: pointer;

    transition:
        transform .2s ease,
        background .2s ease;
}
@media (hover: hover) {
    button:hover {
        transform: translateY(-2px);
    
        background: #8bc856;
    }
}

button:disabled {
    background: #ccc;

    cursor: not-allowed;

    transform: none;
}

input[type="radio"] {
    margin-right: 8px; /* Finom, tiszta távolság a gomb és a szöveg között */
    cursor: pointer;   /* Mutató kéz ikon a jobb kattintási élményért */
}

/* =========================
   TYPOGRAPHY
========================= */

h1,
h2,
h3,
h4,
h5,
h6 {
  line-height: 1.1;
  font-weight: 600;
}

p {
  line-height: 1.1;
}

/* =========================
   LAYOUT
========================= */

section {
  width: 100%;
}

.container {
  margin: 0 auto;
}

/* =========================
   REUSABLE COMPONENTS
========================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 190px;
  padding: 14px 28px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease;
}

.btn-primary {
  background: #3d7d3e;
  color: white;
  border: 1px solid #3d7d3e;
}

@media (hover: hover) {
    .btn-primary:hover {
      background: #2d5d2e;
      transform: translateY(-2px);
    }
}

.btn-secondary {
  background: rgba(255,255,255,0.08);
  color: white;
  border: 1px solid rgba(255,255,255,0.25);
  backdrop-filter: blur(6px);
}

@media (hover: hover) {
    .btn-secondary:hover {
      background: rgba(255,255,255,0.14);
      border-color: rgba(255,255,255,0.4);
      transform: translateY(-2px);
    }
}

.add-to-cart-btn,
.details-btn {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 12px;
  background: #7ba547;
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

@media (hover: hover) {
    .add-to-cart-btn:hover,
    .details-btn:hover {
      background: #8bc856;
      transform: translateY(-2px);
    }
}

.product-card,
.tasting-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
  width: 320px;
  height: 100%;
  flex-shrink: 0;
}

.tasting-card .filler{
  flex-grow: 1;
}

@media (hover: hover) {
    .product-card:hover,
    .tasting-card:hover {
      transform: translateY(-4px);
      box-shadow: 0 16px 40px rgba(0,0,0,0.12);
    }
}

.product-content,
.tasting-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-price,
.tasting-price {
  font-size: 1.4rem;
  font-weight: 700;
  color: #3d7d3e;
  margin-top: auto;
  margin-bottom: 20px;
}

.catalogue-grid,
.tasting-grid {
  display: flex;
  flex-wrap: wrap;
  padding: 50px;
  gap: 32px;
}

.product-description,
.tasting-desc {
  height: 4.8rem; 
  color: #666;
  line-height: 1.6;
  margin-bottom: 20px;
  /* Szöveglevágás 3 ponttal (...) */
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;  
  overflow: hidden;
  text-overflow: ellipsis;
  
  transition: color 0.3s ease;
}

.product-image {
    height: 200px;
    padding: 0px;
    
    /* Meleg, lágy krém-pezsgő háttér, ami illeszkedik a főoldal fényeihez */
    background: #fdfbf7; 
    
    /* Lekerekítjük a kép tetejét, hogy kövesse a kártya formáját */
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
    
    /* Finom belső sötétedés a sarkokban, ami mélységet ad a palack mögött */
    box-shadow: inset 0 0 20px rgba(18, 16, 13, 0.04);
    
    /* Alsó elválasztó vonal, ami lágyan átvezet a szöveges részhez */
    border-bottom: 1px solid #f3ece2;
    
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    
    /* Finom árnyék maguknak a borosüvegeknek, hogy térbelinek tűnjenek */
    filter: drop-shadow(0 8px 12px rgba(18, 16, 13, 0.12));
    
    /* Finom mozgás animáció előkészítése */
    transition: transform 0.3s ease, filter 0.3s ease;
}

.qty-input {
  width: 70px;
  text-align: center;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid #ddd;
  appearance: textfield;
  -moz-appearance: textfield;
}

.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.form-group {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px;
}

.form-item {
  flex-grow: 1;
}

.form-group .full-row {
  flex-basis: 100%;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid #ddd5c8;
  margin-top: 10px;
  background: #fff;
  color: #1f1f1f;
}

.form-group textarea {
  resize: vertical;
}

#gdpr-link{
  color: blue;
  text-decoration: underline;
}

.hidden {
    display: none !important;
}

.toast-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.toast {
    background-color: #e2ebd9; 
    color: #242c1f; 
    padding: 14px 28px;
    border-radius: 8px;
    
    /* Elegáns sötétszürke keret, ami határozottan elvágja az oldaltól */
    border: 2px solid #2c2a29; 
    
    box-shadow: 0 12px 32px rgba(36, 44, 31, 0.22);
    font-family: "Cormorant Garamond", serif; 
    font-size: 17px; 
    font-weight: 600; 
    letter-spacing: 0.5px;
    
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), 
                transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 240px;        
}

/* Sikeres állapot: Megtartja a sötétszürke keretet, de a bal oldala vastag zöld csíkot kap */
.toast.success {
    border-left: 6px solid #82b440; 
}
.toast.success .toast-svg {
    color: #558223; 
}

/* Hiba / Figyelmeztető állapot: Megtartja a sötétszürke keretet, de a bal oldala vastag narancs csíkot kap */
.toast.error {
    border-left: 6px solid #e67e22; 
}
.toast.error .toast-svg {
    color: #b35400; 
}


/* Animáció */
.toast.show {
    opacity: 1;
    transform: translateY(0);
}

/* =========================
   DECORATION
========================= */

.grape {

  position: fixed;

  top: 0;

  height: 100vh;

  opacity: 1;

  pointer-events: none;

  z-index: 0;
}

.grape-left {
  left: 0;
}

.grape-right {

  right: 0;

  transform: scaleX(-1);
}




/* =========================
   SECTION HEADERS (JAVÍTOTT)
========================= */

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 10px auto 30px auto;
  padding: 0 20px;
}

/* A főcím stílusa */
.section-title {
  font-size: 2.8rem;
  font-weight: 600;
  color: #1f1f1f;
  position: relative;
  display: inline-block;
  
  /* Megnövelt alsó távolság, hogy a díszítés kényelmesen elférjen */
  padding-bottom: 35px; 
  margin-bottom: 15px;
}

/* A díszítővonal pontos pozicionálása */
.section-title::after {
  content: "";
  position: absolute;
  bottom: 15px; /* Feljebb emelve a szövegtől */
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 1px;
  background-color: #3d7d3e;
}

/* A csillag pontos pozicionálása a vonal közepére */
.section-title::before {
  content: "✦";
  position: absolute;
  bottom: 8px; /* Tökéletesen a vonal közepére igazítva */
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.8rem;
  color: #3d7d3e;
  background: #f3eee8; /* Fontos: megegyezik a body háttérszínével */
  padding: 0 8px;
  z-index: 1;
}

/* Az alcím stílusa */
.section-subtitle {
  font-family: sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #7ba547;
  display: block;
  margin-top: 5px;
}

@media (max-width: 768px) {

  .grape {
    display: none;
  }
  .product-card,
  .tasting-card {
    width: 100%;
  }
  .section-header {
    margin: 40px auto 30px auto;
  }
  .section-title {
    font-size: 2.1rem;
  }

}
