/* -------------------- RESET -------------------- */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
    font-family: 'Poppins', sans-serif; 
}

html { 
    scroll-behavior: smooth; 
}

body { 
    background: linear-gradient(180deg, #121212, #1b1b1b);
    color: #eee;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    max-width: 1200px; 
    margin: 30px auto; 
    padding: 0 20px;
    flex: 1;
}

/* -------------------- HEADER -------------------- */
header {
    background: rgba(31, 31, 31, 0.95);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

header h1 { 
    color: #eee; 
    font-size: 28px; 
    font-weight: 700; 
}

nav a {
    margin: 0 15px;
    text-decoration: none;
    color: #eee;
    font-weight: 500;
    position: relative;
    transition: 0.2s ease;
}

nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 0%;
    height: 2px;
    background: #eee;
    transition: 0.3s ease;
}

nav a:hover::after, 
nav a.active::after { 
    width: 100%; 
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.auth-btn {
    background: transparent;
    color: #eee;
    border: 1px solid #444;
    padding: 6px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: 0.3s;
}

.auth-btn:hover {
    background: #eee;
    color: #121212;
}

#cart {
    font-size: 16px;
    background: #121212;
    color: #eee;
    padding: 8px 15px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    border: 1px solid #333;
    transition: 0.3s ease, transform 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

#cart:hover { 
    transform: scale(1.05); 
}

/* -------------------- HOME -------------------- */
#home-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 60px 20px;
}

#home-section h1 { 
    font-size: 42px; 
    margin-bottom: 20px; 
    font-weight: 700; 
    color: #eee; 
}

#home-section p { 
    font-size: 18px; 
    color: #ccc; 
    max-width: 700px; 
}

#home-section .btn {
    margin-top: 20px;
    background: #121212;
    color: #eee;
    padding: 12px 25px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid #333;
    transition: 0.3s ease, transform 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

#home-section .btn:hover { 
    transform: scale(1.05); 
    background: #333; 
}

/* -------------------- SEARCH -------------------- */
.search-bar { 
    display: flex; 
    justify-content: center; 
    margin-bottom: 30px; 
}

.search-bar input {
    padding: 14px;
    width: 60%;
    max-width: 500px;
    border-radius: 25px;
    border: none;
    background-color: rgba(31, 31, 31, 0.8);
    color: #eee;
    font-size: 16px;
}

.search-bar input::placeholder { 
    color: #aaa; 
}

/* -------------------- PRODUCTS -------------------- */
.products-header {
    text-align: center;
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.products-header.visible { 
    opacity: 1; 
    transform: translateY(0); 
}

.products-header h1 { 
    font-size: 48px; 
    color: #fff; 
    font-weight: 700; 
    margin: 0; 
}

.products { 
    display: flex; 
    flex-wrap: wrap; 
    justify-content: center; 
    gap: 25px; 
}

.product {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    width: 250px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
    transition: 0.3s ease, transform 0.3s ease, opacity 0.6s ease;
    text-align: center;
    overflow: hidden;
    color: #eee;
    opacity: 0;
    transform: translateY(20px);
}

.product.visible { 
    opacity: 1; 
    transform: translateY(0); 
}

.product:hover { 
    transform: translateY(-5px); 
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.7); 
}

.product img { 
    width: 100%; 
    height: 180px; 
    object-fit: cover; 
    transition: 0.3s ease; 
    cursor: pointer;
}

.product-placeholder {
    width: 100%;
    height: 180px;
    background: linear-gradient(135deg, #2a2a2a 0%, #1f1f1f 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.product-placeholder span {
    max-width: 90%;
    word-wrap: break-word;
}

.product:hover img { 
    transform: scale(1.05); 
}

.product h3 { 
    margin: 10px 0 5px; 
    font-size: 18px; 
    font-weight: 600; 
    color: #eee; 
}

.product p { 
    font-size: 14px; 
    color: #ccc; 
    padding: 0 10px 10px 10px; 
}

.price { 
    font-weight: bold; 
    color: #eee; 
    margin: 10px 0; 
    font-size: 16px; 
}

.product button, 
.add-to-cart-btn {
    background: #121212;
    color: #eee;
    border: none;
    padding: 12px;
    width: 100%;
    border-radius: 0 0 20px 20px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    border: 1px solid #333;
    transition: 0.3s ease, transform 0.2s ease;
}

.product button:hover,
.add-to-cart-btn:hover { 
    transform: translateY(-2px) scale(1.05); 
    background: #333; 
}

/* -------------------- TABLE / CART -------------------- */
table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(31, 31, 31, 0.9);
    border-radius: 15px;
    overflow: hidden;
}

th, td { 
    padding: 15px; 
    border-bottom: 1px solid #333; 
    text-align: center; 
    color: #eee; 
}

th { 
    background: #121212; 
}

.total { 
    text-align: right; 
    font-weight: bold; 
    margin-top: 15px; 
    font-size: 18px; 
}

.btn { 
    background: #121212; 
    color: #eee; 
    border: none; 
    padding: 10px 15px; 
    border-radius: 10px; 
    cursor: pointer; 
    font-weight: 600; 
    margin-top: 10px; 
    border: 1px solid #333; 
    transition: 0.3s ease, transform 0.2s ease; 
    text-decoration: none;
    display: inline-block;
}

.btn:hover { 
    transform: scale(1.05); 
    background: #333; 
}

.remove-btn {
    margin: 0;
    padding: 5px 10px;
}

.qty-input {
    width: 60px;
    padding: 5px;
    background: #222;
    color: #eee;
    border: 1px solid #444;
    border-radius: 5px;
    text-align: center;
}

/* -------------------- FORM -------------------- */
form {
    background: rgba(31, 31, 31, 0.85);
    backdrop-filter: blur(8px);
    padding: 25px;
    border-radius: 20px;
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
}

form input, 
form textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border-radius: 15px;
    border: none;
    background-color: #121212;
    color: #eee;
}

form input::placeholder, 
form textarea::placeholder { 
    color: #aaa; 
}

form input:focus, 
form textarea:focus { 
    outline: none; 
    border: 1px solid #eee; 
    box-shadow: 0 0 10px #eee; 
}

/* -------------------- MODALS -------------------- */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-content {
    background: #1b1b1b;
    padding: 20px;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    position: relative;
}

.product-modal-content img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 15px;
}

.product-modal-content h2 {
    color: #eee;
    margin-bottom: 10px;
}

.product-modal-content p {
    color: #ccc;
    margin-bottom: 10px;
}

.modal-price {
    font-size: 20px;
    font-weight: bold;
    color: #eee;
    margin-bottom: 15px;
}

.modal-option {
    margin-bottom: 10px;
}

.modal-option label {
    color: #eee;
    display: block;
    margin-bottom: 5px;
}

.modal-option select,
.modal-option input {
    padding: 8px;
    border-radius: 5px;
    background: #121212;
    color: #eee;
    border: 1px solid #333;
}

.close {
    position: absolute;
    top: 10px;
    right: 15px;
    cursor: pointer;
    font-size: 24px;
    color: #eee;
}

.close:hover {
    color: #fff;
}

/* -------------------- FOOTER -------------------- */
footer {
    background: #1b1b1b;
    color: #ccc;
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}

footer p { 
    margin: 5px 0; 
    font-size: 14px; 
}

/* -------------------- RESPONSIVE -------------------- */
@media (max-width: 800px) {
    header { 
        flex-direction: column; 
        gap: 10px; 
        padding: 10px; 
    }
    
    .header-right { 
        width: 100%; 
        justify-content: center; 
    }
    
    nav { 
        display: flex; 
        flex-wrap: wrap; 
        justify-content: center; 
    }
}

h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #eee;
    font-weight: 700;
}
