body {
    font-family: Open Sans Light, sans-serif;
    font-size: 18pt;
    font-weight: 300;
    line-height: 1.6;
}

/* Responsive font sizes */
@media screen and (max-width: 768px) {
    body {
        font-size: 16pt;
    }
}

@media screen and (max-width: 480px) {
    body {
        font-size: 14pt;
    }
}

a, a.visited {
	color: #333333;
	text-decoration: underline dashed;
    transition: color 0.3s ease;
}

a:hover {
    color: #555;
}

h1, h2, h3, h4 {
    font-weight: 300;
    margin-bottom: 30px;
}

/* Better responsive heading sizes */
h4 {
    font-size: 1.3em;
    margin-bottom: 10px;
}

@media screen and (max-width: 768px) {
    h4 {
        font-size: 1.2em;
    }
}

p {
    text-align: justify;
}

/* Better mobile text alignment */
@media screen and (max-width: 768px) {
    p {
        text-align: left;
    }
}

.uv-banner {
    margin: 100px 0 100px 0;
    text-align: center;
}

.uv-banner h1 {
    font-size: 3em;
}

.uv-banner h2 {
    font-size: 1.5em;
}

@media screen and (max-width: 600px) {
    .uv-banner h1 {
        font-size: 2em;
    }

    .uv-banner h2 {
        font-size: 1.1em;
    }
}

.uv-link {
	margin-top: 40px;	
}

.uv-link a, .uv-link a.visited {
	font-size: 1.2em;
	font-weight: 300;
}

/* Language Tabs */
.language-tabs {
    border-bottom: 3px solid #e0e0e0;
    margin-bottom: 30px;
    margin-top: 20px;
}

.language-tabs .nav-link {
    font-size: 1.2em;
    font-weight: 600;
    color: #666;
    border: none;
    border-bottom: 3px solid transparent;
    background: none;
    padding: 15px 30px;
    margin-bottom: -3px;
    transition: all 0.3s ease;
    outline: none; /* Remove default focus outline */
}

.language-tabs .nav-link:hover {
    color: #333;
    border-bottom-color: #ccc;
    background: rgba(0,0,0,0.02);
}

.language-tabs .nav-link.active {
    color: #333;
    border-bottom-color: #333;
    background: none;
}

.language-tabs .language-flag {
    font-size: 1.3em;
    margin-right: 8px;
}

/* Tab Content */
.tab-content {
    min-height: 400px;
}

.tab-pane {
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.tab-pane.show.active {
    opacity: 1;
    transform: translateY(0);
}

/* Language Cards (adapted for tabs) */
.language-card {
    background: #fafafa;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 40px;
    border: 2px solid #e0e0e0;
}

.language-header {
    margin-bottom: 25px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 15px;
}

.language-title {
    margin: 0;
    font-size: 2.2em;
    font-weight: 300;
}

.language-title a {
    text-decoration: none;
    color: #333;
    transition: color 0.3s ease;
}

.language-title a:hover {
    color: #666;
    text-decoration: underline dashed;
}

.language-content {
    line-height: 1.6;
}

.content-section {
    margin-bottom: 25px;
}

.content-section h3 {
    font-size: 1.3em;
    font-weight: 400;
    margin-bottom: 15px;
    color: #444;
}

.author-headshot {
    width: 100%;
    border-radius: 50%;
    aspect-ratio: 1;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.author-headshot:hover {
    transform: scale(1.05);
}

/* Accessibility improvements */
.featured-link:focus {
    outline: none;
    background-color: rgba(0,0,0,0.05);
    border-radius: 4px;
}

/* Language-specific focus styles */
#english-tab:focus {
    outline: none;
    background-color: rgba(101,170,177,0.15); /* Light version of #65aab1 */
    border-radius: 4px 4px 0 0;
}

#icelandic-tab:focus {
    outline: none;
    background-color: rgba(37,126,169,0.15); /* Light version of #257ea9 */
    border-radius: 4px 4px 0 0;
}

#spanish-tab:focus {
    outline: none;
    background-color: rgba(66,24,105,0.15); /* Light version of #421869 */
    border-radius: 4px 4px 0 0;
}

/* Fallback for any other nav links */
.language-tabs .nav-link:focus {
    outline: none;
    background-color: rgba(0,0,0,0.05); /* Grey fallback */
    border-radius: 4px 4px 0 0;
}

/* Performance optimization */
* {
    box-sizing: border-box;
}

img {
    max-width: 100%;
    height: auto;
}

.featured-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.featured-item {
    margin-top: 20px;
    padding: 8px 0;
}

.featured-link {
    color: #555;
    text-decoration: none;
    font-weight: 300;
    font-size: smaller;
}

.featured-link:hover {
    color: #333;
    text-decoration: underline;
}

.featured-link h4 {
    font-size: smaller;
    text-transform: uppercase;
    margin-bottom: 0;
}

/* Tab-specific active states */
#english-tab.active {
    border-bottom-color: #65aab1 !important;
}

#icelandic-tab.active {
    border-bottom-color: #257ea9 !important;
}

#spanish-tab.active {
    border-bottom-color: #421869 !important;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .language-tabs .nav-link {
        font-size: 1em;
        padding: 12px 15px;
    }
    
    .language-tabs .language-flag {
        font-size: 1.1em;
        margin-right: 5px;
    }
    
    .language-card {
        padding: 20px;
        margin-bottom: 30px;
    }
    
    .language-title {
        font-size: 1.8em;
    }
    
    .content-section h3 {
        font-size: 1.2em;
    }
    
    /* Improve mobile spacing */
    .uv-banner {
        margin: 50px 0 50px 0;
    }
    
    .featured-item {
        margin-bottom: 15px;
    }
    
    .author-headshot {
        max-width: 200px;
        margin: 0 auto 20px auto;
        display: block;
    }
}

@media screen and (max-width: 480px) {
    .language-tabs .nav-link {
        font-size: 0.9em;
        padding: 10px 12px;
    }
    
    /* Stack tabs vertically on very small screens */
    .language-tabs {
        flex-direction: column;
        border-bottom: none;
    }
    
    .language-tabs .nav-item {
        width: 100%;
        border-bottom: 1px solid #e0e0e0;
    }
    
    .language-tabs .nav-link {
        text-align: center;
        border-bottom: none;
        margin-bottom: 0;
        border-radius: 0;
    }
    
    .language-tabs .nav-link.active {
        background-color: #f8f9fa;
        border-bottom: none;
    }
    
    /* Better mobile spacing */
    .uv-banner {
        margin: 30px 0 30px 0;
    }
    
    .language-card {
        padding: 15px;
        margin-bottom: 20px;
    }
    
    .featured-item {
        margin-bottom: 12px;
    }
    
    .featured-item a {
        display: block;
        padding: 15px;
        background: #f8f9fa;
        border-radius: 8px;
        text-decoration: none;
        border: 1px solid #e9ecef;
    }
    
    .featured-item a:hover {
        background: #e9ecef;
        transform: none; /* Remove any transform effects on mobile */
    }
    
    .author-headshot {
        max-width: 150px;
        margin: 0 auto 15px auto;
        display: block;
    }
    
    /* Stack columns on mobile */
    .row .col-lg-8,
    .row .col-lg-4 {
        margin-bottom: 20px;
    }
}

.lang-button {
    text-align: center;
}

.lang-button:not(.collapsed) {
  color: var(--bs-accordion-active-color);
  border-bottom: dashed 1px;
  background-color: #ffffff;
  box-shadow: none;
}

.lang-col p {
    text-align: right;
}

.lang-row {
    margin-bottom: 20px;
}

.lang-panel {
    padding: 100px 300px;
}

.lang-panel h2 {
    font-size: 3.0em;
}

@media screen and (max-width: 1200px) {

    .lang-col p {
        text-align: left;
    }
    
    .lang-panel {
        padding: 100px 100px;
    }

    .lang-panel h2 {
        font-size: 2.0em;
    }

}
