:root {
    --primary: #ff6500;
    --primary-dark: #e85b00;
    --primary-light: #fff0e5;

    --green: #16a34a;
    --green-light: #e8f8ed;

    --blue: #0284c7;
    --blue-light: #eaf4ff;

    --red: #ef4444;
    --red-light: #ffecec;

    --purple: #7c3aed;
    --purple-light: #f2eaff;

    --yellow: #f59e0b;
    --yellow-light: #fff7ed;

    --text: #0f172a;
    --muted: #64748b;
    --bg: #f5f6fa;
    --card: #ffffff;

    --radius-xl: 26px;
    --radius-lg: 22px;
    --radius-md: 16px;

    --shadow-card: 0 12px 32px rgba(15, 23, 42, .08);
    --shadow-soft: 0 8px 22px rgba(15, 23, 42, .06);
    --font-main: "Inter", system-ui, -apple-system, BlinkMacSystemFont,
                 "Segoe UI", Roboto, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}
html,
body,
button,
input,
select,
textarea{
    font-family: var(--font-main);
}
body {
    margin: 0;
    font-family: "Segoe UI", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
}

.app-shell {
    width: 100%;
    max-width: 430px;
    min-height: 100vh;
    margin: 0 auto;
    background: #fff;
    padding: 18px 16px 100px;
}

.app-card {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 18px;
    box-shadow: var(--shadow-card);
    border: 1px solid #f1f5f9;
    margin-bottom: 18px;
}

.app-title {
    font-size: 26px;
    font-weight: 900;
    margin: 4px 0 6px;
}

.app-desc {
    font-size: 15px;
    color: var(--muted);
    line-height: 1.5;
    margin-bottom: 18px;
}

.app-section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.app-section-title {
    font-size: 20px;
    font-weight: 900;
}

.app-section-link {
    color: var(--primary);
    font-size: 15px;
    font-weight: 800;
    text-decoration: none;
}

/* BUTTONS */

.btn {
    border: none;
    border-radius: 16px;
    padding: 13px 16px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-muted {
    background: #eef0f4;
    color: var(--text);
}

.btn-danger {
    background: var(--red);
    color: white;
}

.btn-full {
    width: 100%;
}

/* ICON BOX */

.icon-box {
    width: 48px;
    height: 48px;
    border-radius: 17px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.icon-green {
    background: var(--green-light);
    color: var(--green);
}

.icon-blue {
    background: var(--blue-light);
    color: var(--blue);
}

.icon-orange {
    background: var(--primary-light);
    color: var(--primary);
}

.icon-red {
    background: var(--red-light);
    color: var(--red);
}

.icon-purple {
    background: var(--purple-light);
    color: var(--purple);
}

.icon-yellow {
    background: var(--yellow-light);
    color: var(--yellow);
}

/* FORM */

label {
    display: block;
    font-size: 13px;
    font-weight: 800;
    color: #334155;
    margin: 10px 0 6px;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 14px;
    font-size: 16px;
    outline: none;
    background: #fff;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 101, 0, .12);
}

.form-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 18px;
}

.input-money {
    font-size: 21px;
    font-weight: 900;
}

/* LIST */

.ui-list-item {
    display: grid;
    grid-template-columns: 52px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid #edf0f5;
}

.ui-list-item:last-child {
    border-bottom: none;
}

.ui-list-main strong {
    display: block;
    font-size: 16px;
    font-weight: 900;
}

.ui-list-main span {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    color: var(--muted);
}

.ui-list-value {
    text-align: right;
    font-weight: 900;
    font-size: 14px;
}

/* STAT CARD */

.stat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-card {
    background: #fff;
    border-radius: 20px;
    padding: 14px;
    box-shadow: var(--shadow-soft);
    border: 1px solid #f1f5f9;
}

.stat-card-head {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-label {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.stat-value {
    font-size: 18px;
    font-weight: 900;
    margin-top: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.text-green {
    color: var(--green);
}

.text-red {
    color: var(--red);
}

.text-orange {
    color: var(--primary);
}

/* BOTTOM NAV */

.bottom-nav {
    position: fixed;
    left: 50%;
    bottom: 10px;
    transform: translateX(-50%);
    width: min(430px, calc(100% - 20px));
    height: 72px;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: blur(16px);
    border-radius: 24px;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    box-shadow: 0 14px 40px rgba(15, 23, 42, .16);
    z-index: 999;
    padding: 8px 4px;
}

.bottom-nav a {
    text-decoration: none;
    color: #9ca3af;
    text-align: center;
    font-size: 11px;
    font-weight: 800;
}

.bottom-nav i {
    display: block;
    font-size: 22px;
    margin-bottom: 3px;
}

.bottom-nav a.active {
    color: var(--primary);
}

.bottom-nav-v2 {
    position: fixed;
    left: 50%;
    bottom: 10px;
    transform: translateX(-50%);
    width: min(430px, calc(100% - 20px));
    height: 74px;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(16px);
    border-radius: 24px;
    display: grid;
    grid-template-columns: repeat(5,1fr);
    box-shadow: 0 14px 40px rgba(15,23,42,.16);
    z-index: 999;
    padding: 8px 4px;
}

.bottom-nav-v2 a {
    text-decoration: none;
    color: #9ca3af;
    text-align: center;
    font-size: 11px;
    font-weight: 800;
}

.bottom-nav-v2 a i {
    display: block;
    font-size: 22px;
    margin-bottom: 3px;
}

.bottom-nav-v2 a.active {
    color: var(--primary);
}

.fab-add {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 5px solid #fff;
    background: linear-gradient(135deg, #ff6500, #ffb000);
    color: #fff;
    font-size: 26px;
    margin: -28px auto 0;
    box-shadow: 0 12px 28px rgba(255,101,0,.35);
}

.quick-add-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,.35);
    opacity: 0;
    visibility: hidden;
    transition: .25s;
    z-index: 998;
}

.quick-add-overlay.show {
    opacity: 1;
    visibility: visible;
}

.quick-add-sheet {
    position: fixed;
    left: 50%;
    bottom: 0;
    transform: translate(-50%, 105%);
    width: min(430px, 100%);
    background: #fff;
    border-radius: 28px 28px 0 0;
    padding: 12px 18px 110px;
    box-shadow: 0 -18px 45px rgba(15,23,42,.18);
    transition: .28s ease;
    z-index: 999;
}

.quick-add-sheet.show {
    transform: translate(-50%, 0);
}

.sheet-handle {
    width: 48px;
    height: 5px;
    border-radius: 999px;
    background: #e5e7eb;
    margin: 0 auto 16px;
}
.ui-list-item.disabled{
    opacity:.45;
    filter:grayscale(100%);
}

.ui-list-item.disabled span{
    color:#999;
}