/*=========================================
  TECH STORE
  STYLE.CSS - PART 1
=========================================*/

/* Google Font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

/* Reset */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

html{
    scroll-behavior:smooth;
}

body{
    font-family:'Poppins',sans-serif;
    background:#0f172a;
    color:#ffffff;
    overflow-x:hidden;
}

/* Scrollbar */

::-webkit-scrollbar{
    width:10px;
}

::-webkit-scrollbar-track{
    background:#111827;
}

::-webkit-scrollbar-thumb{
    background:#38bdf8;
    border-radius:10px;
}

::-webkit-scrollbar-thumb:hover{
    background:#0ea5e9;
}

::selection{
    background:#38bdf8;
    color:#fff;
}

/*=========================================
HEADER
=========================================*/

header{

    width:100%;

    display:flex;

    justify-content:space-between;

    align-items:center;

    padding:18px 8%;

    background:#111827;

    position:sticky;

    top:0;

    z-index:999;

    border-bottom:1px solid #1f2937;

}

/* Logo */

.logo{

    display:flex;

    align-items:center;

    gap:12px;

}

.logo img{

    width:55px;

    height:55px;

    object-fit:cover;

    border-radius:50%;

}

.logo h2{

    color:#38bdf8;

    font-size:28px;

    font-weight:700;

}

.logo a{

    color:white;

    text-decoration:none;

    padding:10px 16px;

    border-radius:8px;

    transition:.3s;

    font-weight:500;

}


/*=========================================
Navigation
=========================================*/

nav{

    display:flex;

    align-items:center;

    gap:18px;

}

nav a{

    color:white;

    text-decoration:none;

    padding:10px 16px;

    border-radius:8px;

    transition:.3s;

    font-weight:500;

}

nav a:hover{

    background:#38bdf8;

    color:#111827;

}

#user-status{

    color:#38bdf8;

    font-weight:600;

}

#logout-btn{

    border:none;

    padding:10px 16px;

    border-radius:8px;

    background:#ef4444;

    color:white;

    cursor:pointer;

    transition:.3s;

}

#logout-btn:hover{

    background:#dc2626;

}

/*=========================================
Cart
=========================================*/

.cart-icon{
    position:relative;
}

.cart-icon a{
    position:relative;
    display:flex;
    align-items:center;
    justify-content:center;
    width:48px;
    height:48px;
    color:#fff;
    font-size:28px;
    text-decoration:none;
}

.cart-count{
    position:absolute;
    top:-6px;
    right:-6px;
    min-width:20px;
    height:20px;
    padding:0 5px;
    border-radius:50%;
    background:#ef4444;
    color:#fff;
    font-size:11px;
    font-weight:700;
    display:flex;
    justify-content:center;
    align-items:center;
    line-height:1;
}



/*=========================================
Hero
=========================================*/

.hero{
    height: 80vh;
    background: linear-gradient(
        rgba(15,23,42,0.8),
        rgba(15,23,42,0.8)
    ),
    url("images/hero.jpg") center/cover no-repeat;
    
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    
    text-align: center;
    padding: 20px;
}

.hero h1{

    font-size:58px;

    margin-bottom:20px;

    font-weight:700;

}

.hero p{

    font-size:22px;

    color:#d1d5db;

    margin-bottom:30px;

}

.hero button{

    padding:15px 35px;

    border:none;

    border-radius:40px;

    background:#38bdf8;

    color:#111827;

    font-size:18px;

    font-weight:600;

    cursor:pointer;

    transition:.3s;

}

.hero button:hover{

    transform:translateY(-4px);

    background:#0ea5e9;

}

/*=========================================
Search
=========================================*/

.search-box{

    margin-top:40px;

    width:100%;

    display:flex;

    justify-content:center;

}

.search-box input{

    width:450px;

    max-width:95%;

    padding:15px 22px;

    border:none;

    outline:none;

    border-radius:40px;

    font-size:16px;

    background:white;

    color:#111827;

    box-shadow:0 5px 15px rgba(0,0,0,.2);

}

.search-box input:focus{

    border:2px solid #38bdf8;

}



.search-box button{
    margin-left:10px;
    padding:15px 20px;
    border:none;
    border-radius:40px;
    background:#38bdf8;
    color:#111827;
    cursor:pointer;
    font-size:16px;
    transition:.3s;
}

.search-box button:hover{
    background:#0ea5e9;
}
/*=========================================
Category Filters
=========================================*/

.filters{

    margin-top:35px;

    display:flex;

    justify-content:center;

    align-items:center;

    flex-wrap:wrap;

    gap:15px;

}

.filters button{

    padding:12px 22px;

    border:none;

    border-radius:30px;

    background:#1e293b;

    color:white;

    cursor:pointer;

    transition:.3s;

    font-size:15px;

}

.filters button:hover{

    background:#38bdf8;

    color:#111827;

}

/*=========================================
Buttons
=========================================*/

button{

    transition:.3s;
cursor: pointer;
}

button:hover{

    transform:translateY(-2px);

}


.buy-btn {
    background: #22c55e;
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 18px;
}

/*=========================================
Links
=========================================*/

a{

    transition:.3s;

}


/* =========================================================
PRODUCTS SECTION
========================================================= */

.products {
width: 90%;
max-width: 1200px;
margin: 50px auto;
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 30px;
}

/* =========================================================
PRODUCT CARD
========================================================= */

.card {
position: relative;
background: #111827;
border: 1px solid #1f2937;
border-radius: 15px;
padding: 20px;
text-align: center;
transition: 0.3s ease;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
overflow: hidden;
}

.card:hover {
transform: translateY(-8px);
border-color: #38bdf8;
box-shadow: 0 15px 35px rgba(56, 189, 248, 0.15);
}

/* =========================================================
PRODUCT IMAGE LINK
========================================================= */

.card > a {
display: block;
text-decoration: none;
}

.card img {
width: 100%;
height: 220px;
object-fit: cover;
border-radius: 10px;
margin-bottom: 15px;
transition: 0.3s ease;
}

.card:hover img {
transform: scale(1.03);
}

/* =========================================================
PRODUCT CATEGORY
========================================================= */

.category {
display: inline-block;
margin: 5px 0 8px;
color: #94a3b8;
font-size: 14px;
}

/* =========================================================
PRODUCT NAME
========================================================= */

.card h3 {
font-size: 21px;
color: #ffffff;
margin-bottom: 8px;
}

/* =========================================================
PRODUCT RATING
========================================================= */

.rating {
margin: 10px 0;
color: #facc15;
font-size: 18px;
letter-spacing: 2px;
}

/* =========================================================
PRODUCT PRICE
========================================================= */

.price {
margin: 12px 0;
}

.price del {
color: #94a3b8;
margin-right: 8px;
font-size: 14px;
}

.price strong {
color: #38bdf8;
font-size: 23px;
font-weight: 700;
}

/* =========================================================
DISCOUNT BADGE
========================================================= */

.discount {
position: absolute;
top: 15px;
left: 15px;
background: #ef4444;
color: #ffffff;
padding: 6px 12px;
border-radius: 25px;
font-size: 13px;
font-weight: 600;
z-index: 10;
}

/* =========================================================
STOCK LABEL
========================================================= */

.stock {
display: inline-block;
margin: 10px 0 15px;
padding: 6px 14px;
background: #22c55e;
color: #ffffff;
border-radius: 20px;
font-size: 13px;
font-weight: 600;
}

.stock.out {
background: #ef4444;
}

.stock.low {
background: #f59e0b;
}

/* =========================================================
ADD TO CART BUTTON
========================================================= */

.add-cart {
width: 100%;
padding: 12px 20px;
border: none;
border-radius: 8px;
background: #38bdf8;
color: #111827;
font-family: 'Poppins', sans-serif;
font-size: 16px;
font-weight: 600;
cursor: pointer;
transition: 0.3s ease;
}

.add-cart:hover {
background: #0ea5e9;
transform: translateY(-2px);
}

.add-cart:active {
transform: scale(0.98);
}

/* =========================================================
PRODUCT ID
========================================================= */

.product-id {
margin: 0 0 10px;
color: #64748b;
font-size: 13px;
}

/* =========================================================
FADE ANIMATION
========================================================= */

.card {
animation: fadeProduct 0.6s ease;
}

@keyframes fadeProduct {


from {
    opacity: 0;
    transform: translateY(30px);
}

to {
    opacity: 1;
    transform: translateY(0);
}


}

/*=========================================
Responsive
=========================================*/

@media(max-width:992px){

.products{

grid-template-columns:repeat(2,1fr);

}

}

@media(max-width:768px){

.products{

grid-template-columns:1fr;

padding:50px 20px;

}

.card img{

height:220px;

}

.section-title{

font-size:32px;

}

}

@media(max-width:480px){

.card h3{

font-size:20px;

}

.price strong{

font-size:22px;

}

.add-cart{

font-size:15px;

}

}

/*=========================================
  SHOPPING CART
=========================================*/

.cart-container{
    width:90%;
    max-width:1200px;
    margin:50px auto;
}

.cart-title{
    text-align:center;
    margin-bottom:40px;
    font-size:38px;
    color:#38bdf8;
}

.cart-item{
    display:flex;
    align-items:center;
    gap:20px;
    background:#1e293b;
    border-radius:15px;
    padding:20px;
    margin-bottom:25px;
}

.cart-item img{
    width:120px;
    height:120px;
    object-fit:cover;
    border-radius:12px;
}

.cart-info{
    flex:1;
}

.cart-info h3{
    margin-bottom:10px;
}

.cart-info p{
    color:#38bdf8;
    font-size:18px;
}

.quantity{
    display:flex;
    align-items:center;
    gap:10px;
    margin-top:12px;
}

.quantity button{
    width:35px;
    height:35px;
    border:none;
    background:#38bdf8;
    color:#111827;
    border-radius:8px;
    cursor:pointer;
    font-weight:bold;
}

.quantity input{
    width:55px;
    text-align:center;
    background:#0f172a;
    color:#fff;
    border:1px solid #334155;
    border-radius:8px;
    padding:6px;
}

.remove-btn{
    background:#ef4444;
    color:#fff;
    border:none;
    padding:10px 18px;
    border-radius:8px;
    cursor:pointer;
}

.remove-btn:hover{
    background:#dc2626;
}

.cart-summary{
    background:#1e293b;
    padding:25px;
    border-radius:15px;
    margin-top:30px;
}

.summary-row{
    display:flex;
    justify-content:space-between;
    margin:15px 0;
}

.total-row{
    border-top:1px solid #334155;
    padding-top:15px;
    font-size:22px;
    font-weight:bold;
}

.checkout-btn,
.continue-btn,
.clear-btn{
    display:inline-block;
    margin-top:20px;
    padding:14px 25px;
    border:none;
    border-radius:10px;
    text-decoration:none;
    cursor:pointer;
    font-weight:600;
}

.checkout-btn{
    background:#38bdf8;
    color:#111827;
}

.continue-btn{
    background:#22c55e;
    color:#fff;
}

.clear-btn{
    background:#ef4444;
    color:#fff;
}

/*=========================================
CHECKOUT
=========================================*/

.checkout-container{
    width:90%;
    max-width:800px;
    margin:60px auto;
    background:#1e293b;
    padding:35px;
    border-radius:18px;
}

.checkout-container h2{
    margin-bottom:25px;
    color:#38bdf8;
}

.checkout-container input,
.checkout-container textarea,
.checkout-container select{
    width:100%;
    padding:14px;
    margin-bottom:18px;
    border:none;
    border-radius:10px;
    background:#0f172a;
    color:#fff;
}

.checkout-container textarea{
    resize:vertical;
    min-height:120px;
}

.checkout-container button{
    width:100%;
    padding:15px;
    border:none;
    border-radius:10px;
    background:#38bdf8;
    color:#111827;
    font-size:17px;
    cursor:pointer;
}

/*=========================================
LOGIN / REGISTER
=========================================*/

.form-container{
    width:90%;
    max-width:450px;
    margin:80px auto;
    background:#1e293b;
    padding:35px;
    border-radius:18px;
}

.form-container h2{
    text-align:center;
    margin-bottom:25px;
    color:#38bdf8;
}

.form-container input{
    width:100%;
    padding:14px;
    margin-bottom:18px;
    border:none;
    border-radius:10px;
    background:#0f172a;
    color:#fff;
}

.form-container button{
    width:100%;
    padding:14px;
    background:#38bdf8;
    color:#111827;
    border:none;
    border-radius:10px;
    font-size:16px;
    font-weight:600;
    cursor:pointer;
}

.form-container p{
    text-align:center;
    margin-top:20px;
}

.form-container a{
    color:#38bdf8;
}

/*=========================================
CONTACT PAGE
=========================================*/

.contact-container{
    width:90%;
    max-width:900px;
    margin:70px auto;
}

.contact-container h2{
    text-align:center;
    margin-bottom:35px;
    color:#38bdf8;
}

.contact-container form{
    background:#1e293b;
    padding:35px;
    border-radius:18px;
}

.contact-container input,
.contact-container textarea{
    width:100%;
    padding:15px;
    margin-bottom:18px;
    border:none;
    border-radius:10px;
    background:#0f172a;
    color:#fff;
}

.contact-container textarea{
    min-height:150px;
}

.contact-container button{
    width:100%;
    padding:15px;
    background:#38bdf8;
    color:#111827;
    border:none;
    border-radius:10px;
    cursor:pointer;
}

/*=========================================
FOOTER
=========================================*/

footer{
    background:#111827;
    text-align:center;
    padding:35px;
    margin-top:60px;
}

.footer-links{
    margin-bottom:18px;
}

.footer-links a{
    color:#fff;
    text-decoration:none;
    margin:0 15px;
}

.footer-links a:hover{
    color:#38bdf8;
}

footer p{
    color:#cbd5e1;
}

/*=========================================
WHATSAPP BUTTON
=========================================*/

.whatsapp-btn{
    position:fixed;
    right:25px;
    bottom:25px;
    width:60px;
    height:60px;
    border-radius:50%;
    background:#25D366;
    display:flex;
    justify-content:center;
    align-items:center;
    color:#fff;
    font-size:30px;
    text-decoration:none;
    box-shadow:0 8px 20px rgba(0,0,0,.3);
    z-index:999;
    transition:.3s;
}

.whatsapp-btn:hover{
    transform:scale(1.1);
}

/*=========================================
LOADER
=========================================*/

.loader{
    width:60px;
    height:60px;
    border:6px solid #334155;
    border-top:6px solid #38bdf8;
    border-radius:50%;
    animation:spin 1s linear infinite;
    margin:100px auto;
}

@keyframes spin{
    100%{
        transform:rotate(360deg);
    }
}

/*=========================================
UTILITY CLASSES
=========================================*/

.text-center{
    text-align:center;
}

.mt-20{
    margin-top:20px;
}

.mt-40{
    margin-top:40px;
}

.mb-20{
    margin-bottom:20px;
}

.mb-40{
    margin-bottom:40px;
}

.hidden{
    display:none;
}

.flex{
    display:flex;
}

.space-between{
    justify-content:space-between;
}

.align-center{
    align-items:center;
}

/*=========================================
MOBILE RESPONSIVE
=========================================*/

@media(max-width:992px){

.cart-item{
    flex-direction:column;
    text-align:center;
}

.quantity{
    justify-content:center;
}

}

@media(max-width:768px){

.cart-container,
.checkout-container,
.contact-container,
.form-container{
    width:95%;
}

.summary-row{
    font-size:15px;
}

.checkout-btn,
.continue-btn,
.clear-btn{
    width:100%;
    margin-bottom:15px;
}

.footer-links{
    display:flex;
    flex-direction:column;
    gap:12px;
}

.whatsapp-btn{
    width:55px;
    height:55px;
    font-size:26px;
}

}

@media(max-width:480px){

.cart-item img{
    width:100px;
    height:100px;
}

.cart-title{
    font-size:30px;
}

.checkout-container,
.form-container,
.contact-container{
    padding:25px;
}

}

/*====================================
PRODUCT DETAILS PAGE
====================================*/


.product-details-container{

width:90%;

max-width:1100px;

margin:60px auto;

}



.product-details{

display:grid;

grid-template-columns:1fr 1fr;

gap:40px;

background:#1e293b;

padding:40px;

border-radius:20px;

}



.product-details img{

width:100%;

border-radius:15px;

}



.product-info h1{

font-size:35px;

margin-bottom:15px;

}



.product-info .category{

color:#94a3b8;

}



.product-info .price strong{

font-size:30px;

}



.product-description{

color:#cbd5e1;

line-height:1.8;

margin:20px 0;

}



.quantity-box{

display:flex;

gap:15px;

align-items:center;

margin:20px 0;

}



.quantity-box input{

width:60px;

padding:10px;

text-align:center;

}



.buy-btn{

background:#22c55e;

color:white;

padding:15px 30px;

border:none;

border-radius:10px;

cursor:pointer;

font-size:18px;

}



@media(max-width:768px){


.product-details{

grid-template-columns:1fr;

}


}

#topBtn{
    position:fixed;
    bottom:100px;
    right:25px;
    width:55px;
    height:55px;
    border:none;
    border-radius:50%;
    background:#38bdf8;
    color:#111827;
    font-size:22px;
    cursor:pointer;
    display:none;
    z-index:999;
    box-shadow:0 5px 15px rgba(0,0,0,.3);
}

#topBtn:hover{
    background:#0ea5e9;
    color:white;
}

/* ==========================================
   EXTRA MOBILE RESPONSIVE IMPROVEMENTS
========================================== */

@media (max-width: 768px){

    header{
        padding:15px;
    }

    nav{
        width:100%;
        display:flex;
        flex-direction:column;
        align-items:center;
        gap:10px;
    }

    nav a,
    #logout-btn{
        width:100%;
        text-align:center;
    }

   .hero {
        padding: 40px 20px;
        text-align: center;
    }

    .hero h1 {
        font-size: 32px;
        line-height: 1.3;
    }

    .hero p {
        font-size: 16px;
    }

    .shop-btn {
        width: 100%;
        max-width: 300px;
        margin: 20px auto;
    }

    .search-box {
        width: 100%;
        max-width: 100%;
        display: flex;
    }

    .search-box input {
        width: 100%;
        min-width: 0;
    }

    .search-box button {
        flex-shrink: 0;
    }

    .filters {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }

    .filters button {
        flex: 1 1 calc(50% - 10px);
        min-width: 120px;
    }


    .products{
        width:95%;
        gap:20px;
    }

    .card{
        padding:15px;
    }

    .card img{
        height:200px;
    }

    .product-details{
        padding:20px;
    }

    .quantity-box{
        flex-direction:column;
        align-items:flex-start;
    }

    .buy-btn,
    .add-cart,
    .checkout-btn,
    .continue-btn,
    .clear-btn{
        width:100%;
    }

    .cart-item{
        padding:15px;
    }

    .cart-info{
        text-align:center;
    }

    .quantity{
        justify-content:center;
    }

    footer{
        padding:25px 15px;
    }

}

@media (max-width:480px){

    body{
        font-size:15px;
    }

    .logo img{
        width:45px;
        height:45px;
    }

    .logo h2{
        font-size:20px;
    }

    .hero h1{
        font-size:24px;
    }

    .hero p{
        font-size:14px;
    }

    .filters button{
        width:100%;
    }

    .card img{
        height:180px;
    }

    .price strong{
        font-size:20px;
    }

    .product-info h1{
        font-size:24px;
    }

    .checkout-container,
    .contact-container,
    .form-container{
        padding:20px;
    }

    #topBtn,
    .whatsapp-btn{
        width:50px;
        height:50px;
    }
}

/* ===========================
   AMAZON STYLE MOBILE HEADER
=========================== */

header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    position:sticky;
    top:0;
    background:#111827;
    padding:15px 20px;
    z-index:999;
}

.menu-toggle{
    display:none;
    background:none;
    border:none;
    color:white;
    font-size:28px;
    cursor:pointer;
}

.cart-icon{
    position:relative;
}

.cart-icon a{
    color:white;
    font-size:28px;
    text-decoration:none;
}

.cart-count{
    position:absolute;
    top:-8px;
    right:-10px;
    min-width:20px;
    height:20px;
    background:#ef4444;
    color:#fff;
    border-radius:50%;
    display:flex;
    justify-content:center;
    align-items:center;
    font-size:11px;
    font-weight:bold;
}

/* Mobile */

@media(max-width:768px){

    .menu-toggle{
        display:block;
    }

    .logo{
        flex:1;
        justify-content:center;
    }

    .logo h2{
        font-size:22px;
    }

    .logo img{
        width:40px;
        height:40px;
    }

    nav{
        position:fixed;
        top:70px;
        left:-100%;
        width:260px;
        height:100vh;
        background:#111827;
        display:flex;
        flex-direction:column;
        align-items:flex-start;
        padding:20px;
        transition:.35s ease;
        gap:5px;
        z-index:998;
    }

    nav.active{
        left:0;
    }

    nav a,
    #logout-btn{
        width:100%;
        padding:15px;
        text-align:left;
    }

    .cart-icon a{
        font-size:26px;
    }
}



 


