/* assets/css/style.css */

/* Global */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Tahoma, sans-serif;
    background: #f5f7fb;
    color: #1f2933;
}

a {
    color: #2563eb;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Header */
.site-header, .admin-header {
    background: linear-gradient(90deg, #ffffff 0%, #e5edf9 40%, #d0e2ff 100%);
    border-bottom: 1px solid #d0d7e2;
}

.header-inner, .admin-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

.logo a {
    font-weight: 700;
    font-size: 20px;
    color: #1d4ed8;
}

.main-nav a, .admin-nav a {
    margin-left: 18px;
    font-size: 14px;
    font-weight: 500;
}

/* Main */
.main-content, .admin-main {
    padding: 24px 0 40px;
}

.section {
    margin-bottom: 32px;
}

.grid-products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

/* Card */
.card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e1e5f0;
    padding: 16px 18px;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
    margin-bottom: 16px;
}

.post-card h3,
.product-card h3 {
    margin-top: 0;
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.table th,
.table td {
    border-bottom: 1px solid #e5e7eb;
    padding: 8px 6px;
    text-align: left;
}

/* Buttons */
button,
.btn-primary,
.btn-secondary,
.btn-link {
    display: inline-block;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 16px;
}

.btn-primary,
button.btn-primary {
    background: linear-gradient(90deg, #2563eb, #1d4ed8);
    color: #ffffff;
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.35);
}

.btn-secondary {
    background: #ffffff;
    color: #1d4ed8;
    border: 1px solid #d0defa;
}

.btn-link {
    background: transparent;
    color: #2563eb;
    padding: 0;
    border-radius: 0;
}

/* Forms */
.form-vertical label {
    display: block;
    font-size: 13px;
    margin-bottom: 10px;
}

.form-vertical input,
.form-vertical textarea,
.form-vertical select {
    width: 100%;
    margin-top: 4px;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    font-size: 14px;
}

/* Alerts */
.alert {
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 10px;
}

.alert-danger {
    background: #fee2e2;
    color: #b91c1c;
}

.alert-success {
    background: #dcfce7;
    color: #166534;
}

.alert-info {
    background: #e0f2fe;
    color: #075985;
}

/* Price */
.price {
    font-weight: 600;
    margin: 8px 0;
}

.price-lg {
    font-size: 22px;
    font-weight: 700;
    color: #1d4ed8;
}

/* Footer */
.site-footer,
.admin-footer {
    border-top: 1px solid #d0d7e2;
    background: #f9fafb;
    padding: 12px 0;
    font-size: 13px;
    text-align: center;
}

/* Login & Installer */
.admin-login-body,
.installer-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: radial-gradient(circle at top, #e0edff 0, #f5f7fb 60%);
}

.login-wrapper,
.installer-wrapper {
    max-width: 420px;
    width: 100%;
}

/* Admin layout */
.admin-body {
    background: #f4f6fb;
}

.admin-two-columns {
    display: grid;
    grid-template-columns: 1.1fr 1.3fr;
    gap: 16px;
}

.admin-section h2 {
    margin-top: 0;
}

/* Cart */
.cart-total {
    text-align: right;
    font-size: 15px;
    margin: 10px 0;
}

/* Responsive */
@media (max-width: 768px) {
    .header-inner,
    .admin-header-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .main-nav a,
    .admin-nav a {
        margin-left: 0;
        margin-right: 12px;
    }

    .admin-two-columns {
        grid-template-columns: 1fr;
    }
}
