/* CSS Custom Properties - University of Houston Branding */
:root {
    /* UH Primary Colors */
    --color-uh-red: #C8102E;
    --color-uh-white: #FFFFFF;
    
    /* UH Secondary Colors */
    --color-uh-black: #000000;
    --color-uh-slate: #54585A;
    
    /* UH Accent Colors */
    --color-uh-brick: #960C22;
    --color-uh-teal: #00B388;
    --color-uh-gold: #F6BE00;
    --color-uh-gray: #888B8D;
    --color-uh-green: #00866C;
    --color-uh-mustard: #D89B00;
    --color-uh-chocolate: #640817;
    --color-uh-forest: #005950;
    --color-uh-ocher: #B97800;
    --color-uh-cream: #FFF9D9;
    
    /* Design System Colors */
    --color-primary: var(--color-uh-red);
    --color-secondary: var(--color-uh-teal);
    --color-success: var(--color-uh-green);
    --color-warning: var(--color-uh-gold);
    --color-danger: var(--color-uh-brick);
    --color-text: var(--color-uh-slate);
    --color-text-light: var(--color-uh-gray);
    --color-background: var(--color-uh-white);
    --color-background-light: var(--color-uh-cream);
    
    /* Spacing & Layout */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --border-radius: 12px;
    --border-radius-sm: 6px;
    --border-radius-lg: 16px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --shadow-sm: 0 2px 4px rgba(84, 88, 90, 0.1);
    --shadow-md: 0 4px 6px rgba(84, 88, 90, 0.1);
    --shadow-lg: 0 10px 15px rgba(84, 88, 90, 0.15);
}

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

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-background);
}

/* Skip link for accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: var(--color-primary);
    color: white;
    padding: 8px;
    z-index: 1000;
    text-decoration: none;
    border-radius: var(--border-radius-sm);
    transition: top 0.3s;
}

.skip-link:focus {
    top: 6px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.2;
}

h1 {
    font-size: 3.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--color-uh-red) 0%, var(--color-uh-brick) 100%);
    color: white;
    padding: 100px 0;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.hero-description {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.8;
    line-height: 1.5;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: white;
    color: var(--color-uh-red);
}

.btn-primary:hover {
    background-color: var(--color-uh-cream);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background-color: white;
    color: var(--color-uh-red);
}

/* Navigation */
.main-nav {
    background-color: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2rem;
    padding: 1rem 20px;
}

.nav-link {
    text-decoration: none;
    color: #4b5563;
    font-weight: 500;
    padding: 0.5rem;
    transition: color 0.2s;
}

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

/* Sections */
.section {
    padding: 80px 0;
}

.bg-light {
    background-color: #f9fafb;
}

/* Overview Section */
.overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.overview-card {
    background: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--color-uh-teal);
}

.overview-card h3 {
    color: var(--color-uh-red);
    margin-bottom: 1rem;
}

/* Opinions Section */
.opinions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.opinion-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    position: relative;
}

.opinion-card.majority {
    border-left: 4px solid var(--color-uh-green);
}

.opinion-card.concurrence {
    border-left: 4px solid var(--color-uh-teal);
}

.opinion-card.dissent {
    border-left: 4px solid var(--color-uh-red);
}

.author {
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.justice-photo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    float: right;
    margin-left: 1rem;
    margin-bottom: 0.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 2px solid white;
}

.read-link {
    color: var(--color-uh-teal);
    text-decoration: none;
    font-weight: 500;
    margin-top: 1rem;
    display: inline-block;
}

.read-link:hover {
    color: var(--color-uh-red);
}

/* Timeline */
.timeline-container {
    position: relative;
    margin-top: 3rem;
}

.timeline-container::before {
    content: '';
    position: absolute;
    left: 2rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: #e5e7eb;
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding-left: 5rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 1.25rem;
    top: 0.5rem;
    width: 1.5rem;
    height: 1.5rem;
    background-color: var(--color-uh-red);
    border-radius: 50%;
    border: 4px solid white;
    box-shadow: 0 0 0 2px var(--color-uh-gray);
}

.timeline-date {
    font-weight: 600;
    color: var(--color-uh-red);
    margin-bottom: 0.5rem;
}

.timeline-content h4 {
    color: #1f2937;
    margin-bottom: 0.5rem;
}

/* Materials Section */
.materials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.material-section {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

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

.material-list li {
    margin-bottom: 0.75rem;
}

.material-list a {
    color: var(--color-uh-teal);
    text-decoration: none;
    padding: 0.5rem;
    display: block;
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s;
}

.material-list a:hover {
    background-color: var(--color-uh-cream);
    color: var(--color-uh-red);
}

.case-description {
    font-size: 0.85rem;
    color: #6b7280;
    margin-top: 0.25rem;
    font-style: italic;
    line-height: 1.4;
}

/* Practice Section */
.practice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.practice-card {
    background: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    border-top: 4px solid var(--color-uh-gold);
}

.practice-card h3 {
    color: var(--color-uh-mustard);
    margin-bottom: 1rem;
}

/* Footer */
.footer {
    background-color: var(--color-uh-slate);
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.footer a {
    color: var(--color-uh-teal);
    text-decoration: none;
}

.footer a:hover {
    color: var(--color-uh-gold);
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    .hero {
        padding: 60px 0;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .nav-container {
        gap: 1rem;
    }
    
    .section {
        padding: 60px 0;
    }
    
    .timeline-container::before {
        left: 1rem;
    }
    
    .timeline-item {
        padding-left: 3rem;
    }
    
    .timeline-item::before {
        left: 0.25rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus states for accessibility */
.btn:focus,
.nav-link:focus,
a:focus {
    outline: 2px solid var(--color-uh-teal);
    outline-offset: 2px;
}

/* Analysis Page Styles */
.analysis-header {
    background: linear-gradient(135deg, var(--color-uh-red), var(--color-uh-brick));
    color: var(--color-uh-white);
    padding: 2rem 0;
}

.breadcrumb {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.breadcrumb a {
    color: var(--color-uh-white);
    text-decoration: none;
}

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

.analysis-subtitle {
    font-size: 1.1rem;
    font-weight: 400;
    opacity: 0.9;
    margin-top: 0.5rem;
}

.analysis-content {
    padding: 3rem 0;
}

.executive-summary {
    background: #f8f9fa;
    border-left: 4px solid var(--color-uh-teal);
    padding: 2rem;
    border-radius: 8px;
    margin-bottom: 3rem;
}

.executive-summary h2 {
    color: var(--color-uh-red);
    margin-bottom: 1rem;
}

.analysis-section {
    margin-bottom: 3rem;
}

.analysis-section h2 {
    color: var(--color-uh-red);
    border-bottom: 2px solid var(--color-uh-gold);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.analysis-section h3 {
    color: var(--color-uh-slate);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.analysis-section ul, .analysis-section ol {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.analysis-section li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.analysis-section li strong {
    color: var(--color-uh-red);
}

.analysis-footer {
    border-top: 1px solid var(--color-uh-gray);
    padding-top: 2rem;
    margin-top: 3rem;
    text-align: center;
    background: #f8f9fa;
}

.analysis-attribution {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--color-uh-slate);
}

.analysis-attribution a {
    color: var(--color-uh-red);
    text-decoration: none;
}

.analysis-attribution a:hover {
    text-decoration: underline;
    color: var(--color-uh-brick);
}

/* Timeline Link Styles */
.timeline-content h4 a {
    color: var(--color-uh-red);
    text-decoration: none;
}

.timeline-content h4 a:hover {
    text-decoration: underline;
    color: var(--color-uh-brick);
}

.timeline-content p a {
    color: var(--color-uh-teal);
    text-decoration: none;
    font-weight: 500;
}

.timeline-content p a:hover {
    text-decoration: underline;
    color: var(--color-uh-green);
}