/* ============================================
   STYLESHEET: normal.css
   Organization: By purpose/function (best practice)
   Last updated: Nov 2025
============================================ */

/* ============================================
   SECTION 1: IMPORTS & VARIABLES
============================================ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;600&display=swap');
@import "Eurostile/Eurostile.css";
@import "Glass_TTY_VT220/Glass_TTY_VT220.css";

:root {
    /* Color Variables */
    --monkey-shit-brown: #462B10;
    --liddell: #3ac9fd;
    
    --cool-gray: #6E6E6E;
    --dusty-sun: #FCE3C2;
    --dustyrose: #d85282;
    --fanti-blue: #0066cc;
    --ink: #1E1E1E;
    --jianti-red: #cc0000;
    --pure-white: #ffffff;
    --saffron: #F4B942;
    --silver: #ddd;
    --soft-ivory: #FFFBF4;
    --tangerine: #F05A28;
    
    /* Font Stacks */
    --font-system: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-sans: "Helvetica", "Helvetica Neue", "Arial", sans-serif;
    --font-cjk: "Noto Sans SC", "Noto Sans CJK SC", "Noto Sans CJK JP", "Simsun (Founder Extended)", "SimSun-ExtB", sans-serif;
    --font-cjk-alt: "Noto Sans SC", "Noto Sans", "Helvetica Neue", "Eurostile", "Inter", "Simsun (Founder Extended)", "SimSun-ExtB", "MingLiU-ExtB", sans-serif;
    --font-heading: "Helvetica", "Helvetica Neue", "Arial", sans-serif;
    --font-mono: "Glass_TTY_VT220", "Space Mono", monospace;
    --font-serif: serif;
}

/* ============================================
   SECTION 2: BASE & GLOBAL STYLES
============================================ */

body {
    font-family: var(--font-cjk-alt);
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    box-sizing: border-box;
    background-image: url('../images/50brown.png');
    background-repeat: repeat;
    background-size: 2%;
    background-attachment: scroll;    
}

main {
    flex: 1;
    margin-top: 2rem;
    padding: 3rem clamp(1rem, 6vw, 4rem);
    background: var(--soft-ivory);
    border-radius: 40px;
    box-shadow: 0 45px 80px rgba(30, 30, 30, 0.08);
}

/* ============================================
   SECTION 3: TYPOGRAPHY & HEADINGS
============================================ */

/* ============================================
   SECTION 4: FORM ELEMENTS & INPUTS
============================================ */

input[type="text"],
input[type="password"],
input[type="email"] {
    width: 100%;
    background: var(--soft-ivory);
    color: var(--ink);
    border: 1px solid rgba(30, 30, 30, 0.15);
    border-radius: 12px;
    font-size: 1rem;
    padding: 0.9rem 1.1rem;
    margin-top: 0.5rem;
    transition: border-color 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus {
    border-color: var(--tangerine);
    outline: none;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(240, 90, 40, 0.15);
}

button,
input[type="submit"] {
    border: none;
    border-radius: 999px;
    color: var(--soft-ivory);
    font-weight: 600;
    letter-spacing: 0.1rem;
    padding: 0.9rem 1.8rem;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
}

button:hover,
input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 20px rgba(243, 116, 19, 0.35);
}

textarea {
    width: 100%;
    min-height: 300px;
    padding: 10px;
    font-family: var(--font-sans);
    border: 1px solid var(--cool-gray);
    box-sizing: border-box;
    font-size: 12px;
    background-color: var(--pure-white);
}

/* ============================================
   SECTION 5: LAYOUT & CONTAINER STYLES
============================================ */

/* Page Layout Containers */
.radical-detail,
.school-detail,
.usenet-detail,
.about-page,
.donate-page,
.name-index-container,
.syllable-index-container,
.radical-index-container {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Main Content Container */
.content-container {
    font-family: var(--sans);
    padding: 50px;
    max-width: 900px;
    margin: 0 auto;
    line-height: 1.6;
    color: var(--ink);
}

.content-container p {
    margin: 0 0 15px 0;
    text-align: justify;
}

/* Text-only Content Area */
.textonly-content {
    background-color:var(--silver);
    padding: 20px;
    border-radius: 5px;
    margin: 20px 0;
    font-family: var(--sans) !important;
}

.textonly-content h3 {
    margin-top: 0;
    font-size: 16px;
    color: #333;
}

/* Back Navigation Link */
.back-link {
    display: inline-block;
    margin: 20px 20px 0 20px;
    padding: 10px 15px;
    background-color: var(--silver);
    border-radius: 3px;
    text-decoration: none;
    color: var(--liddell);
    transition: background-color 0.2s;
    font-size: 14px;
}

.back-link:hover {
    background-color: var(--silver);
}

/* Spacer with Background */
.tier-spacer {
    height: 10px; 
}

/* ============================================
   SECTION 6: PAGE HEADERS & FOOTERS
============================================ */

.page-header {
    font-family: var(--font-heading);
    background: rgb(70 43 16 / 0.90);
    padding: 15px;
    padding-left: 20px;
    text-align: left;
}

.page-header h1 {
    color: var(--liddell);
    font-size: clamp(2rem, 4vw, 3.2rem);
}

.page-header h2 {
    color: var(--pure-white);
    font-size: clamp(0.85rem, 1.5vw, 1rem);
}

.page-header a {
    color: var(--liddell);
}

.page-header a:visited {
    color: var(--liddell);
}

.page-header h1 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: bold;
}

.page-header h1 a {
    text-decoration: none;
    cursor: pointer;
}

.page-header p {
    margin: 0;
    color: var(--silver);
    font-size: 13px;
}

/* Page Footer */
.page-footer {
    text-align: center;
    margin: 0;
    padding: 15px;
    border-top: none;
    font-family: var(--font-sans);
    background: rgb(70 43 16 / 0.90);
}

/* When body is a column-flex container, push footer to viewport bottom */
.page-footer {
    margin-top: auto;
    width: 100%;
}

/* Footer Search Bar */
.footer-search {
    margin-bottom: 15px;
    padding: 10px 0;
}

.search-form {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.search-form label {
    color: var(--silver);
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.05rem;
}

.search-form input[type="text"] {
    padding: 0.5rem 0.8rem;
    border: 1px solid var(--silver);
    border-radius: 4px;
    font-size: 0.9rem;
    min-width: 150px;
    max-width: 250px;
    background-color: var(--pure-white);
    color: var(--ink);
}

.search-form input[type="text"]:focus {
    outline: none;
    border-color: var(--tangerine);
    box-shadow: 0 0 4px rgba(240, 90, 40, 0.3);
}

.search-form select {
    padding: 0.5rem 0.8rem;
    border: 1px solid var(--silver);
    border-radius: 4px;
    font-size: 0.9rem;
    background-color: var(--pure-white);
    color: var(--ink);
    cursor: pointer;
    min-width: 200px;
}

.search-form select:focus {
    outline: none;
    border-color: var(--tangerine);
    box-shadow: 0 0 4px rgba(240, 90, 40, 0.3);
}

.search-form button {
    padding: 0.5rem 1.2rem;
    background-color: var(--saffron);
    border: none;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
    letter-spacing: 0.05rem;
    text-transform: uppercase;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.search-form button:hover {
    background-color: var(--saffron);
    transform: translateY(-1px);
}

.search-form button:active {
    transform: translateY(0);
}

.page-footer p {
    margin: 0;
    color: var(--dusty-sun);
    font-weight: normal;
}

.page-footer a {
    color: var(--liddell);
    text-decoration: none;
}

.page-footer a:hover {
    text-decoration: underline;
}

/* ============================================
   SECTION 7: DETAIL PAGE COMPONENTS
============================================ */

/* Unihan Detail Panel */
.unihan-detail {
    display: flex;
    font-family: var(--font-sans);
    align-items: center;
    gap: 2rem;
    margin: 0 0 0 0;
    padding: 20px 20px;
    background: var(--soft-ivory);
}

.unihan-detail table {
    width: 100%;
    border-collapse: collapse;
}

.unihan-detail th {
    text-align: left;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--cool-gray);
    width: 30%;
}

.unihan-detail td {
    font-size: 1rem;
}

.unihan-detail tr:last-child td,
.unihan-detail tr:last-child th {
    border-bottom: none;
}

/* Radical Header */
.radical-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin: 0;
    padding: 10px;
    background: var(--soft-ivory);
}

/* Radical Character Display */
.radical-char-display,
.unihan-char-display {
    font-size: 4rem;
    font-weight: bold;
    min-width: 5rem;
    text-align: center;
    font-family: var(--font-cjk-alt);
}

/* Radical Info Section */
.radical-info {
    flex: 1;
}

.radical-info table {
    width: 100%;
    border-collapse: collapse;
}

.radical-info th {
    text-align: left;
    font-size: 0.85rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    color: var(--cool-gray);
    padding: 0.6rem 0 0.4rem;
    width: 30%;
    font-weight: bold;
    padding-right: 12px;
}

.radical-info td {
    font-size: 1rem;
    padding: 0.6rem 0 0.4rem;
    font-weight: normal;
}

.radical-info tr:last-child td,
.radical-info tr:last-child th {
    border-bottom: none;
}

.radical-info p {
    margin: 0.5rem 0;
    font-size: 14px;
}

.radical-info strong {
    color: #333;
}

/* Unihan Info Section */
.unihan-info {
    flex: 1;
}

.unihan-info table {
    width: 100%;
    border-collapse: collapse;
}

.unihan-info th {
    text-align: left;
    font-size: 0.85rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    color: var(--cool-gray);
    line-height: 1.0rem;
    width: 30%;
    font-weight: bold;
    padding-right: 12px;
}

.unihan-info td {
    font-size: 1rem;
    font-weight: normal;
}

.unihan-info tr:last-child td,
.unihan-info tr:last-child th {
    border-bottom: none;
}

/* ============================================
   SECTION 8: DICTIONARY & ENTRY STYLES
============================================ */
#cedictPrimary,
#cedictSecondary,
#edictEntries {
    margin-top: 1rem;

}
#cedictPrimary .cedict-entry {
    border-left: 4px solid var(--saffron);
}

#cedictSecondary .cedict-entry {
    border-left: 4px solid var(--liddell);
}

#edictEntries .cedict-entry {
    border-left: 4px solid var(--jianti-red);
}

.unihan-entries .cedict-entry {
    border-left: 4px solid var(--cool-gray);
}

.unihan-entries {
    font-family: var(--font-sans);
    margin: 0 100px 0 100px;
    background: var(--soft-ivory);
    padding: 1rem;
    padding-top: 0.5rem;
    padding-left: 5px;
    box-shadow: 0 20px 45px rgba(30, 30, 30, 0.08);
}

.cedict-entries {
    font-family: var(--font-sans);
    margin: 0 100px 0 100px;
    background: var(--soft-ivory);
    padding: 1rem;
    padding-top: 0.5rem;
    padding-left: 5px;
    box-shadow: 0 20px 45px rgba(30, 30, 30, 0.08);
}

.cedict-entry {
    background: rgba(244, 185, 66, 0.05);
    border-radius: 8px;
    padding-top: .1rem;
    padding-bottom: .1rem;
    padding-left: 1.5rem;
}

.cedict-header {
    margin: 0 0 0 .2rem;
    font-size: 1.1rem;
    color: var(--ink);   
}

.cedict-header a {
    color: var(--liddell);
    text-decoration: none;
}

.cedict-header a:hover {
    text-decoration: underline;
}

.cedict-entry ol {
    margin: 0;
}

.cedict-entry li {
    margin: .4rem 0;
    color: var(--ink);
}

.cedict-entries h3,
.unihan-entries h3 {
    color: var(--ink);
    font-size: 1.2rem;
    margin-top: 1rem;
    margin-bottom: .8rem;
    font-weight: 600;
}

.cedict-entries h3:first-child,
.unihan-entries h3:first-child {
    margin-top: 0;
}

.cedict-empty {
    color: var(--cool-gray);
    font-style: italic;
}

/* ============================================
   SECTION 9: GRID & STROKE LAYOUT
============================================ */

/* Stroke Sections Container */
.stroke-sections {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    padding-left: 50px;
    padding-right: 50px;
    padding-top: 15px;
    padding-bottom: 15px;
}

/* Stroke Count Marker */
.stroke-marker {
    font-family: var(--font-sans);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--saffron);
    color: var(--ink);
    border: 1px solid var(--monkey-shit-brown);
    border-radius: 50%;
    font-weight: bold;
    font-size: 1.7rem;
    flex-shrink: 0;
}

/* Character Grid Item */
.grid-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--pure-white);
    border: 1px solid var(--silver);
    text-decoration: none;
    color: inherit;
    transition: background-color 0.15s;
    flex-shrink: 0;
    position: relative;
    overflow: visible;
}

.grid-item:hover {
    background-color: #e8f4f8;
}

.grid-item.tradable {
    color: var(--fanti-blue);
}

.grid-item.simpable {
    color: var(--jianti-red);
}

/* Grid Item Wrapper */
.grid-item-wrapper {
    position: relative;
    flex: 0 0 3rem;
    height: 3rem;
    overflow: visible;
}

/* Character Display */
.character {
    font-size: 1.5rem;
    font-weight: bold;
    font-family: var(--font-sans);
    color: var(--ink);
    position: relative;
    z-index: 5;
}

/* Character Grid Layout */
.character-grid,
.stroke-section {
    display: contents;
}

/* Pinyin Label */
.pinyin-label {
    position: absolute;
    top: 4px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-sans);
    font-size: 6px;
    color: var(--cool-gray);
    white-space: nowrap;
    height: auto;
    line-height: 1;
    max-width: 95%;
    overflow: visible;
    text-overflow: clip;
    z-index: 100;
    pointer-events: none;
}

/* ============================================
   SECTION 10: SLIDER & NAVIGATION COMPONENTS
============================================ */

/* Base Slider Containers */
.zi-slider,
.unihan-slider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0;
    margin: 0;
}

/* Slider Window */
.zi-window,
.unihan-window {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Slider Track */
.zi-track,
.unihan-track {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: nowrap;
    gap: 0;
    background-color: transparent;
    border: none;
    height: 3rem;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    width: max-content;
}

.zi-track li,
.unihan-track li {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--pure-white);
    border: 1px solid var(--silver);
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.15s;
    flex-shrink: 0;
    border-radius: 0;
}

.zi-track li:hover,
.unihan-track li:hover {
    background-color: #e8f4f8;
}

.zi-track li.active,
.unihan-track li.active {
    background-color: var(--ink);
    color: var(--liddell);
}

/* Slider Track Items */
.zi-track-item,
.unihan-track-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--pure-white);
    border: 1px solid var(--silver);
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.15s;
    flex-shrink: 0;
    border-radius: 0;
}

.zi-track-item:hover,
.unihan-track-item:hover {
    background-color: #e8f4f8;
}

.zi-track-item.active,
.unihan-track-item.active {
    background-color: var(--ink);
    color: var(--liddell);
}

/* Slider Navigation Buttons */
.zi-nav,
.unihan-nav {
    background-color: var(--saffron);
    border: none;
    padding: 0;
    margin: 0 !important;
    font-size: 1.2rem;
    cursor: pointer;
    transition: opacity 0.15s;
    flex-shrink: 0;
    border-radius: 0;
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zi-nav:hover,
.unihan-nav:hover {
    opacity: 0.7;
}

/* Slider Status Messages */
.zi-status,
.unihan-status {
    position: absolute;
    inset: 0;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    color: var(--cool-gray);
    background: var(--soft-ivory);
    border-radius: 24px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

/* Slider Viewfinder */
.zi-viewfinder,
.unihan-viewfinder {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 60px;
    border-radius: 0;
    border: 3px solid var(--liddell);
    transform: translate(-50%, -50%);
    pointer-events: none;
    box-shadow: 0 0 0 6px rgba(58, 201, 253, 0.15);
}

/* ============================================
   SECTION 11: TABLE STYLES
============================================ */

/* Syllable Table Wrapper */
.table-wrapper {
    margin: 20px auto;
    max-width: 1200px;
    width: fit-content;
}

/* Syllable Table */
.syllable-table {
    font-family: var(--font-sans);
    width: auto;
    border-collapse: collapse;
    margin: 0 auto;
    background: none;
}

.syllable-table th {
    background-color: var(--monkey-shit-brown);
    color: var(--pure-white);
    border: none;
    padding: 1px 2px;
    text-align: center;
    font-weight: bold;
    min-width: 40px;
    font-size: 10px;
    height: 18px;
    line-height: 16px;
}

.syllable-table td {
    border: none;
    padding: 0;
    text-align: center;
    height: 22px;
    line-height: 22px;
}

.syllable-table td:empty {
    background-color: transparent;
}

.syllable-table a {
    color: var(--ink);
    text-decoration: none;
    display: block;
    height: 100%;
    width: 100%;
    background-color: var(--pure-white);
    font-size: 10px;
    padding: 0 1px;
    border: 1px solid var(--silver);
    box-sizing: border-box;
}

.syllable-table a:visited {
    color: var(--ink);
}

.syllable-table a:hover {
    background-color: var(--silver);
    text-decoration: underline;
}

/* Search Results Table */
.search-results-table {
    font-family: var(--font-sans);
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: var(--pure-white);
}

.search-results-table thead {
    background-color: var(--monkey-shit-brown);
    color: var(--pure-white);
}

.search-results-table th {
    padding: 12px;
    text-align: left;
    font-weight: bold;
    border: 1px solid var(--silver);
}

.search-results-table td {
    padding: 10px 12px;
    border: 1px solid var(--silver);
}

.search-results-table tbody tr:nth-child(odd) {
    background-color: var(--soft-ivory);
}

.search-results-table tbody tr:hover {
    background-color: rgba(244, 185, 66, 0.15);
}

.search-results-table .charindex {
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
    min-width: 60px;
}

.search-results-table .charindex a {
    color: var(--ink);
    text-decoration: none;
    font-family: var(--font-cjk-alt);
    transition: color 0.2s;
}

.search-results-table .charindex a:hover {
    color: var(--tangerine);
}

.search-results-table .pronunciation-cell {
    color: var(--cool-gray);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    min-width: 200px;
}

.search-results-table .definition {
    color: var(--ink);
    font-size: 0.95rem;
}

/* ============================================
   SECTION 12: DATA VISUALIZATION & BARS
============================================ */

/* Frequency Bar */
.frequency-bar {
    position: absolute;
    bottom: 2px;
    left: 50%;
    height: 3px;
    background-color: var(--liddell);
    width: 0;
    transform: translateX(-50%);
    max-width: 100%;
}

/* Gender Bars Container */
.gender-bars {
    position: absolute;
    bottom: 2px;
    left: 50%;
    height: 3px;
    display: contents;
    z-index: 10;
}

/* Female Gender Bar */
.gender-bar-female {
    position: absolute;
    bottom: 2px;
    right: 50%;
    background-color: var(--dustyrose);
    height: 3px;
    z-index: 10;
}

/* Male Gender Bar */
.gender-bar-male {
    position: absolute;
    bottom: 2px;
    left: 50%;
    background-color: var(--liddell);
    height: 3px;
    z-index: 10;
}

/* ============================================
   SECTION 13: FORM & CONVERTER STYLES
============================================ */

/* Convert Container */
.convert-container {
    max-width: 100%;
    width: 100%;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Form Wrapper */
.form-wrapper {
    width: 100%;
    max-width: 600px;
    border-radius: 0;
    padding: 20px;
    box-sizing: border-box;
    font-family: var(--font-sans);
    margin-bottom: 20px;
    box-shadow: none;
}

/* Form Group */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    font-weight: bold;
    margin-bottom: 10px;
    font-size: 14px;
    font-family: var(--font-sans);
}

/* Button Container */
.button-container {
    text-align: center;
    margin-top: 15px;
}

button {
    padding: 10px 20px;
    background-color: var(--monkey-shit-brown);
    color: var(--ink);
    border: none;
    cursor: pointer;
    border-radius: 3px;
    font-size: 14px;
}

button:hover {
    opacity: 0.9;
}

/* Status & Output Messages */
#status {
    margin: 0 0 2rem 0;
    padding: 0.8rem 1.2rem;
    border-left: 4px solid var(--tangerine);
    background: rgba(240, 90, 40, 0.08);
    font-size: 0.95rem;
    letter-spacing: 0.05rem;
}

#output {
    font-family: var(--font-mono);
    background: var(--dusty-sun);
    color: var(--ink);
    padding: 2rem;
    border-radius: 32px;
    border: 2px solid rgba(30, 30, 30, 0.05);
    min-height: 320px;
    white-space: pre-wrap;
    line-height: 1.6;
    box-shadow: 0 25px 55px rgba(240, 90, 40, 0.18);
}

#input {
    background: var(--soft-ivory);
    border-radius: 24px;
    padding: 1.5rem 2rem;
    margin: 2rem 0 0;
    box-shadow: 0 18px 32px rgba(30, 30, 30, 0.08);
}

/* ============================================
   SECTION 14: UTILITY & MISCELLANEOUS
============================================ */

.no-results {
    text-align: center;
    padding: 40px 20px;
    color: var(--cool-gray);
}

/* ============================================
   SECTION 15: RESPONSIVE MEDIA QUERIES
============================================ */

@media (max-width: 768px) {
    .grid-item-wrapper {
        flex: 0 0 2.5rem;
        height: 2.5rem;
    }
}

/* ============================================
   SECTION 16: GENERIC CLASS ALIASES
   These provide semantic, generic names for
   domain-specific classes to improve code
   maintainability and reduce duplication.
============================================ */

/* Detail Panel - unifies unihan-detail, radical-detail usage */
.detail-panel {
    display: block;
}



/* Info Section - consolidates radical-info, unihan-info */
.info-section {
    display: block;
}

.info-section table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    padding: 0;
}

.info-section th {
    text-align: right;
    padding: 8px;
    border: 1px solid var(--silver);
    background-color: var(--dusty-sun);
    font-weight: bold;
    font-size: 12px;
    width: 25%;
}

.info-section td {
    padding: 8px;
    text-align: left;
    border: 1px solid var(--silver);
}

.info-section tr:last-child td,
.info-section tr:last-child th {
    border-bottom: 1px solid var(--silver);
}

/* Char Display - consolidates radical-char-display, unihan-char-display */
.char-display {
    display: inline-block;
    margin: 0 auto;
    font-family: var(--font-cjk);
    padding: 20px;
    border-radius: 10px;
    background-color: var(--soft-ivory);
    line-height: 1;
}

/* Slider Components - Generic Base Classes */
.slider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px;
    margin: 20px 0;
}

.slider-nav {
    appearance: none;
    -webkit-appearance: none;
    background: none;
    border: none;
    color: var(--liddell);
    font-size: 20px;
    cursor: pointer;
    padding: 10px;
    font-weight: bold;
    transition: color 0.2s;
}

.slider-nav:hover {
    color: var(--dustyrose);
}

.slider-window {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 5px;
    background-color: var(--pure-white);
    border: 1px solid var(--silver);
    flex: 1;
    max-width: 600px;
    height: 100px;
}

.slider-track {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    position: relative;
    transition: transform 0.3s ease;
}

.slider-track li {
    flex: 0 0 100%;
    text-align: center;
    cursor: pointer;
    padding: 10px;
    user-select: none;
    transition: opacity 0.2s;
}

.slider-track li:hover {
    opacity: 0.7;
}

.slider-track li.active {
    font-weight: bold;
    color: var(--liddell);
}

.slider-item {
    flex: 0 0 auto;
    padding: 10px;
    margin: 0;
    text-align: center;
    user-select: none;
    cursor: pointer;
    border-radius: 3px;
    transition: background-color 0.2s;
}

.slider-item:hover {
    background-color: var(--dusty-sun);
}

.slider-item.active {
    background-color: var(--liddell);
    color: var(--pure-white);
    font-weight: bold;
}

.slider-status {
    text-align: center;
    color: var(--cool-gray);
    font-size: 12px;
    padding: 10px;
}

.slider-viewfinder {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: rgba(58, 201, 253, 0.1);
    pointer-events: none;
}

/* Index Pages */
.index-page {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Detail Pages */
.detail-page {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Entry List and Items */
.entry-list {
    display: block;
}

.entry-item {
    display: block;
    margin-bottom: 15px;
}

.entry-header {
    font-weight: bold;
    padding: 10px;
    background-color: var(--dusty-sun);
    margin-bottom: 10px;
    border-radius: 3px;
}

.entry-empty {
    text-align: center;
    color: var(--cool-gray);
    padding: 20px;
    font-style: italic;
}
