/* Shared RSTC form + modal UI
 * Used by: contact-us, careers, etc.
 */

.rstc-kicker {
    display: inline-block;
    margin: 0 0 10px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #8BC53F;
    font-family: var(--font-family-Roboto, 'Roboto', sans-serif);
}

.rstc-kicker--dark {
    color: #709d2b;
}

.rstc-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px 16px;
}

.rstc-form-grid__full {
    grid-column: 1 / -1;
}

.rstc-label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #3a484e;
}

.rstc-input,
.rstc-select,
.rstc-textarea {
    width: 100%;
    border: 1px solid #dde3df;
    background: #fbfcfa;
    color: #1f2a2e;
    padding: 14px 16px;
    font-size: 15px;
    font-family: var(--font-family-Roboto, 'Roboto', sans-serif);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.rstc-select {
    appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, #709d2b 50%),
        linear-gradient(135deg, #709d2b 50%, transparent 50%);
    background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
    padding-right: 36px;
}

.rstc-textarea {
    min-height: 110px;
    resize: vertical;
}

.rstc-input:focus,
.rstc-select:focus,
.rstc-textarea:focus {
    outline: none;
    border-color: #709d2b;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(112, 157, 43, 0.12);
}

.rstc-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    cursor: pointer;
    padding: 15px 28px;
    background: #709d2b;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 10px 24px rgba(112, 157, 43, 0.28);
}

.rstc-submit:hover {
    background: #5f8a22;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(112, 157, 43, 0.34);
}

.rstc-submit--ghost {
    background: transparent;
    color: #1f2a2e;
    box-shadow: none;
    border: 1px solid rgba(31, 42, 46, 0.16);
}

.rstc-submit--ghost:hover {
    background: transparent;
    color: #709d2b;
    border-color: rgba(112, 157, 43, 0.5);
    box-shadow: none;
    transform: none;
}

.rstc-honeypot {
    position: absolute !important;
    left: -9999px !important;
    opacity: 0 !important;
    height: 0 !important;
    width: 0 !important;
}

.rstc-contact-alert {
    padding: 12px 14px;
    margin-bottom: 18px;
    font-size: 14px;
}

.rstc-contact-alert--success {
    background: rgba(112, 157, 43, 0.12);
    color: #3f6d12;
}

.rstc-contact-alert--error {
    background: rgba(200, 60, 60, 0.1);
    color: #a12626;
}

/* Modal */
.rstc-modal.modal {
    z-index: 2000;
}

.rstc-modal .modal-dialog {
    max-width: 680px;
    margin: 1.25rem auto;
}

.rstc-modal .modal-content {
    border: 0;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(20, 22, 21, 0.18);
}

.rstc-modal__header {
    position: relative;
    padding: 22px 24px 18px;
    border-bottom: 1px solid rgba(31, 42, 46, 0.06);
}

.rstc-modal--light .rstc-modal__header {
    background:
        radial-gradient(ellipse at 90% 20%, rgba(139, 197, 63, 0.14), transparent 50%),
        linear-gradient(180deg, #f7faf4 0%, #eef4ea 100%);
    color: #1f2a2e;
}

.rstc-modal__header-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-right: 42px;
}

.rstc-modal__header-copy {
    min-width: 0;
    flex: 1;
}

.rstc-modal__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 8px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #6fa528;
}

.rstc-modal__badge svg {
    width: 14px;
    height: 14px;
}

.rstc-modal__title {
    margin: 0 0 4px;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.25;
    color: #1f2a2e;
    font-family: var(--font-family-Poppins, 'Poppins', sans-serif);
}

.rstc-modal__title em {
    font-style: normal;
    color: #7ab534;
}

.rstc-modal__role {
    display: block;
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 600;
    color: #2a3539;
}

.rstc-modal__hint {
    margin: 0;
    font-size: 13.5px;
    line-height: 1.5;
    color: #6b767c;
}

.rstc-modal__decor {
    position: relative;
    flex: 0 0 88px;
    width: 88px;
    height: 88px;
    display: grid;
    place-items: center;
}

.rstc-modal__decor-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(139, 197, 63, 0.28);
}

.rstc-modal__decor-ring--a {
    inset: 8px;
    animation: rstc-modal-spin 18s linear infinite;
}

.rstc-modal__decor-ring--b {
    inset: 0;
    border-style: dashed;
    opacity: 0.7;
    animation: rstc-modal-spin 26s linear infinite reverse;
}

.rstc-modal__decor-icon {
    position: relative;
    z-index: 1;
    width: 48px;
    height: 48px;
    filter: drop-shadow(0 0 10px rgba(139, 197, 63, 0.25));
}

.rstc-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(31, 42, 46, 0.12);
    border-radius: 10px;
    background: #fff;
    color: #1f2a2e;
    font-size: 22px;
    line-height: 1;
    opacity: 1;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.rstc-modal__close:hover {
    background: rgba(139, 197, 63, 0.12);
    border-color: rgba(139, 197, 63, 0.4);
    color: #5f8f24;
    opacity: 1;
}

.rstc-modal__body {
    padding: 20px 24px 8px;
    background: #fff;
}

.rstc-modal__footer {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
    padding: 10px 24px 22px;
    background: #fff;
    border-top: 0;
}

.rstc-modal__footer--center {
    justify-content: center;
}

.rstc-modal--light .rstc-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #5f8f24;
}

.rstc-modal--light .rstc-label svg {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
}

.rstc-modal--light .rstc-input,
.rstc-modal--light .rstc-select,
.rstc-modal--light .rstc-textarea {
    border-radius: 10px;
}

.rstc-upload {
    position: relative;
}

.rstc-upload__input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.rstc-upload__ui {
    display: grid;
    grid-template-columns: auto auto 1fr;
    grid-template-areas:
        "icon btn name"
        "note note note";
    align-items: center;
    gap: 8px 12px;
    padding: 16px;
    border: 1.5px dashed #c9d4c8;
    border-radius: 12px;
    background: #f7faf4;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.rstc-upload:hover .rstc-upload__ui,
.rstc-upload__input:focus + .rstc-upload__ui {
    border-color: #8BC53F;
    background: #f3f9ec;
}

.rstc-upload__icon {
    grid-area: icon;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    color: #7ab534;
}

.rstc-upload__icon svg {
    width: 24px;
    height: 24px;
}

.rstc-upload__btn {
    grid-area: btn;
    padding: 7px 12px;
    border-radius: 8px;
    border: 1px solid rgba(122, 181, 52, 0.45);
    background: #fff;
    color: #4f7d1c;
    font-size: 12.5px;
    font-weight: 700;
}

.rstc-upload__name {
    grid-area: name;
    font-size: 13px;
    color: #5c6b70;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rstc-upload__note {
    grid-area: note;
    font-size: 12px;
    color: #7a868c;
}

.rstc-textarea-wrap {
    position: relative;
}

.rstc-textarea-wrap .rstc-textarea {
    padding-bottom: 28px;
    min-height: 110px;
}

.rstc-textarea-count {
    position: absolute;
    right: 12px;
    bottom: 10px;
    font-size: 11px;
    color: #8a969b;
    pointer-events: none;
}

@keyframes rstc-modal-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.modal-backdrop.show {
    opacity: 0.45;
}

@media (max-width: 575px) {
    .rstc-form-grid {
        grid-template-columns: 1fr;
    }

    .rstc-modal .modal-dialog {
        margin: 0.75rem;
    }

    .rstc-modal__header,
    .rstc-modal__body,
    .rstc-modal__footer {
        padding-left: 18px;
        padding-right: 18px;
    }

    .rstc-modal__header-main {
        flex-direction: column;
        align-items: flex-start;
        padding-right: 36px;
    }

    .rstc-modal__decor {
        align-self: flex-end;
        margin-top: -8px;
    }

    .rstc-upload__ui {
        grid-template-columns: auto 1fr;
        grid-template-areas:
            "icon btn"
            "name name"
            "note note";
    }

    .rstc-modal__footer--center {
        flex-direction: column;
    }

    .rstc-modal__footer .rstc-submit {
        width: 100%;
    }
}
