/* Estilos gerais */
:root {
    --primary-color: #4361ee;
    --secondary-color: #3f37c9;
    --accent-color: #4cc9f0;
    --text-color: #333;
    --light-text: #666;
    --background-color: #f8f9fa;
    --card-background: #fff;
    --border-color: #e0e0e0;
    --success-color: #4caf50;
    --highlight-color: #f72585;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 0px 0px 40px 0px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.tagline {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Main content */
main {
    padding: 40px 0;
}

.content-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin: 30px 0;
}

/* Cards */
.card {
    background-color: var(--card-background);
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    width: 100%;
}

.card-header {
    background-color: var(--primary-color);
    color: white;
    padding: 15px 20px;
}

.card-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.card-body {
    padding: 25px;
}

/* Form */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

input[type="number"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

input[type="number"]:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(67, 97, 238, 0.2);
}

.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: background-color 0.3s, transform 0.2s;
    width: 100%;
}

.btn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

/* Results */
.result-item {
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
}

.result-item:last-child {
    border-bottom: none;
}

.result-item h3 {
    font-size: 1rem;
    color: var(--light-text);
    margin-bottom: 5px;
}

.result-item p {
    font-size: 1.5rem;
    font-weight: 600;
}

.highlight {
    color: var(--highlight-color);
    font-size: 2rem;
}

.hidden {
    display: none;
}

.chart-container {
    margin-top: 30px;
    height: 300px;
}

/* Info section */
.info-section {
    margin-top: 40px;
}

.info-section h3 {
    margin: 20px 0 10px;
    color: var(--primary-color);
}

.formula-box {
    background-color: #f5f5f5;
    border-left: 4px solid var(--accent-color);
    padding: 15px;
    margin: 15px 0;
    border-radius: 4px;
    text-align: center;
    font-size: 1.2rem;
}

.info-section ul {
    margin-left: 20px;
    margin-bottom: 20px;
}

.info-section li {
    margin-bottom: 5px;
}

/* Ad containers */
.ad-container {
    margin: 20px 0;
    background-color: #f0f0f0;
    border-radius: 8px;
    overflow: hidden;
}

.ad-horizontal {
    width: 100%;
    height: 120px;
}

.ad-vertical {
    display: none;
}

.ad-placeholder {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    border: 2px dashed #ccc;
    color: #999;
    text-align: center;
    padding: 20px;
}

/* Footer */
footer {
    background-color: #333;
    color: white;
    padding: 30px 0;
    text-align: center;
}

footer a {
    color: white;
    padding: 30px 0;
    text-align: center;
}

.disclaimer {
    font-size: 0.9rem;
    margin-top: 10px;
    opacity: 0.7;
}

/* Responsive */
@media (min-width: 768px) {
    .calculator-section {
        display: flex;
        gap: 20px;
        width: 100%;
    }
    
    .calculator-section .card {
        flex: 1;
    }
    
    .ad-vertical {
        display: block;
        width: 300px;
        height: 600px;
    }
}

@media (min-width: 992px) {
    .content-wrapper {
        flex-wrap: nowrap;
    }
    
    .calculator-section {
        width: 50%;
    }
    
    .results-section {
        width: 50%;
    }
}

@media (max-width: 767px) {
    header h1 {
        font-size: 2rem;
    }
    
    .result-item p {
        font-size: 1.2rem;
    }
    
    .highlight {
        font-size: 1.5rem;
    }
    
    .content-wrapper {
        flex-direction: column;
        padding: 0;
        width: 100%;
        margin: 20px 0;
    }
    
    .calculator-section, 
    .results-section {
        width: 100%;
        display: block;
        padding: 0;
    }
    
    .calculator-section .card,
    .results-section .card {
        width: 100%;
        margin-bottom: 20px;
        border-radius: 0;
    }
    
    .container {
        padding: 20px 10px;
    }
    
    main {
        padding: 10px 0;
    }
    
    .card-body {
        padding: 15px;
    }
    
    .ad-horizontal {
        margin: 10px 0;
    }
}


/* Topbar geral */
.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px;
}

/* Logo */
.logo {
    font-weight: bold;
    font-size: 18px;
}
.logo a {
    color: white;
    text-decoration: none;
}

/* Container do menu direito */
.menu-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Dropdown */
.language-selector {
    position: relative;
}

.dropdown-btn {
    background-color: var(--background-color);
    border: 1px solid #ddd;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    transition: background-color 0.2s;
}

.dropdown-btn:hover {
    background-color: #f5f5f5;
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    background-color: #fff;
    min-width: 160px;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 10;
}

.dropdown-content a {
    padding: 10px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    transition: background-color 0.2s;
}

.dropdown-content a:hover {
    background-color: #f5f5f5;
}

/* Mostrar dropdown ao hover no desktop */
.language-selector:hover .dropdown-content {
    display: block;
}

/* Responsivo */
@media (max-width: 600px) {
    .topbar {
        flex-direction: row;
        align-items: stretch;
        gap: 8px;
    }
    .menu-right {
        justify-content: flex-end;
    }
}
