* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: Arial, Helvetica, sans-serif;
    color: #111827;
    background: #f7f7f8;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font: inherit;
}

.site-container {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    border-bottom: 1px solid #e5e7eb;
    background: #ffffff;
}

.site-header__inner {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.site-logo {
    font-weight: 700;
    letter-spacing: -0.03em;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.site-nav__link,
.site-nav__button {
    border: 0;
    border-radius: 12px;
    padding: 10px 14px;
    background: transparent;
    color: #4b5563;
    cursor: pointer;
}

.site-nav__link.is-active,
.site-nav__link:hover,
.site-nav__button:hover {
    background: #f3f4f6;
    color: #111827;
}

.site-nav__logout {
    margin: 0;
}

.site-footer {
    padding: 28px 0;
    color: #6b7280;
}

.site-footer__inner {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-size: 14px;
}

.auth-page,
.dashboard-page {
    padding: 48px 0;
}

.auth-card,
.dashboard-card {
    width: min(460px, 100%);
    margin: 0 auto;
    padding: 32px;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    background: #ffffff;
}

.dashboard-card {
    width: min(820px, 100%);
}

.auth-title,
.dashboard-title {
    margin: 0 0 8px;
    font-size: 32px;
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.auth-text,
.dashboard-text {
    margin: 0 0 24px;
    color: #6b7280;
    line-height: 1.5;
}

.form {
    display: grid;
    gap: 16px;
}

.form-label {
    display: grid;
    gap: 8px;
    font-size: 14px;
    color: #374151;
}

.form-input {
    width: 100%;
    min-height: 48px;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    padding: 0 14px;
    background: #ffffff;
    outline: none;
}

.form-input:focus {
    border-color: #111827;
}

.form-button {
    min-height: 48px;
    border: 0;
    border-radius: 14px;
    padding: 0 16px;
    background: #111827;
    color: #ffffff;
    cursor: pointer;
}

.form-button:disabled {
    opacity: .65;
    cursor: not-allowed;
}

.form-button_secondary {
    background: #f3f4f6;
    color: #111827;
}

.form-message {
    margin-top: 16px;
    min-height: 22px;
    color: #b91c1c;
    font-size: 14px;
}

.form-message.is-success {
    color: #047857;
}

.auth-links {
    margin-top: 20px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
    color: #4b5563;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 24px;
}

.dashboard-item {
    padding: 18px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #f9fafb;
}

.dashboard-item h3 {
    margin: 0 0 6px;
    font-size: 16px;
}

.dashboard-item p {
    margin: 0;
    color: #6b7280;
    font-size: 14px;
    line-height: 1.4;
}

@media (max-width: 640px) {
    .site-header__inner,
    .site-footer__inner {
        align-items: flex-start;
        flex-direction: column;
    }

    .auth-card,
    .dashboard-card {
        padding: 24px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}
