/* Base Styles */
:root {
    --bs-primary: #7289DA;
    --bs-secondary: #2B3035;
    --bs-success: #43B581;
    --bs-body-bg: #1A1D21;
    --bs-body-color: #FFFFFF;
    --bs-info-rgb: 13, 202, 240;
    --bs-danger-rgb: 220, 53, 69;
    --bs-dark: #212529;
    
    /* Guide-specific variables */
    --guide-primary: #7289DA;
    --guide-secondary: #2C2F33;
    --guide-dark: #23272A;
    --guide-light: #99AAB5;
    --guide-accent: #5865F2;
    --guide-success: #43B581;
    --guide-warning: #FAA61A;
    --guide-danger: #F04747;
    --guide-card-bg: rgba(44, 47, 51, 0.95);
    --guide-section-bg: rgba(35, 39, 42, 0.95);
    --navbar-height: 56px;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bs-body-bg);
    color: var(--bs-body-color);
    scroll-behavior: smooth;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* Navbar Styles */
.navbar {
    background-color: var(--bs-dark) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar-dark .navbar-nav {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap;
    width: 100%;
    padding-bottom: 5px;
}

.navbar-dark .navbar-nav::-webkit-scrollbar {
    display: none;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    transition: color 0.2s ease;
    padding: 0.5rem 1rem;
    white-space: nowrap;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
    color: var(--bs-primary);
}

.navbar-dark .navbar-toggler {
    border: none;
    padding: 0.5rem;
}

.navbar-dark .navbar-toggler:focus {
    box-shadow: none;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.25rem;
}

@media (max-width: 991px) {
    .navbar {
        padding: 0.5rem 0;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    .navbar-brand {
        padding-left: 1rem;
    }

    .navbar-toggler {
        margin-right: 1rem;
    }

    .navbar-collapse {
        max-height: calc(100vh - 56px);
        overflow-y: auto;
    }

    .navbar-nav {
        padding: 0.5rem 1rem;
    }

    .navbar-collapse.show,
    .navbar-collapse.collapsing {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        background: var(--bs-dark);
        z-index: 1030;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    .navbar-nav .nav-link {
        padding: 0.75rem 0;
    }
}

/* Hero Section */
.hero {
    position: relative;
    background: linear-gradient(rgba(26, 29, 33, 0.9), rgba(43, 48, 53, 0.95)),
                url('../../images/vr-background.svg') center/cover no-repeat;
    background-blend-mode: overlay;
    padding: 8rem 0 4rem;
    display: flex;
    align-items: center;
    overflow: hidden;
    margin-bottom: 0;
    text-align: center;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--guide-primary), var(--guide-success));
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero .lead {
    font-size: clamp(1.1rem, 2vw, 1.5rem);
    opacity: 0.9;
    color: var(--bs-body-color);
}

/* Guide Navigation */
.guide-nav {
    background: var(--bs-secondary);
    padding: 1rem 0;
    position: sticky;
    top: var(--navbar-height);
    z-index: 1020;
    border-bottom: 4px solid var(--bs-primary);
    margin-top: calc(var(--navbar-height) * -1 + 56px);
}

.guide-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.guide-nav a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 50rem;
    transition: all 0.3s ease;
    font-weight: 500;
}

.guide-nav a:hover {
    background-color: var(--bs-primary);
    color: white;
}

@media (max-width: 768px) {
    .guide-nav {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .guide-nav::-webkit-scrollbar {
        display: none;
    }

    .guide-nav ul {
        flex-wrap: nowrap;
        padding: 0 0.75rem;
        margin: 0;
        width: max-content;
        min-width: 100%;
        gap: 0.5rem;
    }

    .guide-nav a {
        white-space: nowrap;
        padding: 0.35rem 0.75rem;
        font-size: 0.9rem;
    }

    /* Content adjustments */
    .guide-content {
        padding: 1rem;
    }

    .guide-section {
        padding: 1.25rem;
        margin-bottom: 1.5rem;
        border-radius: 0.75rem;
    }

    .guide-section h2 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
        line-height: 1.3;
    }

    .guide-section h3 {
        font-size: 1.25rem;
        margin: 1.25rem 0 0.75rem;
        line-height: 1.3;
    }

    /* Container padding */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
        max-width: 100%;
    }

    /* Section spacing */
    .py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
}

/* Guide Content */
.guide-content {
    max-width: 1800px;
    margin: 0 auto;
    padding: 2rem;
}

.guide-section {
    background: var(--guide-section-bg);
    border-radius: 1.5rem;
    padding: 3rem;
    margin-bottom: 3rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(114, 137, 218, 0.1);
}

.guide-section h2 {
    color: var(--guide-primary);
    margin-bottom: 2rem;
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.guide-section h3 {
    color: #fff;
    margin: 2.5rem 0 1.5rem;
    font-size: 1.75rem;
    font-weight: 600;
}

/* Method Cards */
.method-card {
    background: var(--guide-card-bg);
    border: 1px solid rgba(114, 137, 218, 0.1);
    border-radius: 1rem;
    padding: 2.5rem;
    margin-bottom: 2.5rem;
    transition: all 0.3s ease;
    color: #fff;
}

.method-card.with-image {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.method-card.with-image > div {
    flex: 2;
}

.method-card.with-image > img {
    flex: 1;
    max-width: 500px;
    object-fit: contain;
}

.method-card h4 {
    color: var(--guide-primary);
    margin-bottom: 1.2rem;
    font-size: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Share button styles */
.share-button {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: 1px solid rgba(114, 137, 218, 0.2);
    color: var(--guide-light);
    padding: 0.5rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.share-button:hover {
    background: rgba(114, 137, 218, 0.1);
    border-color: var(--guide-primary);
    color: var(--guide-primary);
}

.share-button i {
    font-size: 1rem;
}

.method-card p {
    color: var(--guide-light);
    margin-bottom: 1.8rem;
    font-size: 1.1rem;
    line-height: 1.7;
    padding-left: 1.8rem;
}

.method-card img {
    width: 100%;
    height: auto;
    border-radius: 0.75rem;
    border: 1px solid rgba(114, 137, 218, 0.2);
    transition: transform 0.3s ease;
    cursor: pointer;
}

.method-card img:hover {
    transform: scale(1.02);
    border-color: var(--guide-primary);
}

.method-card:hover {
    transform: translateY(-4px);
    border-color: var(--guide-primary);
    box-shadow: 0 4px 12px rgba(114, 137, 218, 0.2);
}

/* Key Points */
.key-points {
    background: rgba(114, 137, 218, 0.1);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin: 1rem 0;
    color: #fff;
}

.key-points ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.key-points li {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 1.1rem;
    line-height: 1.6;
    padding-left: 0.25rem;
}

.key-points li:last-child {
    margin-bottom: 0;
}

.key-points li:before {
    content: '\F26A';
    font-family: 'bootstrap-icons';
    color: var(--guide-primary);
    font-size: 1rem;
}

/* Notes */
.info-note, .warning-note {
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin: 1.5rem 0;
    position: relative;
    width: 100%;
}

.info-note {
    background: rgba(var(--bs-info-rgb), 0.1);
    border-left: 4px solid var(--bs-info);
}

.warning-note {
    background: rgba(var(--bs-danger-rgb), 0.1);
    border-left: 4px solid var(--bs-danger);
}

.info-note h4, .warning-note h4 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.info-note h4:before, .warning-note h4:before {
    font-family: 'bootstrap-icons';
    font-size: 1.25rem;
    flex-shrink: 0;
}

.info-note h4:before {
    content: '\F431';
    color: var(--bs-info);
}

.warning-note h4:before {
    content: '\F33A';
    color: var(--bs-danger);
}

.info-note ul, .warning-note ul {
    margin: 0;
    padding-left: 1.25rem;
}

.info-note li, .warning-note li {
    margin-bottom: 0.5rem;
}

.info-note li:last-child, .warning-note li:last-child {
    margin-bottom: 0;
}

.info-note i {
    color: var(--bs-info);
    font-size: 1.25rem;
    vertical-align: middle;
}

.warning-note i {
    color: var(--bs-danger);
    font-size: 1.25rem;
    vertical-align: middle;
}

.info-note a, .warning-note a {
    color: var(--guide-primary);
    text-decoration: none;
    position: relative;
    font-weight: 500;
    transition: all 0.2s ease;
}

.info-note a:hover, .warning-note a:hover {
    color: var(--guide-accent);
    text-decoration: underline;
}

.guide-section a {
    color: var(--guide-primary);
    text-decoration: none;
    position: relative;
    font-weight: 500;
    transition: all 0.2s ease;
}

.guide-section a:hover {
    color: var(--guide-accent);
    text-decoration: underline;
}

/* Tables */
.table-responsive {
    margin: 2rem 0;
    border-radius: 0.75rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

.table {
    margin: 0;
    min-width: 600px;
    width: 100%;
}

.table th {
    background: rgba(114, 137, 218, 0.1);
    border-bottom: 2px solid rgba(114, 137, 218, 0.2);
    font-weight: 600;
    padding: 1rem;
    white-space: nowrap;
}

.table td {
    padding: 1rem;
    vertical-align: middle;
    min-width: 120px;
}

@media (max-width: 768px) {
    .table-responsive {
        margin: 1rem -0.75rem;
        width: calc(100% + 1.5rem);
        border-radius: 0;
    }

    .table th, .table td {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
}

/* Environment Grid */
.environments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.env-card {
    background: var(--guide-card-bg);
    border: 1px solid rgba(114, 137, 218, 0.1);
    border-radius: 0.75rem;
    overflow: hidden;
    transition: all 0.3s ease;
    aspect-ratio: 6/5;
}

.env-card:hover {
    transform: translateY(-4px);
    border-color: var(--guide-primary);
    box-shadow: 0 4px 12px rgba(114, 137, 218, 0.2);
}

.env-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Modal */
.guide-image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: none;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.guide-image-modal.active {
    display: flex;
}

.guide-image-modal img {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 0.75rem;
    object-fit: contain;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

/* Responsive Design */
@media (max-width: 992px) {
    .guide-section {
        padding: 2rem;
    }

    .method-card.with-image {
        flex-direction: column;
    }

    .method-card.with-image > div,
    .method-card.with-image > img {
        flex: none;
        width: 100%;
    }

    .method-card img {
        max-width: 500px;
        margin: 0 auto;
    }
}

/* Mobile improvements */
@media (max-width: 768px) {
    .method-card ul {
        margin: 0.5rem 0;
    }

    .method-card ul li {
        display: flex;
        align-items: flex-start;
        margin-bottom: 0.5rem;
        line-height: 1.25;
        max-width: 95%;
    }

    .method-card ul li:last-child {
        margin-bottom: 0;
    }

    .method-card h3 {
        font-size: 1.1rem;
        margin: 1rem 0 0.75rem;
    }

    .method-card h3 i {
        font-size: 1rem;
    }

    .warning-note, .info-note {
        margin: 0.75rem -0.25rem;
        width: calc(100% + 0.5rem);
    }
}

@media (max-width: 768px) {
    /* Hero section adjustments */
    .hero {
        padding: 4rem 1rem 2rem;
    }

    .hero h1 {
        font-size: 2.25rem;
        margin-bottom: 1rem;
    }

    .hero .lead {
        font-size: 1.1rem;
        padding: 0 1rem;
    }

    /* Navigation adjustments */
    .navbar-toggler {
        margin-right: 0.5rem;
    }

    .navbar-brand {
        font-size: 1.1rem;
        padding-left: 0.5rem;
    }

    /* Fixed guide navigation */
    .guide-nav {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        background: var(--bs-secondary);
        z-index: 1025;
        padding: 0.5rem 0;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        border-bottom: 4px solid var(--bs-primary);
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }

    /* Card adjustments */
    .card.bg-secondary {
        margin-bottom: 1rem;
    }

    .card.bg-secondary .card-body {
        padding: 1.25rem;
    }

    .card.bg-secondary .card-title {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }

    .card.bg-secondary ul li {
        margin-bottom: 0.5rem;
        font-size: 0.95rem;
    }

    .card.bg-secondary a {
        padding: 0.25rem 0;
    }

    .guide-nav::-webkit-scrollbar {
        display: none;
    }

    .guide-nav ul {
        flex-wrap: nowrap;
        padding: 0 0.75rem;
        margin: 0;
        width: max-content;
        min-width: 100%;
        gap: 0.5rem;
    }

    .guide-nav a {
        white-space: nowrap;
        padding: 0.35rem 0.75rem;
        font-size: 0.9rem;
    }

    /* Adjust main content to account for fixed nav */
    main {
        padding-top: 45px;
    }

    ul {
        padding-left: 0.75rem;
    }

    li {
        margin-bottom: 0.35rem;
    }

    .specs-list li {
        font-size: 0.9rem;
        margin-bottom: 0.35rem;
    }

    .specs-list i {
        font-size: 0.9rem;
    }

    .guide-content {
        padding: 1rem;
    }

    .guide-section {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }

    .guide-section h2 {
        font-size: 2rem;
    }

    .guide-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
        border-radius: 1rem;
    }

    .guide-section h2 {
        font-size: 1.75rem;
        margin-bottom: 1.25rem;
    }

    .guide-section h3 {
        font-size: 1.35rem;
        margin: 1.5rem 0 1rem;
    }

    .method-card {
        padding: 1rem;
        margin-bottom: 1rem;
        border-radius: 0.75rem;
    }

    .method-card p {
        font-size: 0.95rem;
        padding: 0;
        margin-bottom: 1rem;
        line-height: 1.5;
    }

    .method-card h4 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
        gap: 0.5rem;
    }

    .method-card h4 i {
        font-size: 1rem;
    }

    .method-card.with-image {
        flex-direction: column;
        gap: 1rem;
    }

    .method-card.with-image img {
        max-width: 100%;
        margin: 0;
    }

    .key-points {
        padding: 1rem;
        margin: 1rem 0;
        border-radius: 0.75rem;
    }

    .key-points h5 {
        font-size: 1rem;
        margin-bottom: 0.75rem;
    }

    .key-points li {
        font-size: 0.95rem;
        gap: 0.5rem;
        margin-bottom: 0.75rem;
        line-height: 1.5;
        padding-right: 0.75rem;
        display: flex;
        align-items: flex-start;
    }

    .key-points li:before {
        font-size: 1rem;
        min-width: 1.25rem;
        display: inline-block;
        margin-top: 0.2rem;
    }

    .key-points .list-unstyled {
        padding-left: 0;
    }

    .info-note, .warning-note {
        padding: 1rem;
        font-size: 0.95rem;
        margin: 1rem 0;
        border-radius: 0.75rem;
        gap: 0.75rem;
    }

    .info-note h4, .warning-note h4 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
        gap: 0.5rem;
    }

    .info-note h4 i, .warning-note h4 i {
        font-size: 1rem;
    }

    .info-note p, .warning-note p {
        margin-bottom: 0.75rem;
        line-height: 1.5;
    }

    .info-note ul, .warning-note ul {
        margin: 0;
        padding-left: 1rem;
    }

    .info-note li, .warning-note li {
        margin-bottom: 0.5rem;
        line-height: 1.5;
    }

    .method-card ul li {
        text-wrap: balance;
        padding-right: 0.5rem;
    }

    .environments-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 0.75rem;
        margin: 1rem 0;
    }
    
    .env-card {
        max-width: none;
        border-radius: 0.5rem;
    }

    .table-responsive {
        margin: 1rem 0;
        border-radius: 0.5rem;
    }

    .table th, .table td {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
}

/* Tooltip Styles */
.tooltip {
    --bs-tooltip-bg: rgba(33, 37, 41, 0.95);
    --bs-tooltip-color: #fff;
}

.tooltip-inner {
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 8px 12px;
    font-size: 0.9rem;
    max-width: 300px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Quality Row Styles */
.quality-row:hover {
    background-color: rgba(255, 255, 255, 0.05) !important;
}

/* Badge Styles */
.badge.text-bg-dark {
    font-weight: normal;
    letter-spacing: 0.5px;
    background-color: transparent !important;
}

.badge.border {
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.quality-row:hover .badge {
    border-color: rgba(255, 255, 255, 0.3) !important;
}

/* Index Page Styles */
.card.bg-secondary {
    background: var(--guide-card-bg) !important;
    border: 1px solid rgba(114, 137, 218, 0.1);
    transition: all 0.3s ease;
}

.card.bg-secondary:hover {
    transform: translateY(-4px);
    border-color: var(--guide-primary);
    box-shadow: 0 4px 12px rgba(114, 137, 218, 0.2);
}

.card.bg-secondary .card-title {
    color: var(--guide-primary);
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.card.bg-secondary ul li {
    margin-bottom: 0.5rem;
}

.card.bg-secondary ul li:last-child {
    margin-bottom: 0;
}

.card.bg-secondary a {
    color: var(--guide-light);
    text-decoration: none;
    transition: all 0.2s ease;
    display: block;
    padding: 0.35rem 0;
}

.card.bg-secondary a:hover {
    color: var(--guide-primary);
    transform: translateX(4px);
}

/* Footer Styles */
.bg-secondary {
    background-color: var(--bs-dark) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}