:root {
    /* Brand / accent colors */
    --color-primary: #004680;
    --color-primary-deep: #130b56;
    --color-accent-red: #e83828;
    --color-accent-red-dark: #c41d0e;
    --color-accent-yellow: #ffe400;

    /* Grays & base */
    --color-text-main: #333;
    --color-text-sub: #555;
    --color-text-muted: #666;
    --color-border-line: #333;
    --color-bg-service: #e9f4ff;
    --color-bg-strength: #004680;
    --color-bg-voice: #f5f5f5;
    --color-bg-footer: #e5f4ff;
    --color-card-bg: #fdfdfd;
    --color-white: #fff;

    /* Shadows */
    --shadow-btn: 0 6px 12px rgba(0, 0, 0, 0.16);
    --shadow-box: 0 2px 4px rgba(0, 0, 0, 0.12);
    --shadow-hero-ribbon: 0 3px 5px rgba(0, 0, 0, 0.2);
    --shadow-card-soft: 0 2px 4px rgba(0, 0, 0, 0.08);

    /* Accent used for overlay effects (fallback for --accent usage) */
    --accent: rgba(0, 0, 0, 0.04);
}

/* Base */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: var(--color-text-main);
    font-size: 16px;
    font-family: 'Noto Sans JP', 游ゴシック体, YuGothic-M, 'Yu Gothic', YuGothic,
        'ヒラギノ角ゴシック Pro', 'Hiragino Kaku Gothic Pro', メイリオ, Meiryo, Osaka,
        'ＭＳ Ｐゴシック', 'MS PGothic', sans-serif;
    line-height: 1.8;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

section {
    padding: 40px;
}

.inner {
    margin: 0 auto;
    max-width: 980px;
}

h2.section-ttl {
    margin: 0 0 20px;
    text-align: center;
    letter-spacing: 0.1em;
    font-weight: 800;
    font-size: 24px;
}


p strong {
    color: var(--color-accent-red);
    font-weight: 800;
}

/* Hero */
.hero {
    position: relative;
    background: url('/assets/img/ias/ourservices/hero-main.jpg') no-repeat center/cover;
}

.hero-main {
    position: relative;
    display: flex;
    flex-direction: row;
    padding: 40px 0;
    min-height: 260px;

    align-items: flex-start;
    justify-content: space-between;
}

.hero-logo {
    position: absolute;
    top: 0;
    left: 0;
    width: 170px;
}

.hero-copy {
    margin-top: 70px;
    color: var(--color-primary-deep);
}

.hero-copy p.lead-top {
    margin: 0 0 8px;
    text-shadow: 1px 0 var(--color-white),
        -1px 0 var(--color-white),
        0 1px var(--color-white),
        0 -1px var(--color-white),
        1px 1px var(--color-white),
        -1px 1px var(--color-white),
        1px -1px var(--color-white),
        -1px -1px var(--color-white);
    letter-spacing: 0.15em;
    font-weight: 800;
    font-size: 42px;
}

.hero-copy h1 {
    margin: 0 0 10px;
    text-shadow: 1px 0 var(--color-white),
        -1px 0 var(--color-white),
        0 1px var(--color-white),
        0 -1px var(--color-white),
        1px 1px var(--color-white),
        -1px 1px var(--color-white),
        1px -1px var(--color-white),
        -1px -1px var(--color-white);
    letter-spacing: 0.08em;
    font-weight: 900;
    font-size: 55px;
    line-height: 1.4;
}

.hero-copy h1 strong {
    color: var(--color-accent-red);
}

.hero-copy p.lead-top span,
.hero-copy h1 span {
    font-size: smaller;
}

.hero-contact {
    position: absolute;
    right: 0;
    bottom: -25px;
    z-index: 2;
    overflow: hidden;
    will-change: auto;
}

.hero-contact.active {
    z-index: 3;
}

.hero-contact.active .hero-balloon {
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
    transform: translateY(-6px) scale(1.03);
}

.hero-balloon {
    position: relative;
    display: inline-block;
    box-sizing: border-box;
    margin: 1em 0;
    padding: 2.5rem 5px;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: var(--color-accent-yellow);
    text-align: center;
    font-weight: bold;
    font-size: 16px;
    line-height: 1.6;

    /* バルーン自体に常時ふわふわアニメーションを付与（親 transform の影響を受けない） */
    animation: hero-float 3.6s ease-in-out infinite;
    will-change: transform;
}

.hero-balloon:before {
    position: absolute;
    bottom: -3px;
    left: -2px;
    z-index: 0;
    border: 15px solid transparent;
    border-right: 15px solid var(--color-accent-yellow);
    content: '';
    -webkit-transform: rotate(-45deg);
    transform: rotate(-45deg);
}

.hero-balloon strong {
    font-size: 125%;
}

.hero-band {
    position: relative;
    z-index: 1;
    margin: 0 40px;

    /*font-weight: bold;*/
    padding: 10px 40px;
    background: var(--color-accent-red);
    color: var(--color-white);
    text-align: center;
    letter-spacing: 0.12em;
    font-size: 20px;
}

/*.hero-band::before,
        .hero-band::after {
            content: "";
            position: absolute;
            top: 100%;
            width: 0;
            height: 0;
            border-top: 12px solid var(--color-accent-red-dark);
            border-bottom: 0;
        }

        .hero-band::before {
            left: 0;
            border-right: 16px solid transparent;
        }

        .hero-band::after {
            right: 0;
            border-left: 16px solid transparent;
        }*/

.hero-band::before,
.hero-band::after {
    position: absolute;
    top: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-color: var(--color-accent-red) transparent;
    content: '';
}

.hero-band::before {
    left: -15px;
    border-width: 28px 0 28px 15px;
}

.hero-band::after {
    right: -15px;
    border-width: 28px 15px 28px 0;
}

/* Service */
.service {
    background: var(--color-bg-service);
}

.section-ttl {
    margin: 0 0 24px;
    text-align: center;
}

.section-ttl .sub {
    position: relative;
    display: block;
    margin-bottom: 8px;
    color: var(--color-primary-deep);
    letter-spacing: 0.12em;
    font-weight: 600;
    font-size: 20px;
}

.section-ttl .yel-marker {
    background: linear-gradient(transparent 60%, #ff6 60%);
    font-size: 24px;
}

.section-ttl .ttl-line {
    position: relative;
    display: inline-block;
    padding: 0 18px;
    letter-spacing: 0.1em;
    font-weight: 800;
    font-size: 28px;
}

.section-ttl .ttl-line strong {
    color: var(--color-accent-red);
}

.section-ttl .ttl-line::before,
.section-ttl .ttl-line::after {
    position: absolute;
    top: 50%;
    width: 60px;
    height: 1px;
    background: var(--color-border-line);
    content: '';
    transform: rotate(45deg);
}

.section-ttl .ttl-line::before {
    right: 100%;
    margin-right: 16px;
}

.section-ttl .ttl-line::after {
    left: 100%;
    margin-left: 16px;
    transform: rotate(-45deg);
}

.service-sub span {
    color: var(--color-accent-red);
    font-weight: bold;
}

.card-row {
    display: flex;

    gap: 20px;
    flex-wrap: wrap;
}

.card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 6px;
    background: var(--color-card-bg);
    box-shadow: var(--shadow-box);

    flex: 1 1 260px;
}

.card-img {
    overflow: hidden;
    width: 100%;
    height: 150px;
}

.card-img img {
    width: 100%;
    height: 100%;

    object-fit: cover;
}

.card-body {
    padding: 14px 16px 18px;
    text-align: center;
}

.card-body h3 {
    margin: 0 0 8px;
    font-weight: 700;
    font-size: 18px;
}

.card-body p,
.about-text p,
.point-text p,
.voice-text {
    font-weight: 400;
    font-size: 16px;
}

.btn-red {
    display: inline-block;
    padding: 8px 26px;
    border-radius: 20px;
    background: var(--color-accent-red);
    box-shadow: var(--shadow-btn);
    color: var(--color-white);
    letter-spacing: 0.06em;
    font-weight: 500;
    font-size: 15px;
    transition: background-color 0.2s ease,
        transform 0.15s ease,
        box-shadow 0.15s ease;
}

.btn-red:hover,
.btn-red:focus-visible {
    outline: none;
    background: #ff6a6a;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.22);
    transform: translateY(-2px);
}

.btn-red:active {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.18);
    transform: translateY(0);
}

.service .btn-red {
    display: block;
    margin: 0 auto;
    width: 90%;
    text-align: center;
}

/* About */
.about {
    display: flex;
    padding: 0 40px 0 0;

    gap: 20px;
    align-items: stretch;
}

.about-img {
    margin: 0;
    padding: 0;
    width: 100%;
    background: url('/assets/img/ias/ourservices/about.jpg') no-repeat right bottom;
    background-size: cover;

    flex: 0 0 40%;
}

.about-text {
    padding: 40px 40px 40px 24px;
    font-size: 13px;
    line-height: 1.8;

    flex: 1 1 55%;
}

.about-text h3 {
    margin: 0 0 10px;
    letter-spacing: 0.08em;
    font-weight: 800;
    font-size: 28px;
}

.about-text h3 span {
    display: block;
    font-size: 22px;
}

/* Strength */
.strength {
    padding-top: 0;
    background: var(--color-bg-strength);
}

.strength-head {
    color: var(--color-white);
    text-align: center;
    letter-spacing: 0.12em;
    font-weight: 600;
    font-size: 35px;
}

.strength-head span.yel {
    border-bottom: 1px solid var(--color-accent-yellow);
    color: var(--color-accent-yellow);
}

.strength-head span.yel strong {
    font-size: 76px;
}

.point-box {
    position: relative;
    margin-bottom: 18px;
    padding: 26px 24px;
    border-radius: 6px;
    background: var(--color-white);
    box-shadow: var(--shadow-card-soft);

    align-items: stretch;
}

.point-num {
    position: absolute;
    top: 10px;
    left: 0;
    padding: 0 10px;
    background: var(--color-accent-red);
    color: var(--color-white);
    text-align: center;
    font-weight: 700;
}

.point-num .small {
    margin-bottom: 4px;
    letter-spacing: 0.18em;
    font-size: 13px;
}

.point-num .big {
    font-size: 45px;
    line-height: 1.5;
}

.point-main {
    display: flex;

    gap: 18px;
}

.point-text {
    font-size: 14px;
    line-height: 1.9;

    flex: 1;
}

.point-text h3 {
    margin: 0 0 8px;
    padding-left: 100px;
    font-weight: 800;
    font-size: 24px;
}

.point-text .good-for {
    margin-top: 12px;
    background-color: #d5e6f6;
    font-weight: bold;
}

.point-text .good-for div {
    padding: 5px 10px;
    background-color: #00a0e9;
    color: #fff;
}

.point-text ul {
    margin: 8px 0 0 20px;
    padding: 10px;
}

.point-text li {
    margin-bottom: 4px;
}



.point-img {
    overflow: hidden;
    border-radius: 4px;

    flex: 0 0 350px;
    align-self: center;
}

.point-img img {
    width: 100%;
    height: 100%;

    object-fit: cover;
}

.point-box .btn-red {
    margin-top: 15px;
}

.point-box .point-btn {
    width: 100%;
    text-align: center;
}

/* Voice */
.voice-wrap {
    padding: 60px 40px 50px;
    background: url(/assets/img/ias/ourservices/p_da0290_s_da02909.jpg) var(--color-bg-voice);
    background-color: rgba(255, 255, 255, 0.6);

    background-blend-mode: lighten;
}

.voice-title {
    position: relative;
    margin: 0 0 28px;
    text-align: center;
    letter-spacing: 0.1em;
    font-weight: 800;
    font-size: 29px;
}

.voice-title::before {
    position: absolute;
    top: -26px;
    left: 50%;
    padding: 2px 16px;
    border-radius: 999px;
    background: var(--color-primary-deep);
    color: #fff;
    content: 'VOICE';
    letter-spacing: 0.16em;
    font-weight: 700;
    font-size: 12px;
    transform: translateX(-50%);
}

.voice-title::after {
    display: block;
    margin: 8px auto 0;
    width: 60px;
    height: 3px;
    border-radius: 999px;
    background: var(--color-primary-deep);
    content: '';
}

.voice-cards {
    display: flex;

    gap: 18px;
    flex-wrap: wrap;
}

.voice-card {
    padding: 18px 16px 20px;
    border-radius: 6px;
    background: var(--color-white);
    box-shadow: var(--shadow-card-soft);
    text-align: left;
    font-size: 13px;
    line-height: 1.8;

    flex: 1 1 calc(33.333% - 12px);
}

.voice-illust {
    margin: 0 auto 10px;
    width: 100px;
    height: 100px;
}

.voice-illust img {
    display: block;
    width: 100%;
    height: 100%;

    object-fit: contain;
}

.voice-text {
    margin: 0;
}


/* Footer */
footer {
    padding: 26px 40px 40px;
    background: linear-gradient(#86c2f4 0%, #fff 100%);
    font-size: 14px;
}

.footer-btn {
    position: relative;
    display: block;
    overflow: hidden;
    margin: 2rem auto 3rem auto;
    padding: 10px 15px;
    width: 600px;
    border-radius: 100vh;
    background-color: var(--color-accent-yellow);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    color: var(--color-text-main);
    text-align: center;
    text-decoration: none;
    font-weight: bold;
    font-size: 22px;
    transition: background-color 0.3s ease;
}

/* footer-btn の active スタイル（JSでトグルされる） */
.footer-btn.active {
    background-color: #ffd84d;
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.22);
    transform: translateY(-6px);
    /* 少し濃い黄で強調 */
}

.footer-btn.active::after {
    width: 100%;
    transition: width 0.18s ease;
}

.footer-btn .mail-icon {
    display: inline-block;
    width: 28px;
    height: 20px;
    background: url('/assets/img/ias/ourservices/mail-icon.png') no-repeat center/contain;
}

.footer-btn::after {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background-color: var(--accent);
    content: '';
    transition: width 0.3s ease;
}

.footer-btn:hover::after {
    width: 100%;
}

footer .inner {
    display: flex;

    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
}

footer .inner .ft-r {
    text-align: right;
    font-size: 0.8rem;
}

.footer-logo {
    margin-bottom: 15px;
    width: 150px;
}

footer p strong {
    color: var(--color-text-main);
    font-size: 16px;
}

/* Fade-in on scroll */
.fadein {
    opacity: 0;
    transition: opacity 0.7s ease, transform 0.7s ease;
    transform: translateY(30px);
}

.fadein.show {
    opacity: 1;
    transform: translateY(0);
}

/* Hero float keyframes: ゆっくり上下にふわっと動かす */
@keyframes hero-float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-12px);
    }

    100% {
        transform: translateY(0);
    }
}

/* より小さい振幅のモバイル用キーフレーム */
@keyframes hero-float-mobile {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }

    100% {
        transform: translateY(0);
    }
}

/* ユーザーが減速モードを希望している場合はアニメーションを無効化 */
@media (prefers-reduced-motion: reduce) {

    /* animation は .hero-balloon に付与しているため、そちらを無効化する */
    .hero-balloon {
        transition: none !important;
        animation: none !important;
    }
}

/* Responsive */
@media (max-width:500px) {

    .hero-band::before,
    .hero-band::after {
        display: none;
    }
}

@media (max-width: 767px) {
    section {
        padding: 26px 18px;
    }

    .hero-main {
        flex-direction: column;
        padding: 70px 18px 90px;
    }

    .hero-logo {
        left: 18px;
    }

    .hero-copy {
        margin-top: 15px;
    }

    .hero-copy p.lead-top {
        margin-bottom: 0;
        font-size: 24px;
    }

    .hero-copy h1 {
        font-size: 35px;
    }

    .hero-ribbon {
        top: 20px;
        right: 18px;
        width: 130px;
        height: 130px;
    }

    .hero-band::before {
        left: -15px;
        border-width: 22px 0 23px 15px;
    }

    .hero-band::after {
        right: -15px;
        border-width: 22px 15px 23px 0;
    }

    .card {
        flex: 1 1 350px;
    }

    .card-row,
    .about,
    .point-main,
    .voice-cards {
        flex-direction: column;
    }

    /* Mobile: stack about image above text and make image full-width */
    .about {
        padding: 0;
    }

    .about-img {
        min-height: 200px;
        width: 100%;
        background-position: center top;

        flex: 0 0 auto;
    }

    .about-text {
        padding: 16px 18px 0 18px;
    }

    .point-img {
        margin-top: 10px;
        width: 100%;

        flex-basis: auto;
    }

    .voice-title {
        font-size: 22px;
    }

    .voice-wrap {
        padding: 60px 18px 40px;
    }

    .voice-card {
        flex: 1 1 auto;
    }

    h2.section-ttl,
    .strength-head,
    .voice-title {
        font-size: 20px;
    }

    .section-ttl .ttl-line {
        display: inline-block;
        overflow: hidden;
        padding: 0 8px;
        max-width: 100%;
        vertical-align: middle;
        text-overflow: clip;
        white-space: nowrap;
        letter-spacing: 0.06em;
        font-size: 24px;
        line-height: 1.1;
    }

    .section-ttl .ttl-line::before,
    .section-ttl .ttl-line::after {
        display: none;
    }

    .about-text h3,
    .point-text h3,
    .card-body h3,
    .about-text h3 span {
        font-size: 20px;
    }

    .point-text h3 {
        height: 75px;
    }

    footer {
        padding: 26px 18px 34px;
    }

    .service .btn-red {
        max-width: none;
        width: 100%;
    }

    .strength {
        padding: 0 18px 32px;
    }

    .point-box {
        padding: 18px 16px;
    }

    footer .inner .ft-r {
        text-align: center;
    }

    /* モバイル向け: 全体調整 */
    .hero-main {
        padding: 60px 18px 80px;
        min-height: 220px;
    }

    .hero-logo {
        top: 8px;
        left: 18px;
        width: 120px;
    }

    .hero-band {
        margin: 12px 18px;
        padding: 8px 20px;
        letter-spacing: 0.08em;
        font-size: 16px;
    }

    .hero-contact {
        right: 18px;
        bottom: -35px;
        /* animation moved to .hero-balloon to avoid transform conflicts */
    }

    .hero-balloon {
        padding: 1.8rem 6px;
        width: 118px;
        height: 118px;
        font-size: 14px;
        animation: hero-float-mobile 3.6s ease-in-out infinite;
    }

    /* フッターの大きなボタンを小画面に合わせる */
    .footer-btn {
        box-sizing: border-box;
        max-width: none;
        width: 100%;
        font-size: 17px;
    }
}

/* Tablet (768px - 1024px) 向け調整: フォント、行間、ヒーローのバランスを最適化 */
@media (min-width: 768px) and (max-width: 1024px) {

    html,
    body {
        /* 基本の読みやすさを若干向上 */
        font-size: 15.5px;
        line-height: 1.75;
    }

    .hero-main {
        padding: 50px 30px 70px;
        min-height: 240px;
    }

    .hero-logo {
        top: 6px;
        left: 24px;
        width: 140px;
    }

    .hero-copy p.lead-top {
        font-size: 22px;
    }

    .hero-copy h1 {
        font-size: 36px;
        line-height: 1.35;
    }

    .hero-band {
        margin: 12px 24px;
        padding: 8px 24px;
        font-size: 17px;
    }

    .hero-band::before {
        left: -15px;
        border-width: 22px 0 23px 15px;
    }

    .hero-band::after {
        right: -15px;
        border-width: 22px 15px 23px 0;
    }

    h2.section-ttl {
        font-size: 22px;
    }

    .card-body h3,
    .point-text h3,
    .card-body h3 {
        font-size: 18px;
    }

    .voice-title {
        font-size: 28px;
    }

    .strength-head {
        font-size: 32px;
    }

    footer .inner {
        display: block;
    }

    .footer-btn {
        width: 80%;
        font-size: 20px;
    }

    .hero-contact {
        right: 24px;
        bottom: -18px;
    }

    .hero-balloon {
        padding: 2.1rem 6px;
        width: 140px;
        height: 140px;
        font-size: 15px;
        animation: hero-float-tablet 3.6s ease-in-out infinite;
    }

    @keyframes hero-float-tablet {
        0% {
            transform: translateY(0);
        }

        50% {
            transform: translateY(-10px);
        }

        100% {
            transform: translateY(0);
        }
    }
}
