:root{--success-color: #4ade80;--danger-color: #f87171;--warning-color: #f59e0b;--shadow-light: 0 2px 8px rgba(0, 0, 0, .1);--shadow-medium: 0 4px 16px rgba(0, 0, 0, .15);--shadow-heavy: 0 8px 32px rgba(0, 0, 0, .2);--tg-theme-bg-color: #0f172a;--tg-theme-text-color: #f8fafc;--tg-theme-hint-color: #94a3b8;--tg-theme-button-color: #4a9eff;--tg-theme-button-text-color: #ffffff;--tg-theme-secondary-bg-color: rgba(15, 23, 42, .6);--border-color: rgba(148, 163, 184, .2);--sidebar-bg: rgba(15, 23, 42, .8);--sidebar-hover: rgba(30, 41, 59, .7);--surface-primary: rgba(15, 23, 42, .6);--surface-muted: rgba(30, 41, 59, .6);--surface-hover: rgba(30, 41, 59, .75);--surface-elevated: rgba(15, 23, 42, .8);--card-border: rgba(148, 163, 184, .18);--gradient-primary: linear-gradient(135deg, #4a9eff 0%, #6a5cff 100%);--gradient-secondary: radial-gradient(circle at 20% 20%, rgba(76, 29, 149, .4) 0%, rgba(0,0,0,0) 60%), radial-gradient(circle at 80% 30%, rgba(14,165,233,.18) 0%, rgba(0,0,0,0) 60%), #0f172a;--header-height: 64px;--radius-lg: 24px;--radius-md: 16px;--radius-sm: 12px;--space-2xs: 4px;--space-xs: 6px;--space-sm: 8px;--space-md: 12px;--space-lg: 16px;--space-xl: 20px;--space-2xl: 24px;--space-3xl: 32px;--space-4xl: 40px}*,*:before,*:after{margin:0;padding:0;box-sizing:border-box}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:var(--tg-theme-bg-color);color:var(--tg-theme-text-color);line-height:1.6;min-height:100vh;overflow-x:hidden}.app{min-height:100vh;display:flex;flex-direction:column;background:var(--gradient-secondary)}.page-container{width:100%;max-width:1400px;margin:0 auto;padding:clamp(16px,3vw,32px) clamp(16px,3vw,24px)}.header{height:var(--header-height);background:var(--sidebar-bg);border-bottom:1px solid var(--border-color);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);box-shadow:var(--shadow-medium);position:sticky;top:0;z-index:100}.header-content{display:flex;align-items:center;justify-content:space-between;height:100%;padding:0 clamp(16px,3vw,32px);max-width:1400px;margin:0 auto}.header-left{display:flex;align-items:center;min-width:0}.app-title{font-size:clamp(20px,4vw,28px);font-weight:700;margin:0;line-height:1.2;background:var(--gradient-primary);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text}.header-right{display:flex;align-items:center;gap:var(--space-md)}.nav-menu{display:flex;flex-direction:column;gap:var(--space-xs);padding:0 var(--space-lg)}.nav-button{display:flex;align-items:center;gap:var(--space-md);padding:var(--space-lg) var(--space-xl);border:none;border-radius:var(--radius-md);background-color:transparent;color:var(--tg-theme-hint-color);cursor:pointer;font-size:16px;font-weight:500;text-align:left;width:100%;transition:all .3s cubic-bezier(.4,0,.2,1)}.nav-button:hover{background:var(--sidebar-hover);color:var(--tg-theme-text-color);transform:translate(4px)}.nav-button.active{background:var(--gradient-primary);color:var(--tg-theme-button-text-color);box-shadow:var(--shadow-medium);transform:translate(8px)}.nav-icon{font-size:20px;width:24px;text-align:center;flex-shrink:0}.nav-text{flex:1;min-width:0;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.button{position:relative;overflow:hidden;-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;border-radius:var(--radius-md);min-width:120px;min-height:48px;padding:14px 28px;font-size:15px;font-weight:600;line-height:1.2;cursor:pointer;color:var(--tg-theme-button-text-color);background:var(--gradient-primary);transition:all .3s cubic-bezier(.4,0,.2,1);box-shadow:0 2px 8px #4a9eff4d}.button:before{content:"";position:absolute;top:0;left:-100%;width:100%;height:100%;background:linear-gradient(90deg,transparent,rgba(255,255,255,.3),transparent);transition:left .5s}.button:hover:before{left:100%}.button:hover{transform:translateY(-2px);box-shadow:0 6px 20px #4a9eff66}.button:active{transform:translateY(0)}.button:disabled{opacity:.5;cursor:not-allowed;transform:none;box-shadow:none}.button:disabled:before{display:none}.button-secondary{background:var(--sidebar-hover);color:var(--tg-theme-text-color);box-shadow:var(--shadow-light)}.button-secondary:hover{background:var(--surface-hover);box-shadow:var(--shadow-medium);transform:translateY(-2px)}.button-danger{background:linear-gradient(135deg,#f87171,#ef4444);color:#fff;box-shadow:0 2px 8px #f871714d}.button-danger:hover{background:linear-gradient(135deg,#ef4444,#dc2626);box-shadow:0 6px 20px #f8717166;transform:translateY(-2px)}.button-success{background:linear-gradient(135deg,#4ade80,#22c55e);color:#fff;box-shadow:0 2px 8px #4ade804d}.button-success:hover{background:linear-gradient(135deg,#22c55e,#16a34a);box-shadow:0 6px 20px #4ade8066;transform:translateY(-2px)}@media (max-width: 768px){.button{min-height:44px;font-size:14px}.button-danger{font-size:13px;min-width:80px}}.input,.select,textarea.input{width:100%;min-height:48px;padding:14px 18px;border:2px solid var(--border-color);border-radius:var(--radius-md);font-size:15px;line-height:1.5;background-color:var(--tg-theme-secondary-bg-color);color:var(--tg-theme-text-color);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);transition:all .3s cubic-bezier(.4,0,.2,1);box-sizing:border-box}.input:focus,.select:focus,textarea.input:focus{outline:none;border-color:var(--tg-theme-button-color);box-shadow:0 0 0 4px #4a9eff26;background-color:#0f172acc}.input::placeholder,textarea.input::placeholder{color:var(--tg-theme-hint-color);opacity:.8}textarea.input{resize:vertical;min-height:100px}.select{cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");background-position:right 14px center;background-repeat:no-repeat;background-size:18px;padding-right:44px}.budgets-form .form-field:focus-within label{color:var(--tg-theme-button-color);transition:all .2s ease}.card{width:100%;background:var(--surface-primary);border:1px solid var(--card-border);border-radius:var(--radius-lg);padding:clamp(24px,4vw,32px);margin-bottom:var(--space-2xl);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);box-shadow:var(--shadow-medium);transition:transform .3s cubic-bezier(.4,0,.2,1),box-shadow .3s cubic-bezier(.4,0,.2,1);overflow:hidden}.card:hover{box-shadow:var(--shadow-heavy);transform:translateY(-4px)}.loading{display:flex;justify-content:center;align-items:center;padding:80px 20px;font-size:18px;color:var(--tg-theme-hint-color)}.error{color:var(--danger-color);padding:18px 20px;background:linear-gradient(135deg,#f8717126,#ef44441a);border-radius:var(--radius-md);margin-bottom:20px;text-align:center;border:1px solid rgba(248,113,113,.3);font-weight:500}.alert{padding:16px 20px;border-radius:var(--radius-md);font-size:14px;font-weight:500;margin-bottom:16px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.alert-danger{color:var(--danger-color);border:1px solid rgba(248,113,113,.35);background:linear-gradient(135deg,#f8717126,#ef44441a)}.placeholder-card{padding:32px 24px;text-align:center;border-radius:var(--radius-lg);border:2px dashed var(--border-color);color:var(--tg-theme-hint-color);background:var(--surface-muted);font-size:15px;line-height:1.6}.list{list-style:none;width:100%}.list-item{padding:20px 24px;margin-bottom:12px;border-radius:var(--radius-lg);border:1px solid var(--card-border);background:var(--surface-muted);-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);transition:transform .3s cubic-bezier(.4,0,.2,1),box-shadow .3s cubic-bezier(.4,0,.2,1),background .3s cubic-bezier(.4,0,.2,1)}.list-item:hover{background:var(--surface-hover);transform:translateY(-2px);box-shadow:var(--shadow-medium)}.list-item:last-child{margin-bottom:0}.tag{display:inline-flex;align-items:center;gap:var(--space-xs);padding:8px 14px;border-radius:var(--radius-sm);font-size:13px;font-weight:600;background:var(--tg-theme-secondary-bg-color);color:var(--tg-theme-text-color);border:1px solid var(--border-color);margin-right:8px;margin-bottom:8px;-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);transition:all .3s cubic-bezier(.4,0,.2,1)}.tag:hover{transform:translateY(-1px);box-shadow:var(--shadow-light)}.tag.income{background:linear-gradient(135deg,#4ade8033,#22c55e26);color:var(--success-color);border-color:#4ade8080}.tag.expense{background:linear-gradient(135deg,#f8717133,#ef444426);color:var(--danger-color);border-color:#f8717180}@media (max-width: 768px){.tag{font-size:12px;padding:6px 10px}}.budgets-page{display:flex;flex-direction:column;gap:clamp(32px,5vw,40px)}.budgets-hero{display:grid;gap:18px;padding:clamp(32px,6vw,48px) clamp(24px,4vw,40px);border-radius:clamp(20px,4vw,28px);background:var(--surface-primary);border:1px solid var(--card-border);box-shadow:var(--shadow-heavy);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);text-align:center}.budgets-hero h1{font-size:clamp(28px,6vw,48px);font-weight:800;margin:0;line-height:1.1;background:var(--gradient-primary);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text;letter-spacing:-.02em}.budgets-hero p{font-size:clamp(14px,2.5vw,17px);color:var(--tg-theme-hint-color);max-width:700px;margin:0 auto;line-height:1.6}.budgets-panels{display:grid;gap:clamp(32px,5vw,40px);max-width:100%}.budgets-section-title{display:flex;flex-direction:column;gap:8px;margin-bottom:clamp(24px,4vw,32px);padding-bottom:18px;border-bottom:2px solid var(--card-border)}.budgets-section-title h2{font-size:clamp(22px,4vw,32px);font-weight:700;margin:0;line-height:1.2;background:var(--gradient-primary);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text;letter-spacing:-.01em}.budgets-section-title span{font-size:clamp(14px,2.5vw,16px);color:var(--tg-theme-hint-color);font-weight:500;line-height:1.5}.budgets-section-content{display:flex;flex-direction:column;gap:clamp(28px,5vw,36px)}@media (min-width: 1100px){.budgets-section-content{display:grid;grid-template-columns:400px 1fr;gap:clamp(36px,5vw,48px);align-items:start}.budgets-section-content .budgets-form{position:sticky;top:calc(var(--header-height) + 24px);background:var(--surface-muted);padding:clamp(24px,3vw,28px);border-radius:var(--radius-lg);border:1px solid var(--card-border);box-shadow:var(--shadow-medium);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}.budgets-list-section{min-height:400px}}.planned-card{display:grid;grid-template-columns:1fr;gap:clamp(24px,4vw,32px)}@media (min-width: 1100px){.planned-card{display:grid;grid-template-columns:400px 1fr;align-items:start;gap:clamp(36px,5vw,48px)}.planned-card>.budgets-section-title{grid-column:1 / -1}.planned-card>.alert{grid-column:1 / -1}.planned-card>form.budgets-form{grid-column:1;position:sticky;top:calc(var(--header-height) + 24px);background:var(--surface-muted);border:1px solid var(--card-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-medium);padding:clamp(24px,3vw,28px);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}.planned-card>.budgets-subheading,.planned-card>.placeholder-card,.planned-card>.budgets-list{grid-column:2}.planned-card .budgets-list{grid-template-columns:repeat(auto-fit,minmax(340px,1fr));gap:clamp(18px,3vw,24px)}}.budgets-form{display:grid;gap:clamp(24px,4vw,32px)}.budgets-form-grid{display:grid;gap:clamp(16px,3vw,20px)}@media (min-width: 640px){.budgets-form-grid{grid-template-columns:repeat(auto-fit,minmax(220px,1fr))}}.budgets-form-grid--stretch{display:grid;gap:18px}@media (min-width: 768px){.budgets-form-grid--stretch{grid-template-columns:repeat(auto-fit,minmax(240px,1fr))}}.form-field{display:flex;flex-direction:column;gap:clamp(8px,2vw,10px);min-width:0;max-width:100%}.form-field--wide{grid-column:span 2}@media (max-width: 767px){.form-field--wide{grid-column:span 1}}.form-field--full{grid-column:1 / -1}.budgets-form label{font-weight:600;font-size:clamp(14px,2.5vw,15px);letter-spacing:-.01em;color:var(--tg-theme-text-color);margin-bottom:2px}.budgets-form-actions{display:flex;flex-wrap:wrap;gap:clamp(12px,2.5vw,16px);margin-top:clamp(20px,4vw,28px);width:100%}.budgets-form-actions .button{flex:1 1 clamp(160px,25vw,200px);min-width:clamp(140px,20vw,160px)}@media (max-width: 767px){.budgets-form-actions{flex-direction:column;gap:12px}.budgets-form-actions .button{width:100%;font-size:16px}}.budgets-hint{font-size:13px;color:var(--tg-theme-hint-color);line-height:1.5}.budgets-list{display:grid;gap:clamp(18px,3vw,24px)}@media (min-width: 500px){.budgets-list{grid-template-columns:repeat(auto-fit,minmax(300px,1fr))}}@media (min-width: 900px){.budgets-list{grid-template-columns:repeat(auto-fit,minmax(340px,1fr))}}.budget-card{display:flex;flex-direction:column;gap:clamp(14px,2.5vw,18px);padding:clamp(22px,4vw,28px);border-radius:var(--radius-lg);background:var(--surface-primary);border:1px solid var(--card-border);box-shadow:var(--shadow-medium);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);transition:all .3s cubic-bezier(.4,0,.2,1)}.budget-card:hover{transform:translateY(-4px);box-shadow:var(--shadow-heavy);border-color:#94a3b84d}.budget-card-header{display:flex;justify-content:space-between;gap:clamp(14px,3vw,18px);align-items:flex-start;flex-wrap:wrap}.budget-card-meta{display:flex;flex-direction:column;gap:8px;min-width:0;flex:1}.budget-card-title{font-size:clamp(18px,3.5vw,22px);font-weight:700;color:var(--tg-theme-text-color);line-height:1.3;word-break:break-word;letter-spacing:-.01em}.budget-card-meta span{font-size:clamp(13px,2.2vw,15px);line-height:1.5;color:var(--tg-theme-hint-color)}.budget-card-actions{display:flex;flex-wrap:wrap;gap:clamp(8px,2vw,12px);align-items:center;justify-content:flex-end}.budget-card-actions .button{padding:clamp(10px,2vw,12px) clamp(16px,3vw,20px);font-size:clamp(13px,2.2vw,14px);min-height:40px;min-width:80px}@media (max-width: 767px){.budget-card-actions{flex-direction:column;width:100%;gap:10px}.budget-card-actions .button{width:100%;min-height:44px;font-size:14px}}.budget-card-note{font-size:clamp(13px,2.3vw,14px);color:var(--tg-theme-hint-color);background:var(--surface-muted);padding:clamp(12px,2.5vw,16px) clamp(16px,3vw,20px);border-radius:var(--radius-md);border:1px solid var(--card-border);line-height:1.6;margin:clamp(10px,2vw,14px) 0}.budget-card-amounts{display:grid;gap:clamp(14px,2.5vw,18px);margin-top:6px}@media (min-width: 400px){.budget-card-amounts{grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}}@media (min-width: 600px){.budget-card-amounts{grid-template-columns:repeat(auto-fit,minmax(170px,1fr))}}.budget-card-amounts>div{display:flex;flex-direction:column;gap:clamp(6px,1.5vw,8px);padding:clamp(14px,2.5vw,18px);background:var(--surface-muted);border-radius:var(--radius-md);border:1px solid var(--card-border);transition:all .3s cubic-bezier(.4,0,.2,1);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}.budget-card:hover .budget-card-amounts>div{transform:translateY(-2px);box-shadow:var(--shadow-light);border-color:#94a3b84d}.budget-card-label{font-size:clamp(11px,2vw,12px);font-weight:700;letter-spacing:.05em;text-transform:uppercase;color:var(--tg-theme-hint-color);margin-bottom:2px}.budget-card-value{font-size:clamp(16px,3vw,20px);font-weight:700;color:var(--tg-theme-text-color);line-height:1.2;text-align:right;font-variant-numeric:tabular-nums;letter-spacing:-.01em}.budget-card-status{margin-left:auto;font-size:clamp(11px,2vw,12px);font-weight:700;line-height:1.2;white-space:nowrap;border-radius:clamp(8px,1.5vw,10px);padding:clamp(6px,1.2vw,8px) clamp(10px,2vw,14px);border:1px solid rgba(0,0,0,.06);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);justify-self:end;align-self:center;text-transform:uppercase;letter-spacing:.06em}.budget-card-status.over_budget{background:linear-gradient(135deg,#f8717133,#ef444426);border:1px solid rgba(248,113,113,.4);color:var(--danger-color)}.budget-card-status.under_budget,.budget-card-status.on_track,.budget-card-status.above_target{background:linear-gradient(135deg,#4ade8033,#22c55e26);border:1px solid rgba(74,222,128,.4);color:var(--success-color)}.budget-card-status.below_target{background:linear-gradient(135deg,#f59e0b33,#fbbf2426);border:1px solid rgba(245,158,11,.4);color:var(--warning-color)}.budgets-progress{display:flex;flex-direction:column;gap:clamp(10px,2vw,14px);margin-top:clamp(14px,2.5vw,18px)}.budgets-progress-header{display:flex;justify-content:space-between;flex-wrap:wrap;gap:6px;font-size:clamp(12px,2.2vw,13px);font-weight:600;color:var(--tg-theme-hint-color)}.budgets-progress-track{position:relative;height:clamp(10px,2vw,14px);border-radius:999px;background:var(--tg-theme-secondary-bg-color);border:1px solid var(--card-border);box-shadow:inset 0 2px 4px #00000026;overflow:hidden}.budgets-progress-fill{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:inherit;box-shadow:0 0 12px #0000004d;transition:width .8s cubic-bezier(.4,0,.2,1)}.budgets-subheading{margin-bottom:clamp(18px,3vw,24px);font-size:clamp(20px,3.5vw,24px);font-weight:700;line-height:1.3;color:var(--tg-theme-text-color);letter-spacing:-.01em}@media (max-width: 767px){.budgets-hero{padding:clamp(24px,5vw,32px) clamp(20px,4vw,28px);border-radius:var(--radius-lg)}.budgets-form-grid,.budgets-form-grid--stretch{grid-template-columns:1fr!important;gap:clamp(14px,3vw,18px)}.input,.select,textarea.input{max-width:100%;font-size:16px}.card,.planned-card{overflow-x:hidden}}.transaction-filters{display:flex;flex-wrap:wrap;gap:16px;align-items:center;padding:20px;background:var(--surface-muted);border-radius:var(--radius-lg);border:1px solid var(--card-border);margin-bottom:24px}@media (max-width: 768px){.transaction-filters{flex-direction:column!important;align-items:stretch!important;gap:12px!important}.transaction-filters>div{width:100%!important;display:flex!important;flex-direction:column!important;gap:12px!important}.transaction-filters select,.transaction-filters input[type=date]{width:100%!important;flex:1!important}.transaction-filters button{margin:0!important;width:100%!important}}.subscription-buttons{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end;align-items:center}@media (max-width: 480px){.subscription-buttons{flex-direction:column;align-items:stretch;gap:10px}.subscription-buttons .button{width:100%;min-width:auto!important}}@keyframes fadeIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes slideIn{0%{opacity:0;transform:translate(-20px)}to{opacity:1;transform:translate(0)}}.budget-card,.list-item{animation:fadeIn .4s ease-out}.budgets-list>.budget-card:nth-child(1){animation-delay:.05s}.budgets-list>.budget-card:nth-child(2){animation-delay:.1s}.budgets-list>.budget-card:nth-child(3){animation-delay:.15s}.budgets-list>.budget-card:nth-child(4){animation-delay:.2s}.budgets-list>.budget-card:nth-child(5){animation-delay:.25s}.budgets-list>.budget-card:nth-child(6){animation-delay:.3s}*:focus-visible{outline:3px solid var(--tg-theme-button-color);outline-offset:2px;border-radius:var(--radius-sm)}html{scroll-behavior:smooth}::selection{background-color:#4a9eff4d;color:var(--tg-theme-text-color)}.text-center{text-align:center}.text-right{text-align:right}.text-left{text-align:left}.mb-0{margin-bottom:0}.mb-1{margin-bottom:var(--space-sm)}.mb-2{margin-bottom:var(--space-md)}.mb-3{margin-bottom:var(--space-lg)}.mb-4{margin-bottom:var(--space-xl)}.mt-0{margin-top:0}.mt-1{margin-top:var(--space-sm)}.mt-2{margin-top:var(--space-md)}.mt-3{margin-top:var(--space-lg)}.mt-4{margin-top:var(--space-xl)}.flex{display:flex}.flex-column{flex-direction:column}.items-center{align-items:center}.justify-between{justify-content:space-between}.gap-sm{gap:var(--space-sm)}.gap-md{gap:var(--space-md)}.gap-lg{gap:var(--space-lg)}.w-full{width:100%}.hidden{display:none}@media print{.header,.button,.nav-menu,.budget-card-actions{display:none}.card,.budget-card{break-inside:avoid;box-shadow:none;border:1px solid #ccc}body{background:#fff;color:#000}}@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}@media (prefers-contrast: high){.card,.budget-card,.button{border-width:2px}.input:focus,.select:focus,textarea.input:focus{outline:3px solid currentColor;outline-offset:2px}}@media (prefers-color-scheme: dark){:root{--shadow-light: 0 2px 12px rgba(0, 0, 0, .3);--shadow-medium: 0 4px 20px rgba(0, 0, 0, .4);--shadow-heavy: 0 8px 40px rgba(0, 0, 0, .5)}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.budgets-layout{display:grid;gap:clamp(24px,3vw,32px)}@media (min-width: 1100px){.budgets-layout{grid-template-columns:1fr 1fr;align-items:start}}.budgets-column{display:flex;flex-direction:column;gap:clamp(24px,3vw,32px);min-width:0}.budgets-header{display:flex;flex-direction:column;gap:16px}@media (min-width: 768px){.budgets-header{flex-direction:row;justify-content:space-between;align-items:flex-start}}.budgets-header-main{display:flex;flex-direction:column;gap:8px;min-width:0}.budgets-header-title{font-size:clamp(20px,2vw,24px);font-weight:600;color:var(--tg-theme-text-color);line-height:1.2}.budgets-header-desc{font-size:14px;line-height:1.4;color:var(--tg-theme-hint-color);max-width:480px}.budgets-stats{display:flex;flex-wrap:wrap;gap:12px}.stat-card{background:var(--surface-muted);border:1px solid var(--card-border);border-radius:var(--radius-md);box-shadow:var(--shadow-light);padding:12px 16px;min-width:120px;display:flex;flex-direction:column;gap:4px}.stat-label{font-size:12px;font-weight:600;color:var(--tg-theme-hint-color);text-transform:uppercase;letter-spacing:.05em}.stat-value{font-size:16px;font-weight:600;color:var(--tg-theme-text-color);line-height:1.2;font-variant-numeric:tabular-nums}.budgets-card{display:flex;flex-direction:column;gap:clamp(16px,2vw,20px)}.budgets-card-body{display:grid;gap:clamp(24px,3vw,32px)}@media (min-width: 1100px){.budgets-card-body{grid-template-columns:minmax(260px,320px) 1fr;align-items:start}.budgets-form-panel{position:sticky;top:calc(var(--header-height) + 24px)}}.budgets-form-panel{background:var(--surface-muted);border:1px solid var(--card-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-medium);padding:clamp(20px,2vw,24px);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}.planned-card{background:var(--surface-primary);border:1px solid var(--card-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-medium);padding:clamp(20px,2vw,24px);display:flex;flex-direction:column;gap:clamp(24px,3vw,32px)}.planned-header-bar{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:16px;border-bottom:1px solid var(--card-border);padding-bottom:16px}.planned-header-copy{display:flex;flex-direction:column;gap:6px;min-width:0}.planned-title{font-size:clamp(18px,2vw,20px);font-weight:600;line-height:1.3;color:var(--tg-theme-text-color)}.planned-desc{font-size:13px;line-height:1.4;color:var(--tg-theme-hint-color);max-width:480px}.planned-header-actions{display:flex;flex-shrink:0;align-items:center}.plan-cards-grid{display:grid;gap:clamp(16px,2vw,24px)}@media (min-width: 768px){.plan-cards-grid{grid-template-columns:repeat(auto-fit,minmax(360px,1fr))}}.plan-card{background:var(--surface-primary);border:1px solid var(--card-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-light);padding:clamp(16px,2vw,24px);display:flex;flex-direction:column;gap:16px;-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);transition:box-shadow .2s ease,transform .2s ease}.plan-card:hover{transform:translateY(-2px);box-shadow:var(--shadow-medium)}.plan-card-header{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:12px}.plan-card-meta{display:flex;flex-direction:column;min-width:0;gap:6px}.plan-card-title{font-size:14px;font-weight:600;color:var(--tg-theme-text-color);line-height:1.4}.plan-card-dates{font-size:11px;line-height:1.4;color:var(--tg-theme-hint-color);font-variant-numeric:tabular-nums}.plan-card-actions{display:flex;flex-wrap:wrap;gap:6px}.plan-card-action-btn{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:1px solid var(--card-border);background:var(--surface-muted);color:var(--tg-theme-text-color);font-size:12px;line-height:1.2;font-weight:600;border-radius:var(--radius-sm);padding:6px 10px;box-shadow:var(--shadow-light);cursor:pointer;min-width:auto}.plan-card-action-btn.danger{background:linear-gradient(135deg,#f87171,#ef4444);border:1px solid rgba(248,113,113,.45);color:#fff}.plan-card-note{font-size:12px;line-height:1.4;color:var(--tg-theme-hint-color);background:var(--surface-muted);border:1px solid var(--card-border);border-radius:var(--radius-md);padding:12px 16px}.plan-stats-row{display:flex;flex-wrap:wrap;gap:12px;align-items:flex-start}.plan-stat-box{flex:1 1 140px;min-width:0;background:var(--surface-muted);border:1px solid var(--card-border);border-radius:var(--radius-md);padding:12px 16px;display:flex;flex-direction:column;gap:6px}.plan-stat-label{font-size:10px;font-weight:600;color:var(--tg-theme-hint-color);letter-spacing:.05em;text-transform:uppercase}.plan-stat-value{font-size:14px;font-weight:600;color:var(--tg-theme-text-color);line-height:1.3;font-variant-numeric:tabular-nums}.plan-status-pill{align-self:flex-start;border-radius:var(--radius-md);padding:8px 12px;font-size:11px;font-weight:700;line-height:1.2;text-transform:uppercase;letter-spacing:.05em;white-space:nowrap;border:1px solid rgba(0,0,0,.06);min-width:max-content;background:var(--surface-muted);box-shadow:var(--shadow-light)}.plan-status-pill.over_budget{background:#f8717126;border-color:#f8717166;color:var(--danger-color)}.plan-status-pill.under_budget,.plan-status-pill.on_track,.plan-status-pill.above_target{background:#4ade8026;border-color:#4ade8066;color:var(--success-color)}.plan-status-pill.below_target{background:#f59e0b26;border-color:#f59e0b66;color:var(--warning-color, #f59e0b)}.plan-progress{display:flex;flex-direction:column;gap:10px}.plan-progress-header{display:flex;justify-content:space-between;flex-wrap:wrap;gap:6px;font-size:11px;line-height:1.3;font-weight:600;color:var(--tg-theme-hint-color)}.plan-progress-track{position:relative;width:100%;height:8px;border-radius:999px;background:var(--tg-theme-secondary-bg-color);border:1px solid var(--card-border);box-shadow:inset 0 2px 4px #00000026;overflow:hidden}.plan-progress-fill{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:inherit;box-shadow:0 0 12px #0000004d;transition:width .4s ease}.plan-modal-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:#00000080;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);display:flex;align-items:flex-start;justify-content:center;padding:24px;overflow-y:auto;z-index:1000}.plan-modal-card{background:var(--surface-primary);border:1px solid var(--card-border);border-radius:var(--radius-lg);box-shadow:var(--shadow-heavy);width:100%;max-width:420px;padding:24px;display:flex;flex-direction:column;gap:16px;-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px)}.plan-modal-header{display:flex;justify-content:space-between;align-items:flex-start;gap:16px}.plan-modal-close{min-width:auto;min-height:auto;padding:8px 12px;font-size:14px;line-height:1.2}:root{--sidebar-width: 280px;--header-height: 80px}.main-layout{display:flex;flex-direction:column;flex:1;min-height:calc(100vh - var(--header-height));width:100%;min-width:0}.sidebar{position:fixed;top:var(--header-height);left:0;width:var(--sidebar-width);height:calc(100vh - var(--header-height));transform:translate(-100%);transition:transform .3s ease;z-index:1000;background:var(--sidebar-bg);border-right:1px solid var(--border-color);box-shadow:var(--shadow-heavy);padding:24px 0;overflow-y:auto;min-width:0}.sidebar.sidebar-open{transform:translate(0)}.mobile-menu-toggle{display:flex!important;background:none;border:none;color:var(--tg-theme-text-color);font-size:20px;cursor:pointer;padding:8px;border-radius:8px;margin-right:12px;transition:all .2s ease}.mobile-menu-toggle:hover{background-color:var(--sidebar-hover)}.mobile-menu-overlay{position:fixed;top:0;left:0;right:0;bottom:0;background-color:#00000080;z-index:999}.content-area{flex:1;background:var(--tg-theme-bg-color);overflow-y:auto;width:100%;min-width:0;display:block}.page-container{width:100%;min-width:0;max-width:100%;padding:20px 16px;margin:0;box-sizing:border-box}@media (min-width: 769px){.main-layout{flex-direction:row;align-items:stretch}.sidebar{position:relative;top:0;left:0;height:auto;transform:none;transition:none;box-shadow:var(--shadow-medium);flex-shrink:0;width:var(--sidebar-width);min-height:calc(100vh - var(--header-height));border-right:1px solid var(--border-color)}.sidebar.sidebar-open{transform:none}.mobile-menu-toggle{display:none!important}.mobile-menu-overlay{display:none}.content-area{flex:1 1 auto;min-width:0;width:100%;max-width:100%;display:block;overflow-x:hidden;background:var(--tg-theme-bg-color)}.page-container{width:100%;max-width:100%;min-width:0;padding:32px 24px;margin:0;box-sizing:border-box}}
