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

:root {
    --light-bg: #ffffff;
    --light-text: #555555;
    --light-title: #000000;
    --dark-bg: #1a1a1a;
    --dark-text: #cccccc;
    --dark-title: #ffffff;
    --nav-bg-light: rgba(255, 255, 255, 0.85);
    --nav-bg-dark: rgba(30, 30, 30, 0.9);
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--light-bg);
    color: var(--light-text);
    transition: background 0.3s, color 0.3s;
}

body.dark-theme {
    background: var(--dark-bg);
    color: var(--dark-text);
}

body.dark-theme .title {
    color: var(--dark-title);
}

html {
    scroll-behavior: smooth;
}

p {
    color: rgb(85, 85, 85);
}

body.dark-theme p {
    color: var(--dark-text);
}

a, .btn {
    transition: all 300ms ease;
}

a {
    color: black;
    text-decoration: none;
}

body.dark-theme a {
    color: var(--dark-text);
}

a:hover {
    color: grey;
    text-decoration: underline;
    text-underline-offset: 1rem;
    text-decoration-color: rgb(181, 181, 181);
}

/* NAVIGATION */
nav, .nav-links { display: flex; }
nav { justify-content: space-around; align-items: center; height: 17vh; }
.nav-links { gap: 2rem; list-style: none; font-size: 1.5rem; align-items: center; }
.logo {
    height: 2rem;
    width: auto;
}
.logo:hover {
    cursor: pointer;
}
body.dark-theme .logo {
    filter: invert(1);
}
.theme-toggle { font-size: 1.5rem; cursor: pointer; background: none; border: none; color: black; padding: 0; }
body.dark-theme .theme-toggle { color: white; }

/* HAMBURGER MENU */
#hamburger-nav { display: none; }
.hamburger-menu { position: relative; display: inline-block; }
.hamburger-icon { display: flex; flex-direction: column; justify-content: space-between; height: 24px; width: 30px; cursor: pointer; }
.hamburger-icon span { width: 100%; height: 2px; background-color: black; transition: all 0.3s ease-in-out; }
body.dark-theme .hamburger-icon span { background-color: white; }
.menu-links { position: absolute; top: 100%; right: 0; background-color: var(--nav-bg-light); backdrop-filter: blur(15px); width: fit-content; max-height: 0; overflow: hidden; transition: all 0.3s ease-in-out; border-radius: 15px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); z-index: 1000; }
body.dark-theme .menu-links { background-color: var(--nav-bg-dark); } .menu-links a, .menu-links button { display: block; padding: 10px; text-align: center; font-size: 1.5rem; color: black; text-decoration: none; transition: all 0.3s ease-in-out; width: 100%; }
body.dark-theme .menu-links a, body.dark-theme .menu-links button { color: var(--dark-text); }
.menu-links li { list-style: none; }
.menu-links.open { max-height: 300px; }
.hamburger-icon.open span:first-child { transform: rotate(45deg) translate(10px, 5px); }
.hamburger-icon.open span:nth-child(2) { opacity: 0; }
.hamburger-icon.open span:last-child { transform: rotate(-45deg) translate(10px, -5px); }

/* SECTIONS & TITLES */
section { padding-top: 4vh; margin: 0 10rem; box-sizing: border-box; min-height: fit-content; }
.section__text__p1 { text-align: center; font-weight: 600; }
.title { font-size: 3rem; text-align: center; color: var(--light-title); }

.filter-container {
    text-align: center;
    margin: 1rem 0 2rem 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}

.reviews-tag {
    cursor: default;
    padding: 0.4rem 1.2rem;
    font-size: 0.9rem;
    pointer-events: none;
    border-radius: 2rem;
}

#testimonial-filter {
    padding: 0.5rem 1rem;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    border-radius: 8px;
    border: 1px solid rgb(163, 163, 163);
    background-color: var(--light-bg);
    color: var(--light-text);
    cursor: pointer;
}

body.dark-theme #testimonial-filter {
    background-color: #3a3a3a;
    border-color: #666;
    color: var(--dark-text);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* TESTIMONIALS PAGE SPECIFIC */
#testimonials {
    position: relative;
    min-height: 100vh; /* Ensure section fills the screen, but can grow */
    display: flex;
    flex-direction: column;
    justify-content: center; /* Center content vertically */
    padding: 4rem 0;
}
.testimonial-grid-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 2rem; max-width: 1200px; margin: 2rem auto 0 auto; }
.testimonial-card { background: white; border-radius: 1.5rem; border: 1px solid rgb(163, 163, 163); text-align: center; display: flex; flex-direction: column; transition: transform 0.3s ease, box-shadow 0.3s ease; padding: 1.5rem; position: relative; }
.testimonial-card:hover { transform: translateY(-5px); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1); }
body.dark-theme .testimonial-card { background: #2d2d2d; border-color: #555; transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; }
body.dark-theme .testimonial-card:hover { box-shadow: 0 8px 20px rgba(255, 255, 255, 0.1); }
.testimonial-card:has(.options-menu.open) {
    z-index: 20; /* Ensure the active card's menu appears above others */
}

.scale-out-hidden {
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
}
.testimonial-card blockquote { margin: 0; flex-grow: 1; }
.testimonial-card blockquote p { font-style: italic; margin-bottom: 1.5rem; }
.testimonial-author { display: flex; align-items: center; justify-content: flex-start; gap: 1rem; margin-top: auto; width: 100%; }
.author-img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; }
.author-info { display: flex; align-items: center; justify-content: space-between; flex-grow: 1; gap: 1rem; }
.author-text { text-align: left; }
.author-info h3 { margin: 0; font-size: 1.1rem; color: var(--light-title); }
body.dark-theme .author-info h3 { color: var(--dark-title); }
.author-info .author-title { font-size: 0.9rem; color: #555; font-style: normal; margin: 0; }
body.dark-theme .author-info .author-title { color: #bbb; }

/* MENU STYLES */
.menu-container {
    position: relative;
    display: inline-block;
}

.menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light-text);
    transition: background-color 0.3s;
}

body.dark-theme .menu-btn {
    color: var(--dark-text);
}

.menu-btn:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

body.dark-theme .menu-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.options-menu {
    position: absolute;
    right: 0;
    top: 100%;
    background-color: var(--light-bg);
    border: 1px solid #ccc;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    min-width: 140px;
    z-index: 100;
    overflow: hidden;
}

.options-menu.open {
    display: flex;
}

body.dark-theme .options-menu {
    background-color: #2d2d2d;
    border-color: #555;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.menu-option {
    background: none;
    border: none;
    padding: 0.75rem 1rem;
    text-align: left;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--light-text);
    width: 100%;
    transition: background-color 0.2s;
}

body.dark-theme .menu-option {
    color: var(--dark-text);
}

.menu-option:hover {
    background-color: #f0f0f0;
}

body.dark-theme .menu-option:hover {
    background-color: #3a3a3a;
}

/* BUTTONS, ICONS, CONTACT, FOOTER */
.btn-container { display: flex; justify-content: center; gap: 1rem; margin-top: auto; padding-top: 1rem; }
.btn { font-weight: 600; padding: 1rem; width: 8rem; border-radius: 2rem; cursor: pointer; }
.btn-color-1 { border: 1px solid rgb(53, 53, 53); background: rgb(53, 53, 53); color: white; }
.btn-color-1:hover { background: rgb(0, 0, 0); }
.btn-color-2 { border: 1px solid rgb(53, 53, 53); background: none; color: black; }
.btn-color-2:hover { background: rgb(53, 53, 53); color: white; }
body.dark-theme .btn-color-1 { border: 1px solid #ffffff; background: #333333; color: white; }
body.dark-theme .btn-color-1:hover { background: #ffffff; color: #000000; }
body.dark-theme .btn-color-2 { border: 1px solid #ffffff; background: none; color: white; }
body.dark-theme .btn-color-2:hover { background: #ffffff; color: #000000; }
.icon { cursor: pointer; height: 2rem; }
.scroll-down-link, .scroll-up-link {
    display: inline-block;
    position: absolute;
    bottom: 2.5rem;
    right: -5rem;
}
.arrow { width: 30px; height: 30px; }

#contact { display: flex; justify-content: center; flex-direction: column; min-height: 70vh; position: relative; }
.contact-form-container { display: flex; justify-content: center; margin-bottom: 2rem; width: 100%; }
#contact-form { display: flex; flex-direction: column; gap: 1.5rem; width: 100%; max-width: 600px; background: rgb(250, 250, 250); border: 1px solid rgb(163, 163, 163); border-radius: 2rem; padding: 2rem; box-shadow: 0 5px 15px rgba(0,0,0,0.1); }
body.dark-theme #contact-form { background: #2d2d2d; border-color: #555; }
.form-group { display: flex; flex-direction: column; }
.form-group label { font-weight: 600; margin-bottom: 0.5rem; color: var(--light-title); }
body.dark-theme .form-group label { color: var(--dark-title); }
.form-group input, .form-group textarea { padding: 0.75rem; border: 1px solid rgb(163, 163, 163); border-radius: 0.5rem; font-family: inherit; font-size: 1rem; background: var(--light-bg); color: var(--light-text); }
body.dark-theme .form-group input, body.dark-theme .form-group textarea { background: #3a3a3a; border-color: #666; color: var(--dark-text); }
.form-group button { width: 100%; }

/* Form Status Message Styling */
#form-status {
    padding: 0.75rem 1rem;
    margin-top: 1rem;
    border-radius: 0.5rem;
    text-align: center;
    font-weight: 500;
    display: none; /* Hidden by default */
    transition: all 0.3s ease;
}
#form-status.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}
#form-status.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}
/* Dark Theme Adjustments */
body.dark-theme #form-status.success {
    background-color: #1a3a22;
    color: #a7d7b7;
    border-color: #2a5c3d;
}
body.dark-theme #form-status.error {
    background-color: #4d1f24;
    color: #f5c6cb;
    border-color: #843534;
}

.contact-info-upper-container { display: flex; justify-content: center; border-radius: 2rem; border: 1px solid rgb(163, 163, 163); background: rgb(250, 250, 250); margin: 2rem auto; padding: 0.5rem; }
body.dark-theme .contact-info-upper-container { background: #2d2d2d; border-color: #555; }
.contact-info-container { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin: 1rem; }
.contact-info-container p { font-size: larger; }
.contact-icon { cursor: default; }

.contact-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.contact-link:hover {
    text-decoration: underline;
}

.contact-text {
    font-size: larger;
}

footer { height: 26vh; margin: 0 1rem; }
footer p { text-align: center; }

.fade-in-section { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
.fade-in-section.visible { opacity: 1; transform: translateY(0); }

.hidden { display: none; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }

.scroll-down-link, .scroll-up-link {
    display: inline-block;
    position: absolute;
    bottom: 2.5rem;
    right: -1rem;
}

.arrow {
    width: 30px;
    height: 30px;
    margin-top: 1rem;
}

body.dark-theme .arrow,
body.dark-theme .contact-icon {
    filter: invert(1);
}

/* TOAST NOTIFICATION */
.toast-notification {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background-color: rgba(30, 30, 30, 0.95);
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    pointer-events: none;
    text-align: center;
    max-width: 90vw;
}

.toast-notification.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

body.dark-theme .toast-notification {
    background-color: rgba(240, 240, 240, 0.95);
    color: #1a1a1a;
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.15);
}

/* ACCESSIBLE TOOLTIPS */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-5px);
    background-color: rgba(30, 30, 30, 0.9);
    color: #fff;
    padding: 0.4rem 0.8rem;
    border-radius: 0.4rem;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    margin-bottom: 5px;
}

[data-tooltip]:hover::before,
[data-tooltip]:focus-visible::before {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-10px);
}

body.dark-theme [data-tooltip]::before {
    background-color: rgba(220, 220, 220, 0.9);
    color: #000;
    box-shadow: 0 2px 5px rgba(255,255,255,0.1);
}

@media (hover: none), screen and (max-width: 600px) {
    [data-tooltip]::before {
        display: none;
    }
}