/* assets/css/style.css */

:root {
    --bg: #f6f7fb;
    --card: #ffffff;
    --text: #111827;
    --muted: #6b7280;
    --border: #d9dce3;
    --primary: #4f46e5;
    --primary-dark: #4338ca;
    --danger-bg: #fee2e2;
    --danger-text: #991b1b;
    --success-bg: #dcfce7;
    --success-text: #166534;
    --radius: 16px;
    --shadow: 0 10px 30px rgba(17, 24, 39, 0.08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
}

.auth-page {
    display: grid;
    place-items: center;
    padding: 24px;
}

.container {
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    padding: 32px 16px 48px;
}

.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.brand {
    font-size: 24px;
    font-weight: 700;
}

.card {
    background: var(--card);
    border: 1px solid rgba(17, 24, 39, 0.04);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
}

.auth-page .card {
    width: 100%;
    max-width: 420px;
}

h1,
h2,
h3 {
    margin-top: 0;
    margin-bottom: 20px;
}

h1 {
    font-size: 28px;
}

h2 {
    font-size: 24px;
    margin-bottom: 6px;
}

h3 {
    font-size: 20px;
}

.form-group {
    margin-bottom: 16px;
}

label {
    display: block;
    margin-bottom: 7px;
    font-size: 14px;
    font-weight: 600;
}

input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 12px;
    outline: none;
    background: #fff;
    color: var(--text);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.08);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: 0.2s ease;
}

.btn-primary {
    width: 100%;
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-secondary {
    background: #eef0f4;
    color: var(--text);
}

.btn-secondary:hover {
    background: #e2e5ea;
}

.alert {
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 18px;
    font-size: 14px;
    line-height: 1.5;
}

.alert ul {
    margin: 0;
    padding-left: 18px;
}

.alert-error {
    background: var(--danger-bg);
    color: var(--danger-text);
}

.alert-success {
    background: var(--success-bg);
    color: var(--success-text);
}

.muted {
    color: var(--muted);
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.profile-card {
    margin-bottom: 24px;
}

.profile-top {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 24px;
}

.avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: grid;
    place-items: center;
    font-size: 24px;
    font-weight: 700;
    flex-shrink: 0;
}

.profile-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.meta-item {
    padding: 14px;
    background: #f9fafc;
    border: 1px solid #eef1f5;
    border-radius: 14px;
}

.meta-item span {
    display: block;
    margin-bottom: 6px;
    color: var(--muted);
    font-size: 13px;
}

.meta-item strong {
    font-size: 15px;
    word-break: break-word;
}

.grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.password-field {
    position: relative;
}

.password-field input {
    padding-right: 92px;
}

.toggle-password {
    position: absolute;
    top: 39px;
    right: 12px;
    border: none;
    background: transparent;
    color: var(--primary);
    cursor: pointer;
    font-size: 13px;
    padding: 0;
}

.toggle-password:hover {
    text-decoration: underline;
}

@media (max-width: 820px) {
    .grid {
        grid-template-columns: 1fr;
    }

    .profile-meta {
        grid-template-columns: 1fr;
    }
}