/* Contact Page Specific Styles */

/* Page Header */
.page-header {
    margin-top: 0;
    height: 450px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-header-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.page-header-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.page-header-content {
    position: absolute;
    top: 50%;
    left: 200px;
    transform: translateY(-50%);
    z-index: 2;
    text-align: left;
}

.page-title {
    font-family: 'Noto Serif JP', serif;
    font-size: 32px;
    font-weight: 700;
    color: #522601;
    margin: 0;
}

/* Contact Form Section */
.contact-form-section {
    background: #FFF8F4;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.contact-form-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('img/bg_texture.png');
    background-repeat: repeat;
    background-size: auto;
    background-position: top left;
}

.contact-form-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

.contact-description {
    font-size: 18px;
    line-height: 1.6;
    color: #522601;
    text-align: center;
    margin: 60px 0;
}

/* Contact Form */
.contact-form {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 36px;
}

.form-group {
    display: flex;
    flex-direction: row;
    position: relative;
    align-items: flex-start;
    margin-bottom: 36px;
}

.form-label-row {
    display: flex;
    align-items: center;
    margin-bottom: 0;
}

.form-label {
    font-size: 16px;
    font-weight: 400;
    color: #522601;
    width: 128px;
    flex-shrink: 0;
    margin-right: 18px;
}

.required-badge {
    background: #F78400;
    color: #fff;
    font-size: 16px;
    font-weight: 400;
    padding: 0 24px;
    border-radius: 3px;
    width: 80px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
    flex-shrink: 0;
}

.form-input,
.form-textarea {
    background: #fff;
    border: 1px solid #808080;
    border-radius: 3px;
    padding: 9px 16px;
    font-size: 16px;
    font-weight: 400;
    color: #4F4F4F;
    flex: 1;
    max-width: 720px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-input {
    height: 50px;
}

.form-textarea {
    height: 200px;
    resize: vertical;
    font-family: inherit;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: #F78400;
    box-shadow: 0 0 0 2px rgba(247, 132, 0, 0.2);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: #4F4F4F;
}

/* Submit Button */
.submit-button {
    background: linear-gradient(0deg, rgba(255, 5, 5, 1) 0%, rgba(247, 132, 0, 1) 100%);
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 10px 20px;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 0 auto;
    width: fit-content;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(247, 132, 0, 0.3);
}

.submit-button:active {
    transform: translateY(0);
}

.submit-arrow {
    width: 24px;
    height: 24px;
}

/* Active Navigation */
.nav-link.active,
.cta-button.active {
    color: #8F4100;
    font-weight: 700;
}

.cta-button.active {
    background: linear-gradient(0deg, rgba(255, 5, 5, 1) 0%, rgba(247, 132, 0, 1) 100%);
    color: #fff;
}

/* エラーメッセージ位置 */
.error-message {
  position: absolute;
  right: 0;
  bottom: -22px;
  color: #E60000;
  font-size: 14px;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: #fff;
    margin: 15% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 20px 30px;
    border-bottom: 1px solid #E5E7EB;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    color: #522601;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #808080;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: #522601;
}

.modal-body {
    padding: 30px;
    text-align: center;
}

.modal-body p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: #522601;
}

.modal-footer {
    padding: 20px 30px;
    border-top: 1px solid #E5E7EB;
    text-align: center;
}

.modal-button {
    background: linear-gradient(0deg, rgba(255, 5, 5, 1) 0%, rgba(247, 132, 0, 1) 100%);
    color: #fff;
    border: none;
    border-radius: 3px;
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.modal-button:hover {
    transform: translateY(-2px);
}

/* Form Validation Styles */
.form-input.error,
.form-textarea.error {
    border-color: #ff4444;
    box-shadow: 0 0 0 2px rgba(255, 68, 68, 0.2);
}

.error-message {
    color: #ff4444;
    font-size: 16px;
    margin-top: 5px;
    margin-left: 280px;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .contact-form {
        max-width: 800px;
    }
    
    .form-input,
    .form-textarea {
        width: calc(100% - 280px);
        max-width: 600px;
    }
    
    .required-badge {
        left: 120px;
    }
}

@media (max-width: 768px) {
    .page-header-content {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-align: center;
    }
    
    .page-title {
        font-size: 28px;
    }
    
    .contact-description {
        font-size: 16px;
    }
    
    .contact-form {
        max-width: 100%;
        gap: 30px;
    }
    
    .form-group {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .form-label {
        width: auto;
        margin-bottom: 0;
        margin-right: 10px;
    }
    
    .required-badge {
        position: static;
        width: fit-content;
        margin-bottom: 0;
        margin-left: 0;
        margin-right: 0;
    }
    
    .form-label-row {
        display: flex;
        align-items: center;
        margin-bottom: 10px;
    }
    
    .form-input,
    .form-textarea {
        width: 100%;
        margin-left: 0;
    }
    
    .error-message {
        margin-left: 0;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 24px;
    }
    
    .contact-description {
        font-size: 16px;
    }
    
    .form-label {
        font-size: 16px;
    }
    
    .required-badge {
        font-size: 16px;
        padding: 0 16px;
        height: 28px;
    }
    
    .form-input,
    .form-textarea {
        font-size: 16px;
        padding: 8px 12px;
    }
    
    .form-input {
        height: 44px;
    }
    
    .form-textarea {
        height: 150px;
    }
    
    .submit-button {
        font-size: 16px;
        padding: 12px 20px;
    }
    
    .submit-arrow {
        width: 20px;
        height: 20px;
    }
    
    .modal-header h3 {
        font-size: 18px;
    }
    
    .modal-body p {
        font-size: 16px;
    }
    
    .modal-button {
        font-size: 16px;
        padding: 10px 24px;
    }
}
