/*
Theme Name: SWELL CHILD (ma-hikaku)
Theme URI: https://ma-hikaku.jp
Description: SWELL 子テーマ - M&A仲介比較.jp カスタム
Author: ma-hikaku editorial
Template: swell
Version: 1.1.0
Text Domain: swell_child
*/

/* ===== ma_agency archive / single ===== */
.ma-agency-card{
    display:flex;
    gap:24px;
    padding:20px;
    border:1px solid #e5e7eb;
    border-radius:12px;
    margin-bottom:16px;
    background:#fff;
    transition:box-shadow .2s ease;
}
.ma-agency-card:hover{box-shadow:0 6px 20px rgba(0,0,0,.08);}
.ma-agency-card__logo{flex:0 0 120px;}
.ma-agency-card__logo img{width:120px;height:120px;object-fit:contain;background:#f9fafb;border-radius:8px;}
.ma-agency-card__body{flex:1;min-width:0;}
.ma-agency-card__title{font-size:1.25rem;font-weight:700;margin:0 0 6px;}
.ma-agency-card__title a{color:#111827;text-decoration:none;}
.ma-agency-card__rating{color:#f59e0b;font-weight:700;margin-bottom:6px;}
.ma-agency-card__meta{color:#6b7280;font-size:.9rem;margin-bottom:8px;}
.ma-agency-card__summary{color:#374151;line-height:1.6;}
.ma-agency-card__badges{margin-top:8px;display:flex;flex-wrap:wrap;gap:6px;}
.ma-agency-card__badge{background:#eef2ff;color:#4338ca;padding:2px 8px;border-radius:999px;font-size:.75rem;}

.ma-agency-single__header{display:flex;gap:24px;align-items:flex-start;margin-bottom:24px;}
.ma-agency-single__logo img{width:160px;height:160px;object-fit:contain;background:#f9fafb;border-radius:12px;}
.ma-agency-single__title{font-size:1.75rem;font-weight:800;margin:0 0 8px;}
.ma-agency-single__rating{color:#f59e0b;font-weight:700;font-size:1.1rem;}
.ma-agency-single__table{width:100%;border-collapse:collapse;margin:16px 0;}
.ma-agency-single__table th,
.ma-agency-single__table td{border:1px solid #e5e7eb;padding:10px 14px;text-align:left;vertical-align:top;}
.ma-agency-single__table th{background:#f9fafb;width:30%;font-weight:600;}
.ma-agency-single__section{margin:28px 0;}
.ma-agency-single__section h2{border-left:4px solid #4338ca;padding-left:12px;font-size:1.25rem;}
.ma-agency-single__recommended li{margin-bottom:4px;}
.ma-agency-single__cta{display:inline-block;background:#4338ca;color:#fff;padding:12px 20px;border-radius:8px;text-decoration:none;font-weight:700;}
.ma-agency-single__cta:hover{background:#3730a3;}

/* ===== Search form wrapper ===== */
.ma-search-form{background:#f9fafb;padding:20px;border-radius:12px;margin-bottom:24px;}
.ma-search-form h2{margin-top:0;font-size:1.1rem;}

/* =========================================
 * FRONT PAGE
 * ========================================= */
.mh-front{color:#111827;}
.mh-wrap{max-width:1160px;margin:0 auto;padding:0 20px;}
.mh-h2{font-size:1.6rem;font-weight:800;margin:0 0 20px;letter-spacing:-.01em;}
.mh-muted{color:#6b7280;}

/* ---------- HERO ---------- */
.mh-hero{position:relative;overflow:hidden;color:#fff;margin-bottom:40px;}
.mh-hero__bg{position:absolute;inset:0;z-index:0;}
.mh-hero__bg svg{width:100%;height:100%;display:block;}
.mh-hero__inner{
    position:relative;z-index:1;
    max-width:1160px;margin:0 auto;padding:56px 20px 64px;
    display:grid;grid-template-columns:1fr 1fr;gap:40px;align-items:center;
}
.mh-hero__title{font-size:2.6rem;line-height:1.25;font-weight:900;margin:0 0 18px;letter-spacing:-.01em;}
.mh-hero__lead{font-size:1rem;line-height:1.7;opacity:.9;margin:0 0 18px;}
.mh-hero__chips{display:flex;flex-wrap:wrap;gap:8px;}
.mh-chip{display:inline-block;background:#fff;color:#4338ca;padding:6px 14px;border-radius:999px;font-weight:700;font-size:.85rem;}

/* ---------- WIZARD ---------- */
.mh-wizard{
    background:#ffffff;color:#111827;
    border-radius:20px;
    box-shadow:0 18px 50px rgba(15,23,42,.28);
    overflow:hidden;
    border:1px solid rgba(255,255,255,.4);
}
.mh-wizard__head{padding:22px 24px 10px;border-bottom:1px solid #f1f5f9;}
.mh-wizard__pill{display:inline-block;background:#eef2ff;color:#4338ca;padding:4px 12px;border-radius:999px;font-weight:700;font-size:.75rem;letter-spacing:.02em;}
.mh-wizard__title{margin:8px 0 4px;font-size:1.2rem;font-weight:800;}
.mh-wizard__sub{margin:0;color:#6b7280;font-size:.9rem;}
.mh-wizard__body{padding:18px 24px 24px;}
.mh-wizard__progress{height:6px;background:#f1f5f9;border-radius:999px;overflow:hidden;}
.mh-wizard__progress-bar{height:100%;width:0;background:linear-gradient(90deg,#4338ca,#2563eb);transition:width .25s ease;}
.mh-wizard__step-counter{margin-top:6px;font-size:.8rem;color:#6b7280;}
.mh-wizard__question{margin-top:16px;}
.mh-q__title{font-size:1.05rem;font-weight:800;margin-bottom:6px;}
.mh-q__hint{color:#6b7280;font-size:.85rem;margin-bottom:12px;}
.mh-q__opts{display:grid;grid-template-columns:1fr;gap:8px;}
.mh-opt{
    appearance:none;background:#f9fafb;border:1px solid #e5e7eb;
    border-radius:10px;padding:12px 14px;text-align:left;font-weight:600;
    cursor:pointer;transition:all .15s ease;color:#111827;font-size:.95rem;
}
.mh-opt:hover{background:#eef2ff;border-color:#c7d2fe;}
.mh-opt.is-active{background:#4338ca;border-color:#4338ca;color:#fff;}
.mh-wizard__nav{display:flex;gap:8px;margin-top:14px;}
.mh-btn{appearance:none;border:1px solid transparent;border-radius:8px;padding:8px 14px;font-weight:700;cursor:pointer;font-size:.85rem;}
.mh-btn--ghost{background:#fff;border-color:#e5e7eb;color:#4338ca;}
.mh-btn--ghost:hover{background:#eef2ff;}
.mh-btn--ghost:disabled{opacity:.45;cursor:not-allowed;}
.mh-btn--primary{background:#4338ca;color:#fff;}
.mh-btn--primary:hover{background:#3730a3;}

.mh-wizard__result{margin-top:14px;border-top:1px dashed #e5e7eb;padding-top:14px;}
.mh-result__title{font-size:1rem;font-weight:800;margin:0 0 10px;}
.mh-result__list{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:12px;}
.mh-result__item{display:flex;gap:12px;padding:12px;border:1px solid #e5e7eb;border-radius:12px;background:#f9fafb;}
.mh-result__rank{flex:0 0 auto;background:#4338ca;color:#fff;border-radius:8px;padding:4px 10px;font-weight:800;height:fit-content;}
.mh-result__body{flex:1;min-width:0;}
.mh-result__name{font-weight:800;color:#111827;text-decoration:none;font-size:1.05rem;}
.mh-result__name:hover{color:#4338ca;}
.mh-result__rating{color:#f59e0b;font-weight:700;font-size:.85rem;margin-top:2px;}
.mh-result__tags{display:flex;flex-wrap:wrap;gap:4px;margin:6px 0;}
.mh-result__tags span{background:#eef2ff;color:#4338ca;border-radius:999px;padding:2px 8px;font-size:.7rem;font-weight:700;}
.mh-result__excerpt{color:#374151;font-size:.85rem;line-height:1.55;margin:4px 0;}
.mh-result__link{font-size:.8rem;font-weight:700;color:#4338ca;text-decoration:none;}
.mh-result__foot{margin-top:14px;text-align:right;}

.mh-loader{height:6px;background:linear-gradient(90deg,#e5e7eb 0%,#4338ca 50%,#e5e7eb 100%);background-size:200% 100%;animation:mhPulse 1.2s infinite linear;border-radius:999px;margin-top:10px;}
@keyframes mhPulse{0%{background-position:200% 0}100%{background-position:-200% 0}}

/* ---------- SECTIONS ---------- */
.mh-section{padding:48px 0;}
.mh-cat-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;}
.mh-cat{
    display:flex;flex-direction:column;gap:4px;
    padding:18px 20px;border:1px solid #e5e7eb;border-radius:14px;
    background:#fff;text-decoration:none;color:#111827;
    transition:all .15s ease;
}
.mh-cat:hover{transform:translateY(-2px);box-shadow:0 10px 26px rgba(15,23,42,.08);border-color:#c7d2fe;}
.mh-cat span{font-weight:800;font-size:1.05rem;}
.mh-cat em{font-style:normal;color:#6b7280;font-size:.85rem;}

.mh-pick-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;}
.mh-pick-card{
    display:flex;flex-direction:column;gap:6px;
    padding:16px 18px;border:1px solid #e5e7eb;border-radius:12px;
    background:#fff;text-decoration:none;color:#111827;transition:all .15s ease;
}
.mh-pick-card:hover{box-shadow:0 10px 26px rgba(15,23,42,.08);border-color:#c7d2fe;}
.mh-pick-card__title{font-weight:800;font-size:1.05rem;}
.mh-pick-card__rating{color:#f59e0b;font-weight:700;font-size:.85rem;}
.mh-pick-card__tags{display:flex;flex-wrap:wrap;gap:4px;}
.mh-pick-card__tags span{background:#eef2ff;color:#4338ca;border-radius:999px;padding:2px 8px;font-size:.7rem;font-weight:700;}
.mh-pick-card__excerpt{color:#6b7280;font-size:.85rem;line-height:1.55;}

.mh-about{background:#f9fafb;}
.mh-about__lead{max-width:860px;color:#374151;line-height:1.8;}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 960px){
    .mh-hero__inner{grid-template-columns:1fr;padding:40px 20px;}
    .mh-hero__title{font-size:2rem;}
    .mh-cat-grid,.mh-pick-grid{grid-template-columns:1fr 1fr;}
}
@media (max-width: 640px){
    .mh-hero__title{font-size:1.6rem;}
    .mh-cat-grid,.mh-pick-grid{grid-template-columns:1fr;}
}
