/* styles.css - Premium Travel Color Scheme */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* styles.css - Premium Travel Color Scheme */

/* ========================================
   CUSTOM FONTS
   ======================================== */
@font-face {
    font-family: 'Lilita One';
    src: url('../fonts/lilitaone.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Lora';
    src: url('../fonts/Lora-BoldItalic.ttf') format('truetype');
    font-weight: bold;
    font-style: italic;
}

/* ========================================
   FONT ASSIGNMENTS - Recommended
   ======================================== */

/* Lilita One for headings */
h1, h2, h3, 
.header h1,
.modal-title,
.expenses-title,
.currency-settings-title,
.budget-settings-title {
    font-family: 'Lilita One', cursive;
}

/* Lilita One for buttons */
button,
.add-btn,
.continue-btn,
.summary-btn {
    font-family: 'Lilita One', cursive;
}

/* Lora for body text */
body {
    font-family: 'Lora', Georgia, serif;
}

/* Regular text without italic */
.expense-description,
.currency-label,
.budget-label,
input,
select {
    font-family: 'Lora', Georgia, serif;
    font-style: normal; /* Remove italic for readability */
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Lilita One', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 100vh;
    color: #1a1a2e;
    position: relative;
    overflow-x: hidden;
    background: #003580;
}

/* Professional Travel Background - Inspired by Booking.com & Agoda */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(135deg, 
            #002855 0%,
            #003580 35%,
            #004494 65%,
            #1a4d7d 100%
        ),
        url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23ffffff' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
    z-index: -2;
}

/* Subtle professional gradient overlay */
body::after {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(26, 188, 156, 0.06) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(52, 152, 219, 0.08) 0%, transparent 50%),
        linear-gradient(135deg, transparent 30%, rgba(41, 128, 185, 0.05) 70%);
    animation: gradientShift 30s ease infinite;
    z-index: -1;
}

@keyframes gradientShift {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.1); }
}

/* Container */
.container {
    max-width: 420px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* Header Section - Premium Glass Card */
.header {
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 30px;
    margin-bottom: 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.header::before {
    content: '';
    position: absolute;
    width: 140px;
    height: 140px;
    background-image: url('/icons/icon-192x192.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.08;
    right: -30px;
    top: -30px;
    animation: float 6s ease-in-out infinite;
    filter: brightness(1.5);
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(10deg); }
}

.header h1 {
    color: #ffffff;
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

/*
.header h1::before {
    content: '';
    width: 32px;
    height: 32px;
    background-image: url('/icons/icon-96x96.png');
    background-size: contain;
    background-repeat: no-repeat;
    display: inline-block;
}
    */

.location-info {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 15px;
    font-weight: 400;
}

/* Rate Status Pills - Teal accent */
.rate-status {
    font-size: 11px;
    padding: 6px 12px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 5px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rate-status.loading {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    animation: pulse 1.5s ease infinite;
}

.rate-status.live {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    color: white;
    box-shadow: 0 4px 15px rgba(26, 188, 156, 0.4);
}

.rate-status.error {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

/* Currency Settings */
.currency-settings {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.currency-settings-title {
    color: rgba(255, 255, 255, 0.95);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    text-align: center;
}

.currency-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    position: relative;
}

.currency-row:last-child {
    margin-bottom: 0;
}

.currency-label {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    min-width: 85px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Modern Input/Select Styling */
select, input {
    flex: 1;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 14px;
    color: white;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    width: 100%;
    box-sizing: border-box;
}

select {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' fill-opacity='0.7' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
    min-width: 0;
}

select option {
    background: #0a0e27;
    color: white;
}

select:focus, input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(26, 188, 156, 0.4);
    box-shadow: 
        0 0 0 4px rgba(26, 188, 156, 0.08),
        0 0 20px rgba(26, 188, 156, 0.12);
}

/* Expense Form */
.expense-form {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    position: relative;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 10px;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.amount-input-group {
    display: flex;
    gap: 2px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Budget Display */
/* Budget Display - Fixed Layout */
.budget-display {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.budget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.budget-title {
    font-size: 16px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.95);
    display: flex;
    align-items: center;
    gap: 8px;
}

.budget-currency-badge {
    font-size: 11px;
    padding: 4px 10px;
    background: rgba(26, 188, 156, 0.2);
    border: 1px solid rgba(26, 188, 156, 0.4);
    border-radius: 12px;
    color: #1abc9c;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.budget-controls {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.budget-edit-btn, .budget-toggle-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.budget-edit-btn:hover {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    border-color: transparent;
    transform: scale(1.05);
}

.budget-toggle-btn:hover {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-color: transparent;
    transform: scale(1.05);
}

.budget-amounts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.budget-amount-item {
    text-align: center;
}

.budget-label {
    display: block;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    font-weight: 600;
}

.budget-value {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.95);
}

.budget-value.spent {
    color: #ff6b6b;
}

.budget-value.remaining {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.budget-value.remaining.warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.budget-value.remaining.over-budget {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.budget-progress {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    height: 12px;
    overflow: hidden;
    margin-bottom: 10px;
}

.budget-progress-bar {
    height: 100%;
    background: linear-gradient(135deg, #1abc9c, #16a085);
    border-radius: 12px;
    transition: all 0.5s ease;
    box-shadow: 0 0 10px rgba(26, 188, 156, 0.5);
}

.budget-progress-bar.warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    box-shadow: 0 0 10px rgba(243, 156, 18, 0.5);
}

.budget-progress-bar.over-budget {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    box-shadow: 0 0 10px rgba(231, 76, 60, 0.5);
    animation: pulse 1.5s ease infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 10px rgba(231, 76, 60, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(231, 76, 60, 0.8);
    }
}

.budget-percentage {
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.75);
    font-weight: 700;
}

.budget-percentage.warning {
    color: #f39c12;
}

.budget-percentage.over-budget {
    color: #ff6b6b;
    font-weight: 700;
}

/* Budget Settings on Page 1 */
.budget-settings {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.budget-settings-title {
    color: rgba(255, 255, 255, 0.95);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    text-align: center;
}

.budget-description {
    color: rgba(255, 255, 255, 0.65);
    font-size: 13px;
    text-align: center;
    margin-bottom: 20px;
}

.budget-input-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 20px;
}

.budget-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.budget-row label {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    min-width: 85px;
    font-size: 14px;
}

/* Currency symbol - Golden amber for money */
.currency-symbol {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: white;
    padding: 14px 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    min-width: 65px;
    justify-content: center;
    font-size: 18px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.amount-input-group input {
    border: none;
    border-radius: 0;
    background: transparent;
}

/* Add Button - Vibrant Coral/Orange for action */
.add-btn {
    width: 100%;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    color: white;
    border: none;
    padding: 16px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(255, 107, 107, 0.4);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.add-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.add-btn:hover::before {
    width: 300px;
    height: 300px;
}

.add-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 107, 107, 0.5);
}

.add-btn:active {
    transform: translateY(0);
}

.add-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Header Buttons Container */
.header-buttons {
    display: flex;
    gap: 8px;
}

/* Clear Button */
.clear-btn {
    background: rgba(231, 76, 60, 0.15);
    color: #ff6b6b;
    border: 1px solid rgba(231, 76, 60, 0.3);
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.clear-btn:hover {
    background: rgba(231, 76, 60, 0.25);
    border-color: rgba(231, 76, 60, 0.5);
    transform: scale(1.05);
}

/* Summary Button - Teal accent */
.summary-btn {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 10px rgba(26, 188, 156, 0.3);
}

.summary-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(26, 188, 156, 0.4);
}

/* Conversion Display - Teal accent */
.conversion-display {
    background: linear-gradient(135deg, rgba(26, 188, 156, 0.12), rgba(22, 160, 133, 0.12));
    border: 1px solid rgba(26, 188, 156, 0.2);
    padding: 16px;
    border-radius: 12px;
    margin-top: 12px;
    text-align: center;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.conversion-rate {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Expenses Section */
.expenses-section {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    overflow: hidden; /* Prevent content from escaping */
}

.expenses-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    gap: 12px;
}

.expenses-title {
    font-size: 18px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.95);
    letter-spacing: -0.5px;
    flex-shrink: 0;
}

/* Header Buttons Container - ALWAYS SIDE BY SIDE */
.header-buttons {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

/* Summary Button */
.summary-btn {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 2px 10px rgba(26, 188, 156, 0.3);
    white-space: nowrap;
    flex-shrink: 0;
}

.summary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(26, 188, 156, 0.4);
}

.summary-btn:active {
    transform: translateY(0);
}

/* Clear Button */
.clear-btn {
    background: rgba(231, 76, 60, 0.15);
    color: #ff6b6b;
    border: 1px solid rgba(231, 76, 60, 0.3);
    padding: 10px 16px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.clear-btn:hover {
    background: rgba(231, 76, 60, 0.25);
    border-color: rgba(231, 76, 60, 0.5);
    transform: translateY(-2px);
}

.clear-btn:active {
    transform: translateY(0);
}

/* Total amount - Golden gradient */
.total-amount {
    font-size: 20px;
    font-weight: 700;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
}

/* Date Section Styling */
.date-section {
    margin-bottom: 24px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Date Header - Soft purple/teal gradient */
.date-header {
    background: linear-gradient(135deg, rgba(142, 68, 173, 0.15), rgba(26, 188, 156, 0.15));
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.9);
    padding: 10px 16px;
    border-radius: 12px;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 13px;
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.date-header:hover {
    background: linear-gradient(135deg, rgba(142, 68, 173, 0.25), rgba(26, 188, 156, 0.25));
    transform: translateX(2px);
}

.date-header.collapsed {
    margin-bottom: 0;
}

.date-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.date-text {
    font-size: 13px;
}

.date-count {
    background: rgba(255, 255, 255, 0.15);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
}

.date-total {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    gap: 8px;
}

.collapse-icon {
    transition: transform 0.3s ease;
    font-size: 12px;
}

.date-header.collapsed .collapse-icon {
    transform: rotate(-90deg);
}

/* Date Expenses Container */
.date-expenses {
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    max-height: 1000px;
    opacity: 1;
}

.date-expenses.collapsed {
    max-height: 0;
    opacity: 0;
}

/* Expense Items - Coral accent border */
.expense-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 12px;
    border-left: 3px solid;
    border-left-color: #ff6b6b;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.expense-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 107, 0.05), transparent);
    transition: left 0.6s;
}

.expense-item:hover {
    transform: translateX(4px);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border-left-color: #1abc9c;
}

.expense-item:hover::before {
    left: 100%;
}

.expense-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.expense-description {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    font-size: 15px;
}

/* Expense amount - Coral gradient */
.expense-amount {
    font-weight: 700;
    font-size: 16px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.expense-details {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
    display: flex;
    justify-content: space-between;
    font-weight: 500;
}

.expense-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.35);
    margin-top: 8px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.45);
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: bounce 2s ease infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Summary Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.modal-overlay.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: linear-gradient(135deg, rgba(10, 14, 39, 0.98), rgba(26, 31, 58, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 32px;
    max-width: 90%;
    width: 400px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-title {
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: white;
    transform: rotate(90deg);
}

.date-range {
    background: linear-gradient(135deg, rgba(142, 68, 173, 0.2), rgba(26, 188, 156, 0.2));
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 12px 20px;
    border-radius: 12px;
    text-align: center;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
    backdrop-filter: blur(10px);
}

/* Summary Statistics Grid */
.summary-stats {
    display: grid;
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 16px;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-2px);
}

.stat-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.55);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

/* Stat value - Golden gradient */
.stat-value {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Summary Breakdown */
.summary-breakdown {
    margin-top: 24px;
}

.summary-subtitle {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.currency-breakdown {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
}

.currency-breakdown:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(2px);
}

.currency-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.currency-flag {
    font-size: 20px;
}

.currency-name {
    color: rgba(255, 255, 255, 0.85);
    font-size: 14px;
}

.currency-amount {
    font-weight: 600;
    color: white;
    font-size: 16px;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Scrollbar Styling - Teal accent */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.04);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #16a085, #1abc9c);
}

/* Expense Footer with Actions */
.expense-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

/* Expense Action Buttons */
.expense-actions {
    display: flex;
    gap: 8px;
}

.edit-btn, .delete-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
}

/* Edit button hover - Purple accent */
.edit-btn:hover {
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
    border-color: transparent;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(155, 89, 182, 0.4);
}

.delete-btn:hover {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border-color: transparent;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.4);
}

/* Edit Mode Styles - Teal accent */
.add-btn.edit-mode {
    background: linear-gradient(135deg, #1abc9c, #16a085);
    animation: editPulse 2s ease infinite;
}

.cancel-edit-btn {
    width: 100%;
    margin-top: 10px;
    background: rgba(231, 76, 60, 0.15);
    color: #ff6b6b;
    border: 1px solid rgba(231, 76, 60, 0.3);
    padding: 16px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: none;
}

.cancel-edit-btn:hover {
    background: rgba(231, 76, 60, 0.25);
    border-color: rgba(231, 76, 60, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(231, 76, 60, 0.4);
}

.cancel-edit-btn:active {
    transform: translateY(0);
}

@keyframes editPulse {
    0%, 100% {
        box-shadow: 0 4px 20px rgba(26, 188, 156, 0.4);
    }
    50% {
        box-shadow: 0 8px 30px rgba(26, 188, 156, 0.6);
    }
}

/* Editing Expense Highlight */
.expense-item.editing {
    background: rgba(26, 188, 156, 0.08);
    border-left-color: #1abc9c;
    border-left-width: 4px;
    animation: editHighlight 1s ease infinite;
}

@keyframes editHighlight {
    0%, 100% {
        background: rgba(26, 188, 156, 0.08);
    }
    50% {
        background: rgba(26, 188, 156, 0.12);
    }
}

/* Disabled select in edit mode */
select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: rgba(255, 255, 255, 0.04);
}

/* Footer Credits */
.footer {
    margin-top: 40px;
    padding: 20px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.credit {
    color: rgba(255, 255, 255, 0.65);
    font-size: 13px;
    margin-bottom: 10px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
    font-size: 12px;
    transition: all 0.3s ease;
    padding: 5px 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
}

.footer-links a:hover {
    color: #1abc9c;
    background: rgba(26, 188, 156, 0.1);
    transform: translateY(-2px);
}

/* Two-Page Navigation System */
.page {
    display: none;
    opacity: 0;
    animation: fadeIn 0.5s ease forwards;
}

.page.active {
    display: flex;
    flex-direction: column;
}

/* Page 1: Welcome & Currency Setup */
.welcome-page {
    flex: 1;
    justify-content: center;
    gap: 24px;
}

.header-welcome {
    padding: 40px 30px;
}

.header-welcome::before {
    width: 180px;
    height: 180px;
    right: -40px;
    top: -40px;
}

.header-welcome h1 {
    font-size: 32px;
    margin-bottom: 12px;
}

.header-welcome h1::before {
    width: 36px;
    height: 36px;
}

/* Continue Button - Coral gradient */
.continue-btn {
    width: 100%;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    color: white;
    border: none;
    padding: 18px;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(255, 107, 107, 0.4);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 16px;
}

.continue-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.continue-btn:hover::before {
    width: 300px;
    height: 300px;
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 107, 107, 0.5);
}

.continue-btn:active {
    transform: translateY(0);
}

/* Page 2: Main expense tracking */
.tracking-page {
    padding-bottom: 20px;
    gap: 20px;
}

/* Back button */
.back-btn {
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 12px 20px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-4px);
}

/* Compact header for page 2 */
.header-compact {
    padding: 20px;
}

.header-compact h2 {
    color: #ffffff;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.header-compact h2::before {
    content: '';
    width: 28px;
    height: 28px;
    background-image: url('/icons/icon-96x96.png');
    background-size: contain;
    background-repeat: no-repeat;
    display: inline-block;
}

.currency-info {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 12px;
    font-weight: 400;
    text-align: center;
    display: block;
}

@media (max-width: 480px) {
    /* Container */
    .container {
        padding: 15px;
    }

    /* Header */
    .header::before {
        width: 100px;
        height: 100px;
        right: -20px;
        top: -20px;
    }
    
    .header h1 {
        font-size: 22px;
    }
    
    /* Currency Settings */
    .currency-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .currency-label {
        min-width: auto;
    }

    /* Budget Section Mobile */
    .budget-header {
        padding-bottom: 12px;
    }

    .budget-title {
        font-size: 15px;
        gap: 6px;
    }

    .budget-currency-badge {
        font-size: 10px;
        padding: 3px 8px;
    }

    .budget-controls {
        gap: 6px;
    }

    .budget-edit-btn, .budget-toggle-btn {
        width: 40px;
        height: 40px;
        padding: 6px;
        font-size: 14px;
    }

    .budget-amounts {
        gap: 12px;
    }

    .budget-label {
        font-size: 10px;
        margin-bottom: 6px;
    }

    .budget-value {
        font-size: 16px;
    }

    .budget-percentage {
        font-size: 13px;
    }

    .budget-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .budget-row label {
        min-width: auto;
    }

    /* Expenses Section Mobile */
    .expense-item {
        padding: 14px;
    }

    /* IMPORTANT: Keep Summary and Clear All buttons side by side */
    .expenses-header {
        gap: 8px;
    }

    .expenses-title {
        font-size: 16px;
        flex: 0 0 auto;
    }

    .header-buttons {
        display: flex;
        flex-direction: row;  /* ← KEY FIX! Forces buttons to stay side by side */
        gap: 6px;
        flex-shrink: 0;
    }

    .summary-btn, .clear-btn {
        padding: 8px 12px;
        font-size: 11px;
        letter-spacing: 0.3px;
    }

    /* Expense Items */
    .expense-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .expense-actions {
        align-self: flex-end;
    }

    .edit-btn, .delete-btn {
        padding: 8px 12px;
        font-size: 16px;
    }

    /* Modal */
    .modal-content {
        padding: 24px;
    }

    /* Welcome Page */
    .welcome-page {
        gap: 20px;
    }

    .header-welcome {
        padding: 30px 24px;
    }

    .header-welcome::before {
        width: 140px;
        height: 140px;
        right: -30px;
        top: -30px;
    }

    .header-welcome h1 {
        font-size: 28px;
    }

    .header-welcome h1::before {
        width: 32px;
        height: 32px;
    }

    /* Tracking Page */
    .header-compact h2 {
        font-size: 20px;
    }

    .header-compact h2::before {
        width: 24px;
        height: 24px;
    }

    .continue-btn {
        padding: 16px;
        font-size: 15px;
    }

    /* Very small screens adjustment */
    @media (max-width: 360px) {
        .summary-btn, .clear-btn {
            padding: 8px 10px;
            font-size: 10px;
        }
    }
}