*{box-sizing:border-box}:root{font-family:Inter,Segoe UI,system-ui,-apple-system,sans-serif;line-height:1.5;font-weight:400;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}body{margin:0}a{color:inherit}button,input,select,textarea{font:inherit}:root{--bg: #ffffff;--bg-alt: #f7f7f8;--muted: #e5e7eb;--text: #1f2937;--subtle: #6b7280;--primary: #374151;--primary-contrast: #ffffff;--accent: #111827;color:var(--text);background-color:var(--bg-alt)}body{background-color:var(--bg-alt);color:var(--text);min-height:100vh}a{text-decoration:none}.page{min-height:100vh;display:flex;flex-direction:column}main{flex:1;padding:1.5rem clamp(1rem,2vw,3rem) 3rem}.app-header{position:sticky;top:0;z-index:40;display:flex;flex-direction:column;padding:.75rem clamp(1rem,2vw,3rem);background:var(--bg);border-bottom:1px solid var(--muted);box-shadow:0 1px 8px #1118270d}.header-top{display:flex;align-items:center;justify-content:center;margin-bottom:.75rem}.header-bottom{display:flex;align-items:center;justify-content:center}.app-header .brand{display:flex;align-items:center;gap:.75rem;justify-content:center}.app-header .logo{display:inline-flex;align-items:center;justify-content:center;width:2.5rem;height:2.5rem;border-radius:.75rem;background:var(--primary);color:var(--primary-contrast);font-size:1.25rem}.app-header h1{margin:0;font-size:clamp(1.25rem,vw + 1rem,1.5rem);font-weight:600}.header-actions{display:flex;align-items:center;gap:1rem;width:100%;max-width:600px}.header-left{display:flex;align-items:center;gap:1rem}.header-spacer{flex:1}.header-right{display:flex;align-items:center;gap:1rem}.update-toast{display:flex;align-items:center;gap:.5rem;padding:.5rem .75rem;background:var(--muted);border-radius:999px;font-size:.875rem}.header-actions button{border:none;background:none;cursor:pointer;font-size:.875rem}button.primary{background:var(--primary);color:var(--primary-contrast);border:none;padding:.6rem 1.25rem;border-radius:.6rem;font-weight:600;cursor:pointer;transition:transform .15s ease,box-shadow .15s ease}button.primary:disabled{opacity:.5;cursor:not-allowed}button.primary:not(:disabled):hover{transform:translateY(-1px);box-shadow:0 8px 16px #37415126}button.ghost{border:none;background:transparent;color:var(--text);cursor:pointer;padding:.4rem .75rem;border-radius:.5rem;font-weight:500}button.ghost:hover{background:#37415114}button.ghost:disabled{opacity:.6;cursor:not-allowed}button.danger{background:#dc2626;color:#fff;border:none;padding:.4rem .75rem;border-radius:.5rem;font-weight:500;cursor:pointer}button.danger:hover{background:#b91c1c}button.danger:disabled{opacity:.5;cursor:not-allowed}button.cart{position:relative;font-size:1.75rem;padding:.25rem}button.cart .badge{position:absolute;top:-.3rem;right:-.3rem;background:#ef4444;color:#fff;border-radius:999px;padding:0 .45rem;font-size:.7rem;line-height:1.5;font-weight:600}.profile{position:relative}.profile-button{display:flex;align-items:center;gap:.5rem}.profile-button .avatar{width:2rem;height:2rem;border-radius:999px;background:var(--primary);color:var(--primary-contrast);display:grid;place-items:center;font-weight:600}.profile-menu{position:absolute;right:0;top:100%;margin-top:.5rem;background:var(--bg);border:1px solid var(--muted);border-radius:.75rem;min-width:12rem;box-shadow:0 12px 24px #1118272e;list-style:none;padding:.5rem 0;z-index:50}.profile-menu li{margin:0}.profile-menu button{width:100%;text-align:left;padding:.6rem 1rem;background:transparent;border:none;cursor:pointer}.profile-menu button:hover{background:#37415114}.search-bar{background:var(--bg);border-radius:1rem;padding:.75rem;display:flex;flex-direction:column;gap:.75rem;box-shadow:0 12px 24px #1118270d}.search-input-group{display:flex;gap:.5rem;align-items:center}.search-input-group .search-input{position:relative;display:flex;align-items:center;flex:1}.search-input-group .search-input input[type=search]{width:100%;border:2px solid var(--muted);border-radius:1rem;padding:.75rem 1rem .75rem 3rem;font-size:1rem;background:var(--bg);transition:all .2s ease;box-shadow:0 2px 4px #1118270d}.search-input-group .search-input input[type=search]:focus{outline:none;border-color:var(--primary);box-shadow:0 0 0 3px #3741511a}.search-input-group .search-input input[type=search]::placeholder{color:var(--subtle);opacity:.7}.search-input-group .search-input svg{position:absolute;left:.875rem;color:var(--subtle);pointer-events:none;width:1.25rem;height:1.25rem;transition:color .2s ease;z-index:1}.search-input-group .search-input input[type=search]:focus+svg{color:var(--primary)}.search-filters{display:flex;gap:.75rem;align-items:center;flex-direction:row}.filter{display:flex;flex-direction:row;align-items:center;gap:.5rem;font-size:.8rem;color:var(--subtle);width:auto}.filter.toggle{flex-direction:row;align-items:center;gap:.5rem}.filter select,.filter input[type=checkbox]{margin:0}.filter select{border:1px solid var(--muted);border-radius:.75rem;padding:.5rem .75rem;background:var(--bg)}.catalog-layout{display:grid;grid-template-columns:minmax(16rem,20rem) 1fr;gap:1.5rem;margin-top:1.5rem}.catalog-sidebar{background:var(--bg);border-radius:1rem;padding:1rem;box-shadow:0 12px 24px #1118270d}.category-tree{display:flex;flex-direction:column;gap:.5rem}.category-tree .link{width:100%;justify-content:space-between;display:inline-flex;align-items:center}.category-tree .link.active{background:#3741511f;color:var(--accent);font-weight:600}.category-tree ul{list-style:none;padding-left:1.25rem;margin:.25rem 0 0;border-left:1px solid var(--muted)}.category-item{display:flex;align-items:center;gap:.35rem}.category-item .toggle{width:1.8rem;height:1.8rem;border-radius:.5rem;background:var(--bg-alt);font-weight:700}.category-item .toggle.placeholder{background:transparent}.category-item .count{display:inline-flex;align-items:center;justify-content:center;min-width:2rem;margin-left:.5rem;background:var(--bg-alt);border-radius:999px;padding:0 .45rem;font-size:.75rem}.catalog-grid .grid{display:grid;gap:1.5rem;grid-template-columns:repeat(auto-fill,minmax(16rem,1fr))}.product-card{background:var(--bg);border-radius:1rem;overflow:hidden;display:flex;flex-direction:column;box-shadow:0 14px 28px #1118270f;transition:transform .2s ease,box-shadow .2s ease}.product-card:hover{transform:translateY(-4px);box-shadow:0 20px 40px #1118271a}.product-image{height:180px;background:var(--bg-alt);display:flex;align-items:center;justify-content:center;overflow:hidden}.product-image img{max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain;border-radius:.5rem}.image-placeholder{font-size:2.5rem;font-weight:600;color:var(--subtle)}.product-content{flex:1;display:flex;flex-direction:column;padding:1rem 1.25rem 1.25rem;gap:.75rem}.product-header{display:flex;flex-direction:column;gap:.25rem}.product-meta{color:var(--subtle);font-size:.85rem;margin:0}.product-tags{display:flex;flex-wrap:wrap;gap:.35rem;font-size:.75rem}.product-tags span{background:var(--bg-alt);padding:.2rem .5rem;border-radius:.6rem}.product-footer{display:flex;justify-content:space-between;align-items:flex-end;gap:1rem;margin-top:auto}.product-price-stock{display:flex;flex-direction:column;gap:.25rem}.product-header h3{margin:0;font-size:1.1rem;font-weight:600;line-height:1.3}.product-price-stock .price{font-size:1.1rem;font-weight:600;display:flex;align-items:baseline;gap:.35rem;margin:0}.product-price-stock .unit{font-size:.85rem;color:var(--subtle)}.product-price-stock .stock{font-size:.85rem;color:var(--subtle);margin:0}mark.highlight{background:#fef08a;padding:0 .1em}.product-actions{display:flex;flex-direction:column;align-items:flex-start;gap:.75rem;max-width:10rem}.product-actions .quantity{display:inline-flex;align-items:center;border:1px solid var(--muted);border-radius:.75rem;overflow:hidden;width:auto;max-width:8rem}.product-actions .quantity input{width:3rem;text-align:center;border:none;padding:.35rem}.product-actions .quantity button{flex-shrink:0;width:2.2rem;height:2.2rem;border:none;background:var(--bg-alt);font-size:1.2rem;display:flex;align-items:center;justify-content:center}.cart-drawer{position:fixed;top:0;right:0;bottom:0;left:0;background:#11182759;display:none;z-index:100}.cart-drawer.open{display:block}.cart-panel{position:absolute;right:0;top:0;height:100%;width:min(420px,90vw);background:var(--bg);display:flex;flex-direction:column;padding:1.25rem;gap:1rem;box-shadow:-12px 0 24px #1118271a}.cart-panel header{display:flex;align-items:center;justify-content:space-between}.cart-panel header button{font-size:1.5rem;width:2rem;height:2rem;display:flex;align-items:center;justify-content:center;border-radius:50%}.cart-list{flex:1;overflow-y:auto;margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:1rem}.cart-list li{border:1px solid var(--muted);border-radius:.85rem;padding:.75rem}.item-header{display:flex;align-items:center;justify-content:space-between;gap:.75rem}.item-body{margin-top:.75rem;display:flex;justify-content:space-between;gap:.75rem;flex-wrap:wrap}.item-body .quantity{border:1px solid var(--muted);border-radius:.75rem;display:inline-flex;align-items:center;overflow:hidden}.item-body .quantity button{width:2rem;height:2rem;border:none;background:var(--bg-alt);font-size:1.1rem}.item-body .quantity input{width:3rem;border:none;text-align:center}.pricing{display:flex;flex-direction:column;align-items:flex-end;gap:.25rem;font-size:.9rem}.pricing .sum{font-weight:600}.pricing .stock.warning{color:#dc2626}.note{padding:1rem 0;margin:1rem 0}.note label{display:block;margin-bottom:.5rem;font-weight:600}.note textarea{width:100%;border:1px solid var(--muted);border-radius:.75rem;padding:.65rem;resize:vertical}.item-header button.ghost{color:#dc2626;border-color:#dc2626}.item-header button.ghost:hover{background-color:#dc2626;color:#fff}.form-error{color:#dc2626;font-size:.9rem}.route-loading{padding:2rem;text-align:center;color:var(--subtle)}.success{color:#16a34a}.summary{display:flex;justify-content:space-between;align-items:baseline;font-size:1.1rem}.actions{display:flex;justify-content:space-between;align-items:center;width:100%;padding-top:1.5rem}.actions button:first-child{margin-left:0;padding-left:0}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.auth-page,.admin-login,.admin-import,.order-page{background:var(--bg-alt)}.order-header-card,.order-footer-card{background:var(--bg);border-radius:1rem;padding:2rem;margin:1.5rem auto;box-shadow:0 12px 24px #1118270d;border:1px solid var(--muted);max-width:800px}.order-header-content{display:flex;justify-content:space-between;align-items:flex-start;gap:2rem}.order-id-section h2{margin:0 0 .5rem;font-size:1.5rem;font-weight:600;color:var(--text)}.order-id-section .muted{margin:0;color:var(--subtle);font-size:.9rem}.order-info-section{text-align:right}.order-info-section .muted{margin:.25rem 0;color:var(--subtle);font-size:.9rem}.order-items-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(350px,1fr));gap:1.5rem;margin:1.5rem auto;max-width:1200px}.order-item-card{background:var(--bg);border-radius:1rem;padding:1.5rem;box-shadow:0 12px 24px #1118270d;border:1px solid var(--muted);transition:box-shadow .2s ease,transform .2s ease}.order-item-card:hover{box-shadow:0 20px 40px #11182714;transform:translateY(-2px)}.order-item-header{display:flex;align-items:center;gap:1rem;margin-bottom:1rem}.item-number{width:2.5rem;height:2.5rem;border-radius:50%;background:var(--primary);color:var(--primary-contrast);display:flex;align-items:center;justify-content:center;font-weight:600;font-size:1rem;flex-shrink:0}.item-name{font-size:1.1rem;font-weight:600;color:var(--text);flex:1}.order-item-details{display:flex;flex-direction:column;gap:.5rem}.detail-row{display:flex;justify-content:space-between;align-items:center;font-size:.9rem}.detail-row .label{color:var(--subtle);font-weight:500}.detail-row.total-row{margin-top:.5rem;padding-top:.5rem;border-top:1px solid var(--muted)}.detail-row.total-row .label{font-weight:600;color:var(--text)}.sum-value{font-weight:600;color:var(--primary)}.order-footer-card{display:flex;justify-content:space-between;align-items:center;gap:2rem}.order-total .total{margin:0;font-size:1.2rem;font-weight:600;color:var(--text)}.order-total .total strong{color:var(--primary)}@media (max-width: 680px){.order-header-content{flex-direction:column;gap:1rem}.order-info-section{text-align:left}.order-items-grid{grid-template-columns:1fr}.order-footer-card{flex-direction:column;align-items:stretch;gap:1rem}.export-buttons{text-align:center}}.excel-button{background:var(--primary)!important;color:var(--primary-contrast)!important}.auth-card h1{margin-top:0}.auth-page main{display:flex;justify-content:center;align-items:flex-start;padding-top:2rem}.auth-page .admin-form h2{text-align:center}.admin-link{background:none;border:none;color:var(--subtle);font-size:.9rem;padding:.75rem;margin-top:1rem;cursor:pointer;text-align:center;border-radius:.5rem;transition:color .2s}.admin-link:hover{color:var(--text);background:var(--bg-alt)}.admin-nav{display:flex;gap:1rem;margin-bottom:2rem;justify-content:center}.admin-nav button{background:var(--bg);border:1px solid var(--muted);padding:.75rem 1.5rem;border-radius:.75rem;font-weight:500;cursor:pointer;transition:background .2s}.admin-nav button.active{background:var(--primary);color:var(--primary-contrast)}.admin-nav button:hover:not(.active){background:var(--bg-alt)}.form-field label input[type=checkbox]{margin-right:.5rem}.phone-form{display:flex;flex-direction:column;gap:1rem}.form-field{display:flex;flex-direction:column;gap:.4rem}.form-field input,.form-field textarea{border:1px solid var(--muted);border-radius:.75rem;padding:.65rem .75rem}.form-help{font-size:.8rem;color:var(--subtle);margin:0}.dropzone{border:2px dashed var(--muted);border-radius:1rem;padding:2rem;text-align:center;background:var(--bg)}.dropzone input[type=file]{display:none}.table-wrapper{overflow-x:auto}.table-wrapper table,.order-details table,.preview table{width:100%;border-collapse:collapse}table th,table td{border:1px solid var(--muted);padding:.6rem .75rem;text-align:left;font-size:.9rem}table th{background:var(--bg-alt);font-weight:600}@media (max-width: 960px){.catalog-layout{grid-template-columns:1fr}.catalog-sidebar{order:2}.search-bar{order:1;display:flex;flex-wrap:wrap;align-items:flex-start}}.users-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(320px,1fr));gap:2rem;margin-top:2rem}.user-card{background:linear-gradient(135deg,var(--bg) 0%,var(--bg-alt) 100%);border-radius:1.25rem;padding:2rem;box-shadow:0 16px 32px #11182714,0 4px 8px #1118270a;border:1px solid var(--muted);transition:all .3s cubic-bezier(.4,0,.2,1);position:relative;overflow:hidden}.user-card:before{content:"";position:absolute;top:0;left:0;right:0;height:4px;background:linear-gradient(90deg,var(--primary) 0%,var(--accent) 100%);opacity:0;transition:opacity .3s ease}.user-card:hover{box-shadow:0 24px 48px #1118271f,0 8px 16px #1118270f;transform:translateY(-4px) scale(1.02)}.user-card:hover:before{opacity:1}.user-header{display:flex;align-items:center;gap:1.5rem;margin-bottom:1.5rem}.user-avatar{width:4rem;height:4rem;border-radius:50%;background:linear-gradient(135deg,var(--primary) 0%,var(--accent) 100%);color:var(--primary-contrast);display:flex;align-items:center;justify-content:center;font-weight:700;font-size:1.4rem;flex-shrink:0;box-shadow:0 4px 12px #37415133;transition:transform .3s ease}.user-card:hover .user-avatar{transform:scale(1.1)}.user-info{flex:1;min-width:0}.user-info h3{margin:0 0 .25rem;font-size:1.1rem;font-weight:600;color:var(--text)}.user-info .user-phone{margin:0;color:var(--subtle);font-size:.9rem}.admin-badge{background:linear-gradient(135deg,var(--accent) 0%,#1e293b 100%);color:var(--primary-contrast);padding:.375rem 1rem;border-radius:999px;font-size:.8rem;font-weight:700;text-transform:uppercase;letter-spacing:.05em;box-shadow:0 2px 8px #1e293b4d;border:1px solid rgba(255,255,255,.1)}.user-details{margin-bottom:1rem}.user-details p{margin:.25rem 0;font-size:.9rem;color:var(--subtle)}.user-details strong{color:var(--text)}.user-actions{display:flex;gap:.75rem;flex-wrap:wrap}.action-btn{display:inline-flex;align-items:center;gap:.5rem;padding:.75rem 1.25rem;border:1px solid var(--muted);border-radius:.75rem;background:var(--bg);color:var(--text);font-size:.9rem;font-weight:600;cursor:pointer;transition:all .3s cubic-bezier(.4,0,.2,1);box-shadow:0 2px 4px #1118270d;position:relative;overflow:hidden}.action-btn:before{content:"";position:absolute;top:0;left:-100%;width:100%;height:100%;background:linear-gradient(90deg,transparent,rgba(55,65,81,.1),transparent);transition:left .5s ease}.action-btn:hover:not(:disabled){background:var(--bg-alt);border-color:var(--primary);color:var(--primary);transform:translateY(-1px);box-shadow:0 4px 12px #37415126}.action-btn:hover:not(:disabled):before{left:100%}.action-btn:disabled{opacity:.5;cursor:not-allowed;transform:none}.edit-btn:hover:not(:disabled){border-color:#16a34a;color:#16a34a}.delete-btn:hover:not(:disabled){border-color:#dc2626;color:#dc2626}.action-btn svg{flex-shrink:0}.create-user-btn{display:inline-flex;align-items:center;gap:.5rem;background:linear-gradient(135deg,var(--primary) 0%,var(--accent) 100%);color:var(--primary-contrast);border:none;padding:.875rem 1.5rem;border-radius:.75rem;font-weight:600;font-size:1rem;box-shadow:0 4px 12px #37415133;transition:all .3s cubic-bezier(.4,0,.2,1)}.create-user-btn:hover{transform:translateY(-2px);box-shadow:0 8px 20px #3741514d}.create-user-btn:active{transform:translateY(0)}.user-form-card{margin-top:3rem;animation:slideIn .4s cubic-bezier(.4,0,.2,1)}.form-card{background:var(--bg);border-radius:1rem;padding:2rem;box-shadow:0 20px 40px #11182714;border:1px solid var(--muted);max-width:500px;margin:0 auto}.form-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:1.5rem}.form-header h3{margin:0;font-size:1.25rem;font-weight:600;color:var(--text)}.close-btn{background:none;border:none;color:var(--subtle);cursor:pointer;padding:.25rem;border-radius:.5rem;transition:color .2s ease,background .2s ease}.close-btn:hover{color:var(--text);background:var(--bg-alt)}@keyframes slideIn{0%{opacity:0;transform:translateY(-20px) scale(.95)}to{opacity:1;transform:translateY(0) scale(1)}}.users-controls{display:flex;justify-content:space-between;align-items:flex-start;gap:2rem;margin-bottom:2.5rem;flex-wrap:wrap;padding:1.5rem;background:linear-gradient(135deg,var(--bg) 0%,var(--bg-alt) 100%);border-radius:1rem;box-shadow:0 8px 16px #1118270f;border:1px solid var(--muted)}.search-filters{display:flex;flex-direction:row;gap:1rem;flex:1;min-width:250px;padding-left:1rem}.search-input{position:relative;display:flex;align-items:center}.search-input input{width:100%;padding:.875rem 1rem .875rem 3rem;border:2px solid var(--muted);border-radius:1rem;font-size:1rem;background:var(--bg);transition:all .2s ease;box-shadow:0 2px 4px #1118270d}.search-input input:focus{outline:none;border-color:var(--primary);box-shadow:0 0 0 3px #3741511a;background:var(--bg)}.search-input input::placeholder{color:var(--subtle);opacity:.7}.search-input svg{position:absolute;left:.875rem;color:var(--subtle);pointer-events:none;width:1.25rem;height:1.25rem;transition:color .2s ease}.search-input input:focus+svg{color:var(--primary)}.filter-group{display:flex;gap:1rem;flex-wrap:wrap}.filter-group label{display:flex;align-items:center;gap:.5rem;font-size:.9rem;color:var(--subtle);cursor:pointer}.filter-group input[type=radio]{margin:0}.no-results{grid-column:1 / -1;text-align:center;padding:3rem;color:var(--subtle)}.no-results p{margin:0;font-size:1.1rem}.pagination{display:flex;justify-content:center;align-items:center;gap:1rem;margin-top:2rem;padding:1rem;grid-column:1 / -1}.pagination-btn{display:inline-flex;align-items:center;gap:.5rem;padding:.5rem 1rem;border:1px solid var(--muted);border-radius:.6rem;background:var(--bg);color:var(--text);font-size:.9rem;font-weight:500;cursor:pointer;transition:all .2s ease}.pagination-btn:hover:not(:disabled){background:var(--bg-alt);border-color:var(--primary);color:var(--primary)}.pagination-btn:disabled{opacity:.5;cursor:not-allowed}.pagination-info{font-size:.9rem;color:var(--subtle);font-weight:500}.order-expand{width:3rem;text-align:center}.expand-btn{background:none;border:none;cursor:pointer;padding:.5rem;border-radius:.375rem;color:var(--subtle);transition:all .2s ease;display:inline-flex;align-items:center;justify-content:center}.expand-btn:hover{background:#3741511a;color:var(--primary)}.expand-btn svg{transition:transform .2s ease}.expand-btn svg.rotated{transform:rotate(90deg)}.order-details-row{background:linear-gradient(135deg,var(--bg-alt) 0%,rgba(55,65,81,.02) 100%);border-top:1px solid var(--muted)}.order-details-row>td{padding:0;border:none}.order-items-table-container{padding:1.5rem;background:var(--bg);border-radius:.75rem;margin:.5rem 0;border:1px solid var(--muted);box-shadow:0 4px 12px #11182714}.order-items-table-container h4{margin:0 0 1rem;font-size:1.1rem;font-weight:600;color:var(--text);display:flex;align-items:center;gap:.5rem}.order-items-table-container h4:before{content:"📦";font-size:1rem}.order-items-table{width:100%;border-collapse:collapse;background:var(--bg);border-radius:.5rem;overflow:hidden;box-shadow:0 2px 8px #1118270f}.order-items-table th{background:linear-gradient(135deg,var(--primary) 0%,var(--accent) 100%);color:var(--primary-contrast);font-weight:600;padding:.875rem 1rem;text-align:left;font-size:.9rem;border:none}.order-items-table td{padding:.875rem 1rem;border-bottom:1px solid var(--muted);font-size:.9rem;vertical-align:middle}.order-items-table tbody tr:last-child td{border-bottom:none}.order-items-table tbody tr:hover{background:#37415105}.item-article{font-weight:600;color:var(--primary);font-size:.85rem;background:#3741510d;padding:.25rem .5rem;border-radius:.375rem;display:inline-block}.item-name{font-weight:500;color:var(--text);line-height:1.4}.item-quantity{font-weight:500;color:var(--subtle);background:var(--bg-alt);padding:.25rem .5rem;border-radius:.375rem;display:inline-flex;align-items:center;gap:.25rem}.item-price{font-weight:600;color:var(--primary);text-align:right}.item-total{font-weight:700;color:var(--accent);text-align:right;background:linear-gradient(135deg,#1e293b0d,#1e293b1a);padding:.375rem .75rem;border-radius:.5rem;border:1px solid rgba(30,41,59,.1)}@media (max-width: 768px){.order-items-table-container{padding:1rem;margin:.25rem 0}.order-items-table th,.order-items-table td{padding:.5rem .75rem;font-size:.8rem}.item-article{font-size:.75rem;padding:.2rem .4rem}.item-quantity{padding:.2rem .4rem}.item-total{padding:.25rem .5rem}}.loading-state{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:4rem 2rem;gap:1rem;color:var(--subtle)}.loading-spinner{width:3rem;height:3rem;border:3px solid var(--muted);border-top:3px solid var(--primary);border-radius:50%;animation:spin 1s linear infinite}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.contracts-section{margin-bottom:3rem}.contracts-section h3{margin:0 0 1.5rem;font-size:1.5rem;font-weight:600;color:var(--text);display:flex;align-items:center;gap:.75rem}.contracts-section h3:before{content:"";width:4px;height:1.5rem;background:linear-gradient(135deg,var(--primary) 0%,var(--accent) 100%);border-radius:2px}.contracts-list{display:flex;flex-direction:column;gap:2rem}.contract-card{background:linear-gradient(135deg,var(--bg) 0%,var(--bg-alt) 100%);border-radius:1.25rem;padding:2rem;box-shadow:0 12px 24px #11182714;border:1px solid var(--muted);transition:all .3s cubic-bezier(.4,0,.2,1);position:relative;overflow:hidden}.contract-card:before{content:"";position:absolute;top:0;left:0;right:0;height:4px;background:linear-gradient(90deg,var(--primary) 0%,var(--accent) 100%);opacity:0;transition:opacity .3s ease}.contract-card:hover{box-shadow:0 16px 32px #1118271f;transform:translateY(-2px)}.contract-card:hover:before{opacity:1}.contract-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:1.5rem;gap:1rem}.contract-title h4{margin:0 0 .5rem;font-size:1.25rem;font-weight:600;color:var(--text)}.contract-meta{font-size:.9rem;color:var(--subtle);display:block}.contract-products{border-top:1px solid var(--muted);padding-top:1.5rem}.contract-products h5{margin:0 0 1rem;font-size:1rem;font-weight:600;color:var(--text);display:flex;align-items:center;gap:.5rem}.contract-products h5:before{content:"";width:3px;height:1rem;background:var(--primary);border-radius:2px}.products-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:1rem}.product-item{background:var(--bg);border:1px solid var(--muted);border-radius:.75rem;padding:1rem;transition:all .2s ease;display:flex;justify-content:space-between;align-items:center;gap:1rem}.product-item:hover{box-shadow:0 4px 12px #11182714;border-color:var(--primary)}.product-info{flex:1;min-width:0;display:flex;flex-direction:row;align-items:flex-start;gap:.5rem}.product-name{display:inline-block;font-weight:600;color:var(--text);font-size:.95rem;overflow-wrap:break-word}.product-article{display:block;font-size:.8rem;color:var(--subtle)}.product-meta{text-align:right;flex-shrink:0}.product-price{display:block;font-size:.9rem;font-weight:600;color:var(--primary)}.contract-info{flex:1;min-width:0}.contract-info h4{margin:0 0 .5rem;font-size:1.1rem;font-weight:600;color:var(--text)}.contract-details{margin:0;font-size:.9rem;color:var(--subtle);line-height:1.4}.no-contracts{text-align:center;padding:3rem 2rem;color:var(--subtle);font-style:italic;background:var(--bg-alt);border-radius:1rem;border:1px solid var(--muted)}.add-contract-section{background:linear-gradient(135deg,var(--bg) 0%,var(--bg-alt) 100%);border-radius:1.25rem;padding:2rem;box-shadow:0 12px 24px #11182714;border:1px solid var(--muted)}.add-contract-section h3{margin:0 0 1.5rem;font-size:1.25rem;font-weight:600;color:var(--text);display:flex;align-items:center;gap:.75rem}.add-contract-section h3:before{content:"";width:4px;height:1.25rem;background:linear-gradient(135deg,#16a34a,#22c55e);border-radius:2px}.add-contract-form{display:flex;gap:1rem;align-items:center;flex-wrap:wrap}.add-contract-form select{flex:1;min-width:250px;border:2px solid var(--muted);border-radius:.75rem;padding:.875rem 1rem;background:var(--bg);font-size:1rem;transition:all .2s ease;box-shadow:0 2px 4px #1118270d}.add-contract-form select:focus{outline:none;border-color:var(--primary);box-shadow:0 0 0 3px #3741511a}.add-btn{display:inline-flex;align-items:center;gap:.5rem;background:linear-gradient(135deg,#16a34a,#22c55e);color:#fff;border:none;padding:.875rem 1.5rem;border-radius:.75rem;font-weight:600;font-size:1rem;cursor:pointer;transition:all .3s cubic-bezier(.4,0,.2,1);box-shadow:0 4px 12px #22c55e33}.add-btn:hover:not(:disabled){transform:translateY(-2px);box-shadow:0 8px 20px #22c55e4d}.add-btn:active{transform:translateY(0)}.add-btn:disabled{opacity:.5;cursor:not-allowed;transform:none}.back-button{margin-bottom:2rem}.back-button .secondary{display:inline-flex;align-items:center;gap:.5rem;background:var(--bg);color:var(--text);border:1px solid var(--muted);padding:.75rem 1.25rem;border-radius:.75rem;font-weight:500;cursor:pointer;transition:all .2s ease;box-shadow:0 2px 4px #1118270d}.back-button .secondary:hover{background:var(--bg-alt);border-color:var(--primary);color:var(--primary);transform:translateY(-1px);box-shadow:0 4px 12px #37415126}.user-info-section{margin-bottom:3rem}.user-info-section .user-card{max-width:600px;margin:0 auto}.modal-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:#11182780;display:flex;align-items:center;justify-content:center;z-index:1000;padding:1rem}.modal-card{background:var(--bg);border-radius:1rem;padding:2rem;max-width:600px;width:100%;max-height:90vh;overflow-y:auto;box-shadow:0 20px 40px #11182726;border:1px solid var(--muted)}.modal-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:1.5rem}.modal-header h3{margin:0;font-size:1.25rem;font-weight:600;color:var(--text)}.modal-user-info{display:flex;align-items:center;gap:1rem;margin-bottom:2rem;padding:1rem;background:var(--bg-alt);border-radius:.75rem}.modal-user-info .user-avatar{width:3rem;height:3rem;border-radius:50%;background:var(--primary);color:var(--primary-contrast);display:flex;align-items:center;justify-content:center;font-weight:600;font-size:1.2rem;flex-shrink:0}.modal-user-info .user-info h4{margin:0 0 .25rem;font-size:1.1rem;font-weight:600;color:var(--text)}.modal-user-info .user-info p{margin:0;color:var(--subtle);font-size:.9rem}.user-products h4,.contract-title h4{margin:0 0 .5rem;color:var(--text-primary);font-size:1.1rem}.contract-meta{font-size:.85rem;color:var(--text-secondary)}.contract-products h5,.products-selection h4{margin:1rem 0 .5rem;color:var(--text-primary);font-size:1rem}.products-checkboxes{max-height:300px;overflow-y:auto;border:1px solid var(--border-color);border-radius:8px;padding:.5rem;background:var(--bg-secondary)}.product-checkbox{display:flex;align-items:center;gap:.5rem;padding:.25rem;border-radius:4px;cursor:pointer;transition:background-color .2s}.product-checkbox:hover{background:var(--bg-hover)}.product-label{font-size:.9rem;color:var(--text-primary)}.no-products{margin:1rem 0;color:var(--subtle);font-style:italic}.products-list{display:flex;flex-direction:column;gap:.75rem;margin-bottom:2rem}.product-item{display:flex;align-items:center;justify-content:space-between;padding:1rem;background:var(--bg-alt);border-radius:.75rem;border:1px solid var(--muted)}.product-info h5{margin:0 0 .25rem;font-size:1rem;font-weight:600;color:var(--text)}.product-details{margin:0;font-size:.85rem;color:var(--subtle)}.add-product h4{margin:0 0 1rem;font-size:1.1rem;font-weight:600;color:var(--text)}.add-product-form{display:flex;gap:1rem;align-items:center}.add-product-form select{flex:1;border:1px solid var(--muted);border-radius:.75rem;padding:.75rem;background:var(--bg);font-size:1rem}.add-btn{display:inline-flex;align-items:center;gap:.5rem;padding:.75rem 1.25rem}@media (max-width: 680px){.app-header{flex-wrap:wrap;gap:.75rem}main{padding:1rem}.cart-panel{width:min(100%,420px)}.users-grid{grid-template-columns:1fr}.user-header{flex-direction:column;align-items:flex-start;gap:.75rem}.user-actions{flex-direction:column}.action-btn{justify-content:center}.contract-header{flex-direction:column;align-items:stretch;gap:1rem}.contract-title{text-align:center}.products-grid{grid-template-columns:1fr}.product-item{flex-direction:column;align-items:flex-start;gap:.75rem}.product-meta{text-align:left;align-self:flex-end}.add-contract-form{flex-direction:column;gap:1rem}.add-contract-form select{width:100%}}.orders-table-container{background:var(--bg);border-radius:1rem;overflow:hidden;box-shadow:0 4px 6px #11182712}.orders-table{width:100%;border-collapse:collapse;font-size:.9rem}.orders-table thead{background:var(--bg-alt)}.orders-table th{padding:1rem .75rem;text-align:left;font-weight:600;color:var(--text);border-bottom:1px solid var(--muted)}.orders-table td{padding:1rem .75rem;border-bottom:1px solid var(--muted);vertical-align:top}.orders-table tbody tr:hover{background:var(--bg-alt)}.order-id strong{font-family:monospace;font-size:.85rem}.order-note{font-size:.8rem;color:var(--subtle);margin-top:.25rem}.order-user div:first-child{font-weight:500}.order-user .muted{font-size:.8rem;color:var(--subtle)}.order-date{font-size:.9rem}.order-date .muted{font-size:.8rem;color:var(--subtle);margin-top:.25rem}.status-select{padding:.4rem .6rem;border:1px solid var(--muted);border-radius:.5rem;background:var(--bg);font-size:.85rem;min-width:120px}.status-select.status-created{background:#fef3c7;border-color:#f59e0b}.status-select.status-in-progress{background:#dbeafe;border-color:#3b82f6}.status-select.status-processed{background:#d1fae5;border-color:#10b981}.order-total strong{color:var(--primary)}.order-items-count{text-align:center;font-weight:500}.order-actions{text-align:center}.action-btn{display:inline-flex;align-items:center;gap:.5rem;padding:.5rem .75rem;border:1px solid var(--muted);border-radius:.5rem;background:var(--bg);color:var(--text);font-size:.85rem;cursor:pointer;transition:all .2s ease}.action-btn:hover{background:var(--primary);color:var(--primary-contrast);border-color:var(--primary)}.action-btn svg{width:1rem;height:1rem}
