@import url('https://fonts.googleapis.com/css2?family=Mali:wght@400;500;600;700&family=Nunito:wght@500;600;700;800;900&display=swap');

:root {
    /* Hello Kitty-inspired Pink Boutique Theme */
    --primary-pink: #ff5fa2;
    --primary-pink-light: #ff8fc3;
    --primary-pink-dark: #e6458e;
    --secondary-pink: #ffc1dd;
    --light-pink: #fff4fa;
    --lighter-pink: #ffe9f4;
    --accent-orange: #ff9fbd;
    --accent-coral: #ff7eb6;
    --primary-color: var(--primary-pink);
    --primary-peach: var(--primary-pink);
    --secondary-coral: #ffa6cc;
    --light-peach: #ffd5e8;
    --lighter-peach: #fff0f7;
    
    /* Neutrals */
    --white: #ffffff;
    --gray-50: #fafafa;
    --gray-100: #f5f5f5;
    --gray-200: #eeeeee;
    --gray-300: #e0e0e0;
    --gray-400: #bdbdbd;
    --gray-500: #9e9e9e;
    --gray-600: #757575;
    --gray-700: #616161;
    --gray-800: #424242;
    --gray-900: #212121;
    
    /* Text Colors */
    --text-primary: #402437;
    --text-secondary: #815b73;
    --text-disabled: #bdbdbd;
    
    /* Borders & Shadows */
    --border-color: #f0d4e3;
    --shadow-sm: 0 10px 24px rgba(180, 95, 140, 0.08);
    --shadow: 0 18px 40px rgba(180, 95, 140, 0.12);
    --shadow-md: 0 20px 44px rgba(180, 95, 140, 0.14);
    --shadow-lg: 0 28px 60px rgba(180, 95, 140, 0.18);
    --shadow-hover: 0 18px 36px rgba(255, 95, 162, 0.2);
    
    /* Status Colors */
    --success: #44b885;
    --warning: #f2a95d;
    --error: #ef5d8f;
    --info: #7b8cff;
    --gradient-primary: linear-gradient(135deg, #ff73b3 0%, #ff9ccc 48%, #ffd5e8 100%);
    --gradient-secondary: linear-gradient(135deg, #fff0f7 0%, #fff8fb 56%, #ffffff 100%);
    --gradient-accent: linear-gradient(45deg, #ffc4df 0%, #ffd7ea 55%, #fff0f7 100%);
    --gradient-warm: linear-gradient(180deg, #fff5fa 0%, #ffffff 100%);
    --border-radius: 20px;
    --border-radius-sm: 12px;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: auto;
}

body {
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    margin: 0;
    padding: 0;
    background:
        radial-gradient(circle at 15% 18%, rgba(255, 181, 214, 0.35) 0, rgba(255, 181, 214, 0.35) 7%, transparent 7.5%),
        radial-gradient(circle at 85% 22%, rgba(255, 213, 232, 0.42) 0, rgba(255, 213, 232, 0.42) 8%, transparent 8.5%),
        radial-gradient(circle at 22% 82%, rgba(255, 227, 239, 0.55) 0, rgba(255, 227, 239, 0.55) 9%, transparent 9.5%),
        linear-gradient(135deg, #fff5fb 0%, #ffeef7 38%, #ffe3f1 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    /* แก้ปัญหา Address bar มือถือ ทำให้จอขยับ */
    min-height: -webkit-fill-available;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: none; /* ช่วยลดปัญหาการเด้งหรือ Pull-to-refresh ที่รบกวนการ scroll */
}

/* เพิ่มการตอบสนองการทัชสำหรับปุ่มและการ์ดต่างๆ ทันที (ลบ delay) */
a, button, input, select, textarea, .card, .product-card, .plan-card, [onclick] {
    touch-action: manipulation;
}

body::before {
    content: '';
    position: fixed;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 183, 217, 0.18) 0%, transparent 70%);
    pointer-events: none;
    animation: float 20s ease-in-out infinite;
}

h1, h2, h3, .auth-header h1, .auth-header h2, .logo, .navbar-brand {
    font-family: 'Mali', 'Nunito', sans-serif;
    letter-spacing: -0.03em;
}

button, input, select, textarea, .btn, .card, .product-card {
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body::after {
    content: '';
    position: fixed;
    bottom: -50%;
    left: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 212, 232, 0.16) 0%, transparent 70%);
    pointer-events: none;
    animation: float 25s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33% { transform: translate(30px, -30px) rotate(5deg); }
    66% { transform: translate(-20px, 20px) rotate(-5deg); }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.auth-container {
    max-width: 480px;
    margin: 60px auto;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    padding: 48px;
    border-radius: var(--border-radius);
    box-shadow: 0 20px 60px var(--shadow), 
                0 0 0 1px rgba(255, 143, 195, 0.14),
                inset 0 1px 0 rgba(255, 255, 255, 0.8);
    position: relative;
    overflow: hidden;
}

.auth-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--gradient-primary);
    box-shadow: 0 4px 14px rgba(255, 95, 162, 0.28);
}

.auth-container::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background:
        radial-gradient(circle, rgba(255, 201, 226, 0.16) 0%, transparent 52%),
        radial-gradient(circle at 58% 42%, rgba(255, 234, 244, 0.22) 0%, transparent 34%);
    animation: rotate 30s linear infinite;
    pointer-events: none;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.logo {
    text-align: center;
    margin-bottom: 30px;
}

.logo h1 {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
    filter: drop-shadow(0 2px 6px rgba(255, 95, 162, 0.22));
}

.logo h1 i {
    font-size: 42px;
    margin-right: 8px;
}

.logo p {
    color: var(--text-gray);
    font-size: 15px;
    font-weight: 500;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--dark-gray);
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--light-gray);
    border-radius: var(--border-radius-sm);
    font-size: 15px;
    font-weight: 500;
    transition: var(--transition);
    background: linear-gradient(135deg, var(--gray) 0%, rgba(255, 250, 245, 0.8) 100%);
    position: relative;
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
    border-color: var(--light-peach);
    box-shadow: 0 6px 18px rgba(255, 143, 195, 0.12);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-peach);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(255, 143, 195, 0.16),
                0 8px 18px rgba(255, 143, 195, 0.16);
    transform: translateY(-2px);
}

.btn {
    width: 100%;
    padding: 16px 24px;
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: var(--transition);
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    box-shadow: 0 10px 24px rgba(255, 95, 162, 0.26),
                0 4px 12px rgba(255, 180, 214, 0.2);
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::after {
    width: 300px;
    height: 300px;
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 18px 36px var(--shadow-hover),
                0 6px 16px rgba(255, 180, 214, 0.26);
}

.btn-primary:active {
    transform: translateY(-1px) scale(0.98);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-peach);
    border: 2px solid var(--primary-peach);
    box-shadow: 0 6px 18px rgba(255, 143, 195, 0.14);
    position: relative;
    overflow: hidden;
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-secondary);
    opacity: 0;
    transition: opacity 0.3s;
}

.btn-secondary:hover::before {
    opacity: 1;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 22px rgba(255, 143, 195, 0.2);
    border-color: var(--secondary-coral);
}

.btn-secondary span {
    position: relative;
    z-index: 1;
}

.btn-danger {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(238, 90, 111, 0.3);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #ee5a6f 0%, #c44569 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(238, 90, 111, 0.4);
}

.link {
    text-align: center;
    margin-top: 20px;
    color: var(--text-gray);
}

.link a {
    color: var(--primary-pink);
    text-decoration: none;
    font-weight: 600;
}

.link a:hover {
    text-decoration: underline;
}

.alert {
    padding: 16px 20px;
    border-radius: var(--border-radius-sm);
    margin-bottom: 24px;
    font-size: 15px;
    font-weight: 600;
    border-left: 4px solid;
    animation: slideInDown 0.3s ease;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border-left-color: #28a745;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.2);
}

.alert-error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    border-left-color: #dc3545;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.2);
}

.alert-info {
    background: linear-gradient(135deg, #fff0f7 0%, #fff8fc 100%);
    color: #a14f78;
    border-left-color: var(--primary-peach);
    box-shadow: 0 8px 18px rgba(255, 143, 195, 0.16);
}

.alert.btn-primary {
    background: linear-gradient(135deg, var(--primary-pink) 0%, var(--primary-pink-light) 100%);
    color: var(--white);
    border: none;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.navbar {
    background: var(--gradient-primary);
    padding: 18px 0;
    box-shadow: 0 4px 24px var(--shadow),
                0 1px 0 rgba(255, 255, 255, 0.2) inset;
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg,
                transparent 0%, 
                rgba(255, 255, 255, 0.16) 50%, 
                transparent 100%);
    animation: shimmer 3s ease-in-out infinite;
    pointer-events: none;
}

@keyframes shimmer {
    0%, 100% { transform: translateX(-100%); }
    50% { transform: translateX(100%); }
}

.navbar-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    color: var(--white);
    font-size: 26px;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2),
                 0 4px 12px rgba(255, 204, 153, 0.3);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}

.navbar-brand i {
    font-size: 28px;
    margin-right: 8px;
}

.navbar-link i {
    margin-right: 6px;
    font-size: 16px;
}

.navbar-menu {
    display: flex;
    gap: 20px;
    align-items: center;
}

.navbar-link {
    color: var(--white);
    text-decoration: none;
    padding: 10px 18px;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
    font-weight: 600;
    font-size: 15px;
}

.navbar-link:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-1px);
}

.dashboard {
    margin-top: 30px;
}

.dashboard-header {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 15px var(--shadow);
    margin-bottom: 30px;
}

.dashboard-header h2 {
    color: var(--primary-pink);
    margin-bottom: 10px;
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.menu-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 240, 247, 0.92) 100%);
    padding: 36px;
    border-radius: var(--border-radius);
    box-shadow: 0 8px 24px var(--shadow),
                inset 0 1px 0 rgba(255, 255, 255, 0.8);
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid rgba(255, 215, 232, 0.72);
    position: relative;
    overflow: hidden;
}

.menu-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(255, 95, 162, 0.26);
}

.menu-card::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 201, 226, 0.22) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.menu-card:hover::before {
    transform: scaleX(1);
}

.menu-card:hover::after {
    width: 400px;
    height: 400px;
}

.menu-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--primary-peach);
    box-shadow: 0 20px 50px var(--shadow-hover),
                0 0 0 1px rgba(255, 143, 195, 0.22),
                inset 0 1px 0 rgba(255, 255, 255, 1);
}

.menu-card-icon {
    font-size: 56px;
    margin-bottom: 18px;
    display: inline-block;
    color: var(--primary-color);
    position: relative;
    width: 64px;
    height: 64px;
}

.menu-card-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: var(--transition);
}

.menu-card-icon::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(255, 210, 234, 0.42) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    transition: var(--transition);
}

.menu-card:hover .menu-card-icon {
    transform: scale(1.15) rotate(8deg);
    animation: bounce 0.6s ease;
}

.menu-card:hover .menu-card-icon img {
    filter: drop-shadow(0 6px 14px rgba(255, 143, 195, 0.32));
}

.menu-card:hover .menu-card-icon::after {
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(255, 196, 223, 0.52) 0%, rgba(255, 232, 243, 0.32) 52%, transparent 72%);
}

@keyframes bounce {
    0%, 100% { transform: scale(1.15) rotate(8deg) translateY(0); }
    50% { transform: scale(1.15) rotate(8deg) translateY(-10px); }
}

.menu-card h3 {
    color: var(--dark-gray);
    margin-bottom: 10px;
}

.menu-card p {
    color: var(--text-gray);
    font-size: 14px;
}

.card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(255, 245, 250, 0.9) 100%);
    padding: 36px;
    border-radius: var(--border-radius);
    box-shadow: 0 8px 24px var(--shadow),
                inset 0 1px 0 rgba(255, 255, 255, 0.9);
    margin-bottom: 24px;
    border: 1px solid rgba(255, 215, 232, 0.65);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
                transparent 0%, 
                rgba(255, 201, 226, 0.14) 50%, 
                transparent 100%);
    transition: left 0.8s ease;
}

.card:hover::before {
    left: 100%;
}

.card:hover {
    box-shadow: 0 12px 36px var(--shadow-hover),
                inset 0 1px 0 rgba(255, 255, 255, 1);
    transform: translateY(-2px);
}

.card-header {
    border-bottom: 2px solid var(--lighter-pink);
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.card-header h3 {
    color: var(--primary-pink);
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--gray);
}

.info-label {
    font-weight: 600;
    color: var(--dark-gray);
}

.info-value {
    color: var(--text-gray);
}

.address-list {
    display: grid;
    gap: 15px;
}

.address-item {
    background: var(--white);
    padding: 24px;
    border-radius: var(--border-radius);
    border: 2px solid var(--light-gray);
    position: relative;
    transition: var(--transition);
}

.address-item:hover {
    border-color: var(--light-pink);
    box-shadow: 0 8px 20px var(--shadow);
    transform: translateY(-2px);
}

.address-item.default {
    border-color: var(--primary-pink);
    background: var(--gradient-secondary);
    box-shadow: 0 8px 24px var(--shadow);
}

.default-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--gradient-primary);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 154, 118, 0.4),
                0 2px 6px rgba(255, 179, 186, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
    letter-spacing: 0.5px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); box-shadow: 0 6px 16px rgba(255, 154, 118, 0.5), 0 3px 8px rgba(255, 179, 186, 0.4); }
}

.address-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

.btn-small {
    padding: 10px 18px;
    font-size: 14px;
    width: auto;
    font-weight: 600;
    border-radius: 10px;
    transition: var(--transition);
    box-shadow: 0 2px 6px rgba(255, 154, 118, 0.2);
}

.btn-small:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 154, 118, 0.3);
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(69, 33, 54, 0.42);
    z-index: 1000;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
}

.modal-content {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 243, 249, 0.96));
    border-radius: 24px;
    width: calc(100vw - 30px) !important;
    max-width: none !important;
    box-shadow: 0 28px 60px rgba(137, 68, 105, 0.22);
    margin: 0 !important;
    height: calc(100vh - 30px) !important;
    max-height: calc(100vh - 30px) !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    border: 1px solid rgba(255, 218, 235, 0.9);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: var(--dark-gray);
    font-size: 18px;
    flex: 1;
    padding-right: 10px;
}

.modal-body {
    padding: 20px;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.close-btn {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-gray);
    cursor: pointer;
    padding: 0;
    width: 36px;
    height: 36px;
    min-width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: var(--transition);
    flex-shrink: 0;
}

.close-btn:hover {
    background: var(--lighter-peach);
    color: var(--primary-peach);
}

.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(74, 35, 61, 0.36);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    backdrop-filter: blur(3px);
}

.spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top: 5px solid var(--primary-peach);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hidden {
    display: none !important;
}

@media (max-width: 768px) {
    .auth-container {
        margin: 20px;
        padding: 25px;
    }

    .navbar-content {
        flex-direction: column;
        gap: 15px;
    }

    .navbar-menu {
        flex-wrap: wrap;
        justify-content: center;
    }

    .menu-grid {
        grid-template-columns: 1fr;
    }

    .info-row {
        flex-direction: column;
        gap: 5px;
    }

    .address-actions {
        flex-direction: column;
    }

    .btn-small {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 22px;
    }

    .card {
        padding: 20px;
    }

    .modal-content {
        padding: 20px;
    }
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    cursor: pointer;
}

.g-recaptcha {
    margin-bottom: 20px;
}

.status-badge {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
    position: relative;
    overflow: hidden;
}

.status-badge::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.status-badge:hover::before {
    left: 100%;
}

.status-active {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border: 1px solid #b1dfbb;
}

.status-pending {
    background: linear-gradient(135deg, #fff3cd 0%, #ffe8a1 100%);
    color: #856404;
    border: 1px solid #ffd966;
}

.status-badge.status-pending {
    background: var(--text-gray);
}

.status-suspended {
    background: #f8d7da;
    color: #721c24;
}

.status-badge.status-out-of-stock {
    background: #ffa500;
}

.status-badge.status-inactive {
    background: var(--text-gray);
}

.status-cancelled {
    background: var(--gray);
    color: var(--text-gray);
}

/* Alert Modal Styles */
.alert-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.alert-modal.active {
    opacity: 1;
    visibility: visible;
}

.alert-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(74, 35, 61, 0.42);
    backdrop-filter: blur(4px);
}

.alert-modal-content {
    position: relative;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(255, 242, 248, 0.97));
    border-radius: 20px;
    padding: 40px 30px 30px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 28px 64px rgba(137, 68, 105, 0.24),
                0 0 0 1px rgba(255, 143, 195, 0.14);
    transform: scale(0.9) translateY(-20px);
    transition: transform 0.3s;
}

.alert-modal.active .alert-modal-content {
    transform: scale(1) translateY(0);
}

.alert-modal-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: iconBounce 0.6s ease;
}

@keyframes iconBounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.alert-modal-icon.success {
    color: #28a745;
}

.alert-modal-icon.error {
    color: #dc3545;
}

.alert-modal-icon.warning {
    color: #ffc107;
}

.alert-modal-icon.info {
    color: var(--primary-peach);
}

.alert-modal-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--dark-gray);
    margin-bottom: 15px;
}

.alert-modal-message {
    font-size: 16px;
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 25px;
    white-space: pre-line;
}

.alert-modal-btn {
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    padding: 12px 30px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 10px 24px rgba(255, 95, 162, 0.24);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.alert-modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(255, 95, 162, 0.28);
}

.alert-modal-btn i {
    font-size: 18px;
}

/* Products Page Styles */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 30px;
}

.product-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--gray-200);
    position: relative;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary-pink);
}

.product-image {
    width: 100%;
    height: 280px;
    background: var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-image .no-image {
    font-size: 48px;
    color: var(--gray);
}

.product-image .status-badge {
    position: absolute;
    top: 12px;
    right: 12px;
}

.product-info {
    padding: 20px;
}

.product-key {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-name {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 12px;
    min-height: 20px;
}

.product-price {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary-pink);
    margin-bottom: 8px;
}

.product-shipping {
    font-size: 13px;
    color: var(--text-gray);
    margin: 4px 0;
}

.product-date {
    font-size: 12px;
    color: var(--text-gray);
    margin: 4px 0;
}

.product-remark {
    font-size: 13px;
    color: var(--text-gray);
    font-style: italic;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border-color);
}

.product-actions {
    padding: 0 20px 20px;
    display: flex;
    gap: 10px;
}

.product-actions .btn-small {
    flex: 1;
}

.image-upload-container {
    text-align: center;
}

.image-button-group {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 10px;
}

.image-button-group .btn-small {
    flex: 1;
    max-width: 150px;
}

.generate-button-group {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
}

.btn-generate {
    flex: 2;
    min-width: 150px;
}

.btn-download-gen {
    flex: 1;
    flex-shrink: 0;
    min-width: 120px;
    max-width: 150px;
}

.generated-image-preview {
    width: 100%;
    max-width: 400px;
    height: 300px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    background: var(--gray);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.generated-image-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.preview-placeholder {
    text-align: center;
    color: var(--text-gray);
}

.preview-placeholder i {
    font-size: 48px;
    color: var(--gray);
    margin-bottom: 10px;
    opacity: 0.5;
}

.preview-placeholder p {
    font-size: 14px;
    margin: 0;
}

/* Image Preview Modal */
body.modal-open {
    overflow: hidden;
    touch-action: none;
    position: fixed;
    width: 100%;
}

.image-preview-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    padding: 0;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.95);
}

.image-preview-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-preview-content {
    max-width: 95%;
    max-height: 95%;
    object-fit: contain;
    animation: zoomIn 0.3s;
}

.image-preview-close {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #fff;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    z-index: 10001;
}

.image-preview-close:hover,
.image-preview-close:focus {
    color: var(--primary-peach);
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.image-preview {
    width: 100%;
    height: 250px;
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    cursor: pointer;
    transition: var(--transition);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.image-preview:hover {
    border-color: var(--primary-peach);
    background-color: var(--lighter-peach);
}

.image-preview i {
    font-size: 48px;
    color: var(--gray);
    margin-bottom: 10px;
}

.image-preview p {
    color: var(--text-gray);
    font-size: 14px;
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-gray);
}

.empty-state i {
    font-size: 80px;
    color: var(--gray);
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 24px;
    color: var(--dark-gray);
    margin-bottom: 10px;
}

.empty-state p {
    font-size: 16px;
    margin-bottom: 30px;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.dashboard-header h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--dark-gray);
}

.dashboard-header h2 i {
    color: var(--primary-peach);
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }
    
    body.modal-open {
        position: fixed;
        width: 100%;
        height: 100%;
        overflow: hidden;
    }
    
    .container {
        padding: 10px;
        max-width: 100vw;
        overflow-x: hidden;
    }
    
    .modal {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }
    
    .modal.active {
        padding: 0;
        align-items: flex-start;
        overflow-y: auto;
    }
    
    .modal-content {
        max-width: 100%;
        width: 100%;
        border-radius: 0;
        margin: 0;
        min-height: 100%;
        max-height: none;
        display: flex;
        flex-direction: column;
    }
    
    .modal-header {
        padding: 15px;
        flex-shrink: 0;
    }
    
    .modal-header h3 {
        font-size: 16px;
    }
    
    .modal-body {
        padding: 15px;
        flex: 1;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .modal-footer {
        padding: 12px 15px;
        gap: 8px;
        flex-shrink: 0;
        background: var(--white);
        border-top: 1px solid var(--border-color);
    }
    
    .modal-footer .btn {
        flex: 1;
        min-width: 100px;
    }
    
    .form-group label {
        font-size: 14px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 16px;
        max-width: 100%;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    .image-preview {
        height: 180px;
    }
    
    .image-button-group {
        flex-direction: row;
    }
    
    .image-button-group .btn-small {
        max-width: none;
        font-size: 13px;
        padding: 10px 12px;
    }
    
    .generated-image-preview {
        height: 200px;
        max-width: 100%;
    }
    
    .generate-button-group {
        flex-direction: column;
    }
    
    .btn-generate,
    .btn-download-gen {
        width: 100%;
        flex: none;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .dashboard-header .btn {
        width: 100%;
    }
    
    .navbar-content {
        padding: 0 15px;
    }
    
    .navbar-brand {
        font-size: 16px;
    }
    
    .navbar-menu {
        gap: 10px;
    }
    
    .navbar-link {
        font-size: 13px;
    }
    
    .menu-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .alert-modal-content {
        max-width: 90%;
        padding: 30px 20px 20px;
    }
    
    .alert-modal-title {
        font-size: 20px;
    }
    
    .alert-modal-message {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .modal-header h3 {
        font-size: 15px;
    }
    
    .close-btn {
        width: 32px;
        height: 32px;
        min-width: 32px;
        font-size: 24px;
    }
    
    .btn {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .btn-small {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .product-card {
        border-radius: 12px;
    }
    
    .product-image {
        height: 180px;
    }
    
    .product-info {
        padding: 15px;
    }
    
    .product-key {
        font-size: 16px;
    }
    
    .product-price {
        font-size: 20px;
    }
}
