@import url('https://fonts.googleapis.com/css2?family=Fira+Mono:wght@400;700&family=Montserrat:wght@700&display=swap');

html, body {
    height: 100%;
}

body {
    font-family: 'Fira Mono', monospace;
    background: linear-gradient(135deg, #181c1f 0%, #232b2f 100%);
    color: #eafbe7;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    background: #181f23;
    padding: 2em 1em 1em 1em;
    text-align: center;
    border-bottom: 2px solid #5fff9c;
    box-shadow: 0 2px 16px rgba(0,0,0,0.18);
    position: relative;
}

@keyframes headerFadeIn {
    from { opacity: 0; transform: translateY(-30px);}
    to { opacity: 1; transform: none;}
}

header h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.8em;
    letter-spacing: 2px;
    color: #5fff9c;
    margin: 0 0 0.2em 0;
    text-shadow: 0 2px 12px #10181a;
    animation: titlePop 1.2s cubic-bezier(.68,-0.55,.27,1.55);
}

@keyframes titlePop {
    0% { transform: scale(0.7); opacity: 0; }
    70% { transform: scale(1.1); opacity: 1; }
    100% { transform: scale(1); }
}

header p {
    color: #b2ffe2;
    font-size: 1.2em;
    margin: 0;
    animation: fadeIn 1.5s;
}

/* Terminal styling */
.terminal-mockup {
    display: block !important; /* Make terminal visible */
    max-width: 600px;
    margin: 1.5em auto 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    animation: fadeIn 1.8s;
}

.terminal-bar {
    background: #232d23;
    height: 2.1em;
    display: flex;
    align-items: center;
    padding: 0 1em;
    border-bottom: 1px solid #222;
    position: relative;
}

.terminal-bar .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 7px;
    display: inline-block;
}
.terminal-bar .red { background: #ff5f56; }
.terminal-bar .yellow { background: #ffbd2e; }
.terminal-bar .green { background: #27c93f; }
.terminal-title {
    color: #baffc9;
    font-size: 1em;
    margin-left: 1em;
    font-family: 'Fira Mono', monospace;
    opacity: 0.7;
    letter-spacing: 1px;
}

.terminal-body {
    background: #181f18;
    min-height: 2.7em;
    padding: 1.1em 1.2em 1.1em 1.2em;
    font-family: 'Fira Mono', monospace;
    font-size: 1.13em;
    color: #3ee96b;
    display: flex;
    align-items: center;
    white-space: pre;
    letter-spacing: 0.5px;
    position: relative;
    word-break: break-all;
    overflow-x: auto;
    /* Garante que o texto não vaze em telas pequenas */
    max-width: 100%;
}

.terminal-cursor {
    display: inline-block;
    width: 0.7em;
    height: 1.1em;
    background: none;
    border-left: 2px solid #3ee96b;
    margin-left: 2px;
    animation: blink-cursor 1s steps(1) infinite;
    vertical-align: middle;
}

@keyframes blink-cursor {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}

/* Layout principal responsivo */
.container {
    display: flex;
    max-width: 1200px;
    margin: 2em auto 4em auto;
    gap: 2em;
    padding: 0 1em;
    width: 100%;
    box-sizing: border-box;
    flex: 1 0 auto;
}

nav {
    background: #20282d;
    border-radius: 14px;
    padding: 2em 1.5em;
    min-width: 220px;
    max-width: 320px;
    box-shadow: 0 2px 18px rgba(0,0,0,0.13);
    height: fit-content;
    position: sticky;
    top: 2em;
    animation: fadeInLeft 1.2s;
    box-sizing: border-box;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav li {
    cursor: pointer;
    color: #5fff9c;
    font-size: 1.1em;
    margin-bottom: 1.2em;
    padding: 0.5em 0.8em;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s, transform 0.1s, box-shadow 0.2s;
    font-weight: bold;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    word-break: break-word;
}

nav li::before {
    content: "";
    position: absolute;
    left: -100%;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(95,255,156,0.13);
    transition: left 0.3s;
    z-index: 0;
}

nav li:hover::before, nav li.active::before {
    left: 0;
}

nav li:hover, nav li.active {
    background: #5fff9c;
    color: #181f23;
    border: 1.5px solid #5fff9c;
    box-shadow: 0 4px 18px rgba(95,255,156,0.13);
    z-index: 1;
}

main {
    flex: 1;
    background: #181f23;
    padding: 2.5em 2em;
    border-radius: 18px;
    min-height: 350px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.17);
    animation: fadeIn 0.7s;
    word-break: break-word;
    transition: box-shadow 0.3s;
    width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
}

/* Add animation for post content */
main.animating {
    animation: contentFadeIn 0.6s;
}

@keyframes contentFadeIn {
    from { opacity: 0.3; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Code block styling */
pre {
    background: #1a2328;
    border-radius: 5px;
    padding: 1em;
    border-left: 4px solid #5fff9c;
    overflow-x: auto;
    margin: 1.5em 0;
}

code {
    font-family: 'Fira Mono', monospace;
    color: #d1ffca;
}

/* Styled links */
a {
    color: #5fff9c;
    text-decoration: none;
    border-bottom: 1px dashed #5fff9c;
    transition: color 0.2s, border-bottom 0.2s;
}

a:hover {
    color: #b2ffe2;
    border-bottom: 1px solid #b2ffe2;
}

/* Footer responsivo */
footer {
    text-align: center;
    padding: 1.2em 2em;
    background: linear-gradient(90deg, #20282d 60%, #5fff9c22 100%);
    color: #b2ffe2;
    border-top: 1.5px solid #5fff9c;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.13);
    animation: fadeIn 1.2s;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1em;
    min-height: 3.2em;
    transition: padding 0.2s, font-size 0.2s;
    position: static;
    width: 100%;
    margin-top: auto;
}

footer .footer-icon {
    font-size: 1.2em;
    vertical-align: middle;
    margin-right: 0.3em;
    color: #5fff9c;
    animation: footerPulse 2.5s infinite;
}

@keyframes footerPulse {
    0%, 100% { filter: brightness(1);}
    50% { filter: brightness(1.7);}
}

/* Responsividade para tablets */
@media (max-width: 900px) {
    .container {
        flex-direction: column;
        gap: 0.7em;
        max-width: 98vw;
        padding: 0 0.5em;
    }
    nav {
        min-width: unset;
        max-width: 100vw;
        width: 100%;
        margin-bottom: 1em;
        position: static;
        padding: 1em 0.5em;
        border-radius: 10px;
    }
    main {
        border-radius: 10px;
    }
    
    .terminal-mockup {
        max-width: 90%;
    }
    
    .nav-section {
        margin-bottom: 1em;
    }
}

/* Responsividade para celulares */
@media (max-width: 600px) {
    header h1 {
        font-size: 1.1em;
    }
    header p {
        font-size: 0.93em;
    }
    .container {
        padding: 0 0.1em;
        margin: 0.5em auto 2.5em auto;
        max-width: 100vw;
        gap: 0.3em;
    }
    nav {
        border-radius: 6px;
        padding: 0.5em 0.1em;
        max-width: 100vw;
        min-width: 0;
        margin-bottom: 0.5em;
    }
    nav li {
        font-size: 0.93em;
        margin-bottom: 0.5em;
        padding: 0.25em 0.2em;
    }
    main {
        border-radius: 6px;
        padding: 0.4em 0.05em;
        font-size: 0.93em;
        min-height: 180px;
        box-shadow: 0 1px 8px rgba(0,0,0,0.10);
    }
    footer {
        font-size: 0.9em;
        padding: 0.4em 0.05em;
        min-height: 1.7em;
    }
    
    .terminal-mockup {
        max-width: 95%;
        margin: 1em auto 0;
    }
    
    .terminal-body {
        font-size: 0.9em;
        padding: 0.8em;
    }
    
    .nav-title {
        font-size: 1em;
        margin: 0 0 0.7em 0.3em;
    }
    
    .nav-section {
        margin-bottom: 0.7em;
    }
}

/* Pequenos ajustes para telas muito pequenas */
@media (max-width: 400px) {
    nav {
        padding: 0.1em 0.01em;
        border-radius: 4px;
    }
    nav li {
        font-size: 0.85em;
        padding: 0.1em 0.05em;
    }
    main {
        font-size: 0.85em;
        padding: 0.1em 0.01em;
        border-radius: 4px;
    }
    footer {
        font-size: 0.8em;
        padding: 0.1em 0.01em;
        border-radius: 0;
    }
}

/* Aumenta o contraste do texto para acessibilidade */
body, main, nav, header, footer {
    color-scheme: dark;
}

/* Garante que o terminal não vaze horizontalmente */
.terminal-mockup, .terminal-body {
    box-sizing: border-box;
    overflow-x: auto;
}

/* Navigation sections styling */
.nav-section {
    margin-bottom: 2em;
}

.nav-title {
    color: #b2ffe2;
    font-size: 1.2em;
    margin: 0 0 1em 0.5em;
    letter-spacing: 1px;
    font-family: 'Montserrat', sans-serif;
    position: relative;
}

.nav-title::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 30px;
    height: 2px;
    background: #5fff9c;
}

/* Different styling for news items - now matches the green theme */
#news-list li {
    border-left: 3px solid #5fff9c; /* Changed from orange to green */
}

#news-list li:hover, #news-list li.active {
    background: #5fff9c; /* Changed from orange to green */
    color: #181f23;
    border: 1.5px solid #5fff9c; /* Changed from orange to green */
    box-shadow: 0 4px 18px rgba(95,255,156,0.13); /* Changed from orange to green */
}

#news-list li::before {
    background: rgba(95,255,156,0.13); /* Changed from orange to green */
}

/* News content styling */
.news-date {
    display: inline-block;
    background: #232b2f;
    padding: 0.3em 0.7em;
    border-radius: 4px;
    font-size: 0.85em;
    margin-bottom: 1em;
    color: #5fff9c; /* Changed from orange to green */
}

/* Advertisement styling */
.ad-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1em 2em 1em;
    box-sizing: border-box;
}

.ad-wrapper {
    width: 100%;
    height: 90px;
    background-color: transparent;
    border-radius: 8px;
    overflow: hidden;
    margin: 0 auto;
    position: relative;
}

/* Make sure the iframe takes full width */
.ad-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Responsive adjustments */
@media (max-width: 900px) {
    .ad-container {
        padding: 0 0.5em 1.5em 0.5em;
    }
    
    .ad-wrapper {
        height: 80px;
    }
}

@media (max-width: 600px) {
    .ad-container {
        padding: 0 0.1em 1em 0.1em;
    }
    
    .ad-wrapper {
        height: 60px;
    }
}
