/* ======================= SELLER REGISTRATION MODAL ======================= */
/* Bootstrap modal in the brand's clothes (see landing/seller-registration-
   modal.blade.php). Every rule is scoped to .seller-modal / .seller-form so
   Bootstrap's own .modal-header and .form-check keep their defaults anywhere
   else. Sides are logical (inline-start/end): one sheet serves the RTL and
   the LTR page. */
.seller-modal .modal-content {
    border: none;
    border-radius: 22px;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.25);
}

/* Header: a gradient dome, the title centred on it */
.seller-modal .modal-header {
    position: relative;
    height: 100px;
    padding: 20px 0;
    border-bottom: none;
    overflow: hidden;
    justify-content: center;
}

.seller-modal .modal-header::before {
    content: "";
    position: absolute;
    top: -100px;
    inset-inline: 0;
    height: 200px;
    border-radius: 50%;
    background-image: linear-gradient(to left, var(--main-color), var(--second-color));
}

.seller-modal .modal-title {
    position: relative;
    z-index: 1;
    flex: 1;
    font-family: "font_bold";
    font-size: 24px;
    line-height: 1.4;
    text-align: center;
    color: var(--white-color);
}

.seller-modal .btn-close {
    position: absolute;
    top: 20px;
    inset-inline-end: 40px;
    z-index: 1;
    margin: 0;
    opacity: 0.9;
}

.seller-modal .modal-body {
    padding: 20px 28px 28px;
}

/* Form */
.seller-form {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-family: "font_regular";
    color: #333;
}

.seller-form__header h3 {
    font-family: "font_bold";
    font-size: 22px;
    color: var(--main-color);
    margin-bottom: 4px;
}

.seller-form__header p {
    font-size: 15px;
    color: #666;
    margin: 0;
}

.seller-form__group,
.seller-form__section {
    min-width: 0;
    padding: 0;
    margin: 0;
    border: 0;
}

.seller-form__group legend {
    float: none;
    width: auto;
    font-family: "font_bold";
    font-size: 18px;
    line-height: 1.5;
    margin-bottom: 8px;
    color: #333;
}

.seller-form__choices {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 40%;
}

/* Bootstrap's .form-check floats the box to the left; here it is a flex row */
.seller-form .form-check {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
}

.seller-form .form-check-input {
    float: none;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    margin: 0;
    border-color: #c9d1cf;
    cursor: pointer;
}

.seller-form .form-check-input:checked {
    background-color: var(--main-color);
    border-color: var(--main-color);
}

.seller-form .form-check-input:focus {
    border-color: var(--second-color);
    box-shadow: 0 0 0 0.2rem rgba(66, 96, 95, 0.2);
}

.seller-form .form-check-label {
    font-size: 16px;
    color: #333;
    cursor: pointer;
}

/* Sections: shown by seller-registration-modal.js for the chosen seller_type */
.seller-form__section {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.seller-form__title {
    font-family: "font_bold";
    font-size: 20px;
    color: #333;
    margin-bottom: 14px;
}

.seller-form .row {
    row-gap: 14px;
}

/* Text fields with a floating label on the border */
.seller-field {
    position: relative;
}

.seller-field input,
.seller-field select {
    width: 100%;
    height: 55px;
    padding: 0 16px;
    border: 1.4px solid #e9eeed;
    border-radius: 18px;
    background-color: var(--white-color);
    font-family: "font_regular";
    font-size: 16px;
    color: #333;
    outline: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.seller-field input:focus {
    border-color: var(--second-color);
    box-shadow: 0 0 0 3px rgba(139, 150, 126, 0.18);
}

.seller-field label,
.seller-file__title {
    position: absolute;
    top: -11px;
    inset-inline-start: 24px;
    padding: 0 6px;
    font-size: 14px;
    line-height: 1.5;
    color: #666;
    background-color: var(--white-color);
    pointer-events: none;
    font-weight: 600;
}

/* File fields: the input stays focusable but out of sight; the label is the box */
.seller-file {
    position: relative;
}

.seller-file input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
}

.seller-file__box {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 120px;
    padding: 30px 16px;
    border: 1.4px solid #e9eeed;
    border-radius: 18px;
    background-color: var(--white-color);
    font-size: 15px;
    color: #333;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.seller-file__box:hover,
.seller-file input:focus-visible+.seller-file__box {
    border-color: var(--second-color);
}

.seller-file input:focus-visible+.seller-file__box {
    box-shadow: 0 0 0 3px rgba(139, 150, 126, 0.18);
}

.seller-file__box i {
    font-size: 28px;
    color: var(--second-color);
}

.seller-file__box.has-preview i {
    display: none;
}

.seller-file__preview {
    width: 70%;
    max-height: 160px;
    object-fit: contain;
    border-radius: 10px;
}

.seller-file__hint {
    font-size: 14px;
    color: #666;
    word-break: break-all;
}

.seller-file__box.has-file .seller-file__hint {
    color: var(--main-color);
}

/* Terms */
.seller-form__agree {
    align-items: flex-start;
}

.seller-form__agree .form-check-input {
    margin-top: 3px;
}

.seller-form__agree .form-check-label {
    line-height: 1.6;
}

.seller-form__agree small {
    display: block;
    font-size: 13px;
    color: #777;
}

/* Commission notice */
.seller-form__notice {
    padding: 12px 14px;
    border-radius: 12px;
    background-color: rgba(139, 150, 126, 0.07);
}

.seller-form__notice p {
    margin: 0;
    font-size: 14px;
    line-height: 1.8;
    color: #444;
}

/* Submit: the outlined variant of .main-btn (general.css) on a white card */
.seller-form .main-btn {
    width: 100%;
    margin-top: 10px;
    border-color: var(--main-color);
    font-size: 18px;
}

.seller-form .main-btn>span:first-child {
    color: var(--main-color);
    padding-inline-start: 12px;
}

.seller-form .main-btn .arrow-btn {
    width: 30px;
    height: 30px;
    font-size: 16px;
}

.seller-form .main-btn .arrow-btn::before {
    width: 30px;
    height: 30px;
    background-color: var(--main-color);
}

.seller-form .main-btn .arrow-btn i,
.seller-form .main-btn:hover .arrow-btn i {
    color: var(--white-color);
}

/* The fill that grows from behind the arrow on hover */
.seller-form .main-btn::before {
    content: "";
    position: absolute;
    top: 50%;
    inset-inline-end: 7px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: var(--main-color);
    transform: translateY(-50%);
    transition: all 0.5s ease;
}

.seller-form .main-btn:hover::before {
    width: 100%;
    height: 300px;
}

.seller-form .main-btn:hover>span:first-child {
    color: var(--white-color);
}

/* Validation — client (jQuery Validation) and server (422) share the same
   marks: .is-invalid / .is-valid on the control, p.seller-form__error under it */
.seller-form__error {
    margin: 6px 12px 0;
    font-size: 13px;
    line-height: 1.6;
    color: #b3261e;
}

.seller-form__group .seller-form__error,
.seller-form__block .seller-form__error {
    margin-inline: 0;
}

.seller-field input.is-invalid,
.seller-file input.is-invalid+.seller-file__box {
    border-color: #d9534f;
}

.seller-field input.is-invalid:focus,
.seller-file input.is-invalid:focus-visible+.seller-file__box {
    box-shadow: 0 0 0 3px rgba(217, 83, 79, 0.15);
}

.seller-form .form-check-input.is-invalid {
    border-color: #d9534f;
}

.seller-field input.is-valid,
.seller-file input.is-valid+.seller-file__box {
    border-color: var(--color-rank-green, #7fa05c);
}

/* Errors with no field of their own: 429, 5xx, network */
.seller-form__alert {
    padding: 12px 14px;
    border-radius: 12px;
    background-color: rgba(217, 83, 79, 0.08);
    color: #8f2a26;
    font-size: 14px;
    line-height: 1.7;
}

.seller-form__alert p {
    margin: 0;
}

/* While the request is in flight */
.seller-form .main-btn:disabled {
    opacity: 0.7;
    cursor: progress;
}

.seller-form .main-btn.is-loading .arrow-btn i {
    animation: sellerSpin 0.9s linear infinite;
}

@keyframes sellerSpin {
    to {
        transform: rotate(328deg);
    }
}

/* Success: the account exists, the OTP is on its way, activation is in the app */
.seller-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 24px 8px 12px;
    text-align: center;
    outline: none;
}

.seller-success__icon {
    width: 84px;
    height: 84px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(150deg, rgba(139, 150, 126, 0.18) 0%, rgba(66, 96, 95, 0.18) 100%);
    color: var(--main-color);
    font-size: 40px;
}

.seller-success__title {
    font-family: "font_bold";
    font-size: 22px;
    color: var(--main-color);
    margin: 0;
}

.seller-success__text {
    font-family: "font_regular";
    font-size: 15px;
    line-height: 1.9;
    color: #555;
    max-width: 460px;
    margin: 0;
}

.seller-success__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    width: 100%;
    margin-top: 6px;
}

.seller-success__actions .main-btn {
    width: min(100%, 320px);
    margin: 0;
    border-color: var(--main-color);
    font-size: 18px;
}

.seller-success__actions .main-btn>span:first-child {
    color: var(--main-color);
    padding-inline-start: 12px;
}

.seller-success__actions .main-btn .arrow-btn,
.seller-success__actions .main-btn .arrow-btn::before {
    width: 30px;
    height: 30px;
    background-color: var(--main-color);
}

.seller-success__actions .main-btn .arrow-btn i,
.seller-success__actions .main-btn:hover .arrow-btn i {
    color: var(--white-color);
}

.seller-success__actions .main-btn::before {
    content: "";
    position: absolute;
    top: 50%;
    inset-inline-end: 7px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: var(--main-color);
    transform: translateY(-50%);
    transition: all 0.5s ease;
}

.seller-success__actions .main-btn:hover::before {
    width: 100%;
    height: 300px;
}

.seller-success__actions .main-btn:hover>span:first-child {
    color: var(--white-color);
}

/* The store badges of the download section, on a white card */
.seller-success__store {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 9px 18px;
    border: 1.4px solid #e9eeed;
    border-radius: 12px;
    color: #0e1a16;
    background: var(--white-color);
    direction: ltr;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.seller-success__store:hover {
    color: #0e1a16;
    transform: translateY(-2px);
    box-shadow: 0 10px 22px rgba(66, 96, 95, 0.12);
}

.seller-success__store i {
    font-size: 26px;
    color: var(--main-color);
}

.seller-success__store-label {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.seller-success__store-label small {
    font-size: 10px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    opacity: 0.8;
}

.seller-success__store-label b {
    font-family: "font_bold";
    font-size: 15px;
}

.seller-success__close {
    margin-top: 4px;
    padding: 6px 18px;
    border: none;
    background: transparent;
    color: #666;
    font-family: "font_regular";
    font-size: 15px;
    text-decoration: underline;
    cursor: pointer;
}

.seller-success__close:hover {
    color: var(--main-color);
}
