:root {
    --bg-color: #f0f4f8;
    --accent-vibrant: #ff6b6b;
    --accent-vibrant-hover: #fa5252;
    --accent-secondary: #4ecdc4;
    --accent-secondary-hover: #38b2a8;
    --accent-yellow: #ffd93d;
    --text-color: #2d3436;
    --text-muted: #8795a1;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --border-radius: 24px;
    --shadow-soft: 0 15px 35px rgba(0, 0, 0, 0.08), 0 5px 15px rgba(0, 0, 0, 0.04);
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.15), 0 8px 20px rgba(0, 0, 0, 0.08);
    --input-bg: #f8fafc;
}

*, *::before, *::after { box-sizing: border-box; }
body {
    margin: 0; height: 100vh; height: 100dvh;
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    overflow: hidden;
    display: flex; flex-direction: column;
}

#vanta-bg {
    position: absolute;
    top: 0; left: 0; width: 100vw; height: 100vh; height: 100dvh;
    z-index: -1; pointer-events: none;
}

.app-container {
    flex: 1; display: flex; flex-direction: column; align-items: center;
    padding: 2rem; position: relative; z-index: 1;
    overflow-y: auto; overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

.glass-card {
    margin: auto;
    background: var(--glass-bg);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    padding: 3rem; width: 100%; max-width: 700px;
    border: 2px solid rgba(255, 255, 255, 0.6);
    overflow: hidden; position: relative; min-height: 600px;
    transition: box-shadow 0.3s ease;
    flex-shrink: 0;
}

h1 { font-size: 2rem; margin: 0; font-weight: 800; color: var(--text-color); }
.subtitle { font-size: 1.25rem; color: var(--text-muted); font-weight: 700; margin-bottom: 1.5rem; text-transform: uppercase; letter-spacing: 1px; }
.centered { text-align: center; }

.header-banner {
    display: flex; flex-direction: column; align-items: center; gap: 1rem; margin-bottom: 2rem;
}
.banner-icon {
    font-size: 2.5rem; color: var(--accent-yellow);
    background: #fff; padding: 1.25rem; border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    transform: rotate(-10deg);
}

.divider { height: 2px; background: #edf2f7; margin: 2rem auto; width: 80%; border-radius: 2px; }

.input-wrapper { display: flex; justify-content: center; }
.input-group {
    display: flex; align-items: center;
    background: var(--input-bg);
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 0.5rem 1rem;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    flex: 1;
}
.input-group:focus-within {
    border-color: var(--accent-secondary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(78, 205, 196, 0.15);
    transform: translateY(-2px);
}
.icon-muted { color: var(--text-muted); font-size: 1.1rem; margin-right: 0.75rem; }

.input, .employee-input {
    border: none; background: transparent; outline: none;
    font-size: 1.1rem; font-family: inherit; font-weight: 600;
    width: 100%; color: var(--text-color); padding: 0.5rem 0;
}
.large-input { max-width: 350px; padding: 0.75rem 1.5rem; border-radius: 20px; }
.large-input .input { font-size: 1.5rem; text-align: center; }

.employee-input-container {
    display: grid;
    grid-template-columns: 2fr 1.5fr auto;
    gap: 0.75rem; margin-bottom: 0.75rem;
    align-items: center;
}

.remove-btn {
    background: #fee2e2; color: #ef4444; border: none;
    width: 50px; height: 50px; border-radius: 16px;
    display: flex; justify-content: center; align-items: center;
    cursor: pointer; font-size: 1.2rem;
}
.remove-btn:hover { background: #ef4444; color: #fff; transform: scale(1.1) rotate(5deg) !important; }

.bounce-hover {
    cursor: pointer; border: none; font-family: inherit; font-weight: 700;
    border-radius: 16px; padding: 1.25rem; font-size: 1.1rem;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.bounce-hover:hover:not(:disabled) {
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--shadow-hover);
}
.bounce-hover:active:not(:disabled) { transform: scale(0.98); }

.add-employee {
    background-color: var(--accent-secondary); color: white; margin-top: 1rem;
    box-shadow: 0 4px 15px rgba(78, 205, 196, 0.3);
}
.add-employee:hover { background-color: var(--accent-secondary-hover); }

.calculate {
    background-color: var(--accent-vibrant); color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}
.calculate:disabled { background-color: #cbd5e0; cursor: not-allowed; box-shadow: none; transform: none; }
.calculate:not(:disabled):hover { background-color: var(--accent-vibrant-hover); }

.back-button { background-color: white; color: var(--text-color); border: 2px solid #e2e8f0; }
.back-button:hover { border-color: var(--text-muted); background: #f8fafc; }

@keyframes slideUpFade {
    0% { opacity: 0; transform: translateY(20px) scale(0.95); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}
.animate-entry { animation: slideUpFade 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; opacity: 0; }

section { transition: 0.5s cubic-bezier(0.65, 0, 0.35, 1); width: 100%; position: absolute; left: 0; top: 0; padding: 3rem; }
.app-container .glass-card { position: relative; }

.calculate-section { transform: translateX(120%); opacity: 0; pointer-events: none; }
.input-section { transform: translateX(0); opacity: 1; position: relative; padding: 0; }

.input-section.hidden { transform: translateX(-120%); opacity: 0; pointer-events: none; position: absolute; }
.calculate-section.active { transform: translateX(0); opacity: 1; pointer-events: all; position: relative; padding: 0;}

.employee-tips { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 1rem;}
.employee-tip {
    background: white; padding: 1.25rem 1.5rem; border-radius: 16px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03); cursor: pointer;
    border: 2px solid transparent; transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative; overflow: hidden;
}
.employee-tip:hover { transform: scale(1.02) translateY(-2px); border-color: var(--accent-yellow); }

.employee-tip-content { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.employee-tip-name { font-size: 1.2rem; font-weight: 700; margin: 0; }
.employee-tip-amount { font-size: 1.5rem; color: var(--accent-vibrant); font-weight: 800; margin: 0; }
.employee-tip-arrow { color: var(--text-muted); font-size: 1.2rem; }

.employee-checked { display: none; }
.strikethrough + .employee-tip-content::after {
    content: ''; position: absolute; top: 50%; left: 1.5rem; right: 1.5rem;
    height: 4px; background: var(--accent-secondary); opacity: 0.8; border-radius: 2px;
}
.strikethrough + .employee-tip-content { opacity: 0.5; }

footer { padding: 1.5rem; text-align: center; font-size: 0.85rem; color: #64748b; font-weight: 600; z-index: 10; }
.flex { display: flex; } .justify-center { justify-content: center; } .items-center { align-items: center; }
.justify-between { justify-content: space-between; } .gap-4 { gap: 1rem; } .w-full { width: 100%; }
.mt-4 { margin-top: 1rem; } .mt-12 { margin-top: 3rem; } .mb-12 { margin-bottom: 3rem; } .py-4 { padding: 1rem 0; }

@media (max-width: 640px) {
    .app-container { padding: 1rem; }
    .glass-card { padding: 1.25rem; border-radius: 16px; }
    .employee-input-container { grid-template-columns: 2fr 1.5fr auto; gap: 0.4rem; }
    .input-group { padding: 0.4rem 0.5rem; }
    .icon-muted { margin-right: 0.4rem; font-size: 0.95rem; }
    .input, .employee-input { font-size: 0.95rem; }
    .remove-btn { width: 38px; height: 38px; font-size: 1rem; border-radius: 10px; }
    .header-banner { margin-bottom: 1rem; gap: 0.5rem; }
    .banner-icon { font-size: 1.5rem; padding: 0.75rem; }
    .mt-12 { margin-top: 1.5rem; }
    .mb-12 { margin-bottom: 1.5rem; }
    h1 { font-size: 1.25rem; }
    .subtitle { margin-bottom: 0.75rem; font-size: 1rem; }
    .divider { margin: 1.25rem auto; }
    .bounce-hover { padding: 0.8rem; font-size: 0.95rem; }
}
