

/* --- LAYOUT RESETS --- */
/* Allow full-width rendering for the homepage main content area */
.bd-main .bd-content,
.bd-article-container,
.bd-article {
    max-width: 100% !important;
    padding: 0 !important;
}

/* Bypass PyData theme's default container max-width constraints */
.bd-container .bd-page-width {
    max-width: 100% !important;
    padding: 0 !important;
}

/* Hide breadcrumbs and sidebars on homepage */
.bd-header-article {
    display: none !important;
}

@media (min-width: 992px) {
    .bd-sidebar-primary, .bd-sidebar-secondary {
        display: none !important;
    }
}

/* --- HERO COMPONENT --- */
/* Full-viewport background container */
.hero-container {
    width: 100%;
    position: relative;
    overflow: hidden;
    color: var(--pst-color-text);
}

.hero-container::before {
    content: '';
    position: absolute;
    top: 0;
    right: -10%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(230,0,0,0.15) 0%, rgba(230,0,0,0) 70%);
    z-index: 0;
    border-radius: 50%;
}

/* Primary grid layout for hero section */
.hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1440px;
    margin: 0 auto;
    padding: 6rem 2rem 2rem 2rem; /* Reduced bottom padding */
    align-items: flex-start;
}

/* Left Column: Typography and Calls to Action */
.hero-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 1rem;
}

.hero-equation {
    font-family: monospace;
    color: #a88b32;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.hero-title {
    font-size: 5.5rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.05;
    color: #1c1919;
    margin: 0;
    letter-spacing: -0.03em;
}

.hero-title .fury-red {
    color: #cc0000;
    display: block;
}

html[data-theme="dark"] .hero-title .fury-red {
    color: #ff4444;
}

.hero-description {
    font-size: 1.2rem;
    color: var(--pst-color-text-muted, #555);
    line-height: 1.6;
    max-width: 90%;
}

/* Call to Action Buttons */
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2rem;
    margin-top: 1rem;
}

.btn-primary {
    background-color: #e60000;
    color: white !important;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.2s;
}

.btn-primary:hover {
    background-color: #cc0000;
}

.btn-secondary {
    color: var(--pst-color-text) !important;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    text-decoration: underline;
}

/* Terminal/Installation Command Blocks */
.install-blocks {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.install-block {
    background: #1a1a1a;
    color: #f8f8f8;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    font-family: monospace;
    font-size: 0.95rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.install-block .install-prompt {
    color: #e60000;
    margin-right: 0.5rem;
}

/* Right Column: Visual Features and Code Demonstration */
.hero-visuals {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding-top: 14rem; /* push visuals down so horse card aligns with body text, not the title top */
}

/* Visual Feature Presentation Card */
.visual-card {
    background: white;
    border-radius: 12px;
    padding: 10px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    position: relative;
}

/* Decorative corner accents */
.visual-card::before, .visual-card::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 3px solid #e60000;
}

.visual-card::before {
    top: -10px;
    left: -10px;
    border-right: none;
    border-bottom: none;
    border-radius: 8px 0 0 0;
    padding: 0;
    background: transparent;
    -webkit-mask: none;
    pointer-events: auto;
}

.visual-card::after {
    bottom: -10px;
    right: -10px;
    border-left: none;
    border-top: none;
    border-radius: 0 0 8px 0;
}

.visual-card img,
.visual-card video {
    width: 100%;
    border-radius: 8px;
    display: block;
    background: black;
}

.visual-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 5px 0 5px;
    font-size: 0.75rem;
    color: #888;
    font-family: monospace;
}

.visual-footer__dot {
    color: #e60000;
    margin-right: 0.5rem;
}

/* Interactive Code Editor Demonstration Block */
.code-editor {
    background: #151111;
    border-radius: 12px;
    padding: 1.5rem;
    font-family: monospace;
    color: #ddd;
    font-size: 0.85rem;
    line-height: 1.5;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    position: relative;
}

/* Code editor header: filename on the left, copy button on the right */
.code-editor__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #888;
    margin-bottom: 1rem;
    font-size: 0.8rem;
}

.code-keyword  { color: #e64545; }
.code-module   { color: #d6b85c; }
.code-function { color: #d6b85c; }
.code-number   { color: #7db87d; }
.code-var      { color: #a8a8a8; }

/* --- RESPONSIVE DESIGN --- */
@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        padding: 3rem 2rem; /* Matches fury-features-grid padding */
    }

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

/* --- DARK MODE COMPONENT OVERRIDES --- */

/* Hero container is transparent — background comes from global html rule */
html[data-theme="dark"] .hero-container,
html[data-theme="light"] .hero-container {
    background: transparent;
}

/* Hide hero's own glow pseudo-element — global html rule provides the glow */
html[data-theme="dark"] .hero-container::before,
html[data-theme="light"] .hero-container::before {
    display: none;
}

/* Equation color stays warm amber */
html[data-theme="dark"] .hero-equation {
    color: #b89a3a;
}

/* Title white in dark mode */
html[data-theme="dark"] .hero-title {
    color: #ffffff;
}

/* Slightly brighter red for "furiously fast." */
html[data-theme="dark"] .hero-title .fury-red {
    color: #ff1a1a;
}

/* Description text slightly muted white */
html[data-theme="dark"] .hero-description {
    color: #c0b8b8;
}

/* "Browse the examples" link */
html[data-theme="dark"] .btn-secondary {
    color: #e0d8d8 !important;
}

/* Install blocks: dark with a subtle border */
html[data-theme="dark"] .install-block {
    background: #1c1212;
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: none;
}

/* Visual card in dark mode */
html[data-theme="dark"] .visual-card {
    background: #150f0f;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

html[data-theme="dark"] .visual-footer {
    color: #666;
}

/* Code editor stays dark, just a bit more contrast */
html[data-theme="dark"] .code-editor {
    background: #130e0e;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}



.install-block__copy-button,
.code-editor__copy-button {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    width: 6.5rem;
    gap: 0;
    color: #888;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-size: inherit;
    line-height: 1;
    transition: color 0.05s ease;
}

.install-block__copy-button:hover,
.code-editor__copy-button:hover {
    color: white;
}

.install-block__copy-label,
.code-editor__copy-label {
    max-width: 0;
    opacity: 0;
    overflow: hidden;
    white-space: nowrap;
    font-size: 0.85rem;
    font-weight: 600;
    transition: max-width 0.1s ease-out, opacity 0.1s ease-out, margin-right 0.1s ease-out;
}

.install-block__copy-label::after,
.code-editor__copy-label::after {
    content: "Copy";
}

.install-block__copy-button:hover .install-block__copy-label,
.code-editor__copy-button:hover .code-editor__copy-label {
    max-width: 4rem;
    opacity: 1;
    margin-right: 0.5rem;
}

.install-block__copy-button.is-copy-success,
.code-editor__copy-button.is-copy-success {
    color: #2ea043;
}

.install-block__copy-button.is-copy-success .install-block__copy-label,
.code-editor__copy-button.is-copy-success .code-editor__copy-label {
    max-width: 5rem;
    opacity: 1;
    margin-right: 0.5rem;
}

.install-block__copy-button.is-copy-success .install-block__copy-label::after,
.code-editor__copy-button.is-copy-success .code-editor__copy-label::after {
    content: "Copied!";
}

html[data-theme="dark"] .install-block__copy-button.is-copy-success,
html[data-theme="dark"] .code-editor__copy-button.is-copy-success {
    color: #3fb950;
}

/* --- FEATURES COMPONENT --- */
.fury-features {
    width: 100%;
    color: #1c1919;
    padding: 0 0 6rem 0; /* Removing top padding entirely to keep it flush, but using overflow to trap margins */
    margin: 0;
    overflow: hidden; /* Prevent any margin collapse from children */
}

.fury-features-grid {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 2rem;
}

.fury-features__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 3rem;
    margin-top: 2rem; /* Reduced top margin to bring it closer to the hero section */
}

.fury-features__title {
    font-size: 3.5rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.1;
    color: #1c1919;
    margin: 0;
    letter-spacing: -0.02em;
}

.fury-features__link {
    font-size: 1rem;
    font-weight: 700;
    color: #1c1919;
    text-decoration: none;
    transition: color 0.2s;
    margin-bottom: 0.5rem;
}

.fury-features__link:hover {
    color: #e60000;
    text-decoration: underline;
}

.fury-features__list {
    display: flex;
    flex-direction: column;
    gap: 6rem;
}

.fury-feature-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.fury-feature-card__visual {
    width: 100%;
}

.fury-feature-card__image-wrapper {
    background: #ffffff;
    border-radius: 8px;
    padding: 4px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.fury-feature-card__image-wrapper img,
.fury-feature-card__image-wrapper video {
    width: 100%;
    border-radius: 6px;
    display: block;
    background: #000;
}

.fury-feature-card__caption {
    font-family: monospace;
    font-size: 0.75rem;
    color: #666;
    padding: 10px 8px 4px 8px;
}

.fury-feature-card__content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0 2rem;
}

.fury-feature-card__title {
    font-size: 2rem;
    font-weight: 800;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    color: #1c1919;
    margin: 0;
}

.fury-feature-card__description {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.6;
    margin: 0;
}

/* Responsive Features Section */
@media (max-width: 992px) {
    .hero-visuals {
        padding-top: 2rem; /* Fix massive gap on mobile */
    }

    .fury-features__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .fury-feature-card {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .fury-feature-card--reverse .fury-feature-card__visual {
        order: -1;
    }

    .fury-feature-card__content {
        padding: 0;
    }
}

/* --- DARK MODE OVERRIDES FOR FEATURES AND HERO VISUALS --- */
/* Transparent so global html grid/glow shows through */
html[data-theme="dark"] .fury-features,
html[data-theme="light"] .fury-features {
    background: transparent;
}

html[data-theme="dark"] .visual-card {
    background: #150f0f;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

html[data-theme="dark"] .fury-features__title,
html[data-theme="dark"] .fury-feature-card__title {
    color: #ffffff;
}

html[data-theme="dark"] .fury-features__link {
    color: #e0d8d8;
}

html[data-theme="dark"] .fury-features__link:hover {
    color: #ff4444;
}

html[data-theme="dark"] .fury-feature-card__description {
    color: #c0b8b8;
}

html[data-theme="dark"] .fury-feature-card__image-wrapper {
    background: #150f0f;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255,255,255,0.05);
}

html[data-theme="dark"] .fury-feature-card__caption {
    color: #888;
}

/* --- SCIENCES COMPONENT --- */
.fury-sciences {
    width: 100%;
    color: #1c1919;
    padding: 6rem 0;
    margin: 0;
    overflow: hidden;
}

.fury-sciences-grid {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 2rem;
}

.fury-sciences__header {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    margin-bottom: 4rem;
}

.fury-sciences__title {
    font-size: 3.5rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.1;
    color: #1c1919;
    margin: 0;
    letter-spacing: -0.02em;
}

.fury-sciences__description {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.6;
    margin: 0;
}

.fury-sciences__content {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 4rem;
}

.fury-sciences__tabs {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.fury-sciences__tab {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.8rem 1rem;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    cursor: pointer;
    text-align: left;
    font-size: 0.95rem;
    font-weight: 600;
    color: #555;
    transition: all 0.2s;
}

.fury-sciences__tab:hover {
    background: rgba(0,0,0,0.03);
}

.fury-sciences__tab.active {
    background: #ffffff;
    border: 1px solid rgba(230,0,0,0.3);
    color: #1c1919;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.fury-sciences__tab-icon {
    width: 28px;
    height: 28px;
    object-fit: contain;

    /* Strip PyData Sphinx theme image defaults */
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;

    /* In light mode, black SVGs with opacity become grey */
    filter: opacity(0.6);
    transition: filter 0.2s;
}

.fury-sciences__tab.active .fury-sciences__tab-icon {
    /* FURY Red (#e60000) filter approximation from black */
    filter: invert(15%) sepia(87%) saturate(6000%) hue-rotate(355deg) brightness(96%) contrast(115%);
}

.fury-sciences__display {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.fury-sciences__image-wrapper {
    background: #ffffff;
    border-radius: 12px;
    padding: 6px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.fury-sciences__image-wrapper img,
.fury-sciences__image-wrapper video {
    width: 100%;
    border-radius: 8px;
    display: block;
    background: #000;
}

.fury-sciences__item-title {
    font-size: 1.5rem;
    font-weight: 800;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    color: #1c1919;
    margin: 0 0 0.5rem 0;
}

.fury-sciences__item-desc {
    font-size: 1rem;
    color: #555;
    line-height: 1.6;
    margin: 0;
}

@media (max-width: 992px) {
    .fury-sciences__header {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .fury-sciences__content {
        grid-template-columns: 1fr;
    }
    .fury-sciences__tabs {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.75rem;
        overflow-x: visible;
        padding-bottom: 1rem;
    }
    .fury-sciences__tab {
        white-space: nowrap;
        gap: 0.75rem;
        padding: 0.35rem 1rem 0.35rem 0.35rem;
    }
}

.code-editor__lines-count {
    display: none;
    color: #888;
    font-family: monospace;
    font-size: 0.85rem;
}

@media (max-width: 992px) {
    .hero-equation {
        white-space: normal;
        word-break: break-word;
        font-size: 0.8rem;
    }

    /* Mobile visual-card and feature-card gradient border */
    .visual-card::after {
        display: none;
    }

    .fury-feature-card__image-wrapper {
        position: relative;
        padding: 10px;
        border-radius: 12px;
    }

    .visual-card::before {
        content: '';
        position: absolute;
        inset: 0;
        top: 0;
        left: 0;
        width: auto;
        height: auto;
        border: none;
        border-radius: 12px;
        padding: 2px; /* Border thickness */
        box-sizing: border-box;
        z-index: 1;
        background: linear-gradient(135deg, #e60000 0%, rgba(0,0,0,0.08) 10%, rgba(0,0,0,0.08) 90%, #e60000 100%);
        -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
        pointer-events: none;
    }

    html[data-theme="dark"] .visual-card::before {
        background: linear-gradient(135deg, #ff4444 0%, rgba(255,255,255,0.08) 10%, rgba(255,255,255,0.08) 90%, #ff4444 100%);
    }

    .visual-footer {
        align-items: flex-start;
        padding: 12px 5px 0 5px;
        font-size: 0.8rem;
    }
    .visual-footer > span:first-child {
        display: flex;
        align-items: flex-start;
        gap: 0.5rem;
    }
    .visual-footer__dot {
        color: #ff4444;
        font-size: 1.2rem;
        line-height: 0.6;
        margin-right: 0;
    }

    /* Code editor mobile lines count */
    .code-editor__lines-count {
        display: inline;
    }
    .code-editor__copy-button {
        display: none !important;
    }
}

/* --- DARK MODE OVERRIDES FOR SCIENCES --- */
/* Transparent so global html grid/glow shows through */
html[data-theme="dark"] .fury-sciences,
html[data-theme="light"] .fury-sciences {
    background: transparent;
}

html[data-theme="dark"] .fury-sciences__title,
html[data-theme="dark"] .fury-sciences__item-title {
    color: #ffffff;
}

html[data-theme="dark"] .fury-sciences__description,
html[data-theme="dark"] .fury-sciences__item-desc {
    color: #c0b8b8;
}

html[data-theme="dark"] .fury-sciences__tab {
    color: #888;
}

html[data-theme="dark"] .fury-sciences__tab:hover {
    background: rgba(255,255,255,0.05);
}

html[data-theme="dark"] .fury-sciences__tab.active {
    background: #1a1a1a;
    border: 1px solid rgba(255,68,68,0.5);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
}

/* Dark mode icons: black logo on white padding/background */
html[data-theme="dark"] .fury-sciences__tab-icon {
    background: #ffffff !important;
    padding: 4px !important;
    border-radius: 6px !important;
    filter: none !important; /* Keep SVG black */
    opacity: 0.6; /* Dim inactive tabs */
}

/* Active tab icon: full opacity */
html[data-theme="dark"] .fury-sciences__tab.active .fury-sciences__tab-icon {
    opacity: 1;
}

@media (max-width: 992px) {
    html[data-theme="dark"] .fury-sciences__tab {
        color: #c0b8b8;
        background: #0d0808;
        border: 1px solid rgba(255,255,255,0.08);
    }

    html[data-theme="dark"] .fury-sciences__tab:hover {
        background: #150f0f;
        border-color: rgba(255,255,255,0.15);
    }

    html[data-theme="dark"] .fury-sciences__tab.active {
        background: #1a1a1a;
        border: 1px solid rgba(255,68,68,0.8);
        color: #ffffff;
        box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    }

    html[data-theme="dark"] .fury-sciences__tab-icon {
        padding: 6px !important;
        opacity: 1; /* Always fully opaque white background on mobile */
    }
}

html[data-theme="dark"] .fury-sciences__image-wrapper {
    background: #150f0f;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255,255,255,0.05);
}

/* --- EXAMPLES COMPONENT --- */
.fury-examples {
    width: 100%;
    color: #1c1919;
    padding: 6rem 0;
    margin: 0;
    overflow: hidden;
}

.fury-examples-grid {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 2rem;
}

.fury-examples__header {
    margin-bottom: 3rem;
}

.fury-examples__title {
    font-size: 3.5rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.1;
    color: #1c1919;
    margin: 0 0 1rem 0;
    letter-spacing: -0.02em;
}

.fury-examples__description {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.6;
    margin: 0;
}

.fury-examples__cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid rgba(0,0,0,0.1);
    border-left: 1px solid rgba(0,0,0,0.1);
}

.fury-example-card {
    padding: 1.5rem;
    border-right: 1px solid rgba(0,0,0,0.1);
    border-bottom: 1px solid rgba(0,0,0,0.1);
    text-decoration: none;
    transition: background 0.2s;
    display: flex;
    flex-direction: column;
}

.fury-example-card:hover {
    background: rgba(0,0,0,0.02);
    text-decoration: none;
}

.fury-example-card__script {
    font-family: monospace;
    font-size: 0.85rem;
    color: #e60000;
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fury-example-card__arrow {
    font-size: 1rem;
    color: #1c1919;
}

.fury-example-card:hover .fury-example-card__arrow {
    color: #e60000;
}

.fury-example-card__title {
    font-size: 1.1rem;
    font-weight: 800;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    color: #1c1919;
    margin: 0 0 0.5rem 0;
}

.fury-example-card__description {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.5;
    margin: 0;
}

@media (max-width: 992px) {
    .fury-examples__cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .fury-examples__cards {
        grid-template-columns: 1fr;
    }
}

/* DARK MODE EXAMPLES */
/* Transparent so global html grid/glow shows through */
html[data-theme="dark"] .fury-examples,
html[data-theme="light"] .fury-examples {
    background: transparent;
}

html[data-theme="dark"] .fury-examples__title {
    color: #ffffff;
}

html[data-theme="dark"] .fury-examples__description,
html[data-theme="dark"] .fury-example-card__description {
    color: #c0b8b8;
}

html[data-theme="dark"] .fury-examples__cards {
    border-top: 1px solid rgba(255,255,255,0.08);
    border-left: 1px solid rgba(255,255,255,0.08);
}

html[data-theme="dark"] .fury-example-card {
    border-right: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

html[data-theme="dark"] .fury-example-card:hover {
    background: rgba(255,255,255,0.03);
}

html[data-theme="dark"] .fury-example-card__script {
    color: #ff4444;
}

html[data-theme="dark"] .fury-example-card__arrow {
    color: #e0d8d8;
}

html[data-theme="dark"] .fury-example-card:hover .fury-example-card__arrow {
    color: #ff4444;
}

html[data-theme="dark"] .fury-example-card__title {
    color: #ffffff;
}

/* --- CTA COMPONENT --- */
.fury-cta {
    width: 100%;
    background: #af0000; /* deep red */
    background-image: linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 4.5rem 100%;
    color: #ffffff;
    padding: 6rem 0;
    margin: 0;
    overflow: hidden;
}

.fury-cta-grid {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.fury-cta__content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.fury-cta__title {
    font-size: 4rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.05;
    color: #ffffff;
    margin: 0;
    letter-spacing: -0.02em;
}

.fury-cta__description {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.9);
    line-height: 1.6;
    margin: 0;
}

.fury-cta__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2rem;
    margin-top: 1rem;
}

.btn-cta-primary {
    background-color: #ffffff;
    color: #cc0000 !important;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.2s, transform 0.1s;
}

.btn-cta-primary:hover {
    background-color: #f0f0f0;
    text-decoration: none;
}

.btn-cta-secondary {
    color: #ffffff !important;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.2s;
}

.btn-cta-secondary:hover {
    text-decoration: underline;
}

.fury-cta__terminals {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    justify-content: center;
}

.cta-install-block {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: none;
    color: #f8f8f8;
}

.cta-install-block .install-prompt {
    color: #ffcc00;
}

@media (max-width: 992px) {
    .fury-cta-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

/* CTA Terminal Tabs */
.fury-cta__tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 0.5rem;
}

.fury-cta__tab {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.35rem 0.85rem;
    border-radius: 4px;
    transition: all 0.2s;
    font-family: monospace;
}

.fury-cta__tab:hover {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.05);
}

.fury-cta__tab.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
}

.fury-cta__terminal {
    display: none;
}

.fury-cta__terminal.active {
    display: block;
}

/* --- COMMUNITY COMPONENT --- */
.fury-community {
    width: 100%;
    color: #1c1919;
    padding: 6rem 0;
    margin: 0;
    overflow: hidden;
}

.fury-community-grid {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 2rem;
}

.fury-community__title {
    font-size: 3.5rem;
    font-family: "Barlow", "Arial Black", "Helvetica Neue", Arial, sans-serif;
    font-weight: 900;
    line-height: 1.1;
    color: #1c1919;
    margin: 0 0 3rem 0;
    letter-spacing: -0.02em;
}

.fury-community__columns {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.fury-community__col {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.fury-community__col-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.fury-community__col-title i {
    color: #e60000;
}

.fury-community__col p {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    margin: 0;
}

.fury-community__link {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1c1919;
    text-decoration: none;
    margin-top: auto;
    display: inline-block;
}

.fury-community__link:hover {
    color: #e60000;
    text-decoration: underline;
}

.fury-community__citation {
    background: #f0ebe8;
    border-radius: 8px;
    padding: 1.25rem;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #555;
    margin-top: 0.5rem;
}

.fury-community__support-section {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.fury-community__support-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
}

.fury-community__support-section p {
    font-size: 1rem;
    color: #555;
    margin: 0 0 1rem 0;
}

.fury-community__logos {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.fury-community__logo-card {
    background: #ffffff;
    border-radius: 8px;
    padding: 16px 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 160px;
    height: 80px;
    transition: transform 0.2s, box-shadow 0.2s;
    overflow: hidden;
}

.fury-community__logo-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.18);
}

.fury-community__logo-card img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    transform: scale(1.15);
}

/* Specific logo scaling to counteract baked-in transparent padding in source files */
.fury-community__logo-card--luddy img {
    transform: scale(2.2);
}

.fury-community__logo-card--houdini img,
.fury-community__logo-card--modo img,
.fury-community__logo-card--sketchup img {
    transform: scale(1.5);
}

/* Dark mode overrides */
/* Transparent so global html grid/glow shows through */
html[data-theme="dark"] .fury-community,
html[data-theme="light"] .fury-community {
    background: transparent;
}

html[data-theme="dark"] .fury-community__title,
html[data-theme="dark"] .fury-community__col-title,
html[data-theme="dark"] .fury-community__support-title {
    color: #ffffff;
}

html[data-theme="dark"] .fury-community__col p,
html[data-theme="dark"] .fury-community__support-section p {
    color: #c0b8b8;
}

html[data-theme="dark"] .fury-community__link {
    color: #e0d8d8;
}

html[data-theme="dark"] .fury-community__link:hover {
    color: #ff4444;
}

html[data-theme="dark"] .fury-community__citation {
    background: #150f0f;
    border: 1px solid rgba(255,255,255,0.05);
    color: #c0b8b8;
}

html[data-theme="dark"] .fury-community__logo-card {
    background: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.35);
}

@media (max-width: 992px) {
    .fury-community__columns {
        grid-template-columns: 1fr;
    }
}

/* --- MOBILE-FIRST REFINEMENTS (PHONES) --- */
/* The 992px breakpoints above only reflow grids to a single column; the large
   display type and 2rem section padding tuned for tablets still crowd/overflow
   on phone-width viewports, so tighten both further below 576px. */
@media (max-width: 576px) {
    .hero-grid,
    .fury-features-grid,
    .fury-sciences-grid,
    .fury-examples-grid,
    .fury-cta-grid,
    .fury-community-grid {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .fury-features__title,
    .fury-sciences__title,
    .fury-examples__title,
    .fury-cta__title,
    .fury-community__title {
        font-size: 2.25rem;
    }

    .hero-description,
    .fury-sciences__description,
    .fury-examples__description,
    .fury-cta__description {
        font-size: 1rem;
    }

    .fury-community__logo-card {
        width: 140px;
        height: 68px;
    }
}
