/**
 * Base Styles
 * Reset and foundational styles
 */

/* Box Sizing Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Component placeholders - prevent layout shift */
#header-placeholder {
    height: var(--header-height);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-fixed);
    background-color: var(--color-white);
}

#footer-placeholder {
    min-height: 200px;
}

/* Remove default margin and padding */
* {
    margin: 0;
    padding: 0;
}

/* HTML & Body */
html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-family-base);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-normal);
    line-height: var(--line-height-base);
    color: var(--color-text);
    background-color: var(--color-background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-semibold);
    line-height: var(--line-height-tight);
    color: var(--color-gray-900);
}

h1 {
    font-size: var(--font-size-4xl);
}

h2 {
    font-size: var(--font-size-3xl);
}

h3 {
    font-size: var(--font-size-2xl);
}

h4 {
    font-size: var(--font-size-xl);
}

h5 {
    font-size: var(--font-size-lg);
}

h6 {
    font-size: var(--font-size-base);
}

p {
    margin-bottom: var(--spacing-md);
}

p:last-child {
    margin-bottom: 0;
}

/* Links - Base Style (with animated underline like header nav) */
a {
    color: var(--color-gray-700);
    text-decoration: none;
    position: relative;
    transition: color var(--transition-fast);
}

a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: width var(--transition-base);
}

a:hover {
    color: var(--color-primary);
}

a:hover::after {
    width: 100%;
}

/* Links in buttons and elements with their own styling - no underline effect */
/* Note: Card elements removed - they use ::after for animated borders (see enhancements.css) */
.btn,
.logo__text,
.header__logo,
.header__logo a,
.header__email,
.value-item,
.lang-switcher__option,
.lang-switcher__current,
.contact-detail__value,
.footer__address a,
.footer__nav-list a {
    position: static;
}

.btn::after,
.logo__text::after,
.header__logo a::after,
.header__email::after,
.value-item::after,
.lang-switcher__option::after,
.lang-switcher__current::after,
.contact-detail__value::after,
.footer__address a::after,
.footer__nav-list a::after {
    content: none;
}

/* Links on primary/dark backgrounds */
.section--primary a,
.hero a,
.page-hero a,
.cta a {
    color: rgba(255, 255, 255, 0.9);
}

.section--primary a::after,
.hero a::after,
.page-hero a::after,
.cta a::after {
    background-color: var(--color-white);
}

.section--primary a:hover,
.hero a:hover,
.page-hero a:hover,
.cta a:hover {
    color: var(--color-white);
}

/* Links in footer (dark background) */
.footer a {
    color: var(--color-gray-400);
}

.footer a::after {
    background-color: var(--color-white);
}

.footer a:hover {
    color: var(--color-white);
}

/* Links that should keep primary color (contact details, inline text) */
.contact-detail__value,
.text-block a,
.faq-item__answer a,
.expertise-block__text a,
.values__text a,
.partner__text a,
.experience__description a {
    color: var(--color-primary);
}

.contact-detail__value:hover,
.text-block a:hover,
.faq-item__answer a:hover,
.expertise-block__text a:hover,
.values__text a:hover,
.partner__text a:hover,
.experience__description a:hover {
    color: var(--color-primary-dark);
}

/* Lists */
ul, ol {
    list-style: none;
}

/* Images */
img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Forms */
input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
    background: none;
    border: none;
}

/* Address */
address {
    font-style: normal;
}

/* Tables */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

/* Utility: Screen Reader Only */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Container */
.container {
    width: 100%;
    max-width: var(--container-max-width);
    margin-inline: auto;
    padding-inline: var(--spacing-lg);
}

/* Section */
.section {
    padding-block: var(--spacing-4xl);
}

.section--alt {
    background-color: var(--color-background-alt);
}

.section--primary {
    background-color: var(--color-primary);
    color: var(--color-white);
}

.section__title {
    text-align: center;
    margin-bottom: var(--spacing-3xl);
}

.section--primary .section__title {
    color: var(--color-white);
}

/* Main Content Area */
.main {
    min-height: calc(100vh - var(--header-height));
}
