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

:root {
    --primary-color: #3189B9;
    --primary-dark: #1A4761;
    --primary-hover: #25688D;
    --bg-color: #fcfcfc;
    --text-color: #333;
    --border-color: #e0e0e0;
    --header-bg: #f8f9fa;
    --shadow-color: rgba(0, 0, 0, 0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

/* Container - REMOVED - Using flat sections instead */

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-banner {
    background: linear-gradient(135deg, #a8d0e6 0%, #c3dfe6 100%);
    background-image: url('/images/swirl-pattern.svg'), linear-gradient(135deg, #a8d0e6 0%, #c3dfe6 100%);
    background-size: cover, cover;
    background-position: center, center;
    background-repeat: no-repeat, no-repeat;
    overflow: hidden;
    position: relative;
}

.header-content {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    min-height: 112px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.header-text {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    padding: 16px 0;
}

.header-image {
    flex: 0 0 auto;
    display: flex;
}

.header-image img {
    height: 112px;
    width: auto;
    display: block;
    border-radius: 0;
    box-shadow: none;
}

.site-title {
    font-size: 2rem;
    margin: 0;
    color: #2c5282;
}

.site-title a {
    text-decoration: none;
    color: #2c5282;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.5);
}

.site-title .subtitle {
    display: block;
    font-size: 1.2rem;
    font-style: italic;
    color: #2c5282;
    font-weight: normal;
    opacity: 0.9;
}

/* Navigation */
.main-nav {
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
    position: relative;
    background-color: white;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 24px;
    position: relative;
}

.menu-toggle.mobile-only {
    display: none;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #2c5282;
    margin-bottom: 5px;
    transition: all 0.3s ease;
    position: relative;
}

.menu-toggle span:last-child {
    margin-bottom: 0;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    margin: 0;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.main-nav a:hover,
.main-nav a.active {
    background-color: var(--primary-color);
    color: white;
}

/* Main Content */
.site-main {
    min-height: calc(100vh - 200px);
    max-width: 1200px;
    margin: 0 auto;
}

.content-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
    padding: 2rem;
}

/* Sidebar */
.sidebar {
    background-color: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px var(--shadow-color);
    height: fit-content;
    position: sticky;
    top: 100px;
}

.widget {
    margin-bottom: 2rem;
}

.widget:last-child {
    margin-bottom: 0;
}

.widget h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.link-list {
    list-style: none;
}

.link-list li {
    margin-bottom: 0.5rem;
}

.link-list a {
    color: var(--primary-color);
    text-decoration: none;
}

.link-list a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* Main Content Area */
.main-content {
    background-color: white;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 8px var(--shadow-color);
}

.main-content h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--primary-dark);
}

.main-content p {
    margin-bottom: 1rem;
}

.main-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.main-content a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* Content with Image */
.content-with-image {
    overflow: hidden;
}

.float-left {
    float: left;
    margin: 0 1.5rem 1rem 0;
    max-width: 300px;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 4px var(--shadow-color);
}

.float-right {
    float: right;
    margin: 0 0 1rem 1.5rem;
    max-width: 300px;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 4px var(--shadow-color);
}

/* Definition Box */
.definition {
    background-color: #f8f9fa;
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 4px;
}

.definition p {
    margin-bottom: 0.5rem;
}

.definition-body {
    padding-left: 1.5rem;
}

.pronunciation {
    font-style: italic;
    color: #666;
}

.grammar {
    font-style: italic;
    color: #666;
}

/* Footer */
.site-footer {
    background-color: var(--header-bg);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    text-align: center;
    color: #666;
}

/* Forms */
form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.required {
    color: #e74c3c;
}

.form-help {
    font-size: 0.875rem;
    color: #666;
    margin-top: 0.25rem;
}

.btn {
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: var(--primary-hover);
}

/* Alert Messages */
.alert {
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 4px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .content-layout {
        display: flex;
        flex-direction: column;
        padding: 1rem;
    }
    
    .header-content {
        padding: 0 1rem;
    }
    
    .nav-menu {
        padding: 0 1rem;
    }
    
    .sidebar {
        position: static;
        order: 2;
        margin-top: 2rem;
        display: none;
    }
    
    .home-page .sidebar {
        display: block;
    }
    
    .main-content {
        order: 1;
    }
    
    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        background-color: white;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        z-index: 999;
        transform: translateY(-100%);
        transition: transform 0.3s ease;
        opacity: 1;
    }
    
    .main-nav.active {
        transform: translateY(0);
    }
    
    .menu-toggle.mobile-only {
        display: block;
        order: -1;
        margin-right: 1rem;
    }
    
    .nav-menu {
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        background-color: white;
    }
    
    .nav-menu li {
        border-bottom: 1px solid var(--border-color);
        background-color: white;
    }
    
    .nav-menu a {
        display: block;
        padding: 1rem 20px;
        background-color: white;
    }
    
    .site-title {
        font-size: 1.5rem;
    }
    
    .header-content {
        min-height: auto;
    }
    
    .header-text {
        padding: 0;
        text-align: left;
        flex: 1;
    }
    
    .header-content {
        justify-content: flex-start;
        align-items: center;
        padding-top: 12px;
        padding-bottom: 12px;
    }
    
    .menu-toggle.mobile-only {
        margin-top: 0;
        align-self: center;
    }
    
    .site-title .subtitle {
        display: none;
    }
    
    .header-image {
        display: none;
    }
    
    .float-left,
    .float-right {
        float: left;
        margin: 0 1rem 0.5rem 0;
        max-width: 150px;
    }
    
    h2 {
        font-size: 1.1rem;
    }
    
    .mobile-text {
        display: inline;
    }
    
    .desktop-text {
        display: none;
    }
}

/* Mobile/Desktop text visibility */
.mobile-text {
    display: none;
}

.desktop-text {
    display: inline;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.hidden {
    display: none;
}

/* Lightbox Styles */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    overflow: auto;
}

.lightbox-image {
    display: block;
    max-width: 90%;
    max-height: 80vh;
    margin: 50px auto;
    animation: zoom 0.3s;
}

@keyframes zoom {
    from { transform: scale(0.8); }
    to { transform: scale(1); }
}

.lightbox-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.lightbox-close:hover,
.lightbox-close:focus {
    color: #bbb;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 60px;
    font-weight: bold;
    padding: 0 20px;
    cursor: pointer;
    text-decoration: none;
    user-select: none;
    transition: 0.3s;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.lightbox-prev {
    left: 10px;
}

.lightbox-next {
    right: 10px;
}

.lightbox-caption {
    text-align: center;
    color: #ccc;
    padding: 10px 20px;
    font-size: 1.1rem;
}

/* Mobile adjustments for lightbox */
@media (max-width: 1024px) {
    .lightbox-image {
        max-width: 95%;
        max-height: 70vh;
        margin: 80px auto 50px;
    }
    
    .lightbox-prev,
    .lightbox-next {
        font-size: 40px;
        padding: 0 10px;
    }
    
    .lightbox-close {
        top: 25px;
        right: 25px;
        font-size: 35px;
    }
}

/* Cookie Consent Banner */
#cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.95);
    color: white;
    padding: 20px;
    z-index: 10000;
    font-size: 14px;
    border-top: 3px solid var(--primary-color);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.cookie-consent-content p {
    margin: 0;
    flex: 1;
}

.cookie-consent-buttons {
    display: flex;
    gap: 10px;
}

.cookie-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.cookie-accept {
    background-color: var(--primary-color);
    color: white;
}

.cookie-accept:hover {
    background-color: var(--primary-hover);
}

.cookie-decline {
    background-color: #666;
    color: white;
}

.cookie-decline:hover {
    background-color: #555;
}

/* Mobile adjustments for cookie banner */
@media (max-width: 768px) {
    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .cookie-consent-buttons {
        justify-content: center;
    }
}

/* Spam trap honeypot styles - These elements are hidden from users */
.ohnohoney {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.spamtrap-container {
    position: absolute !important;
    top: -9999px !important;
    left: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    font-size: 0 !important;
    line-height: 0 !important;
    overflow: hidden !important;
    visibility: hidden !important;
    display: block !important;
}

/* Ensure spam trap links are not accessible */
.ohnohoney a,
.spamtrap-container a {
    pointer-events: none !important;
    user-select: none !important;
}

/* Additional hiding for form honeypots */
input[name="honeypot"],
input[value*="spamtrap"],
input[value*="honeypot"] {
    display: none !important;
    visibility: hidden !important;
}