/*
Theme Name: All Is Motion Child
Description: Custom child theme for interdisciplinary research site
Template: twentytwentythree
Version: 1.0
Text Domain: allismotion-child
*/

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Crimson+Text:ital,wght@0,400;0,600;1,400&family=Source+Sans+Pro:wght@300;400;600&display=swap');

/* CSS Custom Properties (Design System) */
:root {
    --deep-charcoal: #2C3E50;
    --warm-stone: #95A5A6;
    --sage-green: #27AE60;
    --terracotta: #E67E22;
    --prussian-blue: #3498DB;
    --off-white: #FDFEFE;
    --light-gray: #F8F9FA;
    --shadow-light: rgba(44, 62, 80, 0.1);
    --shadow-medium: rgba(44, 62, 80, 0.2);

    /* Accessibility Colors */
    --text-secondary: #5D6D7E;
    --text-tertiary: #34495E;
}

/* Override Twenty Twenty-Three styles with our design */
body {
    font-family: 'Crimson Text', serif !important;
    font-size: 18px !important;
    line-height: 1.6 !important;
    color: var(--deep-charcoal) !important;
    background: linear-gradient(135deg, var(--off-white) 0%, var(--light-gray) 100%) !important;
}

/* Typography Overrides */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Crimson Text', serif !important;
    font-weight: 600 !important;
    color: var(--deep-charcoal) !important;
}

h1 { font-size: clamp(3rem, 6vw, 4.5rem) !important; }
h2 { font-size: clamp(2.2rem, 4.5vw, 2.8rem) !important; }
h3 { font-size: 1.6rem !important; }

/* Replace the overly broad typography rule with specific ones */

/* Content paragraphs and text */
.wp-block-post-content p,
.entry-content p {
    font-size: 1.25rem !important; /* ~20px */
},
.welcome-text,
.research-area p,
.about-section p {
    color: var(--text-tertiary) !important;
    font-size: 1.1rem !important;
    line-height: 1.6 !important;
}

/* Navigation and menu lists */
.wp-block-navigation li,
.research-areas li {
    color: var(--text-tertiary) !important;
    font-size: 1.1rem !important;
    line-height: 1.6 !important;
}

/* Latest Posts titles - properly styled links */
.wp-block-latest-posts__post-title {
    color: var(--deep-charcoal) !important;
    font-weight: 600 !important;
    font-size: 1.2rem !important;
    text-decoration: none !important;
    transition: color 0.3s ease !important;
}

.wp-block-latest-posts__post-title:hover {
    color: var(--prussian-blue) !important;
}

/* Other content links */
.wp-block-post-content a,
.entry-content a {
    color: var(--prussian-blue) !important;
    text-decoration: none !important;
    border-bottom: 1px solid var(--sage-green) !important;
    transition: all 0.3s ease !important;
}

.wp-block-post-content a:hover,
.entry-content a:hover {
    color: var(--sage-green) !important;
    border-bottom-width: 2px !important;
}

/* Enhanced contrast for better readability */
.wp-block-quote, blockquote {
    font-size: 1.25rem !important;
    font-weight: 500 !important;
    color: var(--deep-charcoal) !important;
    background: linear-gradient(135deg, var(--light-gray) 0%, rgba(248, 249, 250, 0.8) 100%) !important;
    border-left: 4px solid var(--prussian-blue) !important;
    padding: 2rem !important;
    border-radius: 0 12px 12px 0 !important;
    box-shadow: 0 8px 32px var(--shadow-light) !important;
}

/* Homepage-specific styles */
.homepage-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
}

/* Subtle motion background */
.homepage-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: radial-gradient(circle at 20% 50%, rgba(52, 152, 219, 0.03) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(39, 174, 96, 0.03) 0%, transparent 50%),
                radial-gradient(circle at 40% 80%, rgba(230, 126, 34, 0.03) 0%, transparent 50%);
    z-index: -1;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(1deg); }
}

.site-intro {
    text-align: center;
    margin-bottom: 4rem;
    padding: 3rem 0;
}

.site-intro h1 {
    font-size: clamp(3rem, 6vw, 4.5rem);
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--deep-charcoal);
    position: relative;
    display: inline-block;
}

.site-intro h1::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--sage-green), var(--prussian-blue));
    border-radius: 2px;
}

.tagline {
    font-family: 'Source Sans Pro', sans-serif;
    font-size: clamp(1.3rem, 3vw, 1.5rem);
    color: #5D6D7E;
    margin-bottom: 2.5rem;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.heraclitus-quote {
    background: linear-gradient(135deg, var(--light-gray) 0%, rgba(248, 249, 250, 0.8) 100%);
    border-left: 4px solid var(--prussian-blue);
    margin: 3rem auto;
    padding: 2.5rem;
    border-radius: 0 12px 12px 0;
    max-width: 600px;
    position: relative;
    box-shadow: 0 8px 32px var(--shadow-light);
}

.heraclitus-quote::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 4rem;
    color: var(--prussian-blue);
    opacity: 0.3;
    font-family: Georgia, serif;
}

.heraclitus-quote p {
    font-size: clamp(1.25rem, 3vw, 1.4rem);
    font-style: italic;
    color: var(--deep-charcoal);
    margin-bottom: 1rem;
    line-height: 1.7;
    font-weight: 500;
}

.heraclitus-quote footer {
    text-align: right;
    font-family: 'Source Sans Pro', sans-serif;
    font-size: 1.05rem;
    color: #5D6D7E;
    font-style: normal;
    font-weight: 500;
}

.welcome-text {
    font-size: clamp(1.25rem, 3vw, 1.35rem);
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    color: var(--deep-charcoal);
    font-weight: 400;
}

.research-areas h2 {
    font-size: clamp(2.2rem, 4.5vw, 2.8rem);
    text-align: center;
    margin-bottom: 3rem;
    color: var(--deep-charcoal);
    font-weight: 600;
}

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

.research-area {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 2rem;
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.research-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--sage-green), var(--prussian-blue));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.research-area:hover::before {
    transform: scaleX(1);
}

.research-area:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px var(--shadow-medium);
    background: rgba(255, 255, 255, 0.9);
}

/* Category-specific accent colors */
.research-area:nth-child(1):hover { border-color: var(--sage-green); }
.research-area:nth-child(2):hover { border-color: var(--prussian-blue); }
.research-area:nth-child(3):hover { border-color: var(--terracotta); }
.research-area:nth-child(4):hover { border-color: var(--deep-charcoal); }
.research-area:nth-child(5):hover { border-color: var(--terracotta); }

.research-area h3 {
    margin-bottom: 1rem;
    font-size: 1.6rem;
}

.research-area h3 a {
    text-decoration: none;
    color: var(--deep-charcoal);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: color 0.3s ease;
    font-weight: 600;
}

.research-area h3 a:hover {
    color: var(--prussian-blue);
}

.research-area h3 a .icon {
    font-size: 1.8rem;
    filter: drop-shadow(1px 1px 2px rgba(0,0,0,0.1));
}

.research-area p {
    font-family: 'Source Sans Pro', sans-serif;
    color: #34495E;
    font-size: 1.1rem;
    line-height: 1.6;
    font-weight: 400;
}

.about-section {
    margin-top: 4rem;
    padding-top: 2rem;
    text-align: center;
    border-top: 1px solid rgba(149, 165, 166, 0.3);
}

.about-section p {
    font-family: 'Source Sans Pro', sans-serif;
    color: #5D6D7E;
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

/* Category-specific styling classes */
.category-archaeology {
    --primary-accent: var(--sage-green);
    --secondary-accent: #229954;
}

.category-digital-archaeology {
    --primary-accent: var(--prussian-blue);
    --secondary-accent: #2E86C1;
}

.category-historical-research {
    --primary-accent: var(--terracotta);
    --secondary-accent: #D68910;
}

.category-philosophy {
    --primary-accent: var(--deep-charcoal);
    --secondary-accent: #5D6D7E;
}

.category-creative {
    --primary-accent: var(--terracotta);
    --secondary-accent: #E74C3C;
}

/* Responsive Design */
@media (max-width: 768px) {
    .homepage-content {
        padding: 1rem;
    }

    .site-intro {
        padding: 2rem 0;
        margin-bottom: 3rem;
    }

    .heraclitus-quote {
        margin: 2rem auto;
        padding: 1.5rem;
    }

    .area-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .research-area {
        padding: 1.5rem;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .homepage-content::before,
    .research-area {
        animation: none;
        transition: none;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --deep-charcoal: #000000;
        --text-secondary: #333333;
        --text-tertiary: #333333;
        --shadow-light: rgba(0, 0, 0, 0.3);
        --shadow-medium: rgba(0, 0, 0, 0.5);
    }
}

