/* Classic Classless CSS Framework - Optimized */

:root {
    --primary: #1B4F72;
    --primary-light: #2E7D9F;
    --text: #2C3E50;
    --text-light: #566573;
    --bg: #FFFEF5;
    --bg-secondary: #F8F5F0;
    --border: #B3956B;
    --link: #1B4F72;
    --link-visited: #6C3483;
    --accent: #C86450;
    --max-width: 960px;
}

/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

body {
    font-family: 'Iowan Old Style', 'Palatino Linotype', 'URW Palladio L', P052, serif;
    line-height: 1.75;
    color: var(--text);
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-secondary) 100%);
    background-attachment: fixed;
}

.selector-container {
    background-color: #FFFEF5;
    border: 2px solid var(--border);
    color: var(--text);
}

.selector-container h2 {
    color: var(--primary);
    border-bottom: none;
    padding-bottom: 0;
}

.selector-container label {
    color: var(--text);
}

.selector-container select {
    background-color: #FFFEF5;
    color: var(--text);
    border: 2px inset #B0B0B0;
}

.selector-container select:focus {
    outline: 3px solid var(--primary);
    outline-offset: -3px;
}

.status {
    background-color: #F0E8E0;
    border-left-color: var(--accent);
    color: var(--text);
}

.demo-content {
    background-color: #FFFEF5;
    border: 2px solid var(--border);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Trebuchet MS', 'Lucida Grande', Arial, Helvetica, sans-serif;
    line-height: 1.4;
    font-weight: bold;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--primary);
    text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.5);
}

h1 {
    font-size: 2.5rem;
    border-bottom: 5px double var(--border);
    padding: 1rem 0 0.75rem 0;
    margin-top: 0;
    text-align: center;
    font-variant: small-caps;
    letter-spacing: 2px;
}

h1::after {
    content: '';
    display: block;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    margin: 1rem auto 0;
}

h2 {
    font-size: 2rem;
    border-bottom: 2px solid var(--border);
    padding-bottom: 0.5rem;
    margin-top: 2.5rem;
    color: var(--primary-light);
}

h3 {
    font-size: 1.6rem;
    color: var(--accent);
    font-style: italic;
    margin-top: 2rem;
}

h4 { font-size: 1.35rem; }
h5 { font-size: 1.15rem; }
h6 { font-size: 1rem; text-transform: uppercase; letter-spacing: 2px; font-size: 0.9rem; }

p {
    margin-bottom: 1.5rem;
    color: var(--text-light);
    text-align: justify;
    hyphens: auto;
}

p:first-letter {
    font-size: 1.15em;
    font-weight: bold;
    color: var(--primary);
}

a {
    color: var(--link);
    text-decoration: underline;
    transition: all 0.3s ease;
    position: relative;
}

a:visited {
    color: var(--link-visited);
}

a:hover {
    color: var(--accent);
    text-decoration: underline double;
    font-weight: 600;
}

strong, b {
    font-weight: bold;
    color: var(--primary);
}

em, i {
    font-style: italic;
    color: var(--accent);
}

small {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Lists */
ul, ol {
    margin: 1.5rem 0;
    padding-left: 2.5rem;
    border-left: 4px solid var(--border);
    padding-left: 2rem;
    margin-left: 0.5rem;
}

ul {
    list-style-type: disc;
}

ol {
    list-style-type: decimal;
}

li {
    margin: 0.75rem 0;
    color: var(--text-light);
}

li:first-letter {
    color: var(--text);
}

/* Forms */
select, button {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1rem;
}

select {
    width: 100%;
    padding: 0.75rem;
    border: 2px inset #B0B0B0;
    background-color: var(--bg);
    color: var(--text);
    margin: 1rem 0;
    border-radius: 3px;
    box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    font-weight: 500;
}

select:focus {
    outline: 3px solid var(--primary);
    outline-offset: -3px;
    background-color: #FFFAF5;
}

select:hover {
    background-color: #FFFEF5;
}

button {
    display: inline-block;
    padding: 0.75rem 1.75rem;
    background: linear-gradient(180deg, #E8E8E8 0%, #D0D0D0 100%);
    color: var(--text);
    border: 2px outset #888888;
    cursor: pointer;
    font-weight: bold;
    margin: 1rem 0.5rem 1rem 0;
    font-family: Arial, Helvetica, sans-serif;
    transition: all 0.2s ease;
    border-radius: 3px;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    font-size: 0.95rem;
}

button:hover {
    background: linear-gradient(180deg, #F0F0F0 0%, #D8D8D8 100%);
    border-color: #666666;
    box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.15);
}

button:active {
    border-style: inset;
    box-shadow: inset 2px 2px 4px rgba(0, 0, 0, 0.1);
    transform: translate(1px, 1px);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--text);
    font-size: 0.95rem;
}

/* Utilities */
[hidden] {
    display: none !important;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 2rem 1rem;
        font-size: 15px;
    }

    h1 {
        font-size: 2rem;
        padding: 0.75rem 0 0.5rem 0;
    }

    h2 { font-size: 1.65rem; }
    h3 { font-size: 1.35rem; }

    p {
        text-align: left;
        hyphens: none;
    }
}
