/* ==========================================================================
   YONGGI HUB — Hoja de Estilos Base & Checkout
   ========================================================================== */

:root {
  --bg-color: #f7f6f8;
  --panel-bg: #ffffff;
  --primary: #41334f;
  --primary-hover: #2d2338;
  --text-color: #2b2633;
  --muted-text: #6e6778;
  --line-color: #e5e2ea;
  --accent-soft: #f0ecf4;
  --badge-bg: #eadef0;
  --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --radius: 8px;
  --shadow: 0 4px 20px rgba(65, 51, 79, 0.06);
}

*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-main);
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
}

.wrap {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header & NAVEGACIÓN */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line-color);
}

.brand-container {
  display: flex;
  flex-direction: column;
}

.brand-logo-img {
  height: 38px;
  width: auto;
}

.hub-manifest {
  font-size: 0.82rem;
  color: var(--muted-text);
  margin: 0.2rem 0 0 0;
}

.site-header nav a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary);
  color: #fff;
  padding: 8px;
  z-index: 100;
}
.skip-link:focus {
  top: 0;
}

/* SECCIÓN CHECKOUT */
.checkout-section {
  padding: 3rem 1.5rem;
}

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

.eyebrow {
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 1px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.lead {
  font-size: 1.05rem;
  color: var(--muted-text);
  max-width: 650px;
  margin: 0.5rem auto 2rem auto;
}

.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 2rem;
  margin-top: 1.5rem;
}

/* Tarjeta Principal Formulario */
.checkout-card {
  background: var(--panel-bg);
  border: 1px solid var(--line-color);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 1.15rem;
  color: var(--primary);
  margin-top: 0;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--line-color);
  padding-bottom: 0.5rem;
}

.form-group {
  margin-bottom: 1.25rem;
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.35rem;
}

.form-group input {
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line-color);
  border-radius: 6px;
  font-size: 0.95rem;
  font-family: inherit;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(65, 51, 79, 0.1);
}

.help-text {
  font-size: 0.78rem;
  color: var(--muted-text);
  margin-top: 0.25rem;
}

/* Tarjetas de Selección de Producto */
.product-options {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.product-option-card {
  display: flex;
  align-items: center;
  padding: 0.8rem 1rem;
  border: 1px solid var(--line-color);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: #fcfbfd;
  gap: 0.8rem;
}

.product-option-card:hover {
  border-color: var(--primary);
  background: #f5f2f8;
}

.product-option-card input[type="radio"] {
  accent-color: var(--primary);
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin: 0;
}

.product-option-card.highlight {
  border: 2px solid var(--primary);
  background: var(--accent-soft);
}

/* Miniatura estilo icono */
.product-icon-thumb {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--line-color);
  background-color: #ffffff;
  flex-shrink: 0;
  cursor: zoom-in;
  transition: transform 0.2s ease, border-color 0.2s ease;
  padding: 2px;
}

.product-icon-thumb:hover {
  transform: scale(1.1);
  border-color: var(--primary);
}

.product-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  font-size: 0.92rem;
  gap: 0.5rem;
}

.product-price {
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
}

.badge-price {
  background: var(--primary);
  color: #fff;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
}

/* Caja de Aviso / Disclaimer */
.notice-box {
  background-color: #fff9e6;
  border-left: 4px solid #d97706;
  padding: 1rem;
  border-radius: 4px;
  margin: 1.5rem 0;
}

.notice-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #92400e;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}

.notice-box p {
  margin: 0;
  font-size: 0.83rem;
  color: #78350f;
  line-height: 1.45;
}

/* Botones */
.button.primary {
  display: block;
  width: 100%;
  background: var(--primary);
  color: #ffffff;
  border: none;
  padding: 1rem;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: background 0.2s ease;
}

.button.primary:hover {
  background: var(--primary-hover);
}

/* Lateral Sidebar */
.checkout-sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.sidebar-card {
  background: var(--panel-bg);
  border: 1px solid var(--line-color);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.sidebar-card h3 {
  margin-top: 0;
  font-size: 1rem;
  color: var(--primary);
}

.sidebar-card p {
  font-size: 0.85rem;
  color: var(--muted-text);
}

.contact-mail a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}

.philosophy-mini {
  text-align: center;
  background: var(--accent-soft);
  border: none;
}

.kr-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary);
  display: block;
}

/* Modal Overlay de Ampliación / Zoom */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(43, 38, 51, 0.85);
  backdrop-filter: blur(4px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  padding: 1.5rem;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  position: relative;
  background: #ffffff;
  padding: 1rem;
  border-radius: 8px;
  max-width: 420px;
  width: 100%;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  animation: modalFadeIn 0.25s ease;
}

.modal-content img {
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 4px;
}

#modal-caption {
  margin-top: 0.75rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-color);
}

.modal-close {
  position: absolute;
  top: -12px;
  right: -12px;
  background: var(--primary);
  color: #ffffff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

/* Footer */
footer {
  border-top: 1px solid var(--line-color);
  padding: 2rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--muted-text);
}

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

/* Responsivo */
@media (max-width: 850px) {
  .checkout-grid {
    grid-template-columns: 1fr;
  }
}