:root {
    --primary: #ec4899; /* pink */
    --primary-dark: #db2777;
    --secondary: #f97316; /* accent */
    --bg: #fff7fb; /* very light pink */
    --card-bg: #fffaf5; /* skin/peach */
    --text: #2d1b1b;
    --muted: #6b7280;
    --border: #f9cbe7;
    --danger: #dc2626;
    --success: #16a34a;
    --radius: 10px;
    --shadow: 0 10px 25px rgba(244, 114, 182, 0.25);
    --transition: 0.2s ease;
    --max-width: 1100px;
}

*,
:before,
:after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 1.5rem 1rem 3rem;
}

/* Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 50;
    background: #fff0f6ee;
    backdrop-filter: blur(18px);
    border-bottom: 1px solid #f9cbe7;
}

.nav-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.logo {
    font-weight: 800;
    font-size: 1.3rem;
    background: linear-gradient(120deg, #db2777, #fb7185);
    -webkit-background-clip: text;
    color: transparent;
}

.nav-center,
.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

    .nav-center a,
    .nav-right a {
        font-size: 0.95rem;
        color: var(--muted);
        padding: 0.25rem 0.6rem;
        border-radius: 999px;
        transition: color var(--transition), background var(--transition);
    }

        .nav-center a:hover,
        .nav-right a:hover {
            color: var(--primary);
            background: rgba(236, 72, 153, 0.13);
        }

        .nav-center a.active {
            color: #fff;
            background: linear-gradient(120deg, #ec4899, #f97316);
        }

.nav-user {
    font-size: 0.9rem;
    color: var(--muted);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 1.15rem;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: background var(--transition), transform var(--transition), box-shadow var(--transition), color var(--transition), border-color var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, #ec4899, #f97316);
    color: #fff;
    box-shadow: 0 10px 25px rgba(244, 114, 182, 0.6);
}

    .btn-primary:hover {
        transform: translateY(-1px);
        box-shadow: 0 16px 30px rgba(244, 114, 182, 0.8);
    }

.btn-outline {
    background: transparent;
    border: 1px solid #fecaca;
    color: var(--primary-dark);
}

    .btn-outline:hover {
        border-color: var(--primary-dark);
        background: #fff1f5;
    }

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-sm {
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
}

/* Hero with slider */
.hero {
    background: radial-gradient(circle at top left, #ffe4e6, transparent 65%), radial-gradient(circle at top right, #fef3c7, transparent 60%), #fff7fb;
    border-bottom: 1px solid #f9cbe7;
}

.hero-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 3rem 1rem 2.5rem;
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.3fr);
    gap: 2.5rem;
    align-items: center;
}

.hero-title {
    font-size: clamp(2rem, 3vw, 2.6rem);
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.hero-subtitle {
    color: var(--muted);
    max-width: 480px;
    margin-bottom: 1.25rem;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.4rem;
}

.hero-badge {
    font-size: 0.78rem;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(244, 114, 182, 0.3);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    font-size: 0.85rem;
    color: var(--muted);
}

.hero-visual {
    position: relative;
    height: 280px;
}

.hero-slider {
    position: relative;
    height: 100%;
    border-radius: 26px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.6s ease;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    padding: 1.4rem;
    color: #fff;
}

    .hero-slide::before {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(to top, rgba(24, 24, 27, 0.65), transparent 50%);
    }

.hero-slide-content {
    position: relative;
    z-index: 1;
}

.hero-slide h3 {
    margin: 0 0 0.3rem;
    font-size: 1.3rem;
}

.hero-slide p {
    margin: 0;
    font-size: 0.9rem;
}

.hero-slide.active {
    opacity: 1;
}

.hero-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.85);
    color: #e11d48;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.25);
}

.hero-prev {
    left: 10px;
}

.hero-next {
    right: 10px;
}

.hero-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.35rem;
    z-index: 2;
}

.hero-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    border: none;
    background: rgba(255, 255, 255, 0.7);
    cursor: pointer;
}

    .hero-dot.active {
        width: 18px;
        background: #fb7185;
    }

/* Sections */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

    .section-header h2 {
        margin: 0;
        font-size: 1.3rem;
    }

.card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.25rem;
}

.card-simple {
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    background: #fff5f7;
}

/* Category Grid */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.category-card {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    padding: 1rem 1rem 1.1rem;
    background: linear-gradient(135deg, #ffe4e6, #fef3c7);
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
    min-height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

    .category-card h3 {
        margin: 0;
        font-size: 1rem;
    }

    .category-card p {
        margin: 0.25rem 0 0;
        font-size: 0.8rem;
        color: var(--muted);
    }

    .category-card img {
        position: absolute;
        right: -8px;
        bottom: -12px;
        width: 110px;
        transform: rotate(-4deg);
        opacity: 0.9;
    }

    .category-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 12px 24px rgba(251, 113, 133, 0.45);
    }

/* Product cards */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-top: 0.75rem;
}

.product-card {
    border-radius: 16px;
    background: #fffdfb;
    box-shadow: 0 6px 16px rgba(251, 113, 133, 0.18);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition), box-shadow var(--transition);
}

    .product-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 14px 30px rgba(236, 72, 153, 0.35);
    }

.product-image {
    position: relative;
    padding: 0.75rem;
    background: #fff1f2;
}

    .product-image img {
        border-radius: 14px;
        width: 100%;
        height: 170px;
        object-fit: cover;
    }

.fav-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.93);
    color: #f9739b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.2);
    font-size: 1rem;
    transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

    .fav-btn:hover {
        transform: scale(1.05);
    }

    .fav-btn.active {
        background: #fecaca;
        color: #b91c1c;
    }

.product-body {
    padding: 0.75rem 0.9rem 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    flex: 1;
}

.product-title {
    font-size: 0.95rem;
    font-weight: 600;
}

.product-category {
    font-size: 0.78rem;
    color: var(--muted);
}

.product-bottom-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.35rem;
}

.price {
    font-weight: 700;
    color: var(--primary-dark);
}

.stock {
    font-size: 0.78rem;
    color: var(--muted);
}

.product-actions {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.45rem;
}

/* Filters */
.filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

select,
input[type="number"],
input[type="text"],
input[type="email"],
input[type="password"],
textarea {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border-radius: 999px;
    border: 1px solid #fecdd3;
    font-size: 0.95rem;
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
    background: #fff1f5;
}

textarea {
    border-radius: 10px;
    resize: vertical;
    min-height: 80px;
}

    select:focus,
    input:focus,
    textarea:focus {
        border-color: var(--primary);
        background: #fff;
        box-shadow: 0 0 0 1px rgba(236, 72, 153, 0.35);
    }

/* Forms */
.form-card {
    max-width: 480px;
    margin: 1rem auto;
}

.form-group {
    margin-bottom: 0.75rem;
}

    .form-group label {
        display: block;
        font-size: 0.85rem;
        margin-bottom: 0.2rem;
    }

.form-row {
    display: flex;
    gap: 0.75rem;
}

    .form-row > .form-group {
        flex: 1;
    }

.hint {
    font-size: 0.75rem;
    color: var(--muted);
}

.error {
    font-size: 0.8rem;
    color: var(--danger);
    margin-top: 0.15rem;
}

/* Auth tabs */
.auth-wrapper {
    max-width: 480px;
    margin: 1.5rem auto;
}

.tabs {
    display: flex;
    background: #ffe4e6;
    border-radius: 999px;
    padding: 0.15rem;
    margin-bottom: 0.5rem;
}

    .tabs button {
        flex: 1;
        border-radius: 999px;
        border: none;
        padding: 0.45rem 0.9rem;
        font-size: 0.9rem;
        background: transparent;
        cursor: pointer;
        transition: background var(--transition), color var(--transition), box-shadow var(--transition), transform var(--transition);
    }

        .tabs button.active {
            background: #fff;
            color: var(--primary);
            box-shadow: 0 6px 12px rgba(236, 72, 153, 0.25);
            transform: translateY(-1px);
        }

.tab-content {
    display: none;
}

    .tab-content.active {
        display: block;
    }

/* Table */
.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

    .table th,
    .table td {
        border-bottom: 1px solid #fde2e4;
        padding: 0.45rem 0.4rem;
        text-align: left;
    }

    .table th {
        font-size: 0.8rem;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        color: var(--muted);
    }

    .table tr:last-child td {
        border-bottom: none;
    }

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.05rem 0.45rem;
    border-radius: 999px;
    background: #ffe4e6;
    color: #db2777;
    font-size: 0.7rem;
}

/* Layouts */
.cart-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.1fr);
    gap: 1rem;
    align-items: flex-start;
}

.cart-summary {
    max-width: 360px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 2fr);
    gap: 1.25rem;
}

.admin-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.6fr);
    gap: 1rem;
}

.chip {
    display: inline-flex;
    align-items: center;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.75rem;
    background: #ecfdf5;
    color: #166534;
}

/* Footer */
footer {
    background: #fff1f5;
    border-top: 1px solid #f9cbe7;
    padding: 1.5rem 1rem 1.5rem;
    margin-top: 2rem;
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: space-between;
    align-items: flex-start;
}

.footer-col h4 {
    margin: 0 0 0.5rem;
    font-size: 1rem;
}

.footer-col p,
.footer-col a {
    font-size: 0.85rem;
    color: var(--muted);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

    .footer-links a:hover {
        color: var(--primary-dark);
    }

.footer-bottom {
    max-width: var(--max-width);
    margin: 1rem auto 0;
    border-top: 1px solid #fde2e4;
    padding-top: 0.75rem;
    font-size: 0.8rem;
    color: var(--muted);
    text-align: center;
}

/* Utilities */
.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-muted {
    color: var(--muted);
}

.text-danger {
    color: var(--danger);
}

.text-success {
    color: var(--success);
}

small {
    font-size: 0.8rem;
}

.view {
    display: none;
}

@media (max-width: 900px) {
    .hero-inner {
        grid-template-columns: minmax(0, 1fr);
        padding-bottom: 2rem;
    }

    .hero-visual {
        order: -1;
    }

    .cart-layout,
    .dashboard-grid,
    .admin-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .footer-inner {
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .nav-center {
        display: none;
    }
}
