/*
Theme Name: AscendKit
Author: KieTo.Co
Description: カスタマイズが簡単なLP（ランディングページ）用テーマです。
Version: 1.0
*/

/* Basic Styles */
body {
    margin: 0;
    font-family: sans-serif;
}

/* Text Wrapping for Responsive */
h1, h2, h3, h4, h5, h6, p,
.section-title, .section-description,
.hero-heading, .hero-subheading,
.feature-heading, .feature-text,
.step-heading, .step-text,
.process-heading, .process-text,
.about-heading, .about-text,
.uservoice-name, .uservoice-text,
.achievement-title, .achievement-text {
    overflow-wrap: break-word;
    word-wrap: break-word; /* Legacy fallback */
}

.site-header, .site-footer {
    padding: 1rem 2rem;
    background-color: #f8f9fa;
}
.site-title a {
    text-decoration: none;
    color: #333;
}

.section-title {
    font-size: 2rem;
    margin-bottom: 4rem;
    letter-spacing: 2px;
    color: #333;
    text-align: center;
}

/* Hero Section */
.hero-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
    background-color: #ffffff;
    background-size: cover;
    background-position: center;
    color: #fff;
    text-align: center;
    padding: 2rem;
}

.hero-content {
    background-color: rgba(0, 0, 0, 0.5);
    padding: 2rem 3rem;
    border-radius: 5px;
    max-width: 80%;
}

.hero-heading {
    font-size: clamp(2.0rem, 6vw, 2.5rem); /* 自動調整フォントサイズ */
    margin-top: 0;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.hero-subheading {
    font-size: clamp(1.0rem, 3vw, 1.2rem); /* 自動調整フォントサイズ */
    margin: 0;
}

/* Features Section */
.features-section {
    padding: 6rem 2rem 8rem 2rem;
    text-align: center;
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
}

.features-grid-vertical {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.features-grid-vertical .feature-item {
    width: 100%;
    max-width: 700px;
}

.features-grid-horizontal {
    display: grid;
    gap: 2rem;
}

.features-grid-horizontal.features-grid-1 { grid-template-columns: 1fr; }
.features-grid-horizontal.features-grid-2 { grid-template-columns: repeat(2, 1fr); }
.features-grid-horizontal.features-grid-3 { grid-template-columns: repeat(3, 1fr); }
.features-grid-horizontal.features-grid-4 { grid-template-columns: repeat(2, 1fr); }

.features-grid-horizontal.features-grid-5 {
    grid-template-columns: repeat(6, 1fr);
}

.features-grid-5.features-layout-5-3-2 .feature-item:nth-child(-n+3) { grid-column: span 2; }
.features-grid-5.features-layout-5-3-2 .feature-item:nth-child(4) { grid-column: 2 / span 2; }
.features-grid-5.features-layout-5-3-2 .feature-item:nth-child(5) { grid-column: 4 / span 2; }

.features-grid-5.features-layout-5-2-3 .feature-item:nth-child(1) { grid-column: 2 / span 2; }
.features-grid-5.features-layout-5-2-3 .feature-item:nth-child(2) { grid-column: 4 / span 2; }
.features-grid-5.features-layout-5-2-3 .feature-item:nth-child(n+3) { grid-column: span 2; }

.feature-item {
    padding: 2rem;
    border: 1px solid #eee;
    border-radius: 5px;
    transition: box-shadow 0.3s;
}
.feature-item:hover { box-shadow: 0 5px 15px rgba(0,0,0,0.1); }

.feature-icon { font-size: 3rem; margin-bottom: 1rem; }
.feature-heading { font-size: 1.25rem; margin-top: 0; margin-bottom: 0.5rem; }
.feature-text { font-size: 0.95rem; color: #555; line-height: 1.7; }

/* Steps Section */
.steps-section {
    padding: 6rem 2rem 8rem 2rem;
}

.steps-container { max-width: 1200px; margin: 0 auto; }
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 4rem; align-items: start; }

.step-item {
    position: relative;
    padding: 3rem 3rem 2.5rem 3rem;
    border: 3px solid #eee;
    border-radius: 50px;
    text-align: left;
}

.step-number {
    position: absolute;
    top: -25px;
    left: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
}

.step-heading { font-size: 1.25rem; margin-top: 0; margin-bottom: 0.5rem; }
.step-text { font-size: 0.95rem; color: #555; line-height: 1.7; margin: 0; }

/* Process Section */
.process-section {
    padding: 6rem 2rem 8rem 2rem;
}

.process-container { max-width: 1200px; margin: 0 auto; text-align: center; }
.process-grid { display: flex; flex-direction: column; gap: 1rem; /* Reduced gap for vertical */ }
.process-item { width: 100%; text-align: center; }
.process-image { max-width: 100px; height: auto; margin-left: auto; margin-right: auto; margin-bottom: 1.5rem; border-radius: 5px; box-shadow: 0 5px 15px rgba(0,0,0,0.07); }
.process-heading { font-size: 1.25rem; margin-top: 0; margin-bottom: 0.5rem; }
.process-text { font-size: 0.95rem; color: #555; line-height: 1.7; margin: 0; }

/* Default Vertical/Mobile Connectors */
.process-arrow, .process-line {
    display: block;
    align-self: center;
}
.process-arrow {
    font-size: 2.5rem;
    line-height: 1;
}
.process-arrow::after {
    content: '↓';
}
.process-line {
    width: 2px;
    height: 3rem;
    background-color: #ccc;
}

/* Tablet & Desktop Overrides */
@media (min-width: 768px) {
    .process-grid {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        gap: 0; /* Reset gap for horizontal layout */
    }
    .process-grid-3 .process-item { width: 30%; }
    .process-grid-3 .process-arrow, .process-grid-3 .process-line { width: 5%; }
    .process-grid-4 .process-item { width: 22%; }
    .process-grid-4 .process-arrow, .process-grid-4 .process-line { width: 4%; }
    .process-grid-5 .process-item { width: 18%; }
    .process-grid-5 .process-arrow, .process-grid-5 .process-line { width: 2.5%; }

    .process-arrow::after {
        content: '→';
    }
    .process-line {
        width: auto; /* Allow flex-grow */
        height: 2px;
    }
}

/* About Section */
.image-section {
    padding: 0;
    position: relative;
    /* border: 1px solid #ccc; */
    margin: 6rem auto 8rem auto; /* Increased vertical margin */
    max-width: 1200px;
}
.about-staggered-layout {
    display: grid;
    grid-template-columns: repeat(12, 1fr); /* 12 column grid for flexibility */
    grid-template-rows: auto; /* Rows will size based on content */
    gap: 0; /* No gap between grid items */
    max-width: 1200px; /* Match parent max-width */
    margin: 0 auto; /* Center the layout */
    position: relative; /* For absolute positioning of heading */
    min-height: 500px; /* Minimum height for the staggered layout */
}
.about-container.about-staggered-layout {
    display: grid;
    grid-template-columns: repeat(12, 1fr); /* 12 column grid */
    grid-template-rows: repeat(4, 1fr); /* 4 rows for staggering */
    gap: 0;
    min-height: 500px;
    position: relative;
    grid-template-areas:
        "image image image image image image image . . . . ."
        "image image image image image image image content content content content content"
        "image image image image image image image content content content content content"
        ". . . . . . . content content content content content";
}
.about-image-column {
    grid-area: image;
    z-index: 1;
    overflow: hidden;
}
.about-image-column img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.about-content-column {
    grid-column: 7 / 13; /* Columns 7 to 12 (smaller) */
    grid-row: 2 / 5; /* Rows 2 to 4 */
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-right-section .about-image-column {
    grid-column: 6 / 13; /* Image on the right */
    grid-row: 1 / 4; /* Same rows as default image */
}
.image-right-section .about-content-column {
    grid-column: 1 / 7; /* Content on the left */
    grid-row: 2 / 5; /* Same rows as default content */
}
.about-content-box {
    box-sizing: border-box;
    padding: 3rem;
    color: #fff;
    background-color: #333; /* Dark background for content box */
    width: 100%; /* Fill the column width */
    height: 100%; /* Fill the column height */
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.about-heading {
    position: absolute;
    bottom: 15%;
    left: 5%;
    font-size: 2.5rem;
    font-weight: bold;
    color: #fff; /* Change to white */
    background-color: #333; /* Add black background */
    padding: 1rem 1.5rem; /* Add padding to the entire heading */
    z-index: 3;
    display: block;
    max-width: 80%;
    word-wrap: break-word;
}

.about-text {
    margin-bottom: 2rem;
    line-height: 1.8;
    color: #fff;
}
.about-button {
    color: #000;
    background-color: #fff;
    text-decoration: none;
    border: 1px solid #fff;
    padding: 0.75rem 1.5rem;
    transition: background-color 0.3s, color 0.3s;
    display: inline-flex;
    align-items: center;
}
.about-button:hover {
    background-color: #eee;
    color: #000;
}
.about-button .arrow {
    margin-left: 0.5rem;
    font-weight: bold;
}

/* Section Backgrounds */
.hero-section, .features-section, .steps-section, .process-section, .about-section { background-color: #ffffff; }
.site-main > section:nth-of-type(2n+3) { background-color: #f8f9fa; }

.image-right-section .about-heading {
    left: auto;
    right: 10%;
}



@media (max-width: 991px) {
    .image-section .about-container.about-staggered-layout {
        grid-template-columns: 1fr; /* Stack columns on small screens */
        grid-template-rows: auto; /* Auto height */
        min-height: auto;
    }
    /* New order: Image first */
    .image-section .about-image-column {
        grid-column: 1 / -1; /* Full width */
        grid-row: 1; /* Image above content */
        min-height: 300px; /* Smaller min-height for image */
    }
    /* New order: Content second */
    .image-section .about-content-column {
        grid-column: 1 / -1; /* Full width */
        grid-row: 2; /* Content below image */
        min-height: auto;
    }
    .image-section .about-heading {
        position: relative;
        bottom: auto;
        left: auto;
        right: auto; /* Explicitly reset right */
        transform: none;
        text-align: center;
        font-size: 2rem;
        margin-bottom: 1rem;
        color: #fff;
        background-color: #333;
        padding: 0.5rem 1rem;
        display: table;
        margin-left: auto;
        margin-right: auto;
        white-space: normal;
        max-width: 90%;
    }
    .image-section .about-content-box {
        padding: 2rem;
    }
}

/* User Voice Section */
.uservoice-section {
    padding: 6rem 2rem 8rem 2rem;
}

.uservoice-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.uservoice-grid {
    display: grid;
    gap: 2rem;
    text-align: left;
}

.uservoice-grid-1 { grid-template-columns: 1fr; }
.uservoice-grid-2 { grid-template-columns: repeat(auto-fit, minmax(400px, 1fr)); }
.uservoice-grid-3 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

.uservoice-item {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.07);
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.uservoice-content {
    margin-bottom: 1.5rem;
}

.uservoice-rating .star {
    color: #e0e0e0;
    font-size: 1.2rem;
}

.uservoice-rating .star.filled {
    color: #ffc107;
}

.uservoice-text {
    font-size: 0.95rem;
    line-height: 1.8;
    color: #555;
    margin-top: 1rem;
}

.uservoice-author {
    display: flex;
    align-items: center;
}

.uservoice-image {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 1rem;
}

.uservoice-image-placeholder {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #f0f0f0;
    margin-right: 1rem;
}

.uservoice-name {
    font-weight: bold;
    color: #333;
}

/* Achievements Section */
.achievements-section {
    padding: 6rem 2rem 8rem 2rem;
    background-color: #f8f9fa; /* Light gray background to stand out */
}

.achievements-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.section-description {
    font-size: 1.1rem;
    color: #666;
    max-width: 800px;
    margin: 0 auto 4rem auto;
    text-align: center;
}

.achievements-grid {
    display: grid;
    gap: 3rem;
}

.achievements-grid-1 { grid-template-columns: 1fr; }
.achievements-grid-2 { grid-template-columns: repeat(2, 1fr); }
.achievements-grid-3 { grid-template-columns: repeat(3, 1fr); }
.achievements-grid-4 { grid-template-columns: repeat(4, 1fr); }

.achievement-item {
    background-color: #fff;
    padding: 2.5rem 2rem;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.achievement-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.achievement-value {
    font-size: 3.5rem;
    font-weight: bold;
    color: #333;
    margin-bottom: 0.5rem;
}

.achievement-title {
    font-size: 1.2rem;
    font-weight: normal;
    color: #555;
    margin-top: 0;
    margin-bottom: 1rem;
}

.achievement-text {
    font-size: 0.9rem;
    color: #777;
    line-height: 1.6;
}

/* Free Section */
.free-section-styled {
    padding: 6rem 2rem 8rem 2rem;
}

.free-section-container {
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 767px) {
    /* Font size adjustments for mobile */
    .section-title { font-size: 1.8rem; }
    .feature-heading, .step-heading, .process-heading { font-size: 1.1rem; }
    .feature-text, .step-text, .process-text, .uservoice-text { font-size: 0.9rem; }

    .features-grid-horizontal {
        display: block;
    }

    .features-grid-horizontal .feature-item {
        margin-bottom: 2rem;
    }

    .features-grid-horizontal .feature-item:last-child {
        margin-bottom: 0;
    }

    .steps-grid,
    .uservoice-grid,
    .achievements-grid {
        grid-template-columns: 1fr !important;
    }

    /* New rule for about-heading on very small screens */
    .image-section .about-heading {
        font-size: 1.5rem; /* Further reduced for smaller screens */
        white-space: nowrap; /* Prevent wrapping */
        overflow: hidden; /* Hide overflowing content */
        text-overflow: ellipsis; /* Show ellipsis for truncated text */
        max-width: 100%; /* Use full available width */
    }
}

/* Logo Size Adjustment */
.site-branding img {
    max-width: 120px; /* Adjust this value as needed */
    width: auto !important;      /* Ensure width adjusts based on max-width */
    height: auto !important;     /* Maintain aspect ratio */
    display: block;   /* Helps with consistent rendering */
}

@media (min-width: 768px) {
    .hero-heading br {
        display: none; /* Hide <br> tags on larger screens */
    }
}
