* {
    box-sizing: border-box
}

html {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans JP", sans-serif;
    color: #18211d;
    background: #f5f8f6
}

body {
    margin: 0
}

a {
    color: inherit
}

.site-header {
    background: #fff;
    border-bottom: 1px solid #dfe7e2;
    padding: 18px 22px;
    position: relative;
    text-align: center;
    z-index: 100
}

.header-inner {
    margin: auto;
    max-width: 1040px;
    position: relative
}

.header-brand {
    font-size: 16px;
    text-align: center
}

.header-icon {
    display: block;
    height: 42px;
    left: 0;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px
}

.header-icon img {
    display: block;
    height: 100%;
    width: 100%
}

.header-menu {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 101
}

.menu-toggle {
    align-items: center;
    background: #fff;
    border: 1px solid #d7e0db;
    border-radius: 10px;
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    height: 42px;
    justify-content: center;
    padding: 0;
    width: 42px
}

.menu-toggle:hover,
.menu-toggle[aria-expanded="true"] {
    background: #edf8f2;
    border-color: #9fcdb4
}

.menu-toggle span {
    background: #345247;
    border-radius: 2px;
    height: 2px;
    width: 18px
}

.menu-panel {
    background: #fff;
    border: 1px solid #dce5e0;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(24, 55, 41, .17);
    min-width: 190px;
    padding: 6px;
    position: absolute;
    right: 0;
    text-align: left;
    top: calc(100% + 8px);
    z-index: 102
}

.menu-panel[hidden] {
    display: none
}

.menu-panel a {
    align-items: center;
    border-radius: 8px;
    display: flex;
    gap: 9px;
    padding: 10px 12px;
    text-decoration: none
}

.menu-panel a:hover {
    background: #edf8f2;
    color: #116e49
}

.menu-panel a span {
    color: #168b5b;
    display: inline-block;
    font-size: 1.2rem;
    text-align: center;
    width: 20px
}

.brand {
    display: inline-block;
    text-decoration: none;
    font-size: 2.4rem;
    font-weight: 900;
    letter-spacing: .02em
}

.brand span {
    color: #168b5b
}

.site-header p {
    margin: 0;
    color: #6d7a73;
    font-size: .84rem
}

main {
    width: min(1040px, calc(100% - 28px));
    margin: auto
}

.hero {
    text-align: center;
    padding: 24px 0;
}

.hero h1 {
    font-size: clamp(1.8rem, 5vw, 3rem);
    margin: 0 0 8px
}

.lead {
    color: #66736c;
    margin: 0 0 16px;
    font-size: 14px;
}

.search-form {
    display: flex;
    gap: 9px;
    width: min(760px, 100%);
    margin: 0 auto
}

.search-field {
    flex: 1;
    min-width: 0;
    position: relative
}

.search-form input {
    width: 100%;
    border: 2px solid #cddad2;
    background: #fff;
    padding: 15px 17px;
    border-radius: 12px;
    font-size: 16px;
    outline: none
}

.suggestions {
    background: #fff;
    border: 1px solid #cddad2;
    border-radius: 12px;
    box-shadow: 0 10px 28px rgba(32, 59, 46, .16);
    left: 0;
    max-height: 330px;
    overflow-y: auto;
    position: absolute;
    right: 0;
    text-align: left;
    top: calc(100% + 6px);
    z-index: 20
}

.suggestions[hidden] {
    display: none
}

.suggestions a {
    border-top: 1px solid #edf1ef;
    display: grid;
    gap: 3px;
    padding: 10px 13px;
    text-decoration: none
}

.suggestions a:first-child {
    border-top: 0
}

.suggestions a:hover,
.suggestions a.active {
    background: #edf8f2
}

.suggestions strong {
    color: #116e49;
    font-size: .95rem
}

.suggestions span {
    color: #6d7a73;
    font-size: .78rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap
}

.suggestions-empty {
    color: #65726a;
    font-size: .84rem;
    line-height: 1.5;
    margin: 0;
    padding: 12px 13px
}

.search-form input:focus {
    border-color: #168b5b;
    box-shadow: 0 0 0 3px rgba(22, 139, 91, .11)
}

button {
    font: inherit;
    cursor: pointer
}

.search-form button,
.inline-form button {
    border: 0;
    background: #168b5b;
    color: #fff;
    font-weight: 800;
    border-radius: 12px;
    padding: 0 20px
}

.search-form button:disabled {
    background: #aab7b0;
    cursor: not-allowed;
    opacity: .75
}

.notice {
    max-width: 760px;
    margin: 15px auto 0;
    padding: 13px 15px;
    border-radius: 10px;
    text-align: left
}

.notice.error {
    background: #fff1f0;
    color: #9d2b25;
    border: 1px solid #f0cbc8
}

.notice.success {
    background: #ecf8f1;
    color: #17663f;
    border: 1px solid #c4e8d3
}

.inline-form {
    margin-top: 10px
}

.inline-form button {
    padding: 10px 14px
}

.dictionary {
    max-width: 860px;
    margin: 0 auto 34px
}

.word-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 16px;
}

.word-head h1 {
    font-size: clamp(2rem, 6vw, 3.4rem);
    margin: 2px 0
}

.eyebrow {
    font-size: .78rem;
    font-weight: 800;
    color: #168b5b
}

.reading {
    margin: 0;
    color: #66736c
}

.share {
    border: 1px solid #cfd8d3;
    background: #fff;
    border-radius: 9px;
    padding: 8px 12px
}

.card,
.list-card,
.word-cloud,
.about {
    background: #fff;
    border: 1px solid #dfe7e2;
    border-radius: 16px;
    box-shadow: 0 3px 18px rgba(32, 59, 46, .045)
}

.card {
    padding: 20px;
    margin: 16px 0
}

.card h2,
.list-card h2,
.word-cloud h2,
.about h2 {
    font-size: 1.15rem;
    margin: 0 0 16px
}

.about h2,
.dictionary .card h2,
.columns .list-card h2 {
    background: linear-gradient(90deg, #edf8f2 0%, #f7fbf9 72%, transparent 100%);
    border-left: 5px solid #168b5b;
    border-radius: 6px;
    color: #123d2c;
    font-size: 1.2rem;
    line-height: 1.45;
    padding: 10px 13px
}

.card p {
    line-height: 1.6
}

.summary-card {
    border-left: 5px solid #168b5b
}

.section-nav {
    border-top: 1px solid #e2e9e5;
    margin-top: 18px;
    padding-top: 16px
}

.section-nav>span {
    display: block;
    color: #65726a;
    font-size: .82rem;
    font-weight: 800;
    margin-bottom: 9px
}

.section-nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px
}

.section-nav-links a {
    background: #f1f8f4;
    border: 1px solid #cfe5d9;
    border-radius: 999px;
    color: #116e49;
    font-size: .84rem;
    font-weight: 700;
    padding: 7px 11px;
    text-decoration: none
}

.section-nav-links a:hover {
    background: #e3f3ea;
    border-color: #9fcdb4
}

.dictionary h2[id] {
    scroll-margin-top: 16px
}

.word-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px
}

.word-item {
    border: 1px solid #e2e9e5;
    background: #fbfdfc;
    border-radius: 12px;
    padding: 14px
}

.word-item p {
    font-size: .88rem;
    color: #647169;
    margin: 7px 0 0;
    line-height: 1.6
}

.related-word {
    color: #116e49;
    font-weight: 850;
    text-decoration: underline;
    text-decoration-color: #b8d8c8;
    text-underline-offset: 3px
}

.related-word:hover {
    color: #0b5538;
    text-decoration-color: currentColor
}

.disabled-word {
    color: #222;
    cursor: not-allowed;
    text-decoration: none
}

.bookmark-toggle {
    align-items: center;
    background: #fff;
    border: 1px solid #cfd8d3;
    border-radius: 999px;
    color: #536159;
    display: inline-flex;
    font-size: .82rem;
    font-weight: 700;
    gap: 3px;
    margin-top: 5px;
    padding: 7px 11px;
    transition: background-color .15s, border-color .15s, color .15s
}

.bookmark-toggle span {
    color: #ba8700;
    font-size: 1.15rem;
    line-height: .8
}

.bookmark-toggle:hover {
    background: #fff9e8;
    border-color: #d8bd72;
    color: #705500
}

.bookmark-toggle[aria-pressed="true"] {
    background: #fff8dc;
    border-color: #d9b64e;
    color: #705500
}

.personal-list-head {
    align-items: center;
    display: flex;
    justify-content: space-between;
    gap: 16px
}

.personal-list-head h1 {
    margin-bottom: 0
}

.clear-personal-list {
    background: #fff;
    border: 1px solid #cfd8d3;
    border-radius: 8px;
    color: #65726a;
    font-size: .82rem;
    padding: 7px 10px
}

.clear-personal-list:hover {
    background: #f5f7f6
}

.personal-list-empty {
    color: #738078;
    line-height: 1.7;
    margin: 20px 0 4px
}

.personal-entry-row {
    align-items: center;
    border-top: 1px solid #e7ece9;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px
}

.personal-entry-row:first-child {
    border-top: 0
}

.personal-entry-row>a {
    border: 0;
    min-width: 0
}

.personal-entry-remove {
    background: transparent;
    border: 0;
    color: #7a8780;
    font-size: .78rem;
    padding: 8px
}

.personal-entry-remove:hover {
    color: #a33a32;
    text-decoration: underline
}

.uncreated-word {
    align-items: center;
    display: inline-flex;
    flex-wrap: wrap;
    gap: 7px
}

.uncreated-word .related-word {
    color: #222;
    text-decoration: none
}

.create-word-form {
    display: inline-flex;
    margin: 0
}

.create-word-form button {
    background: #edf8f2;
    border: 1px solid #b8d8c8;
    border-radius: 7px;
    color: #116e49;
    font-size: .75rem;
    font-weight: 800;
    padding: 4px 8px
}

.create-word-form button:hover {
    background: #dff2e7;
    border-color: #8fc5a8
}

.create-word-form button:disabled {
    background: #f0f3f1;
    border-color: #d7ded9;
    color: #89948e;
    cursor: not-allowed
}

.related-word-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px
}

.related-word-top .related-word {
    font-size: 1.03rem
}

.copy-mini {
    border: 0;
    background: none;
    padding: 3px 5px;
    color: #718078;
    font-size: .75rem
}

.section-intro {
    color: #65726a;
    margin-top: -7px
}

.phrase-list {
    display: grid;
    gap: 10px
}

.phrase {
    border-top: 1px solid #e7ece9;
    padding: 12px 0
}

.phrase:first-child {
    border-top: 0;
    padding-top: 0
}

.phrase-top {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between
}

.phrase-top .related-word-label {
    font-size: 1.05rem;
    font-weight: 700
}

.phrase-top .create-word-form button {
    background: #edf8f2;
    border-color: #b8d8c8;
    color: #116e49
}

.phrase-top .create-word-form button:disabled {
    background: #f0f3f1;
    border-color: #d7ded9;
    color: #89948e
}

.phrase-top button {
    border: 1px solid #d7e0db;
    background: #fff;
    border-radius: 7px;
    padding: 5px 9px;
    font-size: .78rem
}

.copy-icon-button,
.phrase-top .copy-icon-button,
.related-word-top .copy-icon-button {
    align-items: center;
    background: #fff;
    border: 1px solid #cfd8d3;
    border-radius: 8px;
    color: #65726a;
    display: inline-flex;
    flex: 0 0 34px;
    height: 34px;
    justify-content: center;
    padding: 0;
    transition: background-color .15s, border-color .15s, color .15s;
    width: 34px
}

.copy-icon-button:hover {
    background: #edf8f2;
    border-color: #9fcdb4;
    color: #116e49
}

.copy-icon-button svg,
.copy-icon-button img {
    height: 18px;
    width: 18px
}

.copy-icon-button svg {
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8
}

.copy-icon-button img {
    display: block;
    opacity: .85
}

.copy-icon-button .check-icon {
    display: none;
    stroke-width: 2.4
}

.copy-icon-button.copied {
    background: #e5f5ec;
    border-color: #8fc9aa;
    color: #087344
}

.copy-icon-button.copied .copy-icon {
    display: none
}

.copy-icon-button.copied .check-icon {
    display: block
}

.phrase p {
    margin: 2px 0 0;
    color: #59665f;
    font-size: 14px;
}

.examples {
    padding-left: 1.4em;
    margin: 0
}

.examples li {
    padding: 2px 0;
    line-height: 1.6
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px
}

.chips a {
    background: #edf5f0;
    color: #276446;
    border-radius: 999px;
    padding: 7px 11px;
    font-size: .9rem;
    text-decoration: none
}

.chips a:hover {
    background: #dcece3;
    color: #174e34
}

.ai-note {
    color: #738078;
    font-size: .78rem;
    line-height: 1.7;
    padding: 0 6px
}

.problem-report {
    border-top: 1px solid #dfe7e2;
    margin-top: 22px;
    padding: 20px 4px 0
}

.problem-report-toggle {
    background: #fff;
    border: 1px solid #cfd8d3;
    border-radius: 8px;
    color: #536159;
    font-size: .84rem;
    font-weight: 700;
    padding: 8px 12px
}

.problem-report-toggle:hover {
    background: #f4f7f5;
    border-color: #aebbb4
}

#problem-report-panel {
    background: #fff;
    border: 1px solid #dfe7e2;
    border-radius: 12px;
    margin-top: 12px;
    padding: 18px
}

#problem-report-panel[hidden] {
    display: none
}

#problem-report-panel h2 {
    font-size: 1.05rem;
    margin: 0 0 14px
}

.problem-report-form label {
    display: block;
    font-size: .88rem;
    font-weight: 800;
    margin-bottom: 7px
}

.problem-report-form textarea {
    border: 1px solid #cddad2;
    border-radius: 9px;
    display: block;
    font: inherit;
    line-height: 1.6;
    padding: 11px 12px;
    resize: vertical;
    width: 100%
}

.problem-report-form textarea:focus {
    border-color: #168b5b;
    box-shadow: 0 0 0 3px rgba(22, 139, 91, .11);
    outline: none
}

.problem-report-actions {
    align-items: center;
    display: flex;
    justify-content: space-between;
    margin-top: 10px
}

.problem-report-count {
    color: #738078;
    font-size: .8rem
}

.problem-report-actions button {
    background: #168b5b;
    border: 0;
    border-radius: 8px;
    color: #fff;
    font-weight: 800;
    padding: 9px 18px
}

.problem-report-actions button:disabled {
    background: #aab7b0;
    cursor: not-allowed
}

.columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 16px 0
}

.list-card {
    padding: 21px
}

.entry-list {
    display: grid
}

.entry-list a {
    text-decoration: none;
    padding: 10px 2px;
    border-top: 1px solid #e7ece9;
    display: grid;
    gap: 3px
}

.entry-list a:first-child {
    border-top: 0
}

.entry-list a:hover strong {
    color: #168b5b
}

.entry-list span {
    color: #78847d;
    font-size: .8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis
}

.more-link {
    display: block;
    margin-top: 10px;
    padding: 11px;
    border-top: 1px solid #e7ece9;
    color: #168b5b;
    font-weight: 800;
    text-align: center;
    text-decoration: none
}

.chips .disabled-word {
    background: #f0f3f1;
    border-radius: 999px;
    padding: 7px 11px;
    font-size: .9rem
}

.more-link:hover {
    color: #0b5538;
    background: #f5faf7;
    border-radius: 8px
}

.expanded-list {
    margin: 0 auto 24px
}

.expanded-list h1 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    margin: 0 0 16px
}

.expanded-list .entry-list a {
    padding: 10px 2px
}

.expanded-list .entry-list span {
    line-height: 1.6;
    overflow: visible;
    text-overflow: clip;
    white-space: normal
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e7ece9
}

.pagination a {
    color: #168b5b;
    font-weight: 800;
    text-decoration: none
}

.pagination span {
    color: #78847d;
    font-size: .85rem
}

.about {
    padding: 24px;
    margin: 16px 0 24px
}

.word-cloud {
    padding: 20px;
    margin: 0 0 16px;
}

#word-cloud-heading {
    text-align: center;
}

.word-cloud-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px
}

.word-cloud-links a {
    display: inline-block;
    color: #176b49;
    background: #edf7f1;
    border: 1px solid #d5e9dd;
    border-radius: 999px;
    padding: 7px 13px;
    line-height: 1.25;
    text-decoration: none;
    transition: background-color .15s, border-color .15s, transform .15s
}

.word-cloud-links a:hover {
    color: #0b5538;
    background: #dcefe4;
    border-color: #b8d9c5;
    transform: translateY(-1px)
}

.word-cloud-size-1 {
    font-size: .85rem
}

.word-cloud-size-2 {
    font-size: 1rem;
    font-weight: 700
}

.word-cloud-size-3 {
    font-size: 1.15rem;
    font-weight: 850
}

.about p {
    color: #5d6962;
    line-height: 1.6;
    margin: 16px 0 0;
}

footer {
    text-align: center;
    margin: 16px 0;
    color: #849087;
    font-size: .8rem
}

@media(min-width:651px) {
    .dictionary {
        max-width: none
    }

    .search-form {
        width: 100%
    }
}

@media(max-width:650px) {
    main {
        width: min(100% - 20px, 1040px)
    }

    .hero {
        padding-top: 28px
    }

    .search-form {
        display: grid
    }

    .search-form button {
        padding: 14px
    }

    .word-grid,
    .columns {
        grid-template-columns: 1fr
    }

    .card {
        padding: 19px
    }

    .dictionary .card h2,
    .columns .list-card h2 {
        font-size: 1.08rem;
        padding: 9px 11px
    }

    .word-head {
        align-items: start
    }

    .share {
        white-space: nowrap
    }

    .site-header {
        padding: 14px
    }

    .header-menu {
        right: 0
    }

    .menu-toggle {
        height: 38px;
        width: 38px
    }

    .header-icon {
        height: 38px;
        width: 38px
    }

    .dictionary {
        margin-bottom: 20px
    }
}

.chips .chip-uncreated {
    background: #f0f3f1;
    border-radius: 999px;
    padding: 4px 5px 4px 11px;
    font-size: .9rem
}