/* 202103 */
.template-contact {
    position: relative;
    display: block;
    height: auto;
    padding-top: 50px;
    padding-bottom: 50px;
    font-family: 'Noto Sans TC', 'Microsoft JhengHei', sans-serif;
    background-position: center;
    background-size: cover;
}

.template-contact .bg {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
}

.template-contact .bg-pc{
    width: 100%;
    height: 100%;
    background-position: 50%;
    background-repeat: no-repeat;
    background-size: cover;
}

.template-contact .bg-mbl{
    width: 100%;
    height: 100%;
    background-position: 50%;
    background-repeat: no-repeat;
    background-size: cover;
    display: none;
}
@media (max-width: 767px){
    .template-contact .bg-pc{
        display: none;
    }
}
@media (max-width: 767px){
    .template-contact .bg-mbl{
        display: block;
    }
}

.template-contact .this_box {
    width: 85%;
    position: relative;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
}

.template-contact .imgs {
    width: 63%;
    display: block;
    position: relative;
}

.template-contact .imgs img {
    max-width: 100%;
}

.template-contact .form {
    width: 470px;
    position: relative;
}

.template-contact .title {
    font-size: 48px;
    color: #fff;
    display: block;
    margin-bottom: 42px;
    /* letter-spacing: 2px; */
    line-height: 1.25em;
    font-family: 'Montserrat', 'PingFang', 'PingFangTC', 'Microsoft JhengHei', Helvetica, Arial, sans-serif;
    font-weight: 500;
}
@media (min-width: 740px) {
    .template-contact .title {
        font-size: 36px;
    }
}

.template-contact .line {
    display: flex;
    padding-bottom: 3px;
    color: #fff;
    margin-bottom: 25px;
    font-size: 16px;
    justify-content: space-between;
    /* border-bottom: 1px solid #a9c0bf; */
    font-weight: 400;
    flex-wrap: wrap;
    transition: all .3s ease;
    position: relative;
}

.template-contact .line.focus {
    border-color: #004f4f;
}

.template-contact .line.code {
    flex-wrap: unset;
}

.template-contact .line.code label {
    min-width: 71px;
}

.template-contact .line.code .input_box {
    padding-right: 25px;
    padding-left: 33px;
}

.template-contact .line label::after {
    content: '';
    display: inline-block;
    width: 100%;
}

.template-contact .line.must label::before {
    content: '*';
    position: absolute;
    right: -10px;
}

.template-contact .line label {
    text-align: justify;
    text-justify: inter-ideograph;
    position: relative;
    height: 30px;
    line-height: 30px;
}
:lang(eng).template-contact .line label{
  text-align: initial;
}

.template-contact .line .input_box {
    width: 75%;
    margin-left: 12px;
    padding: 0;
    border-radius: 0;
    /* background-color: #00385d; */
    height: 32px;
    font-size: 16px;
    position: relative;
    font-family: 'Noto Sans TC', 'Microsoft JhengHei', sans-serif;
    border: none;
    color: #fff;
}

.template-contact .line .textarea_box {
    position: relative;
    width: 100%;
    border: 0;
    background-color: #00385d;
    height: 100px;
    padding: 0;
    font-size: 16px;
    font-family: 'Noto Sans TC', 'Microsoft JhengHei', sans-serif;
    color: #fff;
}

.template-contact .line .error {
    position: absolute;
    color: #9c2f2f;
    bottom: -2px;
    transform: translateY(100%);
    display: none;
    width: 100%;
}

.template-contact .line.null {
    margin-bottom: 40px;
}

.template-contact .line.null .error {
    display: block;
}

.template-contact .button {
    background-color: #004f4f;
    width: 120px;
    height: 40px;
    color: white;
    cursor: pointer;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 30px;
    margin-right: 0;
    margin-left: auto;
    font-weight: 400;
    transition: all .3s ease;
    border: 1px solid #004f4f;
    font-size: 16px;
    font-family: inherit;
}

.thanksWrap {
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.992);
    position: fixed;
    top: 0;
    z-index: 10000;
    display: none;
}

.thanks {
    width: 700px;
    position: absolute;
    left: 50%;
    top: 24%;
    transform: translateX(-50%);
    padding: 8.5% 5%;
    background-color: #fff;
    transition: 2s;
    border-radius: 10px;
}

.thanks .fas {
    font-size: 30px;
    color: #000;
    font-weight: 900;
    float: right;
    top: 40px;
    position: fixed;
    cursor: pointer;
    right: 40px;
}

.thanks h1 {
    font-size: 50px;
    color: #000;
    margin: 0;
    line-height: 1.2;
    margin-bottom: 30px;
    width: 70%;
}

.thanks p {
    font-size: 15px;
    font-weight: 700;
    width: 70%;
}

@media (max-width:1500px) {
    .template-contact .imgs {
        width: 50%;
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        align-content: center;
    }
}

@media (min-width:1199px) {
    .template-contact .button:hover {
        background-color: transparent;
        color: #004f4f;
        border-color: #004f4f;
    }
}

@media (max-width:1200px) {
    .template-contact .form {
        width: 46%;
    }
}

@media (max-width:1000px) {
    .template-contact .line .input_box {
        margin-left: 0;
        width: 100%;
    }
    .template-contact .title {
        font-size: 24px;
        line-height: 32px;
        margin-bottom: 25px;
        letter-spacing: 2px;
    }
    .template-contact {
        padding-top: 110px;
        padding-bottom: 110px;
    }
    .template-contact .this_box {
        width: 90%;
    }
    .template-contact .line.code {
        flex-wrap: wrap;
    }
    .template-contact .line.code .input_box {
        padding-right: 0;
        padding-left: 0;
        margin-bottom: 2px;
        margin-right: 160px;
    }
    .template-contact .line.code img {
        position: absolute;
        right: 0;
        bottom: 4px;
    }
}

/* 739：對齊專案 740 斷點；涵蓋 iPhone Duo 內螢幕直向 (~626) */
@media (max-width:739px) {
    .template-contact .imgs {
        width: 100%;
    }
    .template-contact .form {
        width: 100%;
    }
    .template-contact .this_box {
        display: block;
    }
    .template-contact .title {
        font-size: 26px;
        line-height: 28px;
        margin-bottom: 40px;
        margin-top: 28px;
        letter-spacing: 2px;
    }
    .template-contact .button {
        margin-right: auto;
    }
    .template-contact .imgs {
        width: 90%;
        left: 5%;
    }
    .template-contact {
        padding-top: 20px;
    }
    .template-contact .line.code {
        flex-wrap: wrap;
    }
    .thanks {
        width: 95%;
        padding: 16.5% 5%;
    }
    .thanks h1 {
        font-size: 32px;
    }
    .thanks p {
        width: 100%;
    }

}

/* 2026 contact layout optimization */
.template-contact {
    --contact-card-bg-start: rgba(16, 27, 40, 0.78);
    --contact-card-bg-end: rgba(20, 23, 35, 0.64);
    --contact-card-border: rgba(201, 220, 232, 0.28);
    --contact-text-primary: #f5f7fb;
    --contact-text-secondary: rgba(233, 239, 247, 0.86);
    --contact-divider: rgba(214, 226, 236, 0.2);
    --contact-input-bg: rgba(236, 245, 255, 0.1);
    --contact-input-bg-focus: rgba(236, 245, 255, 0.16);
    --contact-input-border: rgba(197, 219, 236, 0.35);
    --contact-input-border-focus: rgba(196, 231, 243, 0.82);
    --contact-accent: #7bc8b2;
    --contact-accent-hover: #95d9c5;
    --contact-error: #ffb8b8;
}

.template-contact .this_box {
    max-width: 1320px;
    width: min(90%, 1320px);
    align-items: flex-start;
    gap: clamp(28px, 3.2vw, 64px);
}

.template-contact .imgs {
    width: min(58%, 760px);
}

.template-contact .form.contact-form {
    width: min(100%, 620px);
    padding: clamp(24px, 2.2vw, 38px);
    border-radius: var(--radius-11-card, var(--radius-11, 8px));
    border: 1px solid var(--contact-card-border);
    background: linear-gradient(160deg, var(--contact-card-bg-start), var(--contact-card-bg-end));
    box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.template-contact .title {
    margin-bottom: clamp(18px, 1.8vw, 32px);
    font-size: clamp(28px, 2.3vw, 44px);
    letter-spacing: .04em;
    line-height: 1.22;
    font-weight: 500;
    color: var(--contact-text-primary);
}

.template-contact .line {
    display: grid;
    grid-template-columns: minmax(90px, 112px) minmax(0, 1fr);
    column-gap: 14px;
    row-gap: 8px;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--contact-divider);
}

.template-contact .line label {
    height: auto;
    line-height: 1.4;
    text-align: left;
    font-size: 14px;
    letter-spacing: .04em;
    color: var(--contact-text-secondary);
    opacity: 1;
}

.template-contact .line label::after {
    display: none;
}

.template-contact .line.must label::before {
    position: static;
    margin-right: 4px;
}

.template-contact .line .input_box,
.template-contact .line .textarea_box,
.template-contact .line select.input_box,
.template-contact .line input[type="date"] {
    width: 100%;
    min-width: 0;
    margin-left: 0;
    min-height: 44px;
    padding: 10px 12px;
    font-size: 15px;
    border: 1px solid var(--contact-input-border);
    border-radius: var(--radius-11, 8px);
    background: var(--contact-input-bg);
    color: var(--contact-text-primary);
    transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}

.template-contact .line .input_box:focus,
.template-contact .line .textarea_box:focus,
.template-contact .line select.input_box:focus,
.template-contact .line input[type="date"]:focus {
    outline: 0;
    border-color: var(--contact-input-border-focus);
    background: var(--contact-input-bg-focus);
    box-shadow: 0 0 0 3px rgba(123, 200, 178, 0.2);
}

.template-contact .line select.input_box {
    padding-right: 38px;
    font-size: 14px;
    line-height: 1.35;
}

.template-contact .line select.input_box option {
    color: #1d2330;
    background: #f6f9fc;
    white-space: normal;
}

.template-contact .line .textarea_box {
    min-height: 112px;
    resize: vertical;
}

.template-contact .line .error {
    position: static;
    transform: none;
    grid-column: 2 / 3;
    width: auto;
    font-size: 13px;
    color: var(--contact-error);
}

.template-contact .line.null {
    margin-bottom: 16px;
}

.template-contact .contact-captcha-wrap {
    margin-top: 4px;
}

.template-contact .line.vertify-line {
    align-items: center;
}

.template-contact .vertify-field {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    min-width: 0;
    width: 100%;
}

.template-contact .vertify-field .input_box {
    flex: 1 1 160px;
    min-width: 120px;
    max-width: 100%;
    margin-left: 0;
}

.template-contact .vertify-captcha {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.template-contact .vertify-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: var(--contact-text-primary);
    text-decoration: none;
}

.template-contact .vertify-refresh:hover {
    opacity: 0.85;
}

.template-contact .button {
    min-width: 128px;
    border-radius: var(--radius-11, 8px);
    border: 1px solid var(--contact-accent);
    background-color: var(--contact-accent);
    color: #10252a;
    font-weight: 600;
    letter-spacing: .05em;
}

@media (min-width:1199px) {
    .template-contact .button:hover {
        background-color: var(--contact-accent-hover);
        border-color: var(--contact-accent-hover);
        color: #10252a;
    }
}

.template-contact .vertify-captcha img,
.template-contact #contact_captcha {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 48px;
    object-fit: contain;
    border-radius: var(--radius-11, 8px);
    flex: 0 0 auto;
}

.template-contact .line.btn-area {
    display: grid;
    grid-template-columns: minmax(90px, 112px) minmax(0, 1fr);
    column-gap: 14px;
    align-items: center;
    border-bottom: 0;
    padding-bottom: 0;
    margin-top: 10px;
}

.template-contact .line.btn-area .button {
    grid-column: 2 / 3;
    justify-self: stretch;
    width: 100%;
    margin: 0;
}

@media (max-width:1000px) {
    .template-contact .this_box {
        width: min(92%, 980px);
        gap: 28px;
    }

    .template-contact .imgs {
        width: 46%;
    }

    .template-contact .form.contact-form {
        width: 54%;
        padding: 20px 18px;
    }

    .template-contact .line {
        grid-template-columns: 1fr;
        row-gap: 6px;
    }

    .template-contact .line .error {
        grid-column: 1 / 2;
    }

    .template-contact .line.btn-area {
        grid-template-columns: 1fr;
    }

    .template-contact .line.btn-area .button {
        grid-column: 1 / 2;
    }
}

/* 739：對齊專案 740 斷點；涵蓋 iPhone Duo 內螢幕直向 (~626) */
@media (max-width:739px) {
    .template-contact {
        padding-top: 28px;
        padding-bottom: 56px;
    }

    .template-contact .this_box {
        width: min(92%, 560px);
        gap: 18px;
        display: flex;
        flex-direction: column;
    }

    .template-contact .imgs {
        width: 100%;
        left: 0;
    }

    .template-contact .form.contact-form {
        width: 100%;
        padding: 18px 14px;
        border-radius: var(--radius-11-card, var(--radius-11, 8px));
    }

    .template-contact .title {
        margin: 10px 0 18px;
        font-size: 28px;
        line-height: 1.3;
    }

    .template-contact .vertify-field {
        flex-direction: column;
        align-items: stretch;
    }

    .template-contact .vertify-field .input_box {
        flex: 1 1 auto;
        width: 100%;
    }

    .template-contact .vertify-captcha {
        justify-content: flex-start;
    }

    .template-contact .line.btn-area {
        grid-template-columns: 1fr;
    }

    .template-contact .line.btn-area .button {
        grid-column: 1 / 2;
    }
}

/* force color palette over inline/template defaults */
.template-contact .title[style],
.template-contact .line label[style] {
    color: var(--contact-text-primary) !important;
}

.template-contact .line label[style] {
    color: var(--contact-text-secondary) !important;
}

.template-contact .line .input_box::placeholder,
.template-contact .line .textarea_box::placeholder {
    color: rgba(232, 239, 247, 0.55);
}

.template-contact .button {
    border-color: var(--contact-accent) !important;
    background-color: var(--contact-accent) !important;
    color: #10252a !important;
}

@media (min-width:1199px) {
    .template-contact .button:hover {
        background-color: var(--contact-accent-hover) !important;
        border-color: var(--contact-accent-hover) !important;
        color: #10252a !important;
    }
}
