/**
 * Mythical Archives - Custom Design System
 * For Blocksy Theme + GenerateBlocks Pro
 * Version: 2.0.0
 * 
 * Color Palette:
 * - Primary: #1a1a2e (Deep Midnight Indigo)
 * - Secondary: #c9a227 (Arcane Gold)
 * - Accent: #4a90a4 (Celestial Blue)
 * 
 * Typography:
 * - Headings: Cinzel Decorative
 * - Body: Source Serif Pro
 */

/* ================================
   GOOGLE FONTS IMPORT
   ================================ */
@import url('https://fonts.googleapis.com/css2?family=Cinzel+Decorative:wght@400;700;900&family=Cinzel:wght@400;500;600;700;800;900&family=Source+Serif+4:ital,opsz,wght@0,8..60,300;0,8..60,400;0,8..60,500;0,8..60,600;0,8..60,700;1,8..60,300;1,8..60,400;1,8..60,500&display=swap');

/* ================================
   CSS VARIABLES / DESIGN TOKENS
   ================================ */
:root {
    /* Primary Colors - Mythical Palette */
    --ma-midnight-indigo: #1a1a2e;
    --ma-arcane-gold: #c9a227;
    --ma-celestial-blue: #4a90a4;
    
    /* Extended Palette */
    --ma-deep-purple: #16213e;
    --ma-mystic-violet: #2d2d44;
    --ma-ancient-bronze: #a67c00;
    --ma-ethereal-silver: #b8c5d6;
    --ma-parchment: #f5f1e8;
    --ma-aged-paper: #e8e0d0;
    --ma-obsidian: #0f0f1a;
    
    /* Gold Variations */
    --ma-gold-light: #e0c35a;
    --ma-gold-dark: #9a7b1e;
    
    /* Blue Variations */
    --ma-blue-light: #6ab0c2;
    --ma-blue-dark: #3a7080;
    
    /* Semantic Colors */
    --ma-success: #27ae60;
    --ma-warning: #f39c12;
    --ma-danger: #e74c3c;
    --ma-info: var(--ma-celestial-blue);
    
    /* Creature Type Colors */
    --ma-dragon: #e85d04;
    --ma-sea: #0096c7;
    --ma-flying: #90e0ef;
    --ma-humanoid: #dda15e;
    --ma-fire: #d00000;
    --ma-forest: #2d6a4f;
    --ma-shapeshifter: #7b2cbf;
    --ma-guardian: #3a86ff;
    --ma-spirit: #caf0f8;
    --ma-undead: #495057;
    
    /* Culture/Pantheon Colors */
    --ma-greek: #ffd700;
    --ma-norse: #48cae4;
    --ma-japanese: #dc2f02;
    --ma-celtic: #40916c;
    --ma-chinese: #f77f00;
    --ma-egyptian: #e9c46a;
    --ma-hindu: #ff6b35;
    --ma-african: #bc6c25;
    --ma-native: #8b5a2b;
    --ma-slavic: #4361ee;
    --ma-mesopotamian: #b08968;
    --ma-oceanic: #00b4d8;
    
    /* Typography */
    --ma-font-display: 'Cinzel Decorative', 'Cinzel', Georgia, serif;
    --ma-font-heading: 'Cinzel', Georgia, serif;
    --ma-font-body: 'Source Serif 4', 'Source Serif Pro', Georgia, serif;
    --ma-font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Font Sizes (Fluid) */
    --ma-text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
    --ma-text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
    --ma-text-base: clamp(1rem, 0.9rem + 0.5vw, 1.125rem);
    --ma-text-lg: clamp(1.125rem, 1rem + 0.6vw, 1.25rem);
    --ma-text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem);
    --ma-text-2xl: clamp(1.5rem, 1.25rem + 1.25vw, 2rem);
    --ma-text-3xl: clamp(1.875rem, 1.5rem + 1.875vw, 2.5rem);
    --ma-text-4xl: clamp(2.25rem, 1.75rem + 2.5vw, 3.5rem);
    --ma-text-5xl: clamp(3rem, 2rem + 5vw, 5rem);
    
    /* Spacing Scale */
    --ma-space-1: 0.25rem;
    --ma-space-2: 0.5rem;
    --ma-space-3: 0.75rem;
    --ma-space-4: 1rem;
    --ma-space-5: 1.25rem;
    --ma-space-6: 1.5rem;
    --ma-space-8: 2rem;
    --ma-space-10: 2.5rem;
    --ma-space-12: 3rem;
    --ma-space-16: 4rem;
    --ma-space-20: 5rem;
    --ma-space-24: 6rem;
    
    /* Border Radius */
    --ma-radius-sm: 4px;
    --ma-radius-md: 8px;
    --ma-radius-lg: 12px;
    --ma-radius-xl: 16px;
    --ma-radius-2xl: 24px;
    --ma-radius-full: 9999px;
    
    /* Shadows */
    --ma-shadow-sm: 0 1px 3px rgba(26, 26, 46, 0.12), 0 1px 2px rgba(26, 26, 46, 0.24);
    --ma-shadow-md: 0 4px 6px rgba(26, 26, 46, 0.15), 0 2px 4px rgba(26, 26, 46, 0.12);
    --ma-shadow-lg: 0 10px 25px rgba(26, 26, 46, 0.2), 0 5px 10px rgba(26, 26, 46, 0.15);
    --ma-shadow-xl: 0 20px 40px rgba(26, 26, 46, 0.25), 0 10px 20px rgba(26, 26, 46, 0.2);
    --ma-shadow-gold: 0 4px 20px rgba(201, 162, 39, 0.35);
    --ma-shadow-blue: 0 4px 20px rgba(74, 144, 164, 0.35);
    --ma-shadow-inner: inset 0 2px 4px rgba(26, 26, 46, 0.1);
    
    /* Gradients */
    --ma-gradient-hero: linear-gradient(135deg, var(--ma-midnight-indigo) 0%, var(--ma-deep-purple) 50%, var(--ma-mystic-violet) 100%);
    --ma-gradient-gold: linear-gradient(135deg, var(--ma-arcane-gold) 0%, var(--ma-gold-light) 50%, var(--ma-arcane-gold) 100%);
    --ma-gradient-blue: linear-gradient(135deg, var(--ma-celestial-blue) 0%, var(--ma-blue-light) 100%);
    --ma-gradient-dark: linear-gradient(180deg, var(--ma-obsidian) 0%, var(--ma-midnight-indigo) 100%);
    --ma-gradient-card: linear-gradient(145deg, rgba(45, 45, 68, 0.8) 0%, rgba(26, 26, 46, 0.9) 100%);
    
    /* Transitions */
    --ma-ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --ma-ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --ma-ease-dramatic: cubic-bezier(0.22, 1, 0.36, 1);
    --ma-transition-fast: 150ms var(--ma-ease-smooth);
    --ma-transition-normal: 300ms var(--ma-ease-smooth);
    --ma-transition-slow: 500ms var(--ma-ease-smooth);
    --ma-transition-dramatic: 600ms var(--ma-ease-dramatic);
    
    /* Z-Index Scale */
    --ma-z-dropdown: 100;
    --ma-z-sticky: 200;
    --ma-z-fixed: 300;
    --ma-z-modal-backdrop: 400;
    --ma-z-modal: 500;
    --ma-z-popover: 600;
    --ma-z-tooltip: 700;
}

/* ================================
   GLOBAL BASE STYLES
   ================================ */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--ma-font-body);
    font-size: var(--ma-text-base);
    line-height: 1.75;
    color: var(--ma-midnight-indigo);
    background-color: var(--ma-parchment);
}

/* Dark Theme Body */
body.dark-theme,
.dark-mode {
    background-color: var(--ma-midnight-indigo);
    color: var(--ma-parchment);
}

/* Selection */
::selection {
    background: var(--ma-arcane-gold);
    color: var(--ma-midnight-indigo);
}

/* ================================
   TYPOGRAPHY
   ================================ */

/* Display Headings (Hero titles) */
.ma-display,
.hero-title,
.page-hero h1 {
    font-family: var(--ma-font-display);
    font-weight: 900;
    letter-spacing: 0.02em;
    line-height: 1.1;
}

/* Standard Headings */
h1, h2, h3, h4, h5, h6,
.entry-title,
.ct-title,
.wp-block-heading {
    font-family: var(--ma-font-heading);
    font-weight: 700;
    line-height: 1.25;
    color: var(--ma-midnight-indigo);
    letter-spacing: 0.01em;
    margin-top: 0;
}

.dark-mode h1, .dark-mode h2, .dark-mode h3,
.dark-mode h4, .dark-mode h5, .dark-mode h6,
.dark-mode .entry-title {
    color: var(--ma-parchment);
}

h1, .h1 { font-size: var(--ma-text-4xl); font-weight: 900; }
h2, .h2 { font-size: var(--ma-text-3xl); }
h3, .h3 { font-size: var(--ma-text-2xl); }
h4, .h4 { font-size: var(--ma-text-xl); font-weight: 600; }
h5, .h5 { font-size: var(--ma-text-lg); font-weight: 600; }
h6, .h6 { font-size: var(--ma-text-base); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }

/* Body Text */
p {
    margin-bottom: var(--ma-space-4);
}

/* Lead/Intro Text */
.lead,
.entry-content > p:first-of-type {
    font-size: var(--ma-text-lg);
    line-height: 1.8;
    color: var(--ma-mystic-violet);
}

.dark-mode .lead,
.dark-mode .entry-content > p:first-of-type {
    color: var(--ma-ethereal-silver);
}

/* Links */
a {
    color: var(--ma-celestial-blue);
    text-decoration: none;
    transition: color var(--ma-transition-fast);
}

a:hover {
    color: var(--ma-arcane-gold);
}

.dark-mode a {
    color: var(--ma-arcane-gold);
}

.dark-mode a:hover {
    color: var(--ma-gold-light);
}

/* Small/Caption Text */
small, .small, .caption {
    font-size: var(--ma-text-sm);
    color: var(--ma-mystic-violet);
}

/* Blockquotes */
blockquote,
.wp-block-quote {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-xl);
    font-style: italic;
    border-left: 4px solid var(--ma-arcane-gold);
    padding: var(--ma-space-4) var(--ma-space-6);
    margin: var(--ma-space-8) 0;
    background: linear-gradient(90deg, rgba(201, 162, 39, 0.1) 0%, transparent 100%);
}

blockquote cite {
    font-family: var(--ma-font-body);
    font-size: var(--ma-text-sm);
    font-style: normal;
    color: var(--ma-arcane-gold);
    display: block;
    margin-top: var(--ma-space-2);
}

/* ================================
   HEADER & NAVIGATION
   ================================ */
.site-header,
header[data-id="type-1"] {
    background: var(--ma-gradient-dark);
    border-bottom: 1px solid rgba(201, 162, 39, 0.2);
}

/* Site Logo/Title */
.site-branding .site-title,
.site-title a {
    font-family: var(--ma-font-display);
    color: var(--ma-arcane-gold) !important;
    text-shadow: 0 2px 15px rgba(201, 162, 39, 0.4);
    letter-spacing: 0.03em;
}

/* Primary Navigation */
.ct-header-nav > ul > li > a,
.primary-menu > li > a {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ma-ethereal-silver);
    padding: var(--ma-space-2) var(--ma-space-4);
    transition: all var(--ma-transition-fast);
    position: relative;
}

.ct-header-nav > ul > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--ma-arcane-gold);
    transition: all var(--ma-transition-normal);
    transform: translateX(-50%);
}

.ct-header-nav > ul > li > a:hover,
.ct-header-nav > ul > li.current-menu-item > a,
.ct-header-nav > ul > li.current-menu-ancestor > a {
    color: var(--ma-arcane-gold);
}

.ct-header-nav > ul > li > a:hover::after,
.ct-header-nav > ul > li.current-menu-item > a::after {
    width: 100%;
}

/* Dropdown/Mega Menu */
.sub-menu,
.ct-header-dropdown {
    background: var(--ma-midnight-indigo);
    border: 1px solid rgba(201, 162, 39, 0.15);
    border-radius: var(--ma-radius-lg);
    box-shadow: var(--ma-shadow-xl);
    padding: var(--ma-space-2);
}

.sub-menu li a {
    font-family: var(--ma-font-body);
    font-size: var(--ma-text-sm);
    color: var(--ma-ethereal-silver);
    padding: var(--ma-space-2) var(--ma-space-4);
    border-radius: var(--ma-radius-md);
    transition: all var(--ma-transition-fast);
}

.sub-menu li a:hover {
    background: rgba(201, 162, 39, 0.1);
    color: var(--ma-arcane-gold);
    padding-left: var(--ma-space-5);
}

/* ================================
   BUTTONS
   ================================ */
.ma-btn,
.wp-block-button__link,
.ct-button,
button[type="submit"],
input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--ma-space-2);
    padding: var(--ma-space-3) var(--ma-space-6);
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-decoration: none;
    border: none;
    border-radius: var(--ma-radius-md);
    cursor: pointer;
    transition: all var(--ma-transition-normal);
}

/* Primary Button - Gold */
.ma-btn-primary,
.ma-btn--primary,
.wp-block-button.is-style-fill .wp-block-button__link,
.ct-button {
    background: var(--ma-gradient-gold);
    color: var(--ma-midnight-indigo);
    box-shadow: var(--ma-shadow-md);
}

.ma-btn-primary:hover,
.ma-btn--primary:hover,
.wp-block-button.is-style-fill .wp-block-button__link:hover,
.ct-button:hover {
    transform: translateY(-2px);
    box-shadow: var(--ma-shadow-gold);
    filter: brightness(1.1);
}

/* Secondary Button - Blue */
.ma-btn-secondary,
.ma-btn--secondary {
    background: var(--ma-gradient-blue);
    color: white;
    box-shadow: var(--ma-shadow-md);
}

.ma-btn-secondary:hover,
.ma-btn--secondary:hover {
    transform: translateY(-2px);
    box-shadow: var(--ma-shadow-blue);
}

/* Outline Button */
.ma-btn-outline,
.ma-btn--outline,
.wp-block-button.is-style-outline .wp-block-button__link {
    background: transparent;
    border: 2px solid var(--ma-arcane-gold);
    color: var(--ma-arcane-gold);
}

.ma-btn-outline:hover,
.ma-btn--outline:hover,
.wp-block-button.is-style-outline .wp-block-button__link:hover {
    background: var(--ma-arcane-gold);
    color: var(--ma-midnight-indigo);
}

/* Ghost Button (for dark backgrounds) */
.ma-btn-ghost {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--ma-parchment);
}

.ma-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--ma-arcane-gold);
    color: var(--ma-arcane-gold);
}

/* Portal Button (Special CTA) */
.ma-btn-portal {
    background: var(--ma-gradient-hero);
    border: 2px solid var(--ma-arcane-gold);
    color: var(--ma-arcane-gold);
    padding: var(--ma-space-4) var(--ma-space-8);
    font-size: var(--ma-text-base);
    position: relative;
    overflow: hidden;
}

.ma-btn-portal::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--ma-arcane-gold);
    opacity: 0;
    transition: opacity var(--ma-transition-normal);
}

.ma-btn-portal:hover {
    color: var(--ma-midnight-indigo);
}

.ma-btn-portal:hover::before {
    opacity: 1;
}

.ma-btn-portal span {
    position: relative;
    z-index: 1;
}

/* ================================
   CARDS
   ================================ */
.ma-card,
.ct-posts-card,
.wp-block-post,
article.post {
    background: white;
    border-radius: var(--ma-radius-xl);
    overflow: hidden;
    box-shadow: var(--ma-shadow-md);
    transition: all var(--ma-transition-normal);
    border: 1px solid rgba(26, 26, 46, 0.08);
}

.dark-mode .ma-card,
.dark-mode .ct-posts-card {
    background: var(--ma-gradient-card);
    border-color: rgba(201, 162, 39, 0.1);
}

.ma-card:hover,
.ct-posts-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--ma-shadow-xl);
}

.dark-mode .ma-card:hover,
.dark-mode .ct-posts-card:hover {
    box-shadow: var(--ma-shadow-gold);
    border-color: rgba(201, 162, 39, 0.3);
}

/* Card Image */
.ma-card__image,
.ct-posts-card .ct-media-container {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.ma-card__image img,
.ct-posts-card .ct-media-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--ma-transition-slow);
}

.ma-card:hover .ma-card__image img,
.ct-posts-card:hover .ct-media-container img {
    transform: scale(1.08);
}

/* Card Image Overlay */
.ma-card__image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(26, 26, 46, 0.6) 0%, transparent 50%);
    opacity: 0;
    transition: opacity var(--ma-transition-normal);
}

.ma-card:hover .ma-card__image::after {
    opacity: 1;
}

/* Card Content */
.ma-card__content,
.ct-posts-card .entry-card-content {
    padding: var(--ma-space-6);
}

.ma-card__category {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--ma-celestial-blue);
    margin-bottom: var(--ma-space-2);
}

.ma-card__title,
.ct-posts-card .entry-title {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-xl);
    font-weight: 700;
    margin-bottom: var(--ma-space-3);
    line-height: 1.3;
}

.ma-card__title a,
.ct-posts-card .entry-title a {
    color: inherit;
}

.ma-card__title a:hover,
.ct-posts-card .entry-title a:hover {
    color: var(--ma-arcane-gold);
}

.ma-card__excerpt,
.ct-posts-card .entry-excerpt {
    font-size: var(--ma-text-sm);
    color: var(--ma-mystic-violet);
    line-height: 1.7;
    margin-bottom: var(--ma-space-4);
}

.dark-mode .ma-card__excerpt {
    color: var(--ma-ethereal-silver);
}

.ma-card__meta {
    display: flex;
    align-items: center;
    gap: var(--ma-space-4);
    font-size: var(--ma-text-xs);
    color: var(--ma-mystic-violet);
    padding-top: var(--ma-space-4);
    border-top: 1px solid rgba(26, 26, 46, 0.1);
}

/* ================================
   BADGES & TAGS
   ================================ */
.ma-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--ma-space-1);
    padding: var(--ma-space-1) var(--ma-space-3);
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: var(--ma-radius-full);
    white-space: nowrap;
}

/* Creature Type Badges */
.ma-badge--dragon { background: var(--ma-dragon); color: white; }
.ma-badge--sea { background: var(--ma-sea); color: white; }
.ma-badge--flying { background: var(--ma-flying); color: var(--ma-midnight-indigo); }
.ma-badge--humanoid { background: var(--ma-humanoid); color: var(--ma-midnight-indigo); }
.ma-badge--fire { background: var(--ma-fire); color: white; }
.ma-badge--forest { background: var(--ma-forest); color: white; }
.ma-badge--shapeshifter { background: var(--ma-shapeshifter); color: white; }
.ma-badge--guardian { background: var(--ma-guardian); color: white; }
.ma-badge--spirit { background: var(--ma-spirit); color: var(--ma-midnight-indigo); }
.ma-badge--undead { background: var(--ma-undead); color: white; }

/* Pantheon/Culture Badges */
.ma-badge--greek { background: var(--ma-greek); color: var(--ma-midnight-indigo); }
.ma-badge--norse { background: var(--ma-norse); color: var(--ma-midnight-indigo); }
.ma-badge--japanese { background: var(--ma-japanese); color: white; }
.ma-badge--celtic { background: var(--ma-celtic); color: white; }
.ma-badge--chinese { background: var(--ma-chinese); color: white; }
.ma-badge--egyptian { background: var(--ma-egyptian); color: var(--ma-midnight-indigo); }
.ma-badge--hindu { background: var(--ma-hindu); color: white; }
.ma-badge--african { background: var(--ma-african); color: white; }
.ma-badge--slavic { background: var(--ma-slavic); color: white; }
.ma-badge--mesopotamian { background: var(--ma-mesopotamian); color: white; }
.ma-badge--oceanic { background: var(--ma-oceanic); color: white; }

/* Tag Pills */
.ma-tag,
.post-tags a,
.tagcloud a {
    display: inline-block;
    padding: var(--ma-space-1) var(--ma-space-3);
    font-size: var(--ma-text-xs);
    color: var(--ma-celestial-blue);
    background: rgba(74, 144, 164, 0.1);
    border: 1px solid rgba(74, 144, 164, 0.3);
    border-radius: var(--ma-radius-full);
    transition: all var(--ma-transition-fast);
}

.ma-tag:hover,
.post-tags a:hover,
.tagcloud a:hover {
    background: var(--ma-celestial-blue);
    color: white;
}

/* ================================
   HERO SECTIONS
   ================================ */
.ma-hero,
.page-hero {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: var(--ma-gradient-hero);
    padding: var(--ma-space-16) var(--ma-space-4);
}

/* Starfield Background Effect */
.ma-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, var(--ma-arcane-gold), transparent),
        radial-gradient(2px 2px at 40px 70px, var(--ma-ethereal-silver), transparent),
        radial-gradient(1px 1px at 90px 40px, var(--ma-celestial-blue), transparent),
        radial-gradient(2px 2px at 130px 80px, var(--ma-arcane-gold), transparent),
        radial-gradient(1px 1px at 160px 30px, var(--ma-ethereal-silver), transparent);
    background-size: 200px 100px;
    opacity: 0.4;
    animation: twinkle 8s ease-in-out infinite;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.6; }
}

/* Mystical Fog Overlay */
.ma-hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(0deg, var(--ma-midnight-indigo) 0%, transparent 100%);
    pointer-events: none;
}

.ma-hero__content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: var(--ma-space-8);
}

.ma-hero__title {
    font-family: var(--ma-font-display);
    font-size: var(--ma-text-5xl);
    font-weight: 900;
    color: var(--ma-arcane-gold);
    text-shadow: 0 4px 30px rgba(201, 162, 39, 0.5);
    margin-bottom: var(--ma-space-4);
    letter-spacing: 0.02em;
}

.ma-hero__subtitle {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-xl);
    color: var(--ma-ethereal-silver);
    margin-bottom: var(--ma-space-8);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ================================
   PANTHEON GRID
   ================================ */
.ma-pantheon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--ma-space-6);
    padding: var(--ma-space-8) 0;
}

.ma-pantheon-card {
    position: relative;
    aspect-ratio: 4/5;
    border-radius: var(--ma-radius-xl);
    overflow: hidden;
    cursor: pointer;
    transition: all var(--ma-transition-dramatic);
}

.ma-pantheon-card__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transition: transform var(--ma-transition-slow);
}

.ma-pantheon-card:hover .ma-pantheon-card__bg {
    transform: scale(1.1);
}

.ma-pantheon-card__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(26, 26, 46, 0.95) 0%, rgba(26, 26, 46, 0.3) 50%, transparent 100%);
    transition: background var(--ma-transition-normal);
}

.ma-pantheon-card:hover .ma-pantheon-card__overlay {
    background: linear-gradient(0deg, rgba(201, 162, 39, 0.9) 0%, rgba(26, 26, 46, 0.5) 60%, transparent 100%);
}

.ma-pantheon-card__content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--ma-space-6);
    color: white;
    transform: translateY(20px);
    transition: transform var(--ma-transition-normal);
}

.ma-pantheon-card:hover .ma-pantheon-card__content {
    transform: translateY(0);
}

.ma-pantheon-card__title {
    font-family: var(--ma-font-display);
    font-size: var(--ma-text-2xl);
    margin-bottom: var(--ma-space-2);
}

.ma-pantheon-card__count {
    font-size: var(--ma-text-sm);
    opacity: 0.8;
}

/* ================================
   CREATURE CAROUSEL
   ================================ */
.ma-carousel {
    position: relative;
    padding: var(--ma-space-8) 0;
}

.ma-carousel__track {
    display: flex;
    gap: var(--ma-space-6);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: var(--ma-space-4);
}

.ma-carousel__track::-webkit-scrollbar {
    display: none;
}

.ma-carousel__item {
    flex: 0 0 300px;
    scroll-snap-align: start;
}

/* ================================
   SIDEBAR
   ================================ */
.ct-sidebar,
.widget-area,
.sidebar {
    background: white;
    border-radius: var(--ma-radius-xl);
    padding: var(--ma-space-6);
    box-shadow: var(--ma-shadow-md);
}

.dark-mode .ct-sidebar,
.dark-mode .widget-area {
    background: var(--ma-gradient-card);
}

.widget {
    margin-bottom: var(--ma-space-8);
}

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

.widget-title,
.ct-widget-title {
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-lg);
    font-weight: 700;
    color: var(--ma-arcane-gold);
    padding-bottom: var(--ma-space-3);
    margin-bottom: var(--ma-space-4);
    border-bottom: 2px solid var(--ma-celestial-blue);
}

/* ================================
   FOOTER
   ================================ */
.site-footer,
footer[data-id="type-1"] {
    background: var(--ma-obsidian);
    color: var(--ma-ethereal-silver);
    border-top: 1px solid rgba(201, 162, 39, 0.2);
}

.footer-widgets-area {
    padding: var(--ma-space-16) 0 var(--ma-space-8);
}

.footer-widgets-area .widget-title {
    color: var(--ma-arcane-gold);
}

.footer-copyright {
    text-align: center;
    padding: var(--ma-space-6) 0;
    border-top: 1px solid rgba(201, 162, 39, 0.1);
    font-size: var(--ma-text-sm);
    color: var(--ma-mystic-violet);
}

/* ================================
   FORMS & INPUTS
   ================================ */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="url"],
input[type="tel"],
textarea,
select {
    width: 100%;
    padding: var(--ma-space-3) var(--ma-space-4);
    font-family: var(--ma-font-body);
    font-size: var(--ma-text-base);
    color: var(--ma-midnight-indigo);
    background: white;
    border: 2px solid rgba(26, 26, 46, 0.15);
    border-radius: var(--ma-radius-md);
    transition: all var(--ma-transition-fast);
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--ma-celestial-blue);
    box-shadow: 0 0 0 4px rgba(74, 144, 164, 0.15);
}

.dark-mode input,
.dark-mode textarea,
.dark-mode select {
    background: var(--ma-mystic-violet);
    color: var(--ma-parchment);
    border-color: rgba(201, 162, 39, 0.2);
}

/* Search Form */
.search-form {
    display: flex;
    gap: var(--ma-space-2);
}

.search-form .search-field {
    flex: 1;
}

/* ================================
   TABLE OF CONTENTS
   ================================ */
#ez-toc-container,
.toc-container {
    background: var(--ma-aged-paper);
    border: 1px solid rgba(201, 162, 39, 0.3);
    border-radius: var(--ma-radius-lg);
    padding: var(--ma-space-6);
    margin: var(--ma-space-8) 0;
}

.dark-mode #ez-toc-container {
    background: var(--ma-mystic-violet);
}

#ez-toc-container .ez-toc-title {
    font-family: var(--ma-font-heading);
    color: var(--ma-arcane-gold);
    font-weight: 700;
}

#ez-toc-container nav ul li a {
    color: var(--ma-midnight-indigo);
    font-size: var(--ma-text-sm);
    padding: var(--ma-space-1) 0;
    display: block;
    border-bottom: 1px solid transparent;
    transition: all var(--ma-transition-fast);
}

#ez-toc-container nav ul li a:hover {
    color: var(--ma-celestial-blue);
    padding-left: var(--ma-space-2);
}

/* ================================
   PAGINATION
   ================================ */
.ct-pagination,
.pagination,
.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--ma-space-2);
    margin-top: var(--ma-space-12);
}

.ct-pagination .page-numbers,
.pagination .page-numbers,
.nav-links a,
.nav-links span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 var(--ma-space-3);
    font-family: var(--ma-font-heading);
    font-size: var(--ma-text-sm);
    font-weight: 600;
    color: var(--ma-midnight-indigo);
    background: white;
    border: 2px solid rgba(26, 26, 46, 0.1);
    border-radius: var(--ma-radius-md);
    transition: all var(--ma-transition-fast);
}

.ct-pagination .page-numbers:hover,
.pagination .page-numbers:hover,
.nav-links a:hover {
    background: var(--ma-celestial-blue);
    border-color: var(--ma-celestial-blue);
    color: white;
}

.ct-pagination .page-numbers.current,
.pagination .page-numbers.current,
.nav-links .current {
    background: var(--ma-arcane-gold);
    border-color: var(--ma-arcane-gold);
    color: var(--ma-midnight-indigo);
}

/* ================================
   RESPONSIVE DESIGN
   ================================ */
@media (max-width: 1024px) {
    .ma-hero {
        min-height: 60vh;
    }
    
    .ma-hero__title {
        font-size: var(--ma-text-4xl);
    }
}

@media (max-width: 768px) {
    :root {
        --ma-space-8: 1.5rem;
        --ma-space-12: 2rem;
        --ma-space-16: 3rem;
    }
    
    .ma-hero {
        min-height: 50vh;
        padding: var(--ma-space-12) var(--ma-space-4);
    }
    
    .ma-hero__title {
        font-size: var(--ma-text-3xl);
    }
    
    .ma-pantheon-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--ma-space-4);
    }
    
    .ma-carousel__item {
        flex: 0 0 260px;
    }
}

@media (max-width: 480px) {
    .ma-pantheon-grid {
        grid-template-columns: 1fr;
    }
    
    .ma-carousel__item {
        flex: 0 0 85vw;
    }
    
    .ma-card__content {
        padding: var(--ma-space-4);
    }
}

/* ================================
   ANIMATIONS
   ================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.ma-animate-fade-in-up {
    animation: fadeInUp 0.6s var(--ma-ease-dramatic) forwards;
}

.ma-animate-fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.ma-animate-slide-in-left {
    animation: slideInLeft 0.5s var(--ma-ease-smooth) forwards;
}

/* Stagger Animation Delays */
.ma-stagger-1 { animation-delay: 0.1s; }
.ma-stagger-2 { animation-delay: 0.2s; }
.ma-stagger-3 { animation-delay: 0.3s; }
.ma-stagger-4 { animation-delay: 0.4s; }
.ma-stagger-5 { animation-delay: 0.5s; }
.ma-stagger-6 { animation-delay: 0.6s; }

/* ================================
   UTILITY CLASSES
   ================================ */
.ma-text-gold { color: var(--ma-arcane-gold); }
.ma-text-blue { color: var(--ma-celestial-blue); }
.ma-text-indigo { color: var(--ma-midnight-indigo); }

.ma-bg-gold { background-color: var(--ma-arcane-gold); }
.ma-bg-blue { background-color: var(--ma-celestial-blue); }
.ma-bg-indigo { background-color: var(--ma-midnight-indigo); }

.ma-text-center { text-align: center; }
.ma-text-left { text-align: left; }
.ma-text-right { text-align: right; }

.ma-font-display { font-family: var(--ma-font-display); }
.ma-font-heading { font-family: var(--ma-font-heading); }
.ma-font-body { font-family: var(--ma-font-body); }

/* ================================
   PRINT STYLES
   ================================ */
@media print {
    body {
        background: white;
        color: black;
        font-size: 12pt;
    }
    
    .site-header,
    .site-footer,
    .ct-sidebar,
    .ct-pagination,
    #ez-toc-container,
    .ma-hero::before,
    .ma-hero::after {
        display: none !important;
    }
    
    .ma-hero {
        min-height: auto;
        background: none;
        color: black;
    }
    
    .ma-hero__title {
        color: black;
        text-shadow: none;
    }
    
    a {
        color: black;
        text-decoration: underline;
    }
}
