
/* VinoPress Frontend Styles - Clean & Modern */

:root {
    --vp-primary: #88114b; 
    --vp-text: #333;
    --vp-bg-light: #f9fafb;
    --vp-border: #e5e5e5;
    --vp-hover: #1a1a1a;
}

/* SCROLL LOCK FIX: Apply to both html and body */
html.vp-noscroll, 
body.vp-noscroll {
    overflow: hidden !important; 
    height: 100% !important;
    position: relative; 
    touch-action: none; /* Prevent touch scroll on body */
}

.vinopress-container {
    max-width: 900px;
    margin: 0 auto;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    color: var(--vp-text);
    min-height: 550px; 
    position: relative;
    -webkit-tap-highlight-color: transparent; 
}

/* --- NEW "CLEAN & COOL" LOADING SCREEN --- */
.vp-loading-overlay {
    position: absolute;
    inset: 0;
    background: #ffffff;
    z-index: 2000; /* Highest */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease-out;
}

.vp-loader-visual {
    position: relative;
    width: 60px;
    height: 100px;
    margin-bottom: 25px;
}

.vp-glass-bowl {
    width: 50px;
    height: 50px;
    border: 2px solid #1a1a1a;
    border-top: none;
    border-bottom-left-radius: 25px;
    border-bottom-right-radius: 25px;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    background: rgba(255,255,255,0.5);
    z-index: 2;
}

.vp-glass-stem {
    width: 2px;
    height: 35px;
    background: #1a1a1a;
    margin: -1px auto 0;
    z-index: 1;
}

.vp-glass-foot {
    width: 34px;
    height: 2px;
    background: #1a1a1a;
    margin: 0 auto;
    border-radius: 2px;
}

.vp-liquid {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    background: var(--vp-primary);
    animation: vp-fill-up 2.5s ease-in-out infinite;
    z-index: 1;
}

.vp-liquid::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -50%;
    width: 200%;
    height: 20px;
    background: rgba(255,255,255,0.2);
    border-radius: 40%;
    animation: vp-wave-motion 2s linear infinite;
}

.vp-loading-text {
    font-weight: 400;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: #1a1a1a;
    margin-top: 10px;
    opacity: 0;
    animation: vp-fade-text 2.5s ease-in-out infinite;
}

@keyframes vp-fill-up {
    0% { height: 0%; }
    50% { height: 75%; }
    90% { height: 75%; opacity: 1; }
    100% { height: 0%; opacity: 0; }
}

@keyframes vp-wave-motion {
    0% { transform: translateX(0) rotate(0deg); }
    100% { transform: translateX(-25%) rotate(360deg); }
}

@keyframes vp-fade-text {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}


/* --- HOME VIEW (Buttons) --- */
.vp-home-container {
    text-align: center;
    padding: 30px 0;
    animation: vp-fade-in 0.8s ease-out;
}

.vp-home-title {
    font-size: 2rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 5px;
    color: #111;
}

.vp-home-subtitle {
    color: #888;
    margin-bottom: 30px;
    font-weight: 300;
}

.vp-grid-menu {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 15px;
}

.vp-menu-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: white;
    border: 1px solid #e5e5e5;
    padding: 20px 25px;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
    min-height: 70px; 
}

.vp-btn-label {
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 500;
    color: #333;
    transition: color 0.3s;
}

.vp-menu-btn:hover {
    border-color: #000 !important;
    background-color: #fafafa !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.vp-menu-btn:hover .vp-btn-label { color: #000 !important; }

.vp-arrow {
    opacity: 0.3;
    font-size: 1.2rem;
    color: #333;
    transition: all 0.3s ease;
}

.vp-menu-btn:hover .vp-arrow {
    opacity: 1;
    transform: translateX(5px);
    color: #000 !important;
}

/* --- LIST VIEW --- */
.vp-list-header {
    text-align: center;
    margin-bottom: 15px;
    position: relative;
    padding-top: 10px;
}

#vp-back-btn,
.vp-back-link {
    position: absolute;
    left: 10px;
    top: 12px;
    background: none !important;
    border: none !important;
    cursor: pointer;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #888 !important; 
    padding: 10px;
    z-index: 20;
    line-height: 1;
}

#vp-back-btn:hover, .vp-back-link:hover { color: #000 !important; }

.vp-list-header h2 {
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 1.6rem;
    margin: 5px 0 10px 0;
    color: #111;
    padding: 0 40px; 
}

/* --- CONTROLS BAR (Split) --- */
.vp-controls-sticky {
    position: sticky;
    top: 0;
    z-index: 50; 
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid #f0f0f0;
    margin: 0 -15px 20px -15px;
    padding: 12px 15px;
}

.vp-controls-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    max-width: 900px;
    margin: 0 auto;
}

.vp-dropdown-wrapper {
    position: relative;
}

.vp-control-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    background: white;
    border: 1px solid #e5e5e5;
    padding: 11px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #444;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vp-control-btn:hover { background-color: #f8fafc; border-color: #94a3b8; color: #0f172a; }
.vp-control-btn.active { background-color: #fff1f2; border-color: var(--vp-primary); color: var(--vp-primary); }
.vp-control-btn svg { width: 16px; height: 16px; }

.vp-btn-badge {
    background: var(--vp-primary);
    color: white;
    font-size: 0.7rem;
    padding: 1px 6px;
    border-radius: 10px;
    margin-left: 2px;
}


/* WINE ITEMS */
.vp-wine-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 50px; 
    padding: 0 10px;
}

.vp-item {
    display: flex;
    justify-content: space-between;
    align-items: center; 
    padding-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
    opacity: 0;
    transform: translateY(20px);
    animation: vp-slide-up 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* Content Left */
.vp-content-left {
    display: flex;
    align-items: flex-start; 
    flex: 1;
    padding-right: 10px;
}

.vp-wine-image {
    width: 60px;          
    height: 85px;         
    object-fit: contain;  
    border-radius: 4px;
    margin-right: 15px;
    flex-shrink: 0;
    background-color: #ffffff;
    border: 1px solid #f0f0f0; 
    padding: 3px;         
}

.vp-item:last-child { border-bottom: none; }

@keyframes vp-fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes vp-slide-up { to { opacity: 1; transform: translateY(0); } }

.vp-info { flex: 1; }

.vp-info h3 {
    margin: 0 0 4px 0;
    font-size: 1.05rem; 
    font-weight: 500;
    color: #111;
    letter-spacing: 0.3px;
    line-height: 1.3;
}

.vp-year {
    font-size: 0.9em;
    color: #111; 
    font-weight: 500; 
    margin-left: 4px;
    white-space: nowrap;
    opacity: 0.8;
}

.vp-meta {
    color: var(--vp-primary); 
    font-weight: 600;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    line-height: 1.3;
}

.vp-desc {
    font-size: 0.85rem;
    color: #777;
    margin: 6px 0 10px 0;
    line-height: 1.5;
    font-style: italic;
    display: -webkit-box;
    -webkit-line-clamp: 3; 
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vp-prices-text { margin-top: 8px; }
.vp-price-line { font-size: 0.8rem; color: #555; font-weight: 500; }

.vp-badge {
    background-color: var(--vp-primary);
    color: white;
    padding: 6px 10px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95rem; 
    white-space: nowrap;
    margin-left: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    align-self: flex-start;
    margin-top: 2px;
}

.vp-empty {
    text-align: center;
    color: #999;
    padding: 30px 10px;
    font-size: 0.9rem;
    font-style: italic;
}

.vp-footer-note {
    text-align: center;
    font-size: 0.65rem;
    color: #ccc;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px dashed #f5f5f5;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* --- STRICT MOBILE OVERRIDES --- */
@media (max-width: 480px) {
    .vp-home-title { font-size: 1.6rem; }
    .vp-home-subtitle { font-size: 0.9rem; margin-bottom: 25px; }
    
    .vp-list-header h2 { font-size: 1.3rem; letter-spacing: 1px; }
    
    .vp-wine-image { width: 50px; height: 70px; margin-right: 12px; }
    
    .vp-info h3 { font-size: 1rem; }
    .vp-meta { font-size: 0.65rem; }
    .vp-badge { font-size: 0.9rem; padding: 5px 8px; }
    
    .vp-item { padding-bottom: 15px; gap: 0; }
    
    .vp-menu-btn { padding: 15px; min-height: 60px; }
    .vp-btn-label { font-size: 0.9rem; }
    
    .vp-controls-sticky { padding: 10px 15px; margin-bottom: 15px; }
    .vp-control-btn { padding: 12px; font-size: 0.8rem; }
}
