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

body {
    font-family: 'Inter', sans-serif;
    background: #f5f5f5;
    color: #000;
    min-height: 100vh;
}

/* Login */
.admin-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: linear-gradient(135deg, #1a1a1a 0%, #333 100%);
}

.login-box {
    background: #fff;
    padding: 40px;
    border-radius: 12px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.login-logo {
    height: 50px;
    width: auto;
    margin-bottom: 24px;
    display: block;
}

.login-box h1 {
    font-size: 24px;
    margin-bottom: 8px;
}

.login-subtitle {
    color: #666;
    font-size: 14px;
    margin-bottom: 24px;
}

.admin-login-form .form-group {
    margin-bottom: 20px;
}

.admin-login-form label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}

.admin-login-form input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
}

.admin-login-form input:focus {
    outline: none;
    border-color: #000;
}

.login-btn {
    width: 100%;
    padding: 14px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
}

.login-btn:hover {
    background: #333;
}

.login-error {
    color: #c00;
    font-size: 14px;
    margin-top: 12px;
    min-height: 20px;
}

/* Admin Panel */
.admin-panel {
    min-height: 100vh;
}

.admin-header {
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.back-link {
    color: #000;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.back-link:hover {
    opacity: 0.8;
}

.admin-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.admin-logo {
    height: 36px;
    width: auto;
}

.logout-btn {
    padding: 8px 16px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logout-btn:hover {
    background: #333;
}

.admin-main {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 24px;
}

.admin-main h1 {
    font-size: 28px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-subtitle {
    color: #666;
    margin-bottom: 32px;
}

.admin-section {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.admin-section h2 {
    font-size: 18px;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.product-form .form-group {
    margin-bottom: 20px;
}

.product-form label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}

.product-form input,
.product-form select,
.product-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
}

.product-form input:focus,
.product-form select:focus,
.product-form textarea:focus {
    outline: none;
    border-color: #000;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

.image-upload {
    border: 2px dashed #e0e0e0;
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s;
}

.image-upload:hover {
    border-color: #999;
}

.image-upload input[type="file"] {
    display: none;
}

.image-upload-placeholder {
    color: #666;
}

.image-upload-placeholder i {
    font-size: 32px;
    display: block;
    margin-bottom: 8px;
    color: #999;
}

.image-upload-placeholder small {
    display: block;
    margin-top: 4px;
    font-size: 12px;
}

.image-preview {
    position: relative;
}

.image-preview img {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    display: block;
    margin: 0 auto;
}

.remove-image-btn {
    margin-top: 8px;
    padding: 8px 16px;
    background: #c00;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
}

.remove-image-btn:hover {
    background: #a00;
}

.submit-product-btn {
    padding: 14px 24px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
}

.submit-product-btn:hover {
    background: #333;
}

/* Products list */
.products-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.product-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #eee;
    flex-wrap: wrap;
    gap: 12px;
}

.product-item-info {
    flex: 1;
    min-width: 200px;
}

.product-item-name {
    font-weight: 600;
    margin-bottom: 4px;
}

.product-item-meta {
    font-size: 14px;
    color: #666;
}

.product-item-actions {
    display: flex;
    gap: 8px;
}

.product-item-actions button {
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
}

.btn-edit {
    background: #000;
    color: #fff;
}

.btn-delete {
    background: #c00;
    color: #fff;
}

.product-item-actions button:hover {
    opacity: 0.9;
}

.empty-products {
    text-align: center;
    color: #666;
    padding: 32px;
}
