/* Trabajo Final - Estilos Generales Completos */
:root {
  --bg-dark: #0f0c29;
  --bg-purple: #302b63;
  --bg-blue: #24243e;
  --glass-bg: rgba(25, 25, 35, 0.65);
  --glass-border: rgba(255, 255, 255, 0.1);
  --primary: #ff0055; 
  --secondary: #00d4ff; 
  --text-white: #ffffff;
  --text-gray: #b0b0b0;
  --card-radius: 16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Outfit', sans-serif;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg-purple), var(--bg-blue));
  background-attachment: fixed;
  color: var(--text-white);
  min-height: 100vh;
}

/* --- Navbar --- */
.navbar-glass {
  position: sticky; top: 20px; z-index: 1000;
  width: 90%; max-width: 1200px; margin: 0 auto;
  background: rgba(15, 15, 30, 0.85); backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border); border-radius: 50px;
  padding: 10px 30px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}
.nav-content { display: flex; justify-content: space-between; align-items: center; }
.logo-section { display: flex; align-items: center; gap: 10px; text-decoration: none; color: white; }
.logo-section svg { width: 30px; height: 30px; color: var(--secondary); }
.logo-text { font-weight: 800; font-size: 1.4rem; letter-spacing: 1px; }
.nav-links { display: flex; list-style: none; gap: 25px; }
.nav-link { text-decoration: none; color: var(--text-gray); font-weight: 500; transition: 0.3s; }
.nav-link:hover { color: white; text-shadow: 0 0 8px rgba(255,255,255,0.5); }
.nav-actions { display: flex; align-items: center; gap: 20px; }
.cart-wrapper { position: relative; cursor: pointer; color: white; }
.cart-wrapper svg { width: 26px; transition: 0.3s; }
.cart-wrapper:hover svg { color: var(--primary); transform: scale(1.1); }
.cart-badge { 
  position: absolute; top: -5px; right: -8px; background: var(--primary); color: white; 
  font-size: 0.7rem; font-weight: bold; padding: 2px 6px; border-radius: 10px; 
}
.btn-login-nav { 
  background: transparent; border: 1px solid var(--secondary); color: var(--secondary); 
  padding: 6px 18px; border-radius: 20px; cursor: pointer; font-weight: 600; transition: 0.3s; 
}
.btn-login-nav:hover { background: var(--secondary); color: #000; box-shadow: 0 0 15px var(--secondary); }

/* --- Hero --- */
.hero-section { text-align: center; padding: 120px 20px 80px; }
.hero-title { font-size: 4rem; font-weight: 800; line-height: 1.1; margin-bottom: 20px; }
.hero-title span { 
  background: linear-gradient(90deg, var(--secondary), var(--primary)); 
  -webkit-background-clip: text; background-clip: text; color: transparent; 
}
.hero-subtitle { color: var(--text-gray); font-size: 1.3rem; margin-bottom: 40px; max-width: 700px; margin: 0 auto 40px auto; }
.hero-badges { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }
.badge-tech { 
  background: rgba(255,255,255,0.05); padding: 8px 16px; border-radius: 20px; 
  border: 1px solid var(--glass-border); font-size: 0.9rem; color: var(--secondary); 
}

/* --- Secciones Generales --- */
.main-section { max-width: 1200px; margin: 80px auto; padding: 0 20px; }
.section-title { text-align: center; margin-bottom: 50px; }
.section-title h2 { font-size: 2.5rem; margin-bottom: 10px; }
.underline { width: 60px; height: 4px; background: var(--primary); margin: 0 auto; border-radius: 2px; }

/* --- Separadores de Categoría --- */
.category-separator {
    display: flex;
    align-items: center;
    gap: 20px;
    margin: 50px 0 30px 0;
}
.category-separator h3 {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
    white-space: nowrap;
}

/* --- Grid de Productos --- */
.grid-productos { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 30px; }

.card-glass { 
  background: var(--glass-bg); border: 1px solid var(--glass-border); 
  border-radius: var(--card-radius); overflow: hidden; transition: 0.3s; 
  display: flex; flex-direction: column; position: relative;
}
.card-glass:hover { transform: translateY(-10px); border-color: rgba(255,255,255,0.3); }

.card-image-container { 
    height: 250px; background: white; padding: 20px; 
    display: flex; align-items: center; justify-content: center; 
    cursor: pointer; position: relative; overflow: hidden;
}
.card-image-container img { max-width: 100%; max-height: 100%; object-fit: contain; transition: 0.3s; }
.card-image-container:hover img { transform: scale(1.05); }

.card-image-container::after {
    content: "🔎 VER FICHA TÉCNICA";
    position: absolute; bottom: 0; left: 0; width: 100%;
    background: rgba(0,212,255, 0.9); color: #000;
    text-align: center; padding: 10px; font-weight: 800; font-size: 0.9rem;
    transform: translateY(100%); transition: 0.3s ease-in-out;
}
.card-image-container:hover::after { transform: translateY(0); }

.card-content { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.card-content h3 { font-size: 1.1rem; margin-bottom: 15px; line-height: 1.4; }
.card-footer { margin-top: auto; display: flex; justify-content: space-between; align-items: center; }
.price-box { font-size: 1.3rem; font-weight: 800; color: white; }

/* Botones */
.btn-add { 
  background: var(--primary); color: white; border: none; padding: 10px 20px; 
  border-radius: 10px; font-weight: 700; cursor: pointer; transition: 0.3s; 
}
.btn-add:hover { box-shadow: 0 0 20px rgba(255, 0, 85, 0.4); transform: scale(1.05); }
.btn-add.full { width: 100%; }
.btn-outline { background: transparent; border: 1px solid #aaa; color: #aaa; padding: 10px 20px; border-radius: 10px; cursor: pointer; margin-right: 10px; transition: 0.3s;}
.btn-outline:hover { border-color: white; color: white; }
.btn-delete { background: none; border: none; cursor: pointer; font-size: 1.2rem; transition: 0.3s; }
.btn-delete:hover { transform: scale(1.2); color: var(--primary); }

/* --- Configurador y Carrito --- */
.config-layout { display: grid; grid-template-columns: 2fr 1fr; gap: 30px; }
.config-grid-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px; }
.btn-categoria {
  background: rgba(255,255,255,0.05); border: 1px solid var(--glass-border);
  color: white; padding: 20px 10px; border-radius: 12px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 10px; transition: 0.3s;
}
.btn-categoria:hover { background: rgba(255,255,255,0.1); border-color: var(--secondary); box-shadow: 0 0 15px rgba(0, 212, 255, 0.2); }
.btn-categoria svg { width: 30px; height: 30px; }

.config-resumen { background: rgba(0,0,0,0.3); border: 1px solid var(--glass-border); border-radius: 16px; padding: 25px; display: flex; flex-direction: column; }
.resumen-header { margin-bottom: 20px; border-bottom: 1px solid var(--glass-border); padding-bottom: 10px; }
.resumen-lista { flex: 1; margin-bottom: 20px; }
.item-seleccionado { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 0.95rem; color: #ddd; border-bottom: 1px dotted rgba(255,255,255,0.1); padding-bottom: 5px;}
.total-armador { font-size: 1.4rem; font-weight: 800; text-align: right; margin-top: auto; }
.empty-build-msg { text-align: center; color: #888; margin-top: 20px; font-style: italic; }


.carrito-container-pro { background: var(--glass-bg); border-radius: 16px; border: 1px solid var(--glass-border); overflow: hidden; }
.carrito-header { display: grid; grid-template-columns: 2fr 1fr 1fr; padding: 15px 25px; background: rgba(255,255,255,0.05); font-weight: bold; color: var(--secondary); }
.cart-item-pro { display: grid; grid-template-columns: 2fr 1fr 1fr; padding: 20px 25px; align-items: center; border-bottom: 1px solid rgba(255,255,255,0.05); }
.cart-info { display: flex; align-items: center; gap: 15px; }
.cart-info img { width: 60px; height: 60px; background: white; border-radius: 8px; object-fit: contain; padding: 5px; }
.carrito-footer { padding: 25px; display: flex; justify-content: space-between; align-items: center; background: rgba(0,0,0,0.2); }
.total-final { font-size: 1.5rem; font-weight: 800; }
.carrito-actions { display: flex; }

/* --- Footer --- */
.footer-pro { background: #050510; border-top: 1px solid var(--glass-border); margin-top: 80px; padding: 60px 0 20px; }
.footer-container { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; padding: 0 20px; }
.footer-col h4 { color: white; margin-bottom: 20px; font-size: 1.2rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--text-gray); text-decoration: none; transition: 0.3s; }
.footer-col a:hover { color: var(--secondary); }
.footer-bottom { text-align: center; margin-top: 50px; padding-top: 20px; border-top: 1px solid #222; color: #555; }

/* --- Modales (Pago y Otros) --- */
.modal-backdrop { 
    position: fixed; top: 0; left: 0; width: 100%; height: 100%; 
    background: rgba(0,0,0,0.85); display: none; 
    justify-content: center; align-items: center; z-index: 2000; 
    backdrop-filter: blur(5px);
}
.modal-glass { 
    background: #1a1a2e; padding: 30px; border-radius: 20px; 
    border: 1px solid var(--glass-border); width: 90%; 
    max-height: 90vh; overflow-y: auto; position: relative; 
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}
.modal-glass.small { max-width: 400px; text-align: center; }
.modal-glass.large-modal { max-width: 1000px; padding: 0; overflow: hidden; display: flex; flex-direction: column; background: #1a1a2e;}

.close-btn { background: none; border: none; color: #aaa; font-size: 2rem; cursor: pointer; transition: 0.3s; }
.close-btn:hover { color: white; }
.close-btn-float { position: absolute; top: 15px; right: 20px; z-index: 10; background: rgba(0,0,0,0.6); color: white; border: none; width: 40px; height: 40px; border-radius: 50%; font-size: 1.5rem; cursor: pointer; transition: 0.3s; display: flex; align-items: center; justify-content: center;}
.close-btn-float:hover { background: var(--primary); transform: rotate(90deg); }

.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; border-bottom: 1px solid #333; padding-bottom: 10px; }
.modal-header h3 { color: var(--secondary); }

.modal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 20px; padding: 10px;}
.producto-config-item { background: rgba(255,255,255,0.05); padding: 15px; border-radius: 15px; cursor: pointer; text-align: center; border: 1px solid transparent; transition: 0.3s; }
.producto-config-item:hover { border-color: var(--secondary); background: rgba(255,255,255,0.1); transform: translateY(-5px);}
.producto-config-item img { width: 100px; height: 100px; object-fit: contain; background: white; border-radius: 10px; padding: 5px; margin-bottom: 10px;}
.producto-config-item h4 { font-size: 0.9rem; margin-bottom: 5px; height: 40px; overflow: hidden; display: flex; align-items: center; justify-content: center;}

.input-pro { width: 100%; padding: 15px; margin: 20px 0; background: rgba(0,0,0,0.3); border: 1px solid #444; color: white; border-radius: 10px; font-family: inherit; }
.input-pro:focus { outline: none; border-color: var(--secondary); }

/* Estilos de Pagos */
.payment-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 25px; margin-bottom: 20px; }
.payment-card { background: rgba(255,255,255,0.03); border: 1px solid var(--glass-border); padding: 25px; border-radius: 16px; text-align: center; transition: 0.3s; position: relative; overflow: hidden;}
.payment-card:hover { border-color: var(--secondary); background: rgba(255,255,255,0.05); }
.payment-icon { font-size: 3rem; margin-bottom: 15px; }
.payment-card h4 { margin-bottom: 10px; color: white; }
.payment-desc { font-size: 0.9rem; color: #aaa; margin-bottom: 20px; min-height: 40px; }
.highlight-box { background: rgba(0,0,0,0.3); border: 1px dashed var(--glass-border); padding: 20px; border-radius: 12px; text-align: left; font-size: 0.95rem; color: #ddd; }
.highlight-box p { margin-bottom: 8px; word-break: break-all; }
.highlight-box strong { color: var(--secondary); }
.rapipago-code { font-size: 1.5rem; font-weight: 800; text-align: center; color: var(--primary); background: white; padding: 15px; border-radius: 8px; letter-spacing: 3px; margin: 15px 0; }
.copiable { cursor: pointer; border-bottom: 1px dotted var(--secondary); }

/* Detalles Producto */
.detalle-layout { display: grid; grid-template-columns: 40% 60%; height: 100%; min-height: 550px; }
.detalle-img-container { background: white; display: flex; justify-content: center; align-items: center; padding: 40px; position: relative; }
.detalle-img-container img { max-width: 100%; max-height: 450px; object-fit: contain; filter: drop-shadow(0 15px 30px rgba(0,0,0,0.3)); }
.detalle-info-container { padding: 40px; background: rgba(20,20,35,0.95); display: flex; flex-direction: column; overflow-y: auto; }
.detalle-categoria { color: var(--secondary); text-transform: uppercase; letter-spacing: 2px; font-size: 0.8rem; font-weight: bold; margin-bottom: 10px; display: block; }
.detalle-titulo { font-size: 2.5rem; margin-bottom: 15px; line-height: 1.1; font-weight: 800; }
.detalle-descripcion { color: #ccc; margin-bottom: 30px; line-height: 1.6; font-size: 1rem; }
.detalle-specs-title { font-size: 1.2rem; color: white; border-bottom: 1px solid var(--glass-border); padding-bottom: 15px; margin-bottom: 20px; font-weight: 600; }
.detalle-specs-list { list-style: none; margin-bottom: 30px; }
.detalle-specs-list li { margin-bottom: 12px; color: var(--text-gray); display: flex; align-items: flex-start; gap: 12px; font-size: 1rem; }
.detalle-specs-list li::before { content: "⚡"; color: var(--primary); font-size: 1rem; margin-top: 2px; }
.detalle-precio { font-size: 3rem; font-weight: 800; color: white; margin-bottom: 25px; }

/* --- Estilos RMA / Garantías --- */
.rma-steps {
    display: flex;
    flex-direction: column;
    gap: 30px;
    text-align: left;
}
.rma-step { display: flex; gap: 20px; align-items: flex-start; }
.step-number {
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: white; width: 50px; height: 50px; border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    font-size: 1.5rem; font-weight: 800; flex-shrink: 0;
    box-shadow: 0 0 15px rgba(255, 0, 85, 0.4);
}
.step-content h4 { color: var(--secondary); font-size: 1.2rem; margin-bottom: 5px; }
.step-content p { color: #ddd; font-size: 0.95rem; line-height: 1.5; }

/* --- Notificación Flotante (Toast) --- */
.notificacion-glass {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: rgba(10, 10, 20, 0.95);
    border: 1px solid var(--secondary);
    color: white;
    padding: 15px 25px;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
    z-index: 3000;
    font-weight: 600;
    min-width: 250px;
    text-align: center;
    display: none; 
    animation: subirFade 0.5s ease forwards;
}

@keyframes subirFade {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Media Queries */
@media(max-width: 992px) {
    .config-grid-buttons { grid-template-columns: repeat(3, 1fr); }
}

@media(max-width: 768px) {
  .nav-links { display: none; }
  .hero-title { font-size: 2.8rem; }
  .config-layout, .carrito-container-pro, .footer-container, .detalle-layout, .payment-grid { grid-template-columns: 1fr; }
  .config-grid-buttons { grid-template-columns: repeat(3, 1fr); }
  .carrito-header { display: none; }
  .cart-item-pro { grid-template-columns: 1fr; gap: 15px; text-align: center; padding: 20px;}
  .cart-info { flex-direction: column; }
  .carrito-footer { flex-direction: column; gap: 20px; }
  .carrito-actions { width: 100%; justify-content: space-between; }
  .detalle-img-container { height: 300px; padding: 20px; }
  .detalle-img-container img { max-height: 250px; }
  .detalle-info-container { padding: 30px 20px; }
  .modal-glass { padding: 20px; width: 95%; }
}

@media(max-width: 480px) {
    .config-grid-buttons { grid-template-columns: repeat(2, 1fr); }
    .hero-title { font-size: 2.2rem; }
    .payment-grid { grid-template-columns: 1fr; }
}