* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    overflow: hidden;
}

.container {
    height: 100vh;
    width: 100vw;
    border: 12px solid #FF7B41;
    background-color: #f5f5f5;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
    overflow-y: auto;
    overflow-x: hidden;
}

.content-wrapper {
    width: 100%;
    max-width: 600px;
    padding: 15px 20px;
    margin: 0 auto;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.page-title {
    font-size: 1.5em;
    font-weight: bold;
    color: #FF7B41;
    text-align: center;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 0.9em;
    color: #666;
    text-align: center;
    margin-bottom: 20px;
}

.notice {
    font-size: 0.85em;
    color: #d9534f;
    text-align: center;
    margin-bottom: 15px;
    font-style: italic;
}

.contact-form {
    width: 100%;
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 2px solid #FF7B41;
}

.form-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: bold;
    color: #333;
    margin-bottom: 5px;
    font-size: 0.95em;
}

.form-group input,
.form-group textarea {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: Arial, sans-serif;
    font-size: 0.95em;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #FF7B41;
    box-shadow: 0 0 5px rgba(255, 123, 65, 0.3);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.submit-btn,
.reset-btn {
    padding: 12px 30px;
    font-size: 0.95em;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.submit-btn {
    background-color: #FF7B41;
    color: white;
}

.submit-btn:hover {
    background-color: #ff6a2a;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(255, 123, 65, 0.3);
}

.reset-btn {
    background-color: #ccc;
    color: #333;
}

.reset-btn:hover {
    background-color: #bbb;
    transform: translateY(-2px);
}

.form-message {
    margin-top: 15px;
    padding: 12px 15px;
    border-radius: 5px;
    text-align: center;
    font-weight: bold;
    display: none;
}

.form-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

.form-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}

#submission-result {
    display: none;
    background-color: #fff;
    padding: 20px;
    border-radius: 10px;
    border: 2px solid #FF7B41;
    margin-top: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

#submission-result.show {
    display: block;
}

.result-title {
    font-size: 1.2em;
    color: #FF7B41;
    margin-bottom: 15px;
    text-align: center;
    font-weight: bold;
}

.result-content {
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 15px;
    font-size: 0.95em;
    line-height: 1.8;
}

.result-content p {
    margin-bottom: 10px;
}

.result-content strong {
    color: #333;
    min-width: 100px;
    display: inline-block;
}

.result-message-text {
    white-space: pre-wrap;
    word-wrap: break-word;
    background-color: white;
    padding: 10px;
    border-radius: 3px;
    border-left: 3px solid #FF7B41;
    display: block;
    margin-top: 5px;
}

.return-home-btn {
    display: block;
    margin: 0 auto;
    padding: 12px 30px;
    background-color: #FF7B41;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 0.95em;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s;
}

.return-home-btn:hover {
    background-color: #ff6a2a;
    transform: translateY(-2px);
}

.footer-buttons {
    display: flex;
    gap: 10px;
    margin-top: auto;
    padding-bottom: 15px;
}

.home-button,
.back-button {
    padding: 10px 20px;
    font-size: 0.9em;
    background-color: #FF7B41;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.home-button:hover,
.back-button:hover {
    background-color: #ff6a2a;
    transform: translateY(-2px);
}

.footer {
    text-align: center;
    color: #999;
    font-size: 0.85em;
    padding-top: 15px;
    border-top: 1px solid #ddd;
    width: 100%;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .container {
        border-width: 8px;
        padding: 15px 0;
    }

    .content-wrapper {
        max-width: 100%;
        padding: 10px 15px;
    }

    .page-title {
        font-size: 1.3em;
        margin-bottom: 5px;
    }

    .subtitle {
        font-size: 0.85em;
        margin-bottom: 15px;
    }

    .notice {
        font-size: 0.8em;
        margin-bottom: 12px;
    }

    .contact-form {
        padding: 15px;
    }

    .form-group {
        margin-bottom: 12px;
    }

    .button-group {
        gap: 10px;
        margin-top: 15px;
    }

    .submit-btn,
    .reset-btn {
        padding: 10px 20px;
        font-size: 0.9em;
    }

    .footer-buttons {
        padding-bottom: 10px;
    }

    .home-button,
    .back-button {
        padding: 8px 15px;
        font-size: 0.85em;
    }
}

@media (max-width: 480px) {
    .container {
        border-width: 6px;
        padding: 10px 0;
    }

    .content-wrapper {
        padding: 8px 12px;
    }

    .page-title {
        font-size: 1.2em;
    }

    .contact-form {
        padding: 12px;
        gap: 8px;
    }

    .button-group {
        flex-direction: column;
        gap: 8px;
    }

    .submit-btn,
    .reset-btn {
        width: 100%;
        padding: 10px 15px;
    }

    .footer-buttons {
        flex-direction: column;
        width: 90%;
    }

    .home-button,
    .back-button {
        width: 100%;
        padding: 10px 15px;
    }

    #submission-result {
        padding: 15px;
        margin-top: 15px;
    }

    .result-title {
        font-size: 1.1em;
        margin-bottom: 12px;
    }

    .result-content {
        padding: 12px;
        font-size: 0.9em;
    }

    .result-content strong {
        display: block;
        margin-bottom: 3px;
    }

    .return-home-btn {
        padding: 10px 20px;
        font-size: 0.9em;
        width: 100%;
    }
}
