:root {
    --green: #246946;
    --green-dark: #145437;
    --bg-light: #f6f6f6;
    --text: #1a1a1a;
    --border: #d8d8d8;
    --font-main: 'Roboto', sans-serif;
    --size-title: 20px;
    --size-subtitle: 16px;
    --size-body: 14px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-main);
    font-size: var(--size-body);
    color: var(--text);
    background: var(--green);
}

.register-page {
    min-height: 100vh;
    display: grid;
    grid-template-rows: auto 1fr auto;
}

.topbar {
    background: #f5f5f5;
    border-bottom: 1px solid #e3e3e3;
}

.topbar-inner {
    min-height: 62px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.topbar-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #666;
    font-size: var(--size-subtitle);
}

.topbar-right a {
    color: var(--green);
    text-decoration: none;
    font-weight: 600;
}

.sep {
    width: 1px;
    height: 16px;
    background: #cfcfcf;
}

.topbar-link {
    color: #666 !important;
    font-weight: 500 !important;
}

.main-wrap {
    width: 100%;
    padding: 40px 12px;
}

.register-card {
    background: var(--bg-light);
    border: 1px solid #dcdcdc;
    border-radius: 14px;
    padding: 28px 60px 22px;
}

.back-link {
    color: var(--green);
    text-decoration: none;
    font-size: var(--size-subtitle);
    font-weight: 500;
}

.back-link i {
    margin-right: 6px;
}

.register-title {
    margin: 14px 0 20px;
    font-family: var(--font-main);
    font-size: var(--size-title);
    font-weight: 900;
    color: #131313;
}

.form-label {
    margin-bottom: 7px;
    font-size: var(--size-subtitle);
    font-weight: 600;
}

.form-control-custom {
    min-height: 56px;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: #f2f2f2;
    font-size: var(--size-body);
    padding: 10px 16px;
    color: #333;
}

.form-control-custom::placeholder {
    color: #666565;
    font-size: var(--size-body);
}

.form-control-custom:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 0.2rem rgba(36, 105, 70, 0.15);
}

.password-wrap {
    position: relative;
}

.password-wrap .form-control-custom {
    padding-right: 52px;
}

.toggle-password {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: #8f959b;
    font-size: 23px;
    cursor: pointer;
    line-height: 1;
}

.field-error {
    padding-left: 10px;
    margin-top: 6px;
    color: #dc3545;
    font-size: 13px;
    font-weight: 500;
}

.agree-wrap {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: var(--size-subtitle);
    font-weight: 500;
    cursor: pointer;
}


.agree-wrap input {
    width: 19px;
    height: 19px;
    accent-color: var(--green);
    margin-top: 2px;
}

.agree-wrap a {
    color: #2459e2;
    text-decoration: none;
}

.agree-wrap a:hover {
    text-decoration: underline;
}

.btn-register {
    width: 100%;
    min-height: 58px;
    border: 0;
    border-radius: 8px;
    background: var(--green);
    color: #fff;
    font-size: 20px;
    font-weight: 700;
    transition: all 0.2s;
}

.btn-register:hover {
    background: var(--green-dark);
}

.login-now {
    text-align: center;
    margin: 20px 0 0;
    font-size: var(--size-body);
    font-weight: 500;
}

.login-now a {
    color: #2459e2;
    text-decoration: none;
    font-weight: 700;
}
.login-now a:hover{
    color: #1a3bb8;
}
.page-footer {
    background-color: var(--green-dark);
    color: #f4f4f4;
    text-align: center;
    padding: 12px;
    font-size: var(--size-subtitle);
}

@media (max-width: 1199.98px) {
    .register-title {
        font-size: var(--size-title);
    }

    .form-label {
        font-size: var(--size-subtitle);
    }

    .form-control-custom {
        font-size: var(--size-body);
    }

    .btn-register,
    .login-now {
        font-size: var(--size-body);
    }

    .back-link {
        font-size: var(--size-subtitle);
    }

    .agree-wrap {
        font-size: var(--size-subtitle);
    }
}

@media (max-width: 767.98px) {
    .topbar-inner {
        min-height: 56px;
    }

    .topbar-logo {
        height: 40px;
    }

    .topbar-right {
        font-size: 12px;
        gap: 8px;
    }

    .main-wrap {
        padding: 18px 10px;
    }

    .register-card {
        padding: 18px 25px 16px;
        border-radius: 12px;
    }

    .register-title {
        font-size: var(--size-title);
        margin-bottom: 14px;
    }

    .form-label {
        font-size: var(--size-subtitle);
    }

    .form-control-custom {
        min-height: 46px;
        font-size: var(--size-body);
    }

    .toggle-password {
        font-size: 17px;
    }

    .agree-wrap {
        font-size: 14px;
        align-items: flex-start;
    }

    .btn-register {
        min-height: 48px;
        font-size: 16px;
    }

    .login-now {
        font-size: 14px;
    }
}