/* ===================================
   Periodic Table - Modern CSS Styles
   PeriodicTable.com.hk
   =================================== */

/* CSS Variables */
:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary-color: #64748b;
    --background: #f8fafc;
    --surface: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --transition: all 0.2s ease;

    /* Element Category Colors */
    --alkali-metal: #ff6b6b;
    --alkaline-earth: #ffa94d;
    --transition-metal: #ffd43b;
    --post-transition: #69db7c;
    --metalloid: #38d9a9;
    --nonmetal: #4dabf7;
    --halogen: #748ffc;
    --noble-gas: #da77f2;
    --lanthanide: #f783ac;
    --actinide: #e599f7;
    --unknown: #ced4da;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans TC", "Microsoft JhengHei", sans-serif;
    background-color: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header */
.header {
    background: var(--surface);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-icon {
    font-size: 1.75rem;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 0;
}

.nav-link:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, #7c3aed 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.search-container {
    max-width: 500px;
    margin: 0 auto;
    display: flex;
    gap: 0.5rem;
}

#search-input {
    flex: 1;
    padding: 1rem 1.25rem;
    font-size: 1rem;
    border: none;
    border-radius: var(--radius-lg);
    outline: none;
    box-shadow: var(--shadow-lg);
}

#search-input::placeholder {
    color: var(--secondary-color);
}

#search-btn {
    padding: 1rem 1.25rem;
    background: var(--surface);
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-lg);
}

#search-btn:hover {
    background: var(--background);
    transform: scale(1.05);
}

/* Categories Section */
.categories {
    padding: 2rem 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border-color);
}

.categories h3 {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.filter-btn {
    padding: 0.5rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    background: var(--surface);
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

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

.filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Periodic Table Section */
.periodic-table-section {
    padding: 2rem 0 4rem;
}

.table-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: var(--radius-sm);
}

.legend-color.alkali-metal { background: var(--alkali-metal); }
.legend-color.alkaline-earth { background: var(--alkaline-earth); }
.legend-color.transition-metal { background: var(--transition-metal); }
.legend-color.post-transition { background: var(--post-transition); }
.legend-color.metalloid { background: var(--metalloid); }
.legend-color.nonmetal { background: var(--nonmetal); }
.legend-color.halogen { background: var(--halogen); }
.legend-color.noble-gas { background: var(--noble-gas); }
.legend-color.lanthanide { background: var(--lanthanide); }
.legend-color.actinide { background: var(--actinide); }

/* Periodic Table Grid */
.periodic-table {
    display: grid;
    grid-template-columns: repeat(18, minmax(45px, 1fr));
    gap: 3px;
    overflow-x: auto;
    padding-bottom: 1rem;
}

.element {
    aspect-ratio: 1;
    min-width: 45px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    padding: 4px;
    position: relative;
    box-shadow: var(--shadow-sm);
}

.element:hover {
    transform: scale(1.15);
    z-index: 10;
    box-shadow: var(--shadow-xl);
}

.element.hidden {
    opacity: 0.15;
    pointer-events: none;
}

.element.highlight {
    animation: pulse 0.5s ease;
    box-shadow: 0 0 0 3px var(--primary-color);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.element-number {
    font-size: 0.6rem;
    opacity: 0.8;
    position: absolute;
    top: 3px;
    left: 5px;
}

.element-symbol {
    font-size: 1.1rem;
    font-weight: 700;
}

.element-name {
    font-size: 0.5rem;
    text-align: center;
    line-height: 1.2;
    max-width: 100%;
    overflow: hidden;
}

/* Element Category Colors */
.element.alkali-metal { background: var(--alkali-metal); color: #fff; }
.element.alkaline-earth { background: var(--alkaline-earth); color: #fff; }
.element.transition-metal { background: var(--transition-metal); color: #333; }
.element.post-transition { background: var(--post-transition); color: #333; }
.element.metalloid { background: var(--metalloid); color: #fff; }
.element.nonmetal { background: var(--nonmetal); color: #fff; }
.element.halogen { background: var(--halogen); color: #fff; }
.element.noble-gas { background: var(--noble-gas); color: #fff; }
.element.lanthanide { background: var(--lanthanide); color: #fff; }
.element.actinide { background: var(--actinide); color: #fff; }
.element.unknown { background: var(--unknown); color: #333; }

/* Lanthanide/Actinide Labels */
.element-placeholder {
    aspect-ratio: 1;
    min-width: 45px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.7rem;
    color: var(--text-secondary);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
}

.lanthanide-row,
.actinide-row {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(18, minmax(45px, 1fr));
    gap: 3px;
    margin-top: 0.5rem;
}

.row-label {
    grid-column: 1 / 4;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.lanthanide-elements,
.actinide-elements {
    grid-column: 4 / -1;
    display: grid;
    grid-template-columns: repeat(15, minmax(45px, 1fr));
    gap: 3px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    padding: 1rem;
    overflow-y: auto;
}

.modal.active {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 5vh;
}

.modal-content {
    background: var(--surface);
    border-radius: var(--radius-xl);
    max-width: 600px;
    width: 100%;
    box-shadow: var(--shadow-xl);
    animation: slideUp 0.3s ease;
    position: relative;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.modal-close:hover {
    background: var(--background);
    color: var(--text-primary);
}

.modal-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.element-symbol-large {
    width: 100px;
    height: 100px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    font-weight: 700;
    color: white;
}

.element-info-header h2 {
    font-size: 1.75rem;
    margin-bottom: 0.25rem;
}

.element-info-header p {
    color: var(--text-secondary);
    font-size: 1rem;
}

.modal-body {
    padding: 2rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.info-item {
    background: var(--background);
    padding: 1rem;
    border-radius: var(--radius-md);
}

.info-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.info-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.element-description h3 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.element-description p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* SEO Section */
.seo-section {
    background: var(--surface);
    padding: 4rem 0;
    border-top: 1px solid var(--border-color);
}

.seo-content {
    max-width: 800px;
    margin: 0 auto;
}

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

.seo-content h3 {
    font-size: 1.25rem;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
}

.seo-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.8;
}

.quick-facts {
    background: var(--background);
    padding: 1.5rem 2rem;
    border-radius: var(--radius-lg);
    margin-top: 2rem;
}

.quick-facts h3 {
    margin-top: 0;
}

.quick-facts ul {
    list-style: none;
    padding: 0;
}

.quick-facts li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

.quick-facts li:last-child {
    border-bottom: none;
}

.quick-facts strong {
    color: var(--primary-color);
}

/* Footer */
.footer {
    background: var(--text-primary);
    color: white;
    padding: 2rem 0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.footer-text {
    opacity: 0.8;
    font-size: 0.875rem;
}

.footer-nav {
    display: flex;
    gap: 1.5rem;
}

.footer-nav a {
    color: white;
    text-decoration: none;
    opacity: 0.8;
    font-size: 0.875rem;
    transition: var(--transition);
}

.footer-nav a:hover {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .periodic-table {
        grid-template-columns: repeat(18, minmax(40px, 1fr));
    }

    .element {
        min-width: 40px;
    }
}

@media (max-width: 992px) {
    .periodic-table {
        grid-template-columns: repeat(18, minmax(35px, 1fr));
    }

    .element {
        min-width: 35px;
    }

    .element-name {
        display: none;
    }

    .element-symbol {
        font-size: 0.9rem;
    }

    .element-number {
        font-size: 0.5rem;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .nav {
        gap: 1rem;
    }

    .hero {
        padding: 3rem 0;
    }

    .hero h2 {
        font-size: 1.75rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .search-container {
        flex-direction: column;
    }

    .category-filters {
        gap: 0.375rem;
    }

    .filter-btn {
        font-size: 0.75rem;
        padding: 0.375rem 0.75rem;
    }

    .table-legend {
        gap: 0.5rem;
    }

    .legend-item {
        font-size: 0.7rem;
    }

    .periodic-table {
        grid-template-columns: repeat(18, minmax(30px, 1fr));
        gap: 2px;
    }

    .element {
        min-width: 30px;
        padding: 2px;
    }

    .element-symbol {
        font-size: 0.75rem;
    }

    .modal-header {
        padding: 1.5rem;
        gap: 1rem;
    }

    .element-symbol-large {
        width: 70px;
        height: 70px;
        font-size: 2rem;
    }

    .element-info-header h2 {
        font-size: 1.25rem;
    }

    .modal-body {
        padding: 1.5rem;
    }

    .info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .seo-content h2 {
        font-size: 1.5rem;
    }

    .footer-nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .periodic-table {
        grid-template-columns: repeat(18, minmax(24px, 1fr));
        gap: 1px;
    }

    .element {
        min-width: 24px;
        border-radius: var(--radius-sm);
    }

    .element-number {
        display: none;
    }

    .element-symbol {
        font-size: 0.65rem;
    }

    .legend-item {
        font-size: 0.6rem;
    }

    .legend-color {
        width: 12px;
        height: 12px;
    }
}

/* Logo Styles */
.logo {
    text-decoration: none;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav-link.active {
    color: var(--primary-color);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
}

/* Mobile Navigation */
.mobile-nav {
    display: none;
    flex-direction: column;
    background: var(--surface);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem;
}

.mobile-nav.active {
    display: flex;
}

.mobile-nav-link {
    padding: 0.75rem 1rem;
    text-decoration: none;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: var(--transition);
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    background: var(--background);
    color: var(--primary-color);
}

/* Breadcrumbs */
.breadcrumbs {
    background: var(--background);
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.breadcrumb-list {
    display: flex;
    align-items: center;
    list-style: none;
    font-size: 0.875rem;
}

.breadcrumb-list li {
    display: flex;
    align-items: center;
}

.breadcrumb-list li:not(:last-child)::after {
    content: "›";
    margin: 0 0.5rem;
    color: var(--text-secondary);
}

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

.breadcrumb-list a:hover {
    text-decoration: underline;
}

.breadcrumb-list li:last-child {
    color: var(--text-secondary);
}

/* Hero h1 */
.hero h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* Categories h2 */
.categories h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
    color: var(--text-secondary);
}

/* Content Wrapper */
.content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
}

/* Contextual Intro Section */
.intro-section {
    padding: 3rem 0;
    background: var(--background);
}

.contextual-intro h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.contextual-intro p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.contextual-intro strong {
    color: var(--text-primary);
}

/* Guide Section */
.guide-section {
    padding: 4rem 0;
    background: var(--background);
}

.user-guide h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.user-guide h3 {
    font-size: 1.25rem;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
}

.user-guide p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.user-guide a {
    color: var(--primary-color);
}

.faq-item {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin-bottom: 1rem;
    box-shadow: var(--shadow-sm);
}

.faq-item h4 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.faq-item p {
    margin-bottom: 0;
}

/* Latest Articles Section */
.latest-articles {
    padding: 4rem 0;
    background: var(--surface);
}

.latest-articles h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.article-card {
    background: var(--background);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.article-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.article-card a {
    text-decoration: none;
    color: inherit;
}

.article-image {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
}

.article-content {
    padding: 1.5rem;
}

.article-content h3 {
    font-size: 1.125rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    line-height: 1.4;
}

.article-content p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.read-more {
    color: var(--primary-color);
    font-size: 0.875rem;
    font-weight: 500;
}

.view-all-articles {
    text-align: center;
}

.btn-primary {
    display: inline-block;
    padding: 0.875rem 2rem;
    background: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: var(--radius-lg);
    font-weight: 500;
    transition: var(--transition);
}

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

/* Footer Grid */
.footer {
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: white;
    font-size: 1.25rem;
    font-weight: 600;
}

.footer-brand p {
    opacity: 0.8;
    font-size: 0.875rem;
    line-height: 1.6;
}

.footer-links h4 {
    font-size: 1rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.footer-links nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
    opacity: 0.7;
    font-size: 0.875rem;
    transition: var(--transition);
}

.footer-links a:hover {
    opacity: 1;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    opacity: 0.7;
    font-size: 0.875rem;
}

/* Blog Page Styles */
.page-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #7c3aed 100%);
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    opacity: 0.9;
    font-size: 1.125rem;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    padding: 3rem 0;
}

/* Blog Post Styles */
.blog-post {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem 0;
}

.blog-post h1 {
    font-size: 2.25rem;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.blog-meta {
    display: flex;
    gap: 1rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.blog-post h2 {
    font-size: 1.5rem;
    margin: 2.5rem 0 1rem;
    color: var(--text-primary);
}

.blog-post h3 {
    font-size: 1.25rem;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
}

.blog-post p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.blog-post ul,
.blog-post ol {
    margin: 1.5rem 0;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}

.blog-post li {
    margin-bottom: 0.5rem;
    line-height: 1.7;
}

.blog-post strong {
    color: var(--text-primary);
}

.blog-post a {
    color: var(--primary-color);
}

.blog-post blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: var(--text-secondary);
}

.cta-box {
    background: linear-gradient(135deg, var(--primary-color) 0%, #7c3aed 100%);
    color: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
    margin: 2rem 0;
}

.cta-box h3 {
    color: white;
    margin-bottom: 1rem;
}

.cta-box p {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
}

.cta-box .btn-primary {
    background: white;
    color: var(--primary-color);
}

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

/* Static Pages */
.static-page {
    padding: 3rem 0;
}

.static-page h1 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.static-page h2 {
    font-size: 1.5rem;
    margin: 2rem 0 1rem;
    color: var(--text-primary);
}

.static-page p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.static-page ul {
    margin: 1rem 0;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}

.static-page li {
    margin-bottom: 0.5rem;
}

.contact-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-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

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

/* Responsive Updates */
@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .header-content {
        flex-direction: row;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-brand {
        align-items: center;
    }

    .footer-links nav {
        align-items: center;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .articles-grid {
        grid-template-columns: 1fr;
    }

    .blog-post h1 {
        font-size: 1.75rem;
    }
}

/* Print Styles */
@media print {
    .header,
    .hero,
    .categories,
    .modal,
    .footer,
    .breadcrumbs,
    .mobile-nav {
        display: none;
    }

    .periodic-table-section {
        padding: 0;
    }

    .element:hover {
        transform: none;
    }
}
