* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    min-height: 100vh;
    user-select: none;
    -webkit-user-select: none;
}

input, textarea, [contenteditable="true"] {
    user-select: text;
    -webkit-user-select: text;
}

.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */
.header {
    background-color: #3e3d40;
    padding: 10px 20px;
    display: flex;
    align-items: center;
}

.logo {
    height: 40px;
}

.design-name-display {
    color: #ccc;
    font-size: 28px;
    margin-left: 16px;
    padding-left: 16px;
    border-left: 1px solid #555;
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.design-name-display:empty {
    display: none;
}

/* Toolbar */
.toolbar {
    background-color: #fff;
    border-bottom: 1px solid #ddd;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.toolbar-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background-color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 70px;
}

.toolbar-btn:hover {
    background-color: #f0f0f0;
    border-color: #bbb;
}

.toolbar-btn:active {
    background-color: #e0e0e0;
}

.btn-icon {
    font-size: 20px;
    line-height: 1;
}

.btn-label {
    font-size: 12px;
    color: #666;
}

.toolbar-btn-export {
    background-color: #3e3d40;
    color: #fff;
    border-color: #3e3d40;
}

.toolbar-btn-export:hover {
    background-color: #555;
    border-color: #555;
}

.toolbar-btn-export .btn-label {
    color: #fff;
}

.toolbar-separator {
    width: 1px;
    height: 40px;
    background-color: #ddd;
    margin: 0 10px;
}

.toolbar-property {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.toolbar-property label {
    font-size: 10px;
    color: #666;
    text-transform: uppercase;
}

.toolbar-property input,
.toolbar-property select {
    padding: 4px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

.toolbar-property input[type="number"] {
    width: 70px;
}

.toolbar-property input[type="color"] {
    width: 50px;
    height: 28px;
    padding: 2px;
    cursor: pointer;
}

.toolbar-property select {
    min-width: 100px;
}

.toolbar-property input:disabled,
.toolbar-property select:disabled {
    background-color: #f5f5f5;
    cursor: not-allowed;
    opacity: 0.6;
}

.toolbar-property input.warning {
    color: #d32f2f;
    border-color: #d32f2f;
    background-color: #ffebee;
}

.toolbar-checkbox-input {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #666666;
}

/* Warning message box */
.warning-message {
    position: absolute;
    right: 260px;
    top: 50%;
    transform: translateY(-50%);
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 6px;
    padding: 12px 16px;
    padding-right: 32px;
    max-width: 250px;
    font-size: 13px;
    color: #856404;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 100;
}

.warning-close {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 20px;
    height: 20px;
    border: none;
    background: transparent;
    font-size: 18px;
    line-height: 1;
    color: #856404;
    cursor: pointer;
    padding: 0;
}

.warning-close:hover {
    color: #533f03;
}

.warning-message::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    border: 8px solid transparent;
    border-left-color: #ffc107;
    border-right: none;
}

/* Main Content */
.main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* Properties Content (JSON display) */
.properties-content {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.no-selection {
    color: #999;
    font-style: italic;
    font-size: 14px;
}

.element-json {
    font-family: 'Courier New', monospace;
    font-size: 11px;
    background-color: #f8f8f8;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 10px;
    white-space: pre-wrap;
    word-wrap: break-word;
    margin: 0;
    max-height: 400px;
    overflow-y: auto;
}

.storage-info {
    margin-top: 15px;
    padding: 10px;
    background-color: #f0f0f0;
    border-radius: 4px;
    font-size: 11px;
    color: #666;
}

.storage-info div {
    margin-bottom: 4px;
}

.storage-bar {
    height: 8px;
    background-color: #ddd;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 6px;
}

.storage-bar-fill {
    height: 100%;
    background-color: #4CAF50;
    transition: width 0.3s ease;
}

.storage-bar-fill[style*="width: 7"],
.storage-bar-fill[style*="width: 8"],
.storage-bar-fill[style*="width: 9"] {
    background-color: #FF9800;
}

.storage-bar-fill[style*="width: 100"],
.storage-bar-fill[style*="width: 99"],
.storage-bar-fill[style*="width: 98"] {
    background-color: #f44336;
}

.property-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.property-group label {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.property-group input[type="text"],
.property-group input[type="number"],
.property-group select {
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    width: 100%;
}

.property-group input[type="color"] {
    width: 100%;
    height: 35px;
    padding: 2px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

.property-group input:focus,
.property-group select:focus {
    outline: none;
    border-color: #3e3d40;
}

/* Canvas Container */
.canvas-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 30px;
    overflow: auto;
    background-color: #e8e8e8;
}

#designCanvas {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    background-color: #fff;
}

/* Fabric.js Controls Styling */
.canvas-container .upper-canvas {
    cursor: default !important;
}

/* Right Panel with Accordion */
.right-panel {
    width: 250px;
    background-color: #fff;
    border-left: 1px solid #ddd;
    overflow-y: auto;
}

/* Accordion */
.accordion {
    display: flex;
    flex-direction: column;
}

.accordion-item {
    border-bottom: 1px solid #ddd;
}

.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background-color: #f8f8f8;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    color: #555;
    transition: background-color 0.2s;
}

.accordion-header:hover {
    background-color: #f0f0f0;
}

.accordion-header.active {
    background-color: #3e3d40;
    color: #fff;
}

.accordion-icon {
    font-size: 10px;
    transition: transform 0.2s;
}

.accordion-header.active .accordion-icon {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.accordion-content.open {
    max-height: 600px;
    overflow-y: auto;
}

/* Export Section */
.export-buttons {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.export-btn {
    padding: 10px 15px;
    background-color: #3e3d40;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: background-color 0.2s;
}

.export-btn:hover {
    background-color: #555;
}

.export-btn-secondary {
    background-color: #fff;
    color: #3e3d40;
    border: 1px solid #3e3d40;
}

.export-btn-secondary:hover {
    background-color: #f0f0f0;
}

.export-separator {
    height: 1px;
    background-color: #ddd;
    margin: 5px 0;
}

/* Zoom Section */
.zoom-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 15px;
}

.zoom-btn {
    width: 32px;
    height: 32px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #fff;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
}

.zoom-btn:hover {
    background-color: #f0f0f0;
    border-color: #bbb;
}

#zoomLevel {
    font-size: 14px;
    font-weight: 600;
    min-width: 50px;
    text-align: center;
}

.zoom-slider {
    width: calc(100% - 30px);
    margin: 0 15px 15px;
}

.zoom-reset-btn {
    display: block;
    width: calc(100% - 30px);
    margin: 0 15px 15px;
    padding: 8px;
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.zoom-reset-btn:hover {
    background-color: #e0e0e0;
}

.layers-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 10px;
    max-height: 300px;
    overflow-y: auto;
}

.no-layers {
    color: #999;
    font-style: italic;
    font-size: 14px;
}

.layer-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border: 1px solid #eee;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s ease;
    background-color: #fff;
}

.layer-item:hover {
    background-color: #f5f5f5;
    border-color: #ddd;
}

.layer-item.active {
    background-color: #3e3d40;
    color: #fff;
    border-color: #3e3d40;
}

.layer-item.active .layer-type {
    color: #ccc;
}

.layer-icon {
    font-size: 16px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.layer-name {
    flex: 1;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.layer-type {
    font-size: 11px;
    color: #999;
    flex-shrink: 0;
}

/* Layer Drag & Drop */

.layer-item.dragging {
    opacity: 0.5;
    background-color: #e0e0e0;
}

.layer-item.drag-over-top {
    border-top: 2px solid #3e3d40;
    margin-top: -1px;
}

.layer-item.drag-over-bottom {
    border-bottom: 2px solid #3e3d40;
    margin-bottom: -1px;
}

.layer-actions {
    display: flex;
    gap: 2px;
    flex-shrink: 0;
}

.layer-btn {
    width: 20px;
    height: 20px;
    padding: 0;
    border: 1px solid #ddd;
    border-radius: 3px;
    background: #f5f5f5;
    cursor: pointer;
    font-size: 10px;
    line-height: 1;
    color: #666;
}

.layer-btn:hover {
    background: #e0e0e0;
    border-color: #bbb;
}

.layer-item.active .layer-btn {
    border-color: #666;
    background: #555;
    color: #fff;
}

.layer-item.active .layer-btn:hover {
    background: #444;
}

.layer-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.layer-btn:disabled:hover {
    background: #f5f5f5;
    border-color: #ddd;
}

.layer-item.active .layer-btn:disabled {
    background: #555;
}

.layer-item.active .layer-btn:disabled:hover {
    background: #555;
}

/* Footer */
.footer {
    background-color: #3e3d40;
    color: #999;
    padding: 10px 20px;
    text-align: center;
    font-size: 12px;
}

/* Responsive */
@media (max-width: 900px) {
    .right-panel {
        width: 200px;
    }
}

@media (max-width: 768px) {
    .right-panel {
        width: 180px;
    }

    .toolbar-btn {
        min-width: 60px;
        padding: 6px 12px;
    }

    .btn-icon {
        font-size: 18px;
    }

    .btn-label {
        font-size: 11px;
    }
}

@media (max-width: 600px) {
    .main-content {
        flex-direction: column;
    }

    .right-panel {
        width: 100%;
        border-left: none;
        border-top: 1px solid #ddd;
    }

    .canvas-container {
        padding: 15px;
        order: -1;
    }
}

/* ==================== Header Actions ==================== */

.header-spacer {
    flex: 1;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    background: transparent;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.header-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.5);
}

.header-btn-primary {
    background: #4CAF50;
    border-color: #4CAF50;
}

.header-btn-primary:hover {
    background: #43A047;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-wrapper {
    position: relative;
}

.cart-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #f44336;
    color: #fff;
    font-size: 11px;
    font-weight: bold;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-dropdown {
    position: relative;
}

.user-btn {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
    background: #666;
    justify-content: center;
}

.user-btn span {
    font-size: 16px;
    font-weight: bold;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    min-width: 200px;
    display: none;
    z-index: 1000;
}

.dropdown-menu.open {
    display: block;
}

.dropdown-header {
    padding: 12px 16px;
}

.dropdown-header strong {
    display: block;
    color: #333;
    font-size: 14px;
}

.dropdown-header small {
    color: #666;
    font-size: 12px;
}

.dropdown-divider {
    height: 1px;
    background: #eee;
}

.dropdown-item {
    display: block;
    width: 100%;
    padding: 10px 16px;
    border: none;
    background: transparent;
    text-align: left;
    font-size: 14px;
    color: #333;
    cursor: pointer;
}

.dropdown-item:hover {
    background: #f5f5f5;
}

.dropdown-item-danger {
    color: #f44336;
}

.dropdown-item-danger:hover {
    background: #ffebee;
}

/* ==================== Modals ==================== */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.open {
    display: flex;
}

.modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.2s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-small { width: 100%; max-width: 400px; }
.modal-medium { width: 100%; max-width: 500px; }
.modal-large { width: 100%; max-width: 700px; }
.modal-auth { width: 100%; max-width: 420px; }

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border: none;
    background: #f0f0f0;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: #e0e0e0;
}

.modal h2 {
    margin: 0 0 20px;
    font-size: 20px;
    color: #333;
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* ==================== Delete Modal ==================== */

#deleteModal.open {
    z-index: 3000 !important;
}

.delete-warning {
    color: #666;
    margin-bottom: 8px;
}

.delete-design-name {
    font-weight: 600;
    font-size: 16px;
    color: #333;
    background: #f5f5f5;
    padding: 10px 12px;
    border-radius: 6px;
    margin-bottom: 16px;
    word-break: break-word;
}

/* ==================== Auth Modal ==================== */

.auth-tabs {
    display: flex;
    margin-bottom: 24px;
    border-bottom: 2px solid #eee;
}

.auth-tab {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    font-size: 15px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.auth-tab:hover {
    color: #333;
}

.auth-tab.active {
    color: #3e3d40;
    border-bottom-color: #3e3d40;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ==================== Forms ==================== */

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3e3d40;
}

.form-hint {
    font-size: 12px;
    color: #888;
}

.form-error {
    color: #f44336;
    font-size: 13px;
    padding: 8px 12px;
    background: #ffebee;
    border-radius: 4px;
    display: none;
}

.form-error:not(:empty) {
    display: block;
}

.form-success {
    color: #2e7d32;
    font-size: 13px;
    padding: 8px 12px;
    background: #e8f5e9;
    border-radius: 4px;
    display: none;
}

.form-success:not(:empty) {
    display: block;
}

/* ==================== Buttons ==================== */

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary {
    background: #3e3d40;
    color: #fff;
}

.btn-primary:hover {
    background: #555;
}

.btn-primary:disabled {
    background: #999;
    cursor: not-allowed;
}

.btn-secondary {
    background: #fff;
    color: #333;
    border: 1px solid #ddd;
}

.btn-secondary:hover {
    background: #f5f5f5;
}

.btn-danger {
    background: #f44336;
    color: #fff;
}

.btn-danger:hover {
    background: #d32f2f;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #fff;
    color: #333;
    border: 1px solid #ddd;
    font-weight: 500;
}

.btn-google:hover {
    background: #f5f5f5;
    border-color: #ccc;
}

.btn-google .google-icon {
    flex-shrink: 0;
}

.auth-divider {
    display: flex;
    align-items: center;
    margin: 16px 0;
    color: #999;
    font-size: 13px;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #ddd;
}

.auth-divider span {
    padding: 0 12px;
}

/* ==================== Designs List ==================== */

.designs-list {
    margin-top: 16px;
    max-height: 60vh;
    overflow-y: auto;
}

.design-card {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
}

.design-card:hover {
    border-color: #3e3d40;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.design-thumbnail {
    aspect-ratio: 3/1;
    height:300;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: #ccc;
}

.design-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.design-info {
    padding: 12px;
}

.design-name {
    font-weight: 500;
    font-size: 14px;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.design-date {
    font-size: 12px;
    color: #888;
}

.design-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.design-actions button {
    flex: 1;
    padding: 6px;
    font-size: 12px;
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    color: #888;
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

/* ==================== Design Accordion ==================== */

.design-accordion {
    border: 1px solid #eee;
    border-radius: 8px;
    margin-bottom: 8px;
    overflow: hidden;
}

.design-accordion-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    cursor: pointer;
    background: #fafafa;
    transition: background 0.2s;
}

.design-accordion-header:hover {
    background: #f0f0f0;
}

.design-accordion-thumbnail {
    width: 80px;
    height: 27px;
    background: #f5f5f5;
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #ccc;
    flex-shrink: 0;
}

.design-accordion-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.design-accordion-info {
    flex: 1;
    min-width: 0;
}

.design-accordion-name {
    font-weight: 500;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.design-accordion-meta {
    font-size: 12px;
    color: #888;
    margin-top: 2px;
}

.design-accordion-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.design-accordion-actions button {
    padding: 4px 10px;
    font-size: 12px;
}

.design-accordion-arrow {
    font-size: 12px;
    color: #888;
    transition: transform 0.2s;
}

.design-accordion-arrow.open {
    transform: rotate(180deg);
}

.design-accordion-content {
    display: none;
    border-top: 1px solid #eee;
    background: #fff;
}

.design-accordion-content.open {
    display: block;
}

.design-version {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f0;
}

.design-version:last-child {
    border-bottom: none;
}

.design-version-thumbnail {
    width: 80px;
    height: 27px;
    background: #f5f5f5;
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #ccc;
    flex-shrink: 0;
}

.design-version-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.design-version-date {
    flex: 1;
    font-size: 13px;
    color: #555;
}

.design-version-actions {
    display: flex;
    gap: 6px;
}

.design-version-actions button {
    padding: 4px 10px;
    font-size: 12px;
}

/* ==================== Cart ==================== */

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #eee;
    border-radius: 8px;
}

.cart-item-thumb {
    width: 60px;
    height: 40px;
    background: #f5f5f5;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 500;
    font-size: 14px;
}

.cart-item-price {
    font-size: 13px;
    color: #666;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-item-qty input {
    width: 50px;
    padding: 4px 8px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.cart-item-remove {
    padding: 6px;
    border: none;
    background: transparent;
    color: #999;
    cursor: pointer;
    font-size: 18px;
}

.cart-item-remove:hover {
    color: #f44336;
}

.cart-summary {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}

.cart-row {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    margin-bottom: 8px;
}

.cart-total {
    font-weight: 600;
    font-size: 16px;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #eee;
}

.cart-empty {
    text-align: center;
    padding: 40px 20px;
    color: #888;
}

/* ==================== Toast Notifications ==================== */

.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 3000;
}

.toast {
    padding: 12px 20px;
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: toastSlideIn 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.toast-success { background: #4CAF50; }
.toast-error { background: #f44336; }
.toast-info { background: #2196F3; }

.toast-close {
    background: transparent;
    border: none;
    color: inherit;
    font-size: 18px;
    cursor: pointer;
    opacity: 0.7;
}

.toast-close:hover {
    opacity: 1;
}


/* ==================== Loading ==================== */

.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #888;
}
