:root {
    --bg-color: #ffffff;
    --text-color: #111111;
    --text-light: #666666;
    --accent-color: #FF4500;
    --accent-hover: #E03E00;
    --border-color: #EEEEEE;
    --card-bg: #F9F9F9;
    --white: #ffffff;
    --black: #000000;
    --danger: #FF3B30;
    --success: #34C759;

    --esewa: #60BB46;
    --khalti: #5C2D91;

    --font-main: 'Outfit', sans-serif;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Utilities */
.text-accent {
    color: var(--accent-color);
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-4 {
    margin-top: 1rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-family: var(--font-main);
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-align: center;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--accent-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 69, 0, 0.3);
}

.btn-secondary {
    background-color: var(--black);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: #333;
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-color);
}

.btn-outline:hover {
    border-color: var(--text-color);
}

.btn-full {
    width: 100%;
}

.icon-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-color);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.icon-btn span {
    font-size: 1rem;
    font-weight: 500;
}

.icon-btn:hover {
    color: var(--accent-color);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--black);
    letter-spacing: -1px;
}

.logo-dot {
    color: var(--accent-color);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
}

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.cart-btn {
    position: relative;
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -10px;
    background: var(--accent-color);
    color: var(--white);
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-only {
    display: none;
}

.mobile-menu {
    display: none;
    flex-direction: column;
    background: var(--white);
    border-top: 1px solid var(--border-color);
    padding: 1rem 2rem;
}

.mobile-menu.active {
    display: flex;
}

.mobile-link {
    padding: 0.75rem 0;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    border-bottom: 1px solid var(--border-color);
}

/* Hero */
.hero {
    margin-top: 80px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 4rem 2rem;
    display: flex;
    align-items: center;
    gap: 4rem;
    min-height: 80vh;
}

.hero-content {
    flex: 1;
}

.hero-title {
    font-size: 4.5rem;
    line-height: 1.1;
    font-weight: 900;
    margin-bottom: 1.5rem;
    letter-spacing: -2px;
}

.hero-title .accent {
    color: var(--accent-color);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2.5rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image-wrapper {
    flex: 1;
    position: relative;
}

.hero-image {
    width: 100%;
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    object-fit: cover;
}

.hero-badge {
    position: absolute;
    bottom: 30px;
    left: -30px;
    background: var(--white);
    padding: 1rem 1.5rem;
    border-radius: 12px;
    font-weight: 700;
    box-shadow: var(--shadow-md);
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* Sections */
.products-section,
.reviews-section {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--text-light);
    font-size: 1.1rem;
}

/* Filters */
.category-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.filter-btn {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1.25rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 500;
    font-family: var(--font-main);
    transition: var(--transition);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--black);
    color: var(--white);
    border-color: var(--black);
}

/* Product Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.product-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    cursor: pointer;
}

.product-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

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

.product-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    cursor: pointer;
}

.product-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--accent-color);
}

/* Reviews */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.review-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.review-card .stars {
    color: #FFC107;
    margin-bottom: 1rem;
}

.review-card p {
    font-style: italic;
    margin-bottom: 1rem;
    color: var(--text-light);
}

.review-card h4 {
    font-weight: 700;
}

/* Footer */
.footer {
    background: var(--black);
    color: var(--white);
    padding: 4rem 2rem 2rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand p {
    color: #999;
    margin: 1rem 0;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    color: var(--white);
    font-size: 1.5rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--accent-color);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links h3,
.footer-newsletter h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.footer-links a {
    color: #999;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent-color);
}

.footer-newsletter p {
    color: #999;
    margin-bottom: 1rem;
}

.newsletter-form {
    display: flex;
    gap: 0.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem;
    border-radius: 8px;
    border: none;
    outline: none;
    font-family: var(--font-main);
}

.newsletter-form button {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 0 1.5rem;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
}

.footer-bottom {
    text-align: center;
    color: #666;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

/* Modals Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Cart Drawer */
.cart-drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 100%;
    max-width: 400px;
    height: 100%;
    background: var(--white);
    z-index: 2001;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.1);
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.cart-drawer.active {
    right: 0;
}

.cart-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-promo-banner {
    background: #FFF4E5;
    color: #D97706;
    padding: 0.75rem;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 600;
    border-bottom: 1px solid #FDE68A;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-color);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.cart-item {
    display: flex;
    gap: 1rem;
}

.cart-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.cart-item-meta {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.cart-item-price {
    font-weight: 700;
    color: var(--accent-color);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.5rem;
}

.qty-controls {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
}

.qty-btn {
    background: var(--card-bg);
    border: none;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
}

.qty-val {
    padding: 0 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
}

.remove-btn {
    color: var(--danger);
    background: none;
    border: none;
    font-size: 0.85rem;
    cursor: pointer;
}

.cart-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--card-bg);
}

.coupon-box {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.coupon-box input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-main);
}

.coupon-box button {
    background: var(--black);
    color: var(--white);
    border: none;
    padding: 0 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}

.coupon-message {
    font-size: 0.85rem;
    color: var(--success);
    margin-bottom: 1rem;
    min-height: 20px;
}

.cart-summary {
    margin-bottom: 1.5rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.summary-row.total {
    font-size: 1.25rem;
    font-weight: 800;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
    margin-top: 0.5rem;
}

.empty-cart {
    text-align: center;
    color: var(--text-light);
    margin-top: 2rem;
}

/* Modals General */
.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: var(--white);
    z-index: 2001;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.modal-lg {
    max-width: 900px;
}

.modal-sm {
    max-width: 400px;
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: var(--card-bg);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.25rem;
    z-index: 10;
    transition: var(--transition);
}

.modal-close:hover {
    background: #E5E5E5;
}

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 1.5rem;
    font-weight: 800;
}

/* Product Detail Modal */
.product-detail-content {
    display: flex;
    flex-wrap: wrap;
}

.pd-image {
    flex: 1;
    min-width: 300px;
    height: 100%;
}

.pd-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pd-info {
    flex: 1;
    min-width: 300px;
    padding: 2rem;
}

.pd-category {
    font-size: 0.9rem;
    color: var(--text-light);
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.pd-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.pd-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 2rem;
}

.pd-section {
    margin-bottom: 1.5rem;
}

.pd-section h4 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
}

.size-selector,
.color-selector {
    display: flex;
    gap: 0.5rem;
}

.size-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    background: var(--white);
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.size-btn.active,
.size-btn:hover {
    background: var(--black);
    color: var(--white);
    border-color: var(--black);
}

.color-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    box-shadow: 0 0 0 1px var(--border-color);
}

.color-btn.active {
    box-shadow: 0 0 0 2px var(--black);
}

.color-black {
    background: #111;
}

.color-white {
    background: #fff;
}

.color-red {
    background: #FF3B30;
}

.color-blue {
    background: #007AFF;
}

/* Designer Modal */
.designer-layout {
    display: flex;
    flex-wrap: wrap;
}

.designer-preview {
    flex: 1;
    min-width: 300px;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.mockup-container {
    position: relative;
    width: 300px;
    height: 400px;
}

.mockup-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

#tshirt-canvas {
    position: absolute;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    border: 1px dashed rgba(0, 0, 0, 0.2);
}

.designer-controls {
    flex: 1;
    min-width: 300px;
    padding: 2rem;
}

.control-group {
    margin-bottom: 1.5rem;
}

.control-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.file-input,
.text-input-row input,
#designer-color {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-main);
}

.text-input-row {
    display: flex;
    gap: 0.5rem;
}

.text-input-row input {
    flex: 1;
}

#designer-color {
    height: 50px;
    cursor: pointer;
    padding: 0.25rem;
}

.designer-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.designer-actions button {
    flex: 1;
}

/* Auth Modal */
.auth-container {
    padding: 2rem;
}

.auth-tabs {
    display: flex;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.auth-tab {
    flex: 1;
    padding: 1rem;
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    border-bottom: 2px solid transparent;
}

.auth-tab.active {
    color: var(--accent-color);
    border-bottom-color: var(--accent-color);
}

.auth-form {
    display: none;
    flex-direction: column;
    gap: 1rem;
}

.auth-form.active {
    display: flex;
}

.auth-form input {
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-main);
    font-size: 1rem;
}

/* Checkout Modal */
.checkout-layout {
    display: flex;
    flex-wrap: wrap;
}

.checkout-form-section {
    flex: 1.5;
    min-width: 300px;
    padding: 2rem;
    border-right: 1px solid var(--border-color);
}

.checkout-summary-section {
    flex: 1;
    min-width: 250px;
    padding: 2rem;
    background: var(--card-bg);
}

.checkout-form-section h4,
.checkout-summary-section h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

#checkout-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-color);
}

#checkout-form input[type="text"],
#checkout-form input[type="tel"],
#checkout-form input[type="email"] {
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-main);
}

.payment-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.payment-option input {
    display: none;
}

.pay-btn {
    display: block;
    padding: 1rem;
    text-align: center;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.payment-option input:checked+.pay-btn {
    border-color: var(--accent-color);
    background: #FFF4E5;
    color: var(--accent-color);
}

.pay-btn.eSewa {
    color: var(--esewa);
}

.payment-option input:checked+.pay-btn.eSewa {
    border-color: var(--esewa);
    background: #EFFFF0;
}

.pay-btn.khalti {
    color: var(--khalti);
}

.payment-option input:checked+.pay-btn.khalti {
    border-color: var(--khalti);
    background: #F4E8FF;
}

.payment-info-box {
    padding: 1rem;
    background: #f0f0f0;
    border-radius: 8px;
    font-size: 0.9rem;
}

.checkout-items-list {
    max-height: 250px;
    overflow-y: auto;
    margin-bottom: 1.5rem;
}

.chk-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.chk-item-name {
    font-weight: 600;
}

.chk-item-meta {
    color: var(--text-light);
    font-size: 0.8rem;
}

.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--black);
    color: var(--white);
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    z-index: 3000;
    opacity: 0;
    transition: var(--transition);
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Responsive */
@media (max-width: 992px) {
    .hero {
        flex-direction: column;
        text-align: center;
        margin-top: 60px;
        padding: 2rem;
    }

    .hero-title {
        font-size: 3.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }
}

@media (max-width: 768px) {

    .nav-links,
    .nav-login-btn {
        display: none;
    }

    .mobile-only {
        display: block;
    }

    #nav-login-btn {
        display: none;
    }

    .hero-title {
        font-size: 2.8rem;
    }

    .checkout-layout {
        flex-direction: column;
    }

    .checkout-form-section {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .form-row {
        flex-direction: column;
        gap: 1rem;
    }

    .pd-image {
        height: 300px;
    }

    .designer-layout {
        flex-direction: column;
    }
}

/* Dashboard specific mobile styles for admin-dashboard and user-dashboard */
@media (max-width: 992px) {
    .dashboard-container {
        flex-direction: column;
        display: flex;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
        padding: 1rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .top-header, .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}