:root {
    --princess-pink: #ff8fc1;
    --deep-pink: #ff1493;
    --soft-pink: #fff0f8;
    --danger-red: #ff4d6d;
}

body {
    margin: 0;
    font-family: 'Nunito', sans-serif;
    background: linear-gradient(135deg, #ffe6f0 0%, var(--soft-pink) 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Header & Menu */
.header { padding: 15px; display: flex; align-items: center; position: absolute; top: 0; left: 0; width: 100%; box-sizing: border-box; z-index: 100; }
.menu-btn { cursor: pointer; display: flex; flex-direction: column; gap: 5px; padding: 10px; z-index: 1001; }
.menu-btn span { display: block; width: 25px; height: 3px; background: var(--deep-pink); border-radius: 3px; transition: 0.3s; }

/* Sidebar */
.sidebar { position: fixed; top: 0; left: -280px; width: 260px; height: 100%; background: white; box-shadow: 5px 0 15px rgba(255, 20, 147, 0.1); transition: 0.4s ease-in-out; z-index: 1000; padding-top: 80px; display: flex; flex-direction: column; }
.sidebar.active { left: 0; }
.sidebar-item { padding: 15px 25px; font-size: 16px; color: #555; cursor: pointer; transition: 0.3s; display: flex; align-items: center; gap: 10px; }
.sidebar-item:hover { background: var(--soft-pink); color: var(--deep-pink); padding-left: 35px; }
.sidebar-bottom { margin-top: auto; margin-bottom: 20px; border-top: 1px solid #eee; padding-top: 10px; }
.logout-btn { color: var(--danger-red); font-weight: bold; }

/* Main App Card */
.container { display: flex; justify-content: center; align-items: center; min-height: 100vh; padding: 20px; }
.app { background: #fff; width: 350px; border-radius: 30px; padding: 30px; box-shadow: 0 10px 30px rgba(255, 170, 210, 0.4); text-align: center; position: relative; }
h1 { font-family: 'Playfair Display', serif; color: #d36ba6; margin-bottom: 5px; }
.subtitle { font-size: 13px; color: #888; margin-bottom: 20px; }
input[type="date"] { width: 100%; padding: 12px; border-radius: 15px; border: 2px solid #fff0f6; background: #fffafa; margin-bottom: 15px; box-sizing: border-box; outline: none; color: #d36ba6; font-family: inherit; }
.main-btn { width: 100%; padding: 12px; border-radius: 15px; border: none; background: var(--princess-pink); color: white; font-weight: bold; font-size: 16px; cursor: pointer; transition: 0.3s; }
.main-btn:hover { background: #ffb6c1; color: var(--deep-pink); transform: translateY(-2px); }

/* History List */
#history { margin-top: 20px; max-height: 180px; overflow-y: auto; }
.item { background: #fff6fb; border-radius: 12px; padding: 10px 15px; margin-bottom: 8px; display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: #555; border-left: 4px solid #ffb6c1; }

/* Custom Modal */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 192, 203, 0.4); backdrop-filter: blur(4px); display: none; justify-content: center; align-items: center; z-index: 2000; }
.modal-overlay.show { display: flex; }
.modal-content { background: white; width: 300px; padding: 25px; border-radius: 25px; text-align: center; box-shadow: 0 15px 35px rgba(255, 20, 147, 0.2); animation: modalPop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
@keyframes modalPop { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.modal-icon { font-size: 50px; margin-bottom: 15px; display: block; }
.modal-title { font-size: 17px; font-weight: bold; color: #555; margin-bottom: 10px; line-height: 1.4; }
.modal-buttons { display: flex; gap: 10px; margin-top: 20px; }
.modal-btn { flex: 1; padding: 12px; border-radius: 12px; border: none; cursor: pointer; font-weight: bold; }
.btn-cancel { background: #f0f0f0; color: #888; }
.btn-confirm { background: var(--deep-pink); color: white; }

.overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.2); display: none; z-index: 999; }
.overlay.active { display: block; }
.result-box { background: #ffe0ee; border-radius: 20px; padding: 15px; margin-top: 20px; color: #a00050; font-size: 15px; }/* เพิ่มต่อท้ายไฟล์ style.css เดิม */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}