/* EnergyBS - Premium Dark Theme | UX Audit 2025 */

:root {
    /* Color Palette */
    --bg-dark: #0f0f0f;
    /* Softer, premium black */
    --bg-card: #1a1a1a;
    /* Card background */
    --bg-card-hover: #222222;
    --text-white: #ffffff;
    --text-gray: #a3a3a3;
    /* Accessible gray */
    --accent-yellow: #FFD700;
    --accent-blue: #00f0ff;

    /* Effects */
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --glass-bg: rgba(15, 15, 15, 0.8);
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 15px rgba(255, 215, 0, 0.2);

    /* Layout */
    --container-width: 1200px;
    --radius-md: 12px;
    --radius-sm: 6px;
    --transition: all 0.3s ease;
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-white);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6,
.brand-font {
    font-family: 'Space Grotesk', sans-serif;
    color: var(--text-white);
    margin-bottom: 1rem;
    line-height: 1.2;
}

p {
    color: var(--text-gray);
    margin-bottom: 1.5rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}


.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.text-highlight {
    color: var(--accent-yellow);
}

.text-blue {
    color: var(--accent-blue);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Space Grotesk', sans-serif;
    letter-spacing: 1px;
    border: none;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-yellow), #e6c200);
    color: #000;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--accent-yellow);
    color: var(--accent-yellow);
}

.btn-outline:hover {
    background: rgba(255, 215, 0, 0.1);
    transform: translateY(-2px);
}

.price-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid var(--text-gray);
    color: var(--text-white);
    text-align: center;
    border-radius: var(--radius-sm);
    font-weight: 600;
    margin-top: auto;
    transition: var(--transition);
}

.price-btn:hover {
    border-color: var(--accent-yellow);
    color: var(--accent-yellow);
    background: rgba(255, 215, 0, 0.05);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border-bottom: var(--glass-border);
    z-index: 1000;
}

.nav-content {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.logo span {
    color: var(--accent-yellow);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.active-link {
    color: var(--accent-yellow) !important;
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.active-link::before {
    content: '';
    display: block;
    width: 20px;
    height: 20px;
    background-image: url('/favicon.svg');
    background-size: contain;
    background-repeat: no-repeat;
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from {
        transform: scale(0);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.nav-links a {
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-links a:not(.btn):hover {
    color: var(--accent-yellow);
}

/* Sections */
section {
    padding: 100px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 60px;
}

.section-title span {
    color: var(--accent-yellow);
}

/* Hero */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: radial-gradient(circle at center, #1a1a1a 0%, #0f0f0f 70%);
    padding-top: 80px;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 5rem);
    margin-bottom: 20px;
    line-height: 1.1;
}

.hero p {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto 40px;
    color: var(--text-gray);
}

/* Bento Grid */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, minmax(300px, auto));
    gap: 20px;
}

.bento-card {
    background: var(--bg-card);
    border: var(--glass-border);
    border-radius: var(--radius-md);
    padding: 30px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.bento-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-blue);
    box-shadow: var(--shadow-card);
}

.bento-card-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.4;
    transition: var(--transition);
}

.bento-card:hover .bento-card-bg {
    opacity: 0.6;
    transform: scale(1.05);
}

.bento-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95), transparent);
    z-index: 1;
}

.bento-card-content {
    position: relative;
    z-index: 2;
}

.span-2 {
    grid-column: span 2;
}

.span-4 {
    grid-column: span 4;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.feature-card {
    background: var(--bg-card);
    padding: 40px;
    border-radius: var(--radius-md);
    border: var(--glass-border);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    border-color: var(--accent-yellow);
}

.feature-icon {
    font-size: 2.5rem;
    color: var(--accent-yellow);
    margin-bottom: 20px;
}

/* Interactive Calculator */
.calculator-card {
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 40px;
    max-width: 500px;
    margin: 0 auto;
    backdrop-filter: blur(20px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    position: relative;
    overflow: hidden;
}

.calculator-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.form-group {
    margin-bottom: 24px;
    text-align: left;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: var(--text-gray);
    font-size: 0.95rem;
    letter-spacing: 0.5px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    color: var(--text-gray);
    font-size: 1.1rem;
    pointer-events: none;
    transition: var(--transition);
}

.form-control {
    width: 100%;
    padding: 16px 16px 16px 48px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-white);
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-yellow);
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 4px rgba(255, 215, 0, 0.1);
}

.form-control:focus+.input-icon,
.input-wrapper:focus-within .input-icon {
    color: var(--accent-yellow);
}

select.form-control {
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23a3a3a3'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 16px;
}

#calc-btn {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
    border-radius: 12px;
    background: var(--accent-yellow);
    color: #000;
    border: none;
    font-weight: 700;
    letter-spacing: 1px;
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

#calc-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
    background: #FFED4A;
    /* Lighter yellow */
}

/* Success/Result Styling */
#calc-result {
    margin-top: 30px;
    padding: 24px;
    border-radius: 16px;
    text-align: center;
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.result-success {
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
}

.result-neutral {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Gear Grid */
.gear-scroller {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    padding-bottom: 30px;
}

.gear-card {
    background: var(--bg-card);
    border: var(--glass-border);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}

.gear-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-card);
    border-color: var(--accent-blue);
}

.gear-img {
    width: 100%;
    height: 180px;
    background: #111;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.gear-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Installers Page */
.search-container {
    background: var(--bg-card);
    padding: 30px;
    border-radius: var(--radius-md);
    border: var(--glass-border);
    margin-bottom: 40px;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 200px;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #333;
    border-radius: var(--radius-sm);
    color: var(--text-white);
}

.installers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

/* View Toggle */
.btn-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-gray);
    padding: 10px 20px;
    margin: 0 5px;
    border-radius: 20px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.btn-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-toggle.active {
    background: var(--accent-yellow);
    color: #000;
    border-color: var(--accent-yellow);
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
}

/* Installer Cards Redesign */
.installer-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.02) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 30px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    height: 100%;
}

.installer-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 215, 0, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 215, 0, 0.1);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.03) 100%);
}

.installer-card h3 {
    margin-bottom: 5px;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-white);
}

.installer-card .location {
    font-size: 0.95rem;
    color: var(--text-gray);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.installer-card .location i {
    color: var(--accent-yellow);
}

.installer-card .services {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 25px;
}

.service-tag {
    font-size: 0.75rem;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    color: #ccc;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 500;
    transition: var(--transition);
}

.installer-card:hover .service-tag {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.installer-card .actions {
    display: grid;
    gap: 12px;
    margin-top: auto;
}

.btn-website {
    text-align: center;
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-white);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-website:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--text-white);
}

.btn-quote {
    text-align: center;
    padding: 14px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.95rem;
    color: #000;
    background: var(--accent-yellow);
    /* Bright CTA */
    border: none;
    transition: var(--transition);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.2);
}

.btn-quote:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.4);
    background: #FFED4A;
}

/* Articles */
article {
    max-width: 800px;
    margin: 0 auto;
    padding: 120px 20px 60px;
}

article h1 {
    font-size: 3rem;
    margin-bottom: 20px;
}

article h2 {
    font-size: 2rem;
    margin-top: 50px;
    color: var(--accent-yellow);
}

article h3 {
    font-size: 1.5rem;
    margin-top: 30px;
}

article p,
article li {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #ccc;
}

article ul,
article ol {
    margin-left: 20px;
    margin-bottom: 30px;
}

.article-meta {
    font-size: 0.9rem;
    color: var(--text-gray);
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 40px;
}

/* Footer */
footer {
    background: #000;
    padding: 80px 0 40px;
    text-align: center;
    border-top: 1px solid #222;
}

.footer-logo {
    font-size: 1.5rem;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    display: block;
    margin-bottom: 20px;
}

.disclaimer {
    font-size: 0.8rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto 30px;
}

.socials {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.socials a {
    color: var(--text-gray);
    font-size: 1.2rem;
}

.socials a:hover {
    color: var(--text-white);
}

/* Mobile */
@media (max-width: 900px) {
    .bento-grid {
        grid-template-columns: 1fr;
    }

    .span-2,
    .span-4 {
        grid-column: auto;
    }

    .hero h1 {
        font-size: 3rem;
    }

    .nav-links {
        display: none;
    }

    /* TODO: Mobile Menu */
    .search-container {
        flex-direction: column;
    }
}