.dictionary-page { min-height: 100vh; }
.dictionary-nav { display: flex; align-items: center; gap: 5px; }
.dictionary-nav a { min-height: 42px; padding: 9px 14px; border-radius: 10px; color: #34465c; font-size: 14px; font-weight: 750; text-decoration: none; }
.dictionary-nav a:hover, .dictionary-nav .is-active { color: var(--navy); background: #eef5fc; }
.dictionary-nav .dictionary-login { margin-left: 7px; padding-inline: 18px; border-radius: 999px; color: #fff; background: var(--navy); }
.dictionary-nav .dictionary-login:hover { color: #fff; background: var(--navy-deep); }
.dictionary-page .primary-nav > .is-active { color: var(--navy); background: #eef5fc; }

.dictionary-hero { position: relative; min-height: calc(100vh - 86px); overflow: hidden; padding: clamp(64px, 8vw, 112px) 0; background: radial-gradient(circle at 9% 18%, rgba(202,165,101,.21), transparent 25rem), linear-gradient(118deg, #fff 0%, #fbf8f2 50%, #eee4d4 100%); }
.dictionary-hero::after { position: absolute; right: -180px; bottom: -240px; width: 600px; height: 600px; border: 1px solid rgba(169,79,50,.1); border-radius: 50%; box-shadow: 0 0 0 75px rgba(169,79,50,.025), 0 0 0 150px rgba(169,79,50,.018); content: ""; }
.dictionary-hero__inner { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(460px,.9fr) minmax(0,1.1fr); align-items: start; gap: clamp(64px,6vw,88px); }
.dictionary-intro { min-width: 0; padding-top: 25px; }
.dictionary-intro h1 { margin: 0; color: var(--navy-deep); font-family: Georgia,"Times New Roman",serif; font-size: clamp(3.3rem,5.5vw,5.8rem); line-height: .98; letter-spacing: -.035em; }
.dictionary-intro h1 span { color: var(--terracotta); }
.dictionary-intro > p:last-child { max-width: 560px; margin: 30px 0 0; color: var(--ink-soft); font-size: 18px; line-height: 1.72; }

.dictionary-panel { min-width: 0; min-height: 390px; padding: clamp(26px,4vw,45px); border: 1px solid rgba(25,47,72,.14); border-radius: 28px; background: rgba(255,255,255,.94); box-shadow: 0 30px 80px rgba(24,35,49,.16); backdrop-filter: blur(12px); }
.dictionary-search label { display: block; margin-bottom: 10px; color: var(--navy-deep); font-size: 13px; font-weight: 800; }
.dictionary-search__row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.dictionary-search input { width: 100%; min-width: 0; height: 58px; padding: 12px 18px; border: 1px solid #c5d1df; border-radius: 14px; color: var(--ink); background: #fff; font-family: Georgia,"Times New Roman",serif; font-size: 20px; outline: none; }
.dictionary-search input:focus { border-color: var(--navy); box-shadow: 0 0 0 4px rgba(18,63,121,.1); }
.dictionary-search button { display: flex; min-width: 158px; align-items: center; justify-content: center; gap: 12px; padding: 12px 20px; border: 0; border-radius: 14px; color: #fff; background: var(--terracotta); cursor: pointer; font-weight: 800; }
.dictionary-search button:hover { background: var(--terracotta-dark); }
.dictionary-search button:disabled { cursor: wait; opacity: .7; }
.dictionary-examples { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 13px; color: #718093; font-size: 12px; }
.dictionary-examples button { padding: 5px 9px; border: 1px solid #d9e1e9; border-radius: 999px; color: var(--navy); background: #f7fafc; cursor: pointer; font-family: Georgia,"Times New Roman",serif; }
.dictionary-examples button:hover { border-color: #b6c7d9; background: #eef5fc; }
.dictionary-privacy { margin: 14px 0 0; color: #7a8795; font-size: 11px; line-height: 1.5; }
.dictionary-privacy a { color: var(--navy); font-weight: 700; }

.dictionary-status { margin-top: 30px; padding: 16px 18px; border-radius: 12px; color: var(--navy); background: #eef5fc; font-size: 14px; font-weight: 700; }
.dictionary-status.is-loading::before { display: inline-block; width: 15px; height: 15px; margin-right: 10px; border: 2px solid rgba(18,63,121,.2); border-top-color: var(--navy); border-radius: 50%; vertical-align: -3px; content: ""; animation: dictionary-spin .8s linear infinite; }
.dictionary-status.is-error { color: #782e27; background: #f9e8e5; }
@keyframes dictionary-spin { to { transform: rotate(360deg); } }

.dictionary-result { margin-top: 32px; }
.result-heading { display: grid; grid-template-columns: minmax(0,.8fr) minmax(220px,1.2fr); align-items: end; gap: 25px; padding: 24px 0 20px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.result-heading > div { min-width: 0; }
.result-heading span { color: var(--terracotta); font-size: 11px; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.result-heading h2 { max-width: 100%; margin: 3px 0 0; overflow-wrap: anywhere; color: var(--navy-deep); font-family: Georgia,"Times New Roman",serif; font-size: clamp(2rem,4vw,3.3rem); line-height: 1; }
.result-heading p { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.55; }
.result-heading--word { grid-template-columns: minmax(0,1fr); align-items: start; gap: 16px; }
.result-heading--word h2 { font-size: clamp(2.35rem,6vw,4.4rem); }
.result-heading--word .result-translation { width: 100%; }
.result-translation { padding: 14px 17px; border-left: 3px solid var(--terracotta); border-radius: 0 12px 12px 0; background: #fff8f3; }
.result-translation span { display: block; margin-bottom: 4px; color: var(--terracotta); font-size: 10px; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.result-translation p { color: var(--navy-deep); font-family: Georgia,"Times New Roman",serif; font-size: 18px; font-weight: 700; }
.dictionary-entries { display: grid; gap: 13px; margin-top: 18px; }
.dictionary-entry { position: relative; padding: 22px 23px; overflow: hidden; border: 1px solid rgba(202,165,101,.4); border-radius: 17px; background: #fffdf9; }
.entry-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.entry-number { color: #b7955c; font-family: Georgia,serif; font-size: 11px; }
.entry-word-class { padding: 4px 8px; border-radius: 999px; color: #466457; background: #edf5f1; font-size: 10px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.dictionary-entry h2 { margin: 8px 0 0; color: var(--navy-deep); font-family: Georgia,"Times New Roman",serif; font-size: 26px; }
.entry-morphology { display: inline-flex; margin: 8px 0 0; padding: 5px 9px; border-radius: 7px; color: #fff; background: var(--navy); font-size: 12px; font-weight: 800; letter-spacing: .035em; }
.entry-lemma { display: flex; flex-wrap: wrap; gap: 8px; margin: 13px 0 0; color: #56677a; font-family: Georgia,"Times New Roman",serif; font-size: 16px; font-style: italic; }
.entry-lemma span { color: var(--gold); font-style: normal; }
.entry-conjugation { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; gap: 10px; margin-top: 18px; padding: 10px 16px; border: 1px solid var(--navy); border-radius: 999px; color: #fff; background: var(--navy); font-size: 13px; font-weight: 800; text-decoration: none; transition: background .2s ease, transform .2s ease, box-shadow .2s ease; }
.entry-conjugation:hover, .entry-conjugation:focus-visible { color: #fff; background: var(--navy-deep); box-shadow: 0 0 0 3px rgba(18,63,121,.14); outline: none; transform: translateY(-1px); }
.entry-translation { margin: 17px 0 0; color: var(--terracotta-dark); font-family: Georgia,"Times New Roman",serif; font-size: 22px; font-weight: 700; }
.entry-meanings { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0 0; padding: 0; list-style: none; }
.entry-meanings li { padding: 6px 10px; border: 1px solid #dbe3eb; border-radius: 9px; color: #40536a; background: #f8fafc; font-size: 13px; }
.entry-constructions { margin-top: 20px; padding-top: 17px; border-top: 1px solid var(--line); }
.entry-constructions h3 { margin: 0 0 10px; color: var(--navy-deep); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.entry-constructions ul { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; }
.entry-constructions li { padding: 12px 13px; border-radius: 11px; background: #f2f6fa; }
.entry-constructions li > div { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.entry-constructions strong { color: var(--navy-deep); font-size: 13px; }
.entry-constructions code { padding: 3px 6px; border-radius: 5px; color: var(--terracotta-dark); background: #fff; font-family: Georgia,"Times New Roman",serif; font-size: 12px; }
.entry-constructions p { margin: 5px 0 0; color: #667688; font-size: 12px; line-height: 1.5; }
.entry-note { display: flex; gap: 9px; margin: 15px 0 0; color: #667688; font-size: 12px; line-height: 1.55; }
.entry-note span { display: grid; width: 18px; height: 18px; flex: 0 0 18px; place-items: center; border-radius: 50%; color: #fff; background: var(--gold); font-family: Georgia,serif; font-weight: 700; }
.dictionary-empty { margin-top: 28px; padding: 22px; border: 1px solid #e0d4c3; border-radius: 15px; background: #fffaf2; }
.dictionary-empty strong { color: var(--navy-deep); }
.dictionary-empty p { margin: 5px 0 0; color: var(--ink-soft); }

.dictionary-about { padding: 72px 0; background: var(--paper-deep); }
.dictionary-about__grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.dictionary-about article { padding: 27px; border-left: 2px solid rgba(169,79,50,.32); }
.dictionary-about article > span { color: var(--terracotta); font-family: Georgia,serif; font-size: 12px; font-weight: 700; }
.dictionary-about h2 { margin: 8px 0 7px; color: var(--navy-deep); font-family: Georgia,"Times New Roman",serif; font-size: 22px; }
.dictionary-about p { margin: 0; color: var(--ink-soft); font-size: 14px; line-height: 1.6; }

@media (max-width: 1100px) {
    .dictionary-hero__inner { grid-template-columns: 1fr; }
    .dictionary-intro { padding-top: 0; text-align: center; }
    .dictionary-intro > p:last-child { margin-inline: auto; }
}
@media (max-width: 650px) {
    .dictionary-nav > a:not(.is-active):not(.dictionary-login) { display: none; }
    .dictionary-nav a { padding-inline: 10px; }
    .dictionary-nav .dictionary-login { margin-left: 0; padding-inline: 13px; }
    .dictionary-hero { min-height: 0; padding: 50px 0 62px; }
    .dictionary-intro h1 { font-size: clamp(3rem,15vw,4.6rem); }
    .dictionary-panel { padding: 22px 16px; border-radius: 20px; }
    .dictionary-search__row { grid-template-columns: 1fr; }
    .dictionary-search button { min-height: 52px; }
    .result-heading { grid-template-columns: 1fr; gap: 10px; }
    .dictionary-about__grid { grid-template-columns: 1fr; }
    .dictionary-about article { padding: 18px 22px; }
}
@media (prefers-reduced-motion: reduce) {
    .dictionary-status.is-loading::before { animation: none; }
}
