/**
 * NARITA TIME Studio - フォームスタイル
 * 大企業水準のニュートラルデザイン
 *
 * カラー:アイボリー × 墨 × 微金
 * フォント:Noto Sans JP
 */

/* ============================
   ベース・コンテナ
   ============================ */

.nts-form-wrapper {
    max-width: 680px;
    margin: 0 auto;
    padding: 48px 24px;
    font-family: "Noto Sans JP", -apple-system, "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
    color: #2c2c2c;
    font-size: 16px;
    line-height: 1.7;
    background: transparent;
    box-sizing: border-box;
}

.nts-form-wrapper *,
.nts-form-wrapper *::before,
.nts-form-wrapper *::after {
    box-sizing: border-box;
}

.nts-form {
    background: #ffffff;
    border: 1px solid #e5e1d5;
    padding: 56px 48px;
}

/* ============================
   エラー表示
   ============================ */

.nts-alert {
    margin-bottom: 32px;
    padding: 20px 24px;
    border-left: 3px solid;
    background: #fbf9f3;
    font-size: 14px;
}

.nts-alert-error {
    border-left-color: #c04848;
    background: #fdf7f7;
}

.nts-alert-title {
    font-weight: 700;
    font-size: 15px;
    color: #c04848;
    margin-bottom: 8px;
}

.nts-alert ul {
    margin: 0;
    padding: 0 0 0 20px;
    list-style: disc;
}

.nts-alert li {
    margin: 4px 0;
    color: #5a3030;
}

/* ============================
   セクション
   ============================ */

.nts-section {
    margin-bottom: 48px;
    padding-bottom: 48px;
    border-bottom: 1px solid #e5e1d5;
}

.nts-section:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.nts-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 32px 0;
    padding: 0 0 12px 0;
    border-bottom: 2px solid #1a1a1a;
    letter-spacing: 0.05em;
}

/* ============================
   フィールド共通
   ============================ */

.nts-field {
    margin-bottom: 24px;
}

.nts-field:last-child {
    margin-bottom: 0;
}

.nts-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    margin-bottom: 10px;
    letter-spacing: 0.02em;
}

.nts-sub-label {
    display: block;
    font-size: 13px;
    color: #4a4a4a;
    margin: 12px 0 8px 0;
}

.nts-required {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 500;
    color: #ffffff;
    background: #c04848;
    border-radius: 2px;
    vertical-align: middle;
    letter-spacing: 0.05em;
}

.nts-required-inline {
    color: #c04848;
    font-size: 12px;
    margin-left: 4px;
}

.nts-hint {
    display: inline-block;
    margin-left: 8px;
    font-size: 12px;
    font-weight: 400;
    color: #7a7a7a;
}

.nts-fieldset {
    border: none;
    padding: 0;
    margin: 0;
}

.nts-fieldset legend.nts-label {
    padding: 0;
}

/* ============================
   入力フィールド
   ============================ */

.nts-input {
    width: 100%;
    height: 48px;
    padding: 12px 16px;
    font-family: inherit;
    font-size: 16px;
    line-height: 1.5;
    color: #1a1a1a;
    background: #ffffff;
    border: 1px solid #d5d0c2;
    border-radius: 0;
    outline: none;
    transition: border-color 0.15s ease, background-color 0.15s ease;
    -webkit-appearance: none;
    appearance: none;
}

.nts-input::placeholder {
    color: #a0a0a0;
    font-weight: 400;
}

.nts-input:hover {
    border-color: #a8a39a;
}

.nts-input:focus {
    border-color: #1a1a1a;
    border-width: 2px;
    padding: 11px 15px;
    background: #fafaf7;
}

.nts-input:disabled {
    background: #f5f3ed;
    color: #999;
    cursor: not-allowed;
}

/* ============================
   ラジオボタン・チェックボックス
   ============================ */

.nts-radio-group,
.nts-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nts-radio-group-inline {
    flex-direction: row;
    gap: 32px;
    flex-wrap: wrap;
}

.nts-radio-label,
.nts-checkbox-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-size: 15px;
    color: #2c2c2c;
    line-height: 1.6;
    padding: 4px 0;
    user-select: none;
    transition: color 0.15s ease;
}

.nts-radio-label:hover,
.nts-checkbox-label:hover {
    color: #1a1a1a;
}

.nts-radio-label input[type="radio"],
.nts-checkbox-label input[type="checkbox"] {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin: 1px 12px 0 0;
    cursor: pointer;
    accent-color: #1a1a1a;
}

.nts-radio-label span,
.nts-checkbox-label span {
    flex: 1;
}

/* ============================
   条件付き表示フィールド
   ============================ */

.nts-conditional-field {
    margin-top: 16px;
    padding: 16px 20px;
    background: #fbf9f3;
    border-left: 2px solid #d5d0c2;
}

.nts-conditional-field .nts-input {
    background: #ffffff;
}

/* ============================
   注意事項・同意セクション
   ============================ */

.nts-consent-section {
    margin-top: 56px;
    border-bottom: none;
    padding-bottom: 0;
}

.nts-notice {
    margin-bottom: 24px;
    padding: 20px 24px;
    background: #fbf9f3;
    border-left: 3px solid #9a7d2a;
}

.nts-notice-text {
    margin: 0;
    font-size: 13px;
    line-height: 1.8;
    color: #4a4a4a;
}

.nts-consent-label {
    padding: 16px 20px;
    background: #fafaf7;
    border: 1px solid #e5e1d5;
    font-size: 14px;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.nts-consent-label:hover {
    background: #f5f3ed;
    border-color: #d5d0c2;
}

.nts-consent-label input[type="checkbox"]:checked + span {
    color: #1a1a1a;
    font-weight: 500;
}

/* ============================
   送信ボタン
   ============================ */

.nts-submit-wrapper {
    margin-top: 48px;
    text-align: center;
}

.nts-submit-button {
    display: inline-block;
    width: 100%;
    max-width: 400px;
    height: 56px;
    padding: 0 32px;
    font-family: inherit;
    font-size: 16px;
    font-weight: 500;
    color: #ffffff;
    background: #1a1a1a;
    border: none;
    border-radius: 0;
    cursor: pointer;
    letter-spacing: 0.1em;
    transition: background-color 0.2s ease, transform 0.1s ease;
    -webkit-appearance: none;
    appearance: none;
}

.nts-submit-button:hover {
    background: #000000;
}

.nts-submit-button:active {
    transform: translateY(1px);
}

.nts-submit-button:disabled {
    background: #999;
    cursor: not-allowed;
}

.nts-submit-button.nts-loading {
    background: #4a4a4a;
    cursor: wait;
    position: relative;
    color: transparent;
}

.nts-submit-button.nts-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ffffff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: nts-spinner 0.8s linear infinite;
}

@keyframes nts-spinner {
    to {
        transform: rotate(360deg);
    }
}

/* ============================
   ハニーポット(完全に隠す)
   ============================ */

.nts-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

/* ============================
   完了ページ
   ============================ */

.nts-success-wrapper {
    max-width: 680px;
    margin: 0 auto;
    padding: 80px 24px;
    text-align: center;
    font-family: "Noto Sans JP", -apple-system, "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", sans-serif;
}

.nts-success-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 32px;
    border: 2px solid #1a1a1a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #1a1a1a;
}

.nts-success-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 16px;
    letter-spacing: 0.05em;
}

.nts-success-text {
    font-size: 15px;
    color: #4a4a4a;
    line-height: 1.9;
    margin: 0 0 32px;
}

.nts-success-meta {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid #e5e1d5;
    font-size: 13px;
    color: #7a7a7a;
}

/* ============================
   レスポンシブ:タブレット
   ============================ */

@media (max-width: 768px) {
    .nts-form-wrapper {
        padding: 32px 16px;
    }

    .nts-form {
        padding: 40px 28px;
    }

    .nts-section {
        margin-bottom: 36px;
        padding-bottom: 36px;
    }

    .nts-section-title {
        font-size: 17px;
        margin-bottom: 24px;
    }
}

/* ============================
   レスポンシブ:スマートフォン
   ============================ */

@media (max-width: 480px) {
    .nts-form-wrapper {
        padding: 24px 12px;
    }

    .nts-form {
        padding: 32px 20px;
    }

    .nts-section {
        margin-bottom: 32px;
        padding-bottom: 32px;
    }

    .nts-section-title {
        font-size: 16px;
        margin-bottom: 20px;
    }

    .nts-label {
        font-size: 13px;
    }

    .nts-input {
        font-size: 16px;  /* iOS の自動ズーム防止のため16px維持 */
        height: 46px;
    }

    .nts-radio-group-inline {
        gap: 20px;
    }

    .nts-submit-button {
        max-width: 100%;
        height: 52px;
        font-size: 15px;
    }

    .nts-success-wrapper {
        padding: 60px 16px;
    }

    .nts-success-title {
        font-size: 19px;
    }

    .nts-success-text {
        font-size: 14px;
    }
}

/* ============================
   印刷スタイル(任意)
   ============================ */

@media print {
    .nts-form-wrapper {
        max-width: 100%;
        padding: 0;
    }

    .nts-form {
        border: none;
        padding: 0;
    }

    .nts-submit-wrapper {
        display: none;
    }
}

/* ============================
   SWELL テーマ対応:見出しスタイル上書き
   ============================ */

.nts-form-wrapper .nts-section-title,
.nts-form .nts-section-title,
h2.nts-section-title {
    display: block !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #1a1a1a !important;
    background: none !important;
    background-color: transparent !important;
    background-image: none !important;
    margin: 0 0 32px 0 !important;
    padding: 0 0 12px 0 !important;
    border: none !important;
    border-bottom: 2px solid #1a1a1a !important;
    border-radius: 0 !important;
    letter-spacing: 0.05em !important;
    text-align: left !important;
    line-height: 1.4 !important;
    box-shadow: none !important;
    text-shadow: none !important;
}

.nts-form-wrapper .nts-section-title::before,
.nts-form-wrapper .nts-section-title::after,
.nts-form .nts-section-title::before,
.nts-form .nts-section-title::after {
    display: none !important;
    content: none !important;
    background: none !important;
    border: none !important;
}
