:root {
    /* Colors - Dark, Premium, "Sacred" */
    --bg-color: #0a0b10;
    --card-bg: #14161f;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --accent-gold: #d4af37;
    /* Metallic Gold */
    --accent-blue: #375bd4;
    /* Royal Blue - subtle */
    --border-color: #2a2d3a;

    /* Typography */
    --font-heading: 'Cinzel', serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 400;
    letter-spacing: 1px;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Layout */
.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    border-bottom: 1px solid var(--border-color);
    background: rgba(10, 11, 16, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 3px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo span {
    font-weight: 700;
}

nav ul {
    display: flex;
    gap: 2rem;
    list-style: none;
}

nav a {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

nav a:hover,
nav a.active {
    color: var(--accent-gold);
}

/* Main Content Area */
main {
    flex: 1;
    overflow-y: auto;
    padding: 2rem 3rem;
    position: relative;
}

/* Dashboard View */
.dashboard-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    animation: fadeIn 0.8s ease-out;
}

.cathedral-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    cursor: pointer;
    position: relative;
}

.cathedral-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border-color: var(--accent-gold);
}

.card-image {
    height: 250px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.card-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(to top, var(--card-bg), transparent);
}

.card-content {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.4rem;
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
}

.card-location {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.card-summary {
    font-size: 0.95rem;
    color: var(--text-primary);
    opacity: 0.8;
}

/* Detail View */
.detail-view {
    display: none;
    /* Hidden by default */
    animation: slideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.detail-view.active {
    display: block;
}

.back-button {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
    cursor: pointer;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.back-button:hover {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.detail-header {
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 2rem;
}

.detail-title {
    font-size: 3rem;
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
}

.detail-meta {
    display: flex;
    gap: 2rem;
    color: var(--text-secondary);
    font-family: var(--font-heading);
}

.detail-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 4rem;
}

.detail-sidebar {
    position: sticky;
    top: 2rem;
}

.detail-nav {
    list-style: none;
    border-left: 2px solid var(--border-color);
}

.detail-nav li {
    padding: 1rem 0 1rem 1.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    position: relative;
}

.detail-nav li::before {
    content: '';
    position: absolute;
    left: -2px;
    top: 0;
    height: 100%;
    width: 2px;
    background: var(--accent-gold);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.detail-nav li:hover,
.detail-nav li.active {
    color: var(--text-primary);
}

.detail-nav li:hover::before,
.detail-nav li.active::before {
    transform: scaleY(1);
}

.section-content {
    margin-bottom: 4rem;
}

.section-title {
    font-size: 1.8rem;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.data-block {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    border-left: 3px solid var(--accent-gold);
}

.data-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.data-value {
    font-size: 1.1rem;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Timeline View */
.timeline-view {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    animation: fadeIn 0.8s ease-out;
}

.timeline-container {
    position: relative;
    margin-top: 3rem;
    padding: 2rem 0;
    overflow-x: auto;
}

.timeline-item {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    position: relative;
    height: 40px;
}

.timeline-label {
    width: 250px;
    font-family: 'Cinzel', serif;
    font-size: 0.9rem;
    color: var(--text-color);
    padding-right: 1rem;
    text-align: right;
    flex-shrink: 0;
}

.timeline-track {
    flex-grow: 1;
    position: relative;
    height: 100%;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.timeline-bar {
    position: absolute;
    height: 20px;
    background: linear-gradient(90deg, var(--accent-gold), #b8962e);
    border-radius: 4px;
    top: 10px;
    transition: width 0.5s ease, left 0.5s ease;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.timeline-bar:hover {
    filter: brightness(1.2);
    transform: scaleY(1.1);
    z-index: 10;
}

.timeline-bar-dates {
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.8);
    padding: 2px 6px;
    border-radius: 3px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.timeline-bar:hover .timeline-bar-dates {
    opacity: 1;
}

.timeline-axis {
    display: flex;
    justify-content: space-between;
    margin-left: 250px;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

/* About View */
.about-view {
    padding: 2rem;
    max-width: 800px;
    margin: 0 auto;
    animation: fadeIn 0.8s ease-out;
    text-align: center;
}

.about-content {
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-top: 2rem;
}

.about-content p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.lelien {
    color: var(--accent-gold);
    text-decoration: none;
    font-weight: bold;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.lelien:hover {
    border-bottom-color: var(--accent-gold);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}