/* ── Base ── */
* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "DM Sans", sans-serif;
    background-image: url('/pipeline_marketplace/assets/img/bg_try.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;

}

/* ── Header ── */
.regis-header {
    background: #054d20;
    padding: 16px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.img-logo-light {
    max-width: 120px;
    height: auto;
    filter: brightness(0) invert(1);
}

.header-tagline {
    font-size: 12px;
    color: #c8f0d8;
    letter-spacing: 1.5px;
    font-style: italic;
}

/* ── Wrapper ── */
.regis-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 70px);
    padding: 20px 16px;
    background: transparent;
}

/* ── Main card ── */
.regis-card {
    background: #F2F0EF;
    border-radius: 24px;
    border: 2px solid #054d20;
    box-shadow: 0 8px 32px rgba(8, 120, 50, 0.13);
    display: flex;
    overflow: hidden;
    width: 1420px;
    max-width: 97vw;
    min-height: 740px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), min-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.regis-card.step-one {
    width: 520px;
    min-height: 0;
}

.regis-card.step-one .regis-left {
    width: 0;
    padding-left: 0;
    padding-right: 0;
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
}

.regis-card.step-one .regis-divider {
    width: 0;
    opacity: 0;
}

.regis-card.step-one .regis-right {
    padding: 24px 48px;
}

/* ── Left panel ── */
.regis-left {
    background: #F2F0EF;
    width: 440px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 40px;
    gap: 20px;
    overflow: hidden;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        visibility 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.photo-preview-box {
    width: 300px;
    height: 300px;
    border-radius: 16px;
    border: 3px solid #054d20;
    overflow: hidden;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.photo-preview-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.upload-btn {
    background-color: #054d20;
    color: #F2F0EF;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 10px 24px;
    border-radius: 20px;
    cursor: pointer;
    border: none;
    width: 100%;
    text-align: center;
    transition: background 0.2s;
}

.upload-btn:hover {
    opacity: 0.88;
}

.file-name {
    font-size: 11px;
    color: #054d20;
    margin: 0;
    text-align: center;
    word-break: break-all;
}

/* ── Divider ── */
.regis-divider {
    width: 2px;
    background: #087832;
    align-self: stretch;
    margin: 0;
    flex-shrink: 0;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Right panel ── */
.regis-right {
    flex: 1;
    padding: 60px 64px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: padding 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.regis-form-header {
    margin-bottom: 24px;
}

.form-label-small {
    font-size: 11px;
    font-weight: 700;
    color: #087832;
    letter-spacing: 2px;
    margin-bottom: 4px;
}

.regis-title {
    font-size: 44px;
    font-weight: 800;
    color: #054d20;
    margin: 0;
}

/* ── Labels ── */
.field-label {
    font-size: 11px;
    font-weight: 700;
    color: #087832;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    display: block;
    margin-bottom: 5px;
}

/* ── Inputs ── */
.regis-input {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #b8dfc8;
    border-radius: 10px;
    font-family: "DM Sans", sans-serif;
    font-size: 15px;
    color: #054d20;
    background: #fff;
    outline: none;
    transition: border-color 0.2s;
}

.regis-input:focus {
    border-color: #087832;
    background: #fff;
}

.regis-input::placeholder {
    color: #7dbf9a;
}

/* ── Buttons ── */
.btn-cancel {
    background-color: #e8e8e8;
    color: #555;
    border: none;
    padding: 11px 20px;
    border-radius: 10px;
    font-family: "DM Sans", sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-cancel:hover {
    background-color: #d0d0d0;
}

.btn-register {
    background: #087832;
    color: #F2F0EF;
    border: none;
    padding: 11px 20px;
    border-radius: 10px;
    font-family: "DM Sans", sans-serif;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 0.5px;
    transition: opacity 0.2s;
}

.btn-register:hover {
    opacity: 0.88;
}

/* ── Keep old classes so other pages don't break ── */
.hr-style {
    height: 2px;
    background-color: black;
    border: none;
    opacity: 1;
}

.img-logo {
    max-width: 10%;
    height: auto;
}

.img-regis {
    max-width: 100%;
    height: 100%;
    border-radius: 15px;
}

.img-login {
    max-width: 100%;
    height: 100%;
    border-radius: 15px;
}

/* ── Inline validation ── */
.invalid-feedback {
    display: none;
    font-size: 12px;
    font-weight: 600;
    color: #dc3545;
    margin-top: 5px;
}

.regis-input.is-invalid,
.regis-select.is-invalid {
    border-color: #dc3545 !important;
    padding-right: calc(1.5em + 0.75rem);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.regis-input.is-valid,
.regis-select.is-valid {
    border-color: #087832 !important;
    padding-right: calc(1.5em + 0.75rem);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23087832' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.is-invalid ~ .invalid-feedback {
    display: block;
}

/* ── Password strength ── */
.pw-bar {
    height: 4px;
    border-radius: 2px;
    margin-top: 5px;
    width: 0%;
    background: #ccc;
    transition: width 0.3s, background 0.3s;
}

.pw-label {
    font-size: 11px;
    font-weight: 600;
    margin-top: 2px;
}

/* ── Attempt / cooldown notices ── */
.cooldown-box {
    display: none;
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #7d5a00;
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 500;
}

.cooldown-box.show {
    display: block;
}

.attempt-warn {
    display: none;
    color: #dc3545;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 10px;
}

.attempt-warn.show {
    display: block;
}

/* ── Sex dropdown ── */
.regis-select {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #b8dfc8;
    border-radius: 10px;
    font-family: "DM Sans", sans-serif;
    font-size: 14px;
    color: #054d20;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23087832' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 12px center;
    appearance: none;
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s;
}

.regis-select:focus {
    border-color: #087832;
    background-color: #fff;
}

/* ── Error page ── */
.error-card {
    max-width: 480px;
    margin: 80px auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 32px rgba(8, 120, 50, 0.10);
    padding: 40px 36px 32px;
}

.error-card h2 {
    font-size: 22px;
    font-weight: 700;
    color: #dc3545;
    margin-bottom: 16px;
}

.error-list {
    list-style: none;
    padding: 0;
    margin: 0 0 24px 0;
}

.error-list li {
    background: #fff5f5;
    border-left: 4px solid #dc3545;
    padding: 8px 14px;
    border-radius: 6px;
    margin-bottom: 8px;
    font-size: 14px;
    color: #7b2020;
}

.btn-back {
    display: inline-block;
    background: #087832;
    color: #F2F0EF;
    padding: 10px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    transition: background 0.2s;
}

.btn-back:hover {
    background: #054d20;
    color: #F2F0EF;
}

/* ── Success card brand logo ── */
.brand-logo {
    max-height: 36px;
    width: auto;
    display: block;
}

/* ── Step transition animations ── */
.step-hidden {
    display: none !important;
}

.step-exit {
    animation: stepOut 0.25s ease forwards;
}

.step-enter {
    animation: stepIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes stepOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(-20px);
    }
}

@keyframes stepIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ── Login method buttons ── */
.btn-method {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 18px;
    border-radius: 12px;
    font-family: "DM Sans", sans-serif;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
    border: 1.5px solid #d1d5db;
    background: #fff;
    color: #1a1a1a;
    margin-bottom: 12px;
    text-align: left;
}

.btn-method:hover {
    background: #f8f9fa;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.btn-method:active {
    transform: scale(0.99);
}

.btn-microsoft {
    border-color: #d1d5db;
}

.btn-stdnum {
    border-color: #087832;
    color: #087832;
}

.btn-stdnum:hover {
    background: #f0fdf4;
}

/* ── Method divider ── */
.method-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0 4px;
    color: #6b7280;
    font-size: 13px;
}

.method-divider::before,
.method-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e5e5;
}

/* ── Back button ── */
.btn-back {
    background: none;
    border: none;
    color: #6b7280;
    font-family: "DM Sans", sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
}

.btn-back:hover {
    color: #087832;
}