/* css/style.css */

/* Basic Reset and Variables */
:root {
    --primary-color: #e50050; 
    --bg-color: #2f2f2f;      
    --text-light: #ffffff;    
    --text-dark: #333333;     
    --card-bg: #ffffff;
    --price-green: #68b332; /* The nice green from your example */
}

body {
    margin: 0;
    font-family: 'Roboto', sans-serif; 
    background-color: var(--bg-color);
    color: var(--text-light); 
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Chivo', sans-serif;
    margin-top: 0;
}

.container {
    max-width: 1000px; /* Narrowed slightly to match the poster feel */
    margin: 0 auto;
    padding: 0 20px;
}

header {
    background: #1a1a1a; /* Darker header top bar */
    padding: 1rem 0;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--primary-color);
}

header h1 {
    margin: 0;
    font-size: 1.5rem;
    color: var(--primary-color);
}

/* --- The Sliding Magic --- */
#app-container {
    display: flex;
    width: 100%;
    overflow: hidden; 
    position: relative;
    min-height: 70vh;
}

.view {
    min-width: 100%; 
    transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1); 
    box-sizing: border-box;
}

.slide-to-checkout .view {
    transform: translateX(-100%);
}

/* --- Event Grid & Cards (Homepage) --- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 2rem; }
.event-card { background: var(--card-bg); color: var(--text-dark); border-radius: 4px; overflow: hidden; cursor: pointer; transition: transform 0.2s; }
.event-card:hover { transform: translateY(-5px); box-shadow: 0 8px 20px rgba(0,0,0,0.5); }
.event-image { width: 100%; height: 200px; object-fit: cover; display: block; }
.event-info { padding: 1.5rem; }
.event-title { margin: 0 0 0.5rem; font-size: 1.25rem; }
.event-details { margin: 0 0 0.5rem; color: #666; font-size: 0.9rem; }
.event-price { font-weight: bold; color: var(--primary-color); margin-top: 1rem; font-size: 1.1rem; }

/* --- Checkout View Elements --- */
.back-btn { background: none; border: none; font-size: 1rem; cursor: pointer; color: #fff; padding: 0; margin-bottom: 1.5rem; font-family: 'Roboto', sans-serif; opacity: 0.8;}
.back-btn:hover { opacity: 1; text-decoration: underline; }

/* NEW: The Unified Document Look */
.checkout-document {
    background: var(--card-bg);
    border-radius: 4px;
    overflow: hidden; /* Keeps the top image corners rounded if applied */
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    margin-bottom: 3rem;
}

.checkout-header-img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block; /* CRITICAL: Removes the tiny gap below images */
    margin: 0;
}

/* NEW: Two Column Event Meta Data */
.checkout-meta {
    background: #e9e9e9; 
    color: var(--text-dark); 
    padding: 2.5rem;
    display: grid;
    grid-template-columns: 2fr 1fr; /* Left side is wider */
    gap: 3rem;
}

.meta-left h2 { font-size: 2.2rem; margin-bottom: 1rem; }
.event-description { line-height: 1.6; font-size: 0.95rem; margin-bottom: 1.5rem; }
.meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; font-size: 0.9rem; font-weight: bold;}
.meta-grid span { font-weight: normal; display: block; margin-top: 0.3rem;}

.meta-right { border-left: 1px solid #ccc; padding-left: 3rem; }
.meta-right h3 { font-size: 1.3rem; margin-bottom: 1rem; }
.meta-right p { font-size: 0.9rem; margin-bottom: 1.5rem; line-height: 1.5;}

/* NEW: Ticket List Layout */
.checkout-tickets {
    background: #ffffff;
    padding: 2.5rem;
    color: var(--text-dark);
}

.ticket-headers {
    display: flex;
    font-weight: bold;
    font-size: 0.95rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #ddd;
    margin-bottom: 1.5rem;
}

/* Column Alignments for Headers and Rows */
.col-info { flex: 0 0 45%; }
.col-price { flex: 0 0 15%; text-align: center; border-left: 1px solid #ddd;}
.col-qty { flex: 0 0 20%; text-align: center; border-left: 1px solid #ddd;}
.col-sum { flex: 0 0 20%; text-align: center; border-left: 1px solid #ddd;}

/* Ticket Rows */
.ticket-row {
    display: flex;
    align-items: center;
    padding: 1.5rem 0;
    border-bottom: 1px solid #eee;
}

.ticket-info-flex {
    display: flex;
    align-items: center;
}

.ticket-image {
    width: 60px;
    height: 60px;
    object-fit: cover;
    margin-right: 1.5rem;
    border-radius: 4px;
}

.ticket-info-flex h4 { margin: 0 0 0.3rem 0; font-size: 1.1rem; }
.ticket-desc { margin: 0; font-size: 0.85rem; color: #777; line-height: 1.4; padding-right: 1rem;}

/* Prices and Totals */
.price-text {
    color: var(--price-green);
    font-weight: bold;
    font-size: 1.1rem;
}

/* Minimalist +/- Buttons */
.qty-control { display: flex; align-items: center; justify-content: center; gap: 15px; font-size: 1.1rem; font-weight: bold;}
.qty-btn { 
    background: none; border: none; font-size: 1.4rem; font-weight: bold; cursor: pointer; 
    color: var(--text-dark); padding: 0 10px; transition: color 0.2s;
}
.qty-btn:hover { color: var(--primary-color); }
.qty-val { width: 20px; text-align: center; }
