/* Global Styles */
body {
    font-family: 'Hiragino Sans', 'Noto Sans JP', sans-serif;
    line-height: 1.7;
    background: linear-gradient(135deg, #3c2a21 0%, #4a3728 100%);
    color: #e8e9f0;
    position: relative;
}

/* Random Vertical Lines Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        repeating-linear-gradient(90deg,
            transparent 0,
            transparent calc(5% - 1px),
            rgba(255, 255, 255, 0.02) calc(5% - 1px),
            rgba(255, 255, 255, 0.02) 5%
        ),
        repeating-linear-gradient(90deg,
            transparent 0,
            transparent calc(13% - 1px),
            rgba(255, 255, 255, 0.015) calc(13% - 1px),
            rgba(255, 255, 255, 0.015) 13%
        ),
        repeating-linear-gradient(90deg,
            transparent 0,
            transparent calc(29% - 1px),
            rgba(255, 255, 255, 0.01) calc(29% - 1px),
            rgba(255, 255, 255, 0.01) 29%
        ),
        linear-gradient(45deg, #3c2a21 25%, transparent 25%),
        linear-gradient(-45deg, #3c2a21 25%, transparent 25%);
    background-size: 100% 100%, 100% 100%, 100% 100%, 20px 20px, 20px 20px;
    background-position: 0 0, 0 0, 0 0, 10px 0, 0 10px;
    opacity: 0.5;
    z-index: -1;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #2c1810 0%, #4a3728 100%);
    position: relative;
    overflow: hidden;
    padding: 8rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('assets/images/学校の建物.jpg') center/cover;
    opacity: 0.15;
    z-index: 0;
}

.hero-section .container {
    position: relative;
    z-index: 1;
    text-align: center;
}

/* Section Styles */
section {
    padding: 5rem 0;
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    margin: 2rem 0;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

section:first-of-type {
    padding-top: 0;
    background: none;
    border: none;
}

h2 {
    position: relative;
    padding-bottom: 1rem;
    margin-bottom: 3rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(to right, #8b5e34, #a67c52);
}

/* Image Wrapper */
.image-wrapper {
    height: 250px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Feature Cards */
.card {
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    background: linear-gradient(135deg, #4a3728 0%, #3c2a21 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    height: 100%;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.card-image-wrapper {
    height: 200px;
    overflow: hidden;
}

.card-img-top {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-body {
    padding: 2rem;
    color: #e8e9f0;
    background: linear-gradient(135deg, rgba(74, 55, 40, 0.9), rgba(60, 42, 33, 0.9));
}

.card ul {
    padding-left: 1.2rem;
    margin-bottom: 0;
}

/* Equal Height Rows */
.equal-height {
    display: flex;
    flex-wrap: wrap;
}

.equal-height > [class*='col-'] {
    display: flex;
    flex-direction: column;
}

/* Learning Environment Section */
.environment-card {
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 55, 40, 0.8), rgba(60, 42, 33, 0.8));
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.environment-card .content {
    padding: 1.5rem 0;
}

/* Study Scenes Section */
.scene-card {
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 55, 40, 0.8), rgba(60, 42, 33, 0.8));
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.scene-card h4 {
    color: #e8e9f0;
    margin: 1rem 0;
}

.scene-card p {
    color: #d1d1d1;
    text-align: justify;
    line-height: 1.8;
}

/* Success Stories Section */
.success-story {
    text-align: center;
    padding: 2rem;
    height: 100%;
    background: linear-gradient(135deg, rgba(74, 55, 40, 0.8), rgba(60, 42, 33, 0.8));
    border-radius: 8px;
    transition: transform 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.success-story:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* Results Section */
#results .badge {
    font-size: 1rem;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #8b5e34 0%, #a67c52 100%);
}

.list-group-item {
    border: none;
    margin-bottom: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    color: #e8e9f0;
    transition: all 0.2s ease;
    border-radius: 4px !important;
}

.list-group-item:hover {
    transform: translateX(5px);
    background: rgba(255, 255, 255, 0.05);
}

/* Contact Form */
.form-control {
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #e8e9f0;
}

.form-control:focus {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    box-shadow: 0 0 0 0.25rem rgba(139, 94, 52, 0.25);
}

/* Custom Button Styles */
.btn-primary {
    padding: 0.8rem 2rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #8b5e34 0%, #a67c52 100%);
    border: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(139, 94, 52, 0.3);
    background: linear-gradient(135deg, #a67c52 0%, #8b5e34 100%);
}

.btn-light {
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.9rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card, .list-group-item, .success-story, .scene-card, .environment-card {
    animation: fadeIn 0.6s ease-out forwards;
}

/* Text Colors */
.text-muted {
    color: #bbb !important;
}

.lead {
    color: #e8e9f0;
}

/* Form Labels */
.form-label {
    color: #e8e9f0;
}

/* Select Styling */
.form-select {
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #e8e9f0;
}

.form-select:focus {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Footer */
footer {
    background: linear-gradient(135deg, #2c1810 0%, #4a3728 100%);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.03);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .hero-section {
        padding: 4rem 0;
        text-align: center;
    }

    .card {
        margin-bottom: 1.5rem;
    }

    #results h3 {
        margin-top: 2rem;
    }

    section {
        padding: 3rem 0;
    }

    .image-wrapper {
        height: 200px;
    }
}