/*
Theme Name: Hakuba Villa
Author: Wei-Ting Lin
Description: Custom theme for Hakuba Villa
Version: 1.0
*/

body {
    font-family: 'Noto Sans TC', 'Noto Serif JP', Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f2f2f2;
    font-size: 20px;
    color: #434343;
}

p {
    line-height: 38px;
}

*, *::before, *::after {
    box-sizing: border-box;
}

main {
    margin-top: -93px;
}

h2 {
    font-family: 'Marcellus', 'Noto Sans TC', 'Noto Serif JP', Arial, sans-serif;
    font-weight: normal;
}

.hero1 h1, .hero1 p {
    font-family: 'Marcellus', 'Noto Sans TC', 'Noto Serif JP', Arial, sans-serif;
    font-weight: normal;
    letter-spacing: 3px;
}

.title-en {
    font-family: 'Marcellus', 'Noto Sans TC', 'Noto Serif JP', Arial, sans-serif;
    font-size: 79px;
    color: #222222;
    margin: 0;
    letter-spacing: 3px;
}

.text-center {
    text-align: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: white;
    padding: 28px 22px;
    border-radius: 999px;
    text-decoration: none;
    font-size: 20px;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    gap: 10px;
    cursor: pointer;
    min-width: 250px;
    border: 1px solid #0A0A0A;
    color: #0A0A0A;
}

.btn:hover {
    background-color: #626262 !important;
    color: white !important;
    border: none !important;
}

@media (max-width: 768px) {
    body {
        font-size: 15px;
    }
    p {
        line-height: 29px;
    }
    main {
        margin-top: -71px;
    }
    .sm-none {
        display: none;
    }
    .title-en {
        font-size: 40px;
        text-align: center;
    }
    .btn {
        width: 100%;
        font-size: 14px;
        padding: 16px 24px;
        text-align: center;
        justify-content: center;
    }
}

header.site-header {
    padding: 25px 50px 0;
    color: #fff;
    position: relative;
    z-index: 100;
}

.logo a:hover {
    opacity: .7;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 45px;
    height: 40px;
    cursor: pointer;
    z-index: 2001;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 3px;
    background: #fff;
    border-radius: 2px;
}

.nav-list {
    list-style: none;
    display: flex;
    margin: 0;
    padding: 0;
}

.nav-list li {
    margin-left: 20px;
}

.nav-list a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
}

.nav-list a:hover {
    color: #ccc;
}

.section {
    width: 1200px;
    max-width: calc(100% - 40px);
    margin: 160px auto;
}

.section img {
    max-width: 100%;
    height: auto;
}

.site-footer {
    background: #222;
    color: #fff;
    padding: 20px;
    text-align: center;
}

/* RWD 手機版 */
@media (max-width: 768px) {
    header.site-header {
        padding: 5px 5px 0;
        color: #fff;
    }
    .nav-container {
        align-items: flex-start;
    }
    .menu-toggle {
        display: flex;
    }
    .nav-list {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: #626262;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.3s ease-in-out;
        z-index: 2000;
    }

    .nav-list.active {
        right: 0;
    }

    .nav-list li {
        margin: 20px 0;
    }

    .nav-list a {
        font-size: 20px;
        color: #fff;
    }

    .section {
        margin: 100px auto;
    }
}

/* slider 調整 */
.carousel {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    overflow-x: hidden;
    height: 700px;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease;
}

.slide {
    flex: 0 0 65%;   /* 固定每張的寬度佔 70% */
    max-width: 1000px; /* 避免太寬，可依設計調整 */
    margin: 0 10px;   /* 兩邊留一樣的 margin，確保對稱 */
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s ease;
}

.slide img {
    height: 350px;
    transition: all 0.4s ease;
    object-fit: cover;
}

.slide.active img {
    height: 500px;
}

.carousel-controls {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.carousel-controls button {
    background: none;
    border: none;
    font-size: 32px;
    color: #000;
    cursor: pointer;
    margin: 0 20px;
}

@media (min-width: 769px) {
    .slide.active {
        transform: scale(1.3);
        z-index: 1;
    }
}

@media (max-width: 768px) {
    .carousel {
        height: auto;
    }

    .slide {
        flex: 0 0 100%;   /* 滿版，只顯示一張 */
        margin: 0;        /* 移除間隔 */
    }

    .slide img {
        height: auto;    /* 手機維持一個高度即可 */
    }

    .slide.active img {
        height: auto;    /* 不要再放大，避免畫面不協調 */
    }

    .carousel-controls {
        position: initial;
        text-align: center;
        margin-top: 10px;
        transform: initial;
    }
}

.hero1 {
    position: relative;
    height: 780px;
    overflow: hidden;
}

.video-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;  /* 讓影片裁切填滿區塊 */
    z-index: -2;
}

.hero-dark-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #5a656e;
    opacity: 0.5;
    z-index: -1; /* 蓋在影片上，但在文字下 */
}

.hero-overlay {
    position: relative;
    z-index: 1;
    color: #fff;
    text-align: center;
    top: 50%;
    transform: translateY(-50%);
}

.hero-overlay h1 {
    font-size: 79px;
    margin: 20px 0;
    padding: 0 40px;
    color: #222222;
    background: white;
    display: inline-block;
}

.hero-overlay p {
    font-size: 40px;
    margin: 0;
}

.hero-overlay .btn {
    background: #fff;
    color: #000;
    width: 200px;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 100px;
    display: inline-block;
    font-size: 18px;
    margin-top: 40px;
    border: none;
}

.hero2 {
    position: relative;
    height: 660px;
    /*display: flex;*/
    /*align-items: center;*/
    /*justify-content: center;*/
    /*text-align: center;*/
}

.hero2-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black;
    opacity: 0.4;  /* 遮罩透明度，可自行調整 */
    z-index: 1;
}

.hero2-text {
    position: absolute;
    z-index: 2;
    color: #fff;
    bottom: 50px;
    left: 5%;
    text-align: center;
    font-size: 24px;
}

.hero2-text h1 {
    font-size: 40px;
    margin: 0;
    width: 250px;
    color: #222222;
    background: white;
    display: inline-block;
    font-weight: normal;
}

.hero2-text p {
    margin: 10px 0 0;
}

.hero_img2 {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 768px) {
    .hero1 {
        height: 500px;
    }
    .hero2 {
        height: 300px;
    }
    .hero2-text {
        font-size: 22px;
        left: 50%;
        transform: translateX(-50%);
    }
    .hero2-text h1 {
        font-size: 28px;
        padding: 0 15px;
        width: 150px;
    }
    .hero-overlay h1 {
        font-size: 34px;
        padding: 0 8px;
    }
    .hero-overlay p {
        font-size: 18px;
    }
    .hero-overlay .btn {
        width: 150px;
        font-size: 14px;
        margin-top: 20px;
    }
}

/* Footer 區塊排版 */
.site-footer {
    background: #222;
    color: #fff;
    padding: 40px 60px;
    font-size: 14px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-left {
    text-align: left;
    margin-bottom: 90px;
}

.footer-left p {
    line-height: normal;
}

.footer-left .logo img {
    margin-bottom: 15px;
}

.footer-right {
    display: flex;
    justify-content: space-between;
}

.footer-links {
}

.footer-links a {
    color: #fff;
    margin-right: 20px;
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

.copy {
    font-size: 13px;
    color: #aaa;
}

/* 手機版調整 */
@media (max-width: 768px) {
    .site-footer {
        padding: 20px 20px;
    }
    .footer-container {
        width: 100%;
    }

    .footer-left {
        text-align: center;
        margin-bottom: 30px;
    }

    .footer-right {
        flex-direction: column;
        text-align: center;
    }

    .footer-links a {
        display: block;
        margin: 10px 0;
    }
}




/* ABOUT 區塊排版 */
#about {
    display: flex;
    align-items: center;   /* 垂直置中，讓文字和圖片對齊 */
    justify-content: space-between;
    gap: 70px;             /* 左右間距 */
}

#about .text {
    flex: 1;               /* 左側文字占一半 */
}

#about img {
    flex: 1;               /* 右側圖片占一半 */
    max-width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    #about {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
}


/* STAY 區塊排版 */
.stay-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;   /* 讓手機版自動換行 */
}

.stay-text {
    flex: 1;
}

.stay-section .btn {
    flex-shrink: 0;  /* 避免被擠壓變形 */
    margin-top: 20px;
}

.stay-section img {
    margin-top: 8px;   /* 文字區下方的圖片 */
    width: 100%;
    height: auto;
}


/* 手機版調整：直排 */
@media (max-width: 768px) {
    .stay-section {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .stay-section .btn {
        margin: 0 auto;
    }

    .stay-section img {
        margin-top: 10px;
    }
}

.stay-btn .long-arrow {
    position: relative;
    display: inline-block;
    width: 45px;
    height: 1px;
    border-bottom: 1px solid #0A0A0A;
    margin-left: 10px;
    transition: border-color 0.3s ease;
}

.stay-btn .long-arrow::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    width: 14px;
    height: 14px;
    border-top: 1px solid #0A0A0A;
    transition: border-color 0.3s ease;
}

.stay-btn:hover .long-arrow {
    border-color: white;
}

.stay-btn:hover .long-arrow::after {
    border-color: white;
}



/* PLACE 區塊排版 */
.place-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;   /* 讓手機版自動換行 */
}

.place-text {
    flex: 1;
}

.place-section img {
    margin-top: 8px;   /* 文字區下方的圖片 */
    width: 100%;
    height: auto;
}

/* 手機版調整：直排 */
@media (max-width: 768px) {
    .place-section {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .place-section .btn {
        margin: 0 auto;
    }

    .place-section img {
        margin-top: 10px;
    }
}



/* LIFE STYLE 區塊排版 */
.lifestyle-section .text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.lifestyle-text {
    flex: 1;
}

@media (max-width: 768px) {
    .lifestyle-section .text {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        margin-bottom: 20px;
    }
}



/* RESTART 區塊 */
.restart-section {
    position: relative;
    color: white;
    text-align: center;
    padding: 120px 0;
    background-image: url('/wp-content/themes/hakubavilla/img/restart.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    max-width: none;
}

.restart-section h2 {
    font-size: 50px;
    margin: 0 0 65px;
}

.restart-text {
    z-index: 2;
    position: relative;
}

.restart-name {
    font-size: 16px;
}

@media (max-width: 768px) {
    .restart-section {
        max-width: 100%;
        padding: 70px 20px;
    }
    .restart-section h2 {
        font-size: 30px;
        margin-bottom: 10px;
    }
    .restart-content {
        text-align: left;
    }
    .restart-name {
        font-size: 13px;
    }
}



/* ACCESS 區塊 */
.access-section {
    text-align: center;
}

.access-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin-bottom: 40px;
}

.access-logo {
    max-width: 100px;
    height: auto;
}

.access-info {
    margin: 50px 0 0;
    font-size: 24px;
    line-height: 1.8;
}

.access-description {
    font-size: 16px
}

.transport {
    display: flex;
    justify-content: center;
    gap: 0;
    margin-top: 30px;
    font-size: 16px;
}

.transport-item {
    width: 400px;
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: center;
}

.transport-item img {
    width: 60px;
    height: 60px;
}

.transport-item p {
    text-align: left;
    line-height: 32px;
}

@media (max-width: 768px) {
    .access-header {
        flex-direction: column;
        gap: 10px;
    }

    .access-info {
        font-size: 20px;
    }

    .access-description {
        font-size: 14px;
    }

    .transport {
        flex-direction: column;
        gap: 20px;
    }

    .transport-item {
        width: 100%;
        justify-content: start;
    }

    .transport-item p {
        font-size: 14px;
        line-height: 24px;
    }

    .access-logo {
        max-width: 80px;
    }
}


/* Facility Page */
.facility-section .text {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    margin-bottom: 40px;
}

.facility-section .text h2 {
    white-space: nowrap;
}
.facility-section .text p {
    width: 382px;
}

.equipment-title {
    font-size: 65px;
}

.equipment-container {
    display: flex;
    justify-content: space-between;
    margin: 20px 0;
}

.equipment-container h3 {
    font-size: 20px;
    font-weight: bold;
}
.equipment-container ul {
    list-style: none;
    padding: 0;
    font-size: 16px;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .facility-section .text {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        margin-bottom: 20px;
    }
    .equipment-title {
        font-size: 32px;
    }
    .equipment-container {
        flex-direction: column;
        gap: 0;
        text-align: center;
    }
    .facility-section .text p {
        width: 100%;
    }
}


/* Service Page */
.service-container {
    display: flex;
    justify-content: space-between;
    gap: 40px;
}
.service-container h2 {
    font-size: 40px;
    margin: 0;
    font-weight: normal;
}
.service-en {
    font-size: 24px;
    margin: 0 0 30px;
}

@media (max-width: 768px) {
    .service-container {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    .service-container h2 {
        font-size: 30px;
    }
    .service-en {
        font-size: 18px;
        margin-bottom: 20px;
    }
}

.option-section h2 {
    font-size: 60px;
}

.option-container {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    margin-top: 30px;
}
.option-item {
    flex: 1;
}

@media (max-width: 768px) {
    .option-container {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
    .option-section h2 {
        font-size: 40px;
    }
}



/* Contact Page 表單基本樣式 */
.contact-page {
    max-width: 960px;
    width: 100%;
    margin: 180px auto;
}

.contact-page h1 {
    font-size: 36px;
    margin: 0;
    font-weight: normal;
}

.contact-page h3 {
    font-size: 30px;
    margin: 0 0 80px;
    font-weight: normal;
}

input, textarea {
    width: 100%;
    padding: 23px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.name-fields {
    display: flex;
    gap: 28px;
    justify-content: space-between;
}

.step-buttons {
    margin-top: 80px;
}

.contact-btn .long-arrow {
    position: relative;
    display: inline-block;
    width: 45px;
    height: 1px;
    border-bottom: 1px solid #0A0A0A;
    margin-left: 10px;
    transition: border-color 0.3s ease;
}

.contact-btn .long-arrow::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    width: 14px;
    height: 14px;
    border-top: 1px solid #0A0A0A;
    transition: border-color 0.3s ease;
}

.contact-btn:hover .long-arrow {
    border-color: white;
}

.contact-btn:hover .long-arrow::after {
    border-color: white;
}

.prev-step {
    border: none;
    background: none;
    cursor: pointer;
    height: 87px;
}

.prev-step .long-arrow {
    position: relative;
    display: inline-block;
    width: 45px;
    height: 1px;
    border-bottom: 1px solid #0A0A0A;
    margin-right: 10px;
    transition: border-color 0.3s ease;
}

.prev-step .long-arrow::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%) rotate(-45deg);
    width: 14px;
    height: 14px;
    border-top: 1px solid #0A0A0A;
    transition: border-color 0.3s ease;
}

.prev-step:hover{
    opacity: .7;
}

.contact-page form {
    display: grid;
    gap: 24px;
}

.form-group {
    display: flex;
    align-items: center;
    margin-bottom: 40px;
}

.form-label {
    width: 250px;
    margin-bottom: 0;
}

.form-group div {
    flex: 1;
}

.contact-page form textarea {
    grid-column: span 2;
}

.contact-page form button {
    grid-column: span 2;
}

/* 標題區 */
.form-steps {
    margin: 120px 0 80px;
}
.steps {
    display: flex;
    justify-content: center;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0 auto;
    max-width: 750px;
    position: relative;
}

.step-indicator {
    position: relative;
    text-align: center;
    flex: 1;
    font-weight: normal;
}

.step-indicator > span {
    display: inline-block;
    padding-bottom: 4px;
    border-bottom: 2px solid transparent;
}

.step-indicator.active > span {
    border-bottom: 1px solid black;
}

.step-arrow {
    content: '';
    position: absolute;
    right: -10%;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 2px;
    background-color: #A7A2A2;
}

.step-arrow::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    width: 8px;
    height: 8px;
    border-top: 2px solid #A7A2A2;
}

input.error, textarea.error {
    border: 2px solid #e74c3c;
    background-color: #fff2f2;
}

.error-message {
    color: #e74c3c;
    font-size: 14px;
    margin-top: 5px;
    margin-bottom: 10px;
}

.radio-group {
    display: flex;
    gap: 40px;
    align-items: center;
}

.custom-radio {
    position: relative;
    padding-left: 24px;
    cursor: pointer;
    user-select: none;
}

.custom-radio input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.custom-radio .circle {
    position: absolute;
    left: 0;
    top: 10px;
    height: 12px;
    width: 12px;
    border-radius: 50%;
    border: 1px solid #3b3939;
    background-color: white;
}

.custom-radio input[type="radio"]:checked + .circle::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #3b3939;
}

.step-2 {
    max-width: 730px;
    width: 100%;
    margin: 0 auto;
}


/* 響應式設定 */
@media screen and (max-width: 768px) {
    input, textarea {
        width: 100%;
        padding: 15px;
    }

    .contact-page {
        padding: 20px 10px;
        margin: 40px auto 80px;
    }

    .form-steps {
        margin: 60px 0 40px;
    }

    .steps {
        flex-direction: column;
        gap: 10px;
    }

    .contact-page form {
        grid-template-columns: 1fr;
    }

    .form-group {
        margin-bottom: 20px;
        display: block;
    }

    .form-group div {
        margin-top: 5px;
    }

    .step-buttons {
        margin-top: 40px;
    }

    .contact-btn .long-arrow {
        width: 35px;
    }

    .contact-btn .long-arrow::after {
        width: 6px;
        height: 6px;
    }

    .prev-step {
        width: 100%;
        text-align: center;
    }

    .contact-page h1 {
        font-size: 30px;
    }

    .contact-page h3 {
        font-size: 26px;
        margin-bottom: 40px;
    }

    .radio-group {
        gap: 10px;
    }
}

@media screen and (min-width: 769px) {
    .step-2-buttons {
        display: flex;
        justify-content: space-around;
        align-content: center;
        margin-top: 80px;
    }
}
