@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

:root {
    --primary-pink: #FFD2D7;       /* Soft pastel pink */
    --primary-pink-hover: #FFAEB8;
    --primary-pink-light: #FFF0F2;
    --secondary-sage: #D0E1D4;     /* Soft pastel sage green */
    --secondary-sage-hover: #B7D2BD;
    --secondary-sage-light: #F0F5F1;
    --pastel-lavender: #E4DCED;    /* Soft pastel lavender */
    --pastel-lavender-hover: #D4C6E2;
    --pastel-blue: #CDE2F6;        /* Soft pastel sky blue */
    --pastel-blue-hover: #B4D4F0;
    --bg-cream: #FCFBF7;           /* Warm soft white */
    --bg-white: #FFFFFF;
    --text-dark: #4A4A4A;          /* Charcoal text instead of pure black */
    --text-muted: #8E8E8E;
    --border-color: rgba(0, 0, 0, 0.05);
    
    /* Glassmorphism Effect */
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: 0 8px 32px 0 rgba(223, 206, 210, 0.25);
    
    /* Transitions & Border Radii */
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-cream);
    color: var(--text-dark);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, .brand-font {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Common Layout Components */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

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

.nav-left {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-greeting {
    margin-left: 15px;
    color: var(--text-muted);
    font-size: 14px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
}

.logo-img {
    height: 36px;
    width: auto;
    object-fit: contain;
}

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

.nav-links a {
    font-weight: 500;
    color: var(--text-dark);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
}

.nav-links a:hover, .nav-links a.active {
    background-color: var(--primary-pink-light);
    color: #E29C95;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cart-icon-wrapper {
    position: relative;
    cursor: pointer;
    font-size: 20px;
    padding: 5px;
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #E29C95;
    color: var(--bg-white);
    font-size: 11px;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 22px;
    border-radius: var(--radius-md);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Outfit', sans-serif;
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary-pink);
    color: var(--text-dark);
}

.btn-primary:hover {
    background-color: var(--primary-pink-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 210, 215, 0.5);
}

.btn-secondary {
    background-color: var(--secondary-sage);
    color: var(--text-dark);
}

.btn-secondary:hover {
    background-color: var(--secondary-sage-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(208, 225, 212, 0.5);
}

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

.btn-outline:hover {
    background-color: var(--primary-pink-light);
    border-color: var(--primary-pink);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 13px;
    border-radius: var(--radius-sm);
}

/* Grid & Layout Containers */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 30px;
}

/* Hero Section */
.hero-section {
    padding: 80px 0 60px 0;
    text-align: center;
    background: radial-gradient(circle at 50% 50%, #FFF0F2 0%, var(--bg-cream) 70%);
}

.hero-title {
    font-size: 48px;
    line-height: 1.2;
    margin-bottom: 20px;
    color: var(--text-dark);
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 30px auto;
}

/* Category Filter Bar */
.filter-bar {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 20px;
    border-radius: var(--radius-md);
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
    color: var(--text-dark);
}

.filter-btn:hover, .filter-btn.active {
    background-color: var(--primary-pink);
    border-color: var(--primary-pink);
    color: var(--text-dark);
    box-shadow: 0 4px 10px rgba(255, 210, 215, 0.3);
}

/* Product Cards Vertical Alternating List */
.products-grid {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-bottom: 50px;
}

.product-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: row;
    min-height: 280px;
    box-shadow: 0 4px 15px rgba(223, 206, 210, 0.1);
    cursor: pointer;
}

.product-card:nth-child(even) {
    flex-direction: row-reverse;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(223, 206, 210, 0.35);
}

.product-img-wrapper {
    position: relative;
    width: 40%;
    min-width: 280px;
    overflow: hidden;
    background-color: var(--primary-pink-light);
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.product-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--glass-bg);
    backdrop-filter: blur(5px);
    border: 1px solid var(--glass-border);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    z-index: 2;
}

.product-info {
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 60%;
    flex-grow: 1;
}

.product-name {
    font-size: 24px;
    margin-bottom: 12px;
    font-weight: 700;
    color: var(--text-dark);
}

.product-desc {
    font-size: 15px;
    color: var(--text-muted);
    margin-bottom: 25px;
    line-height: 1.6;
}

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

.product-price {
    font-size: 22px;
    font-weight: 700;
    color: #E29C95;
}

/* Mobile Responsiveness for Product Cards */
@media (max-width: 768px) {
    .product-card, .product-card:nth-child(even) {
        flex-direction: column;
        min-height: auto;
    }
    .product-img-wrapper {
        width: 100%;
        height: 250px;
        min-width: 100%;
    }
    .product-info {
        width: 100%;
        padding: 25px;
    }
    .product-name {
        font-size: 20px;
    }
}

/* Modals (Customization Modal) */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    background-color: rgba(74, 74, 74, 0.4);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--bg-white);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 50px rgba(0,0,0,0.1);
    overflow-y: auto;
    position: relative;
    border: 1px solid var(--border-color);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    background: none;
    border: none;
    color: var(--text-muted);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-dark);
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 40px;
}

@media (max-width: 768px) {
    .modal-body {
        grid-template-columns: 1fr;
        padding: 30px 20px;
    }
    .modal-content {
        width: 95%;
    }
}

.modal-img-wrapper {
    background-color: var(--primary-pink-light);
    border-radius: var(--radius-md);
    overflow: hidden;
    height: 300px;
}

.modal-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Customize Options inside Modal */
.option-group {
    margin-bottom: 20px;
}

.option-label {
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    font-size: 15px;
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background-color: var(--bg-cream);
    font-family: 'Outfit', sans-serif;
    color: var(--text-dark);
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-pink);
    background-color: var(--bg-white);
    box-shadow: 0 0 0 3px rgba(255, 210, 215, 0.2);
}

/* Ribbon Color options */
.ribbon-selector {
    display: flex;
    gap: 10px;
}

.ribbon-option {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
}

.ribbon-option.active {
    border-color: var(--text-dark);
    transform: scale(1.1);
}

/* Addon Selection Grid in Modal */
.addons-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    max-height: 200px;
    overflow-y: auto;
    padding-right: 5px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px;
    background-color: var(--bg-cream);
}

.addon-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: var(--bg-white);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.addon-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.addon-icon {
    font-size: 20px;
}

.addon-name {
    font-weight: 500;
    font-size: 14px;
}

.addon-price {
    font-size: 13px;
    color: var(--text-muted);
}

.addon-checkbox {
    cursor: pointer;
    accent-color: #E29C95;
    width: 18px;
    height: 18px;
}

/* Cart Drawer (Glassmorphism trượt) */
.cart-drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    height: 100%;
    z-index: 1100;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-left: 1px solid var(--glass-border);
    box-shadow: -10px 0 30px rgba(0,0,0,0.05);
    transition: right 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
}

@media (max-width: 480px) {
    .cart-drawer {
        width: 100%;
        right: -100%;
    }
}

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

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

.cart-drawer-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 30px;
}

.cart-drawer-footer {
    padding: 30px;
    border-top: 1px solid var(--border-color);
    background-color: rgba(255, 255, 255, 0.5);
}

.cart-item-card {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.cart-item-img {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    background-color: var(--primary-pink-light);
}

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

.cart-item-name {
    font-weight: 700;
    font-size: 15px;
}

.cart-item-customizations {
    font-size: 12px;
    color: var(--text-muted);
    margin: 4px 0;
}

.cart-item-price {
    font-weight: 600;
    color: #E29C95;
    font-size: 14px;
}

.cart-item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.qty-control {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background-color: var(--bg-cream);
}

.qty-btn {
    width: 26px;
    height: 26px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
}

.qty-val {
    width: 26px;
    text-align: center;
    font-size: 13px;
    font-weight: 500;
}

.cart-item-remove {
    background: none;
    border: none;
    cursor: pointer;
    color: #E29C95;
    font-size: 13px;
    font-weight: 500;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
}

/* Authentication Page Styles (Login & Register) */
.auth-wrapper {
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background: radial-gradient(circle at top right, var(--primary-pink-light) 0%, var(--bg-cream) 100%);
}

.auth-card {
    background-color: var(--bg-white);
    width: 100%;
    max-width: 450px;
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 40px rgba(223, 206, 210, 0.3);
    border: 1px solid var(--border-color);
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header h2 {
    font-size: 28px;
    margin-bottom: 8px;
}

.auth-header p {
    color: var(--text-muted);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
    font-size: 14px;
}

.auth-footer-text {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-muted);
}

.auth-footer-text a {
    color: #E29C95;
    font-weight: 600;
}

/* Custom Table style for Staff & Admin panels */
.custom-table-wrapper {
    background-color: var(--bg-white);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: var(--glass-shadow);
    margin-bottom: 30px;
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.custom-table th {
    background-color: var(--primary-pink-light);
    color: var(--text-dark);
    padding: 15px 20px;
    font-weight: 600;
    border-bottom: 1px solid var(--border-color);
}

.custom-table td {
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.custom-table tr:last-child td {
    border-bottom: none;
}

.custom-table tbody tr:hover {
    background-color: var(--bg-cream);
}

/* Order Status Badges */
.status-badge {
    display: inline-flex;
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.status-pending {
    background-color: var(--pastel-lavender);
    color: #5D3F75;
}

.status-preparing {
    background-color: var(--pastel-blue);
    color: #2F5270;
}

.status-shipping {
    background-color: #FDF4E3; /* soft yellow */
    color: #8C6A1E;
}

.status-completed {
    background-color: var(--secondary-sage);
    color: #3E5A44;
}

.status-cancelled {
    background-color: #F8D7DA;
    color: #721C24;
}

/* Admin KPI Dashboard Cards */
.admin-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.kpi-card {
    background-color: var(--bg-white);
    border-radius: var(--radius-md);
    padding: 24px;
    border: 1px solid var(--border-color);
    box-shadow: var(--glass-shadow);
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.kpi-card:nth-child(1) { background-color: var(--primary-pink-light); }
.kpi-card:nth-child(2) { background-color: var(--secondary-sage-light); }
.kpi-card:nth-child(3) { background-color: var(--pastel-blue); }
.kpi-card:nth-child(4) { background-color: var(--pastel-lavender); }

.kpi-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.kpi-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
}

/* Admin Dashboard Subsections */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

@media (max-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

.dashboard-panel {
    background-color: var(--bg-white);
    border-radius: var(--radius-md);
    padding: 30px;
    border: 1px solid var(--border-color);
    box-shadow: var(--glass-shadow);
}

.panel-title {
    font-size: 20px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary-pink-light);
    padding-bottom: 8px;
}

/* Form Styles for Product CRUD modal */
.dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: none;
    background-color: rgba(0, 0, 0, 0.4);
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.dialog-box {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    width: 90%;
    max-width: 500px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid var(--border-color);
}

/* Alert Notification Popup */
.alert-popup {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    color: var(--text-dark);
    font-weight: 600;
    z-index: 2000;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.alert-popup.show {
    transform: translateY(0);
    opacity: 1;
}

.alert-success {
    background-color: var(--secondary-sage);
    border: 1px solid var(--secondary-sage-hover);
}

.alert-error {
    background-color: #F8D7DA;
    border: 1px solid #F5C6CB;
    color: #721C24;
}

/* Profile Order tracking timeline */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 10px;
}

.timeline-step {
    display: flex;
    gap: 15px;
}

.timeline-marker {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--border-color);
}

.timeline-dot.active {
    background-color: #E29C95;
    box-shadow: 0 0 0 4px rgba(226, 156, 149, 0.2);
}

.timeline-line {
    width: 2px;
    flex-grow: 1;
    background-color: var(--border-color);
}

.timeline-step:last-child .timeline-line {
    display: none;
}

.timeline-content {
    font-size: 13px;
    padding-bottom: 15px;
}

.timeline-time {
    color: var(--text-muted);
    font-size: 11px;
}

/* Music request label decoration */
.music-badge {
    background-color: var(--pastel-blue);
    color: #364B5D;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    margin-top: 4px;
}
