:root {
    --primary-color: #57150B;
    /* Rowan Brown */
    --secondary-color: #FFCC00;
    /* Rowan Gold */
    --accent-color: #E63946;
    /* Vibrant Red for PING feel */
    --text-color: #2D3142;
    --text-muted: #4F5D75;
    --bg-light: #F8F9FA;
    --bg-white: #FFFFFF;
    --border-color: #E0E1E6;
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --container-width: 1200px;
    --font-main: 'Outfit', sans-serif;
}

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

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

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header & Nav */
header {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

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

.rowan-brand {
    display: flex;
    flex-direction: column;
    border-right: 2px solid var(--primary-color);
    padding-right: 1.5rem;
}

.university {
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 2px;
    color: var(--primary-color);
}

.ping {
    font-weight: 300;
    font-size: 1.2rem;
    color: var(--text-muted);
}

/* Dropdown styles */
.dropdown {
    position: relative;
}

.dropdown-content {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--bg-white);
    min-width: 220px;
    box-shadow: var(--card-shadow);
    border-radius: 8px;
    padding: 0.5rem 0;
    margin-top: 0;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    z-index: 9999;
}

.dropdown-content::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    width: 100%;
    height: 10px;
}

@keyframes fadeInDropdown {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.dropdown:hover .dropdown-content {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.dropdown-content a {
    color: var(--text-color);
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    display: block;
    font-size: 0.95rem;
    font-weight: 500;
}

.dropdown-content a:hover {
    background-color: var(--bg-light);
    color: var(--accent-color);
}

.dropdown-content hr {
    border: 0;
    border-top: 1px solid var(--border-color);
    margin: 0.5rem 0;
}

.nav-studio {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.icon-spark {
    color: var(--accent-color);
    width: 16px;
    height: 16px;
}

.user-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    cursor: pointer;
    color: var(--text-muted);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    transition: var(--transition);
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.btn {
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

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

.btn-primary:hover {
    background: #7a1d0f;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(87, 21, 11, 0.3);
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
    transition: var(--transition);
}

/* Hero Section */
.hero {
    position: relative;
    height: 70vh;
    min-height: 500px;
    background: url('images/hero_bg.png') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(87, 21, 11, 0.8), rgba(45, 49, 66, 0.6));
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    animation: fadeInUp 1s ease-out;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.2s backwards;
}

.hero-search {
    display: flex;
    background: white;
    padding: 0.5rem;
    border-radius: 50px;
    max-width: 600px;
    margin: 0 auto 3rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 1s ease-out 0.4s backwards;
}

.hero-search:focus-within {
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.25);
    transform: scale(1.02);
}

.hero-search input {
    flex: 1;
    border: none;
    padding: 0.8rem 1.5rem;
    font-size: 1.1rem;
    border-radius: 50px;
    background: transparent;
}

.hero-search input:focus {
    outline: none;
}

.btn-search {
    background: var(--accent-color);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.btn-search:hover {
    transform: scale(1.05);
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 4rem;
    animation: fadeInUp 1s ease-out 0.6s backwards;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-size: 2rem;
    font-weight: 800;
    color: var(--secondary-color);
}

.stat-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-divider {
    width: 1px;
    background: rgba(255, 255, 255, 0.3);
}

/* Sim Browser & Tabs */
.sim-browser {
    padding: 5rem 0;
}

.tab-navigation {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    border-bottom: 2px solid var(--border-color);
}

.tab-btn {
    background: none;
    border: none;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

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

.tab-btn.active {
    color: var(--accent-color);
}

.tab-btn::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--accent-color);
    transition: var(--transition);
}

.tab-btn.active::after {
    width: 100%;
}

.tab-view {
    display: none;
    animation: fadeIn 0.4s ease-out;
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.section-title {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 3rem;
    text-align: center;
}

.browse-category {
    margin-bottom: 4rem;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.category-title {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--primary-color);
}

.category-title i {
    color: var(--accent-color);
}

.category-title h3 {
    font-size: 1.6rem;
}

.view-all {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
}

.view-all:hover {
    text-decoration: underline;
    transform: translateX(5px);
}

.sim-row {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.filter-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }

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

.customize-placeholder {
    padding: 6rem;
    text-align: center;
    background: white;
    border-radius: 30px;
    border: 2px dashed var(--border-color);
    color: var(--text-muted);
}

.customize-placeholder i {
    width: 64px;
    height: 64px;
    margin-bottom: 1.5rem;
    color: var(--accent-color);
}

.customize-placeholder h3 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.customize-placeholder p {
    margin-bottom: 2rem;
}

/* Feature Icons on Cards */
.card-tech-icons {
    display: flex;
    gap: 0.5rem;
    margin-right: auto;
}

.tech-icon {
    width: 20px;
    height: 20px;
    padding: 3px;
    border-radius: 4px;
    background: #f0f0f0;
    font-size: 10px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
}

.tech-icon.html5 {
    color: #E34F26;
    background: rgba(227, 79, 38, 0.1);
}

.filters h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.filters h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent-color);
}

.filter-group {
    margin-bottom: 2.5rem;
}

.filter-group h4 {
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.checkbox-container {
    display: block;
    position: relative;
    padding-left: 35px;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 1rem;
    user-select: none;
    transition: var(--transition);
}

.checkbox-container:hover {
    color: var(--accent-color);
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 22px;
    width: 22px;
    background-color: #e2e8f0;
    border-radius: 4px;
}

.checkbox-container:hover input~.checkmark {
    background-color: #cbd5e0;
}

.checkbox-container input:checked~.checkmark {
    background-color: var(--accent-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked~.checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 8px;
    top: 4px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Simulation Grid */
.sim-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
}

.view-options {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.view-options select {
    padding: 0.6rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: white;
    font-family: inherit;
    cursor: pointer;
}

.sim-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

/* Sim Card */
.sim-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    position: relative;
    cursor: pointer;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.sim-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.sim-card-image {
    height: 180px;
    overflow: hidden;
    position: relative;
}

.sim-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.sim-card:hover .sim-card-image img {
    transform: scale(1.1);
}

.sim-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--accent-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
}

.sim-card-content {
    padding: 1.5rem;
}

.sim-card-content h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.sim-tags {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    background: var(--bg-light);
    color: var(--text-muted);
}

.sim-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.sim-age {
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
}

.btn-play {
    color: var(--accent-color);
    background: none;
    border: none;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

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

.footer-brand .university {
    color: var(--secondary-color);
}

.footer-brand p {
    margin: 1.5rem 0;
    opacity: 0.8;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-links a {
    color: rgba(255, 255, 255, 0.6);
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--secondary-color);
    transform: translateY(-3px);
}

.footer-links h4 {
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

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

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

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

/* Responsive */
@media (max-width: 1024px) {
    .sim-browser {
        grid-template-columns: 1fr;
    }

    .filters {
        display: none;
        /* Mobile filter modal can be added later */
    }

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

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

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

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

/* Featured Banner */
.featured-banner {
    display: flex;
    background: linear-gradient(135deg, var(--primary-color), #4A0E12);
    border-radius: 20px;
    padding: 3rem;
    color: white;
    margin-bottom: 3rem;
    align-items: center;
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.featured-info {
    flex: 1;
    z-index: 2;
}

.badge-featured {
    background: var(--secondary-color);
    color: var(--primary-color);
    padding: 0.4rem 1rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    display: inline-block;
}

.featured-info h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.featured-info p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 500px;
}

.featured-actions {
    display: flex;
    gap: 1rem;
}

.featured-visual {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.featured-visual img {
    max-width: 400px;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    transform: rotate(2deg);
    transition: transform 0.3s ease;
}

.featured-banner:hover .featured-visual img {
    transform: rotate(0deg) scale(1.05);
}

/* Customize View Styles */
.customize-container {
    padding: 1rem;
}

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

.setting-card {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.setting-info {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.setting-info i {
    color: var(--primary-color);
    width: 24px;
    height: 24px;
}

.setting-info h4 {
    margin: 0;
    color: var(--text-color);
}

.setting-info p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Toggle Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    -webkit-transition: .4s;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    -webkit-transition: .4s;
    transition: .4s;
}

input:checked+.slider {
    background-color: var(--primary-color);
}

input:checked+.slider:before {
    -webkit-transform: translateX(26px);
    -ms-transform: translateX(26px);
    transform: translateX(26px);
}

.slider.round {
    border-radius: 24px;
}

.slider.round:before {
    border-radius: 50%;
}

.favorites-section {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 20px;
    text-align: center;
}

.favorites-placeholder {
    padding: 3rem;
    border: 2px dashed #ccc;
    border-radius: 15px;
    margin-top: 1rem;
    color: var(--text-muted);
}

/* Dark Theme Prototype */
body.dark-theme {
    background-color: #1a1a1a;
    color: #f0f0f0;
}

body.dark-theme .nav-links a,
body.dark-theme .university,
body.dark-theme h2,
body.dark-theme h3,
body.dark-theme h4 {
    color: white;
}

body.dark-theme .sim-card,
body.dark-theme .setting-card {
    background: #2a2a2a;
    color: white;
}

body.dark-theme .sim-card-content h4 {
    color: white;
}

/* Page Sections */
.page-section {
    padding: 4rem 0;
    min-height: 60vh;
}

.page-content {
    text-align: center;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.page-icon {
    width: 48px;
    height: 48px;
    color: var(--primary-color);
}

.page-header h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
}

.page-description {
    max-width: 700px;
    margin: 0 auto 3rem;
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Feature Cards (Studio) */
.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.feature-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-card i {
    width: 40px;
    height: 40px;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.btn-large {
    padding: 1rem 3rem;
    font-size: 1.1rem;
}

/* Resource Grid (Teaching) */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.resource-card {
    background: linear-gradient(135deg, var(--primary-color), #4A0E12);
    color: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: left;
}

.resource-card h3 {
    color: white;
    margin-bottom: 0.5rem;
}

.resource-card p {
    opacity: 0.9;
    margin-bottom: 1rem;
}

.resource-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
}

/* Stat Cards (Research) */
.stat-cards {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.stat-card {
    background: var(--bg-light);
    padding: 2rem 3rem;
    border-radius: 15px;
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Initiative List */
.initiative-list {
    max-width: 800px;
    margin: 0 auto;
}

.initiative-item {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 1.5rem;
    text-align: left;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-left: 4px solid var(--primary-color);
}

.initiative-item h3 {
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.initiative-item p {
    color: var(--text-muted);
    margin: 0;
}