:root {
    --primary: #0A2463;
    --secondary: #3E92CC;
    --accent: #FF5722;
    --bg-color: #F4F7F6;
    --card-bg: #FFFFFF;
    --text-dark: #2D3142;
    --text-light: #9094A6;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.4);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-dark);
    line-height: 1.6;
}

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

/* Header */
.navbar {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: -1px;
}
.logo span { color: var(--accent); }

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--secondary);
}

.cart-icon {
    position: relative;
    font-size: 1.5rem;
    color: var(--text-dark);
    text-decoration: none;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--accent);
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 50%;
}

/* Typography */
h1 { font-size: 2.5rem; font-weight: 800; margin: 40px 0 20px; color: var(--primary); }

/* Product Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.product-card {
    background: var(--card-bg);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.product-img-wrapper {
    height: 250px;
    background: #f9f9f9;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 20px;
}

.product-img-wrapper img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
}

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

.product-info {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-category {
    font-size: 0.85rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.product-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.product-price {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--primary);
    margin-top: auto;
}

/* Product Detail Page */
.product-detail-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin: 50px 0;
    background: var(--card-bg);
    padding: 40px;
    border-radius: 24px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.04);
}

.detail-img {
    background: #f8f8f8;
    border-radius: 16px;
    padding: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-img img {
    width: 100%;
    max-width: 500px;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.detail-info h1 { margin-top: 0; font-size: 2.8rem; }
.detail-price { font-size: 2rem; font-weight: 800; color: var(--primary); margin-bottom: 20px; }
.detail-desc { color: var(--text-light); font-size: 1.1rem; margin-bottom: 30px; }

/* Selection Options */
.options-group {
    margin-bottom: 30px;
}

.options-title {
    font-weight: 700;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.power-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.power-option {
    border: 2px solid #eaeaea;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    text-align: center;
    transition: var(--transition);
}

.power-option.selected {
    border-color: var(--secondary);
    background: rgba(62, 146, 204, 0.05);
}

.power-option h4 { font-size: 1.1rem; margin-bottom: 5px; color: var(--primary); }
.power-option p { font-size: 0.85rem; color: var(--text-light); }

/* Power Form */
#powerForm {
    display: none;
    background: #f9fbff;
    padding: 25px;
    border-radius: 16px;
    border: 1px solid #e1ebfa;
    margin-bottom: 30px;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.eye-power {
    margin-bottom: 20px;
}
.eye-power h4 { margin-bottom: 10px; color: var(--primary); border-bottom: 1px solid #e1ebfa; padding-bottom: 5px;}

.power-inputs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.input-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 5px;
}

.input-group input, .input-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.input-group input:focus, .input-group select:focus {
    outline: none;
    border-color: var(--secondary);
}

.btn {
    display: inline-block;
    width: 100%;
    padding: 16px 20px;
    background: var(--primary);
    color: white;
    text-align: center;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn:hover {
    background: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 87, 34, 0.2);
}

/* Cart Page */
.cart-wrapper {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.cart-item {
    display: flex;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid #eaeaea;
}

.cart-item img {
    width: 100px;
    height: auto;
    border-radius: 10px;
    background: #f8f8f8;
    padding: 10px;
    margin-right: 20px;
}

.cart-item-info { flex-grow: 1; }
.cart-item-title { font-size: 1.2rem; font-weight: 700; }
.cart-item-power { font-size: 0.9rem; color: var(--text-light); margin-top: 5px; }

.cart-item-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0 30px;
}

.btn-remove {
    background: none;
    border: none;
    color: #ff3b3b;
    font-size: 1.2rem;
    cursor: pointer;
}

.cart-total {
    text-align: right;
    margin-top: 30px;
    font-size: 1.5rem;
    font-weight: 800;
}

.cart-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
}
.cart-actions .btn { width: auto; padding: 15px 40px; }

/* Footer */
.footer {
    background: #1A1F2B;
    color: white;
    padding: 60px 0 20px;
    margin-top: 80px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h3 { font-size: 1.8rem; margin-bottom: 15px; }
.footer-brand h3 span { color: var(--accent); }
.footer-brand p { color: #a0a4b8; }

.footer-links h4 { margin-bottom: 20px; font-size: 1.1rem; }
.footer-links ul { list-style: none; }
.footer-links ul li { margin-bottom: 10px; }
.footer-links a { color: #a0a4b8; text-decoration: none; transition: color 0.3s; }
.footer-links a:hover { color: white; }

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: #a0a4b8;
    font-size: 0.9rem;
}

/* Dropdown Menu */
.nav-links li {
    position: relative;
}

.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--card-bg);
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-radius: 12px;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    z-index: 100;
}

.nav-links li:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown a {
    display: block;
    padding: 10px 20px;
    color: var(--text-dark);
    font-weight: 500;
}

.dropdown a:hover {
    background: var(--bg-color);
    color: var(--primary);
}

/* Discount Badge */
.discount-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: #ff3b3b;
    color: white;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 5px 10px;
    border-radius: 8px;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(255, 59, 59, 0.3);
}

.product-card {
    position: relative; /* ensure badge is absolute to the card */
}

/* Responsive */
@media (max-width: 768px) {
    .product-detail-wrapper { grid-template-columns: 1fr; padding: 20px; }
    .footer-content { grid-template-columns: 1fr; }
    .power-inputs { grid-template-columns: 1fr; }
    .cart-item { flex-direction: column; text-align: center; }
    .cart-item img { margin: 0 0 15px 0; }
}
