/* ===============================================
   Contact Page Styles - 合同会社CROP お問い合わせページ
   =============================================== */

/* Form Loader Overlay */
.form-loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.form-loader-overlay.show {
    opacity: 1;
    visibility: visible;
}

.form-loader-content {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.1);
    max-width: 400px;
    width: 90%;
}

.form-loader-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #e67e22;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.form-loader-text {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.form-loader-subtext {
    font-size: 14px;
    color: #666;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .form-loader-content {
        padding: 1.5rem;
        max-width: 320px;
    }
    
    .form-loader-spinner {
        width: 50px;
        height: 50px;
    }
    
    .form-loader-text {
        font-size: 16px;
    }
    
    .form-loader-subtext {
        font-size: 13px;
    }
}

/* Contact Section */
.contact-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
    min-height: auto;
}

.contact-section__inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 6rem;
    align-items: start;
}

/* Contact Form Container */
.contact-form-container {
    background: #ffffff;
    border-radius: 20px;
    padding: 4rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(52, 152, 219, 0.1);
}

.contact-form__header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-form__title {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 1rem;
    position: relative;
}

.contact-form__title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-accent));
    margin: 1rem auto 0;
    border-radius: 2px;
}

.contact-form__subtitle {
    font-size: 1.4rem;
    color: var(--color-text-medium);
    line-height: 1.7;
}

/* Form Styles */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-row {
    display: flex;
    gap: 2rem;
}

.form-group {
    flex: 1;
    position: relative;
}

.form-group--half {
    flex: 0 0 calc(50% - 1rem);
}

.form-group--required .form-label::after {
    content: '';
    width: 6px;
    height: 6px;
    background: #e74c3c;
    border-radius: 50%;
    display: inline-block;
    margin-left: 8px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.form-label {
    display: block;
    font-size: 1.4rem;
    font-weight: 500;
    color: var(--color-text-dark);
    margin-bottom: 0.8rem;
    transition: color 0.3s ease;
}

.required {
    color: #e74c3c;
    font-weight: 600;
}

.form-control {
    width: 100%;
    padding: 1.4rem 1.6rem;
    border: 2px solid #e1e8ed;
    border-radius: 12px;
    font-size: 1.4rem;
    font-family: inherit;
    background: #ffffff;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(52, 152, 219, 0.1);
    transform: translateY(-2px);
}

.form-control:invalid:not(:focus):not(:placeholder-shown) {
    border-color: #e74c3c;
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.1);
}

.form-control:valid:not(:focus):not(:placeholder-shown) {
    border-color: #27ae60;
    box-shadow: 0 0 0 4px rgba(39, 174, 96, 0.1);
}

/* Select Styles */
select.form-control {
    cursor: pointer;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1.6rem center;
    background-size: 1.6rem;
    padding-right: 4rem;
    appearance: none;
}

/* Textarea Styles */
textarea.form-control {
    resize: vertical;
    min-height: 120px;
    line-height: 1.6;
}

/* Error Messages */
.error-message {
    color: #e74c3c;
    font-size: 1.2rem;
    margin-top: 0.5rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    min-height: 1.8rem;
}

.error-message.show {
    opacity: 1;
    transform: translateY(0);
}

/* Privacy Notice */
.privacy-notice {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--color-primary);
}

.privacy-notice p {
    font-size: 1.2rem;
    color: var(--color-text-medium);
    margin: 0;
    line-height: 1.6;
}

.privacy-notice a {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.privacy-notice a:hover {
    color: var(--color-accent);
    text-decoration: underline;
}

/* Submit Button */
.form-submit {
    text-align: center;
    margin-top: 2rem;
}

.btn-submit {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-light));
    color: #ffffff;
    border: none;
    padding: 1.6rem 4rem;
    font-size: 1.6rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    min-width: 200px;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.3);
    position: relative;
    overflow: hidden;
}

.btn-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.btn-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(52, 152, 219, 0.4);
}

.btn-submit:hover::before {
    left: 100%;
}

.btn-submit:active {
    transform: translateY(-1px);
    box-shadow: 0 6px 15px rgba(52, 152, 219, 0.3);
}

.btn-submit:disabled {
    background: #bdc3c7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-submit__icon {
    transition: transform 0.3s ease;
}

.btn-submit:hover .btn-submit__icon {
    transform: translateX(5px);
}

/* Loading State */
.btn-submit--loading {
    pointer-events: none;
}

.btn-submit--loading .btn-submit__text {
    opacity: 0.7;
}

.btn-submit--loading .btn-submit__icon {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Contact Info */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.contact-info__item {
    background: #ffffff;
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(52, 152, 219, 0.1);
    transition: all 0.3s ease;
}

.contact-info__item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.contact-info__header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.contact-info__header i {
    font-size: 2.4rem;
    color: var(--color-primary);
    width: 40px;
    text-align: center;
}

.contact-info__header h4 {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--color-text-dark);
    margin: 0;
}

.contact-info__content {
    margin-left: 5.5rem;
}

.contact-info__tel {
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
    letter-spacing: 0.05em;
}

.contact-info__email {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
    word-break: break-all;
}

.contact-info__address {
    font-size: 1.4rem;
    color: var(--color-text-dark);
    line-height: 1.7;
    margin-bottom: 0.5rem;
}

.contact-info__hours,
.contact-info__note,
.contact-info__access {
    font-size: 1.2rem;
    color: var(--color-text-light);
    margin: 0;
}

/* Hidden Field */
.hidden {
    display: none;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .contact-section__inner {
        grid-template-columns: 1fr;
        gap: 4rem;
    }
    
    .contact-form-container {
        padding: 3rem;
    }
    
    .contact-info {
        grid-row: 2;
    }
}

@media (max-width: 768px) {
    .contact-section {
        padding: 4rem 0;
    }
    
    .contact-section__inner {
        padding: 0 1.5rem;
        gap: 3rem;
    }
    
    .contact-form-container {
        padding: 2.5rem;
        border-radius: 16px;
    }
    
    .contact-form__title {
        font-size: 2.4rem;
    }
    
    .form-row {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .form-group--half {
        flex: 1;
    }
    
    .contact-info {
        gap: 2rem;
    }
    
    .contact-info__item {
        padding: 2rem;
    }
    
    .contact-info__content {
        margin-left: 0;
        margin-top: 1rem;
    }
    
    .contact-info__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .contact-info__header i {
        align-self: center;
    }
}

@media (max-width: 480px) {
    .contact-form-container {
        padding: 2rem;
        margin: 0 -0.5rem;
    }
    
    .btn-submit {
        padding: 1.4rem 3rem;
        font-size: 1.4rem;
        min-width: 180px;
    }
    
    .contact-info__tel {
        font-size: 1.8rem;
    }
    
    .contact-info__email {
        font-size: 1.4rem;
    }
}

/* Success/Error Animation */
.form-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    display: none;
}

.form-success.show {
    display: block;
    animation: slideInUp 0.5s ease;
}

.form-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    display: none;
}

.form-error.show {
    display: block;
    animation: slideInUp 0.5s ease;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}