/* 
* domain - Servicii Contabile
* Main Stylesheet
*/

/* Variables */
:root {
    --background: #FAFAF2;
    --accent1: #8A2BE2;
    --accent2: #FFD700;
    --text-color: #2C2C2C;
    --light-gradient-start: #F5F5DC;
    --light-gradient-end: #FFFACD;
    --button-text: #FFFFFF;
    --container-width: 1200px;
    --border-radius: 8px;
    --box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: var(--background);
    color: var(--text-color);
    line-height: 1.6;
    font-size: 16px;
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    margin-bottom: 20px;
    line-height: 1.3;
    font-weight: 700;
}

h1 {
    font-size: 3rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.8rem;
}

p {
    margin-bottom: 20px;
}

a {
    color: var(--accent1);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--accent2);
}

img {
    max-width: 100%;
    height: auto;
}

section {
    padding: 80px 0;
    scroll-margin-top: 90px; /* Added to prevent header overlapping when navigating to anchors */
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    border-radius: var(--border-radius);
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    text-align: center;
}

.btn-primary {
    background-color: var(--accent1);
    color: var(--button-text);
}

.btn-primary:hover {
    background-color: #7825c9;
    color: var(--button-text);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--accent1);
    color: var(--accent1);
}

.btn-secondary:hover {
    background-color: var(--accent1);
    color: var(--button-text);
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    position: relative;
    padding-bottom: 20px;
}

.section-title h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--accent1);
}

/* Header & Navigation */
.main-header {
    padding: 20px 0;
    background-color: var(--background);
    box-shadow: var(--box-shadow);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 2rem;
    font-weight: 700;
}

.logo a {
    color: var(--accent1);
}

.main-nav ul {
    display: flex;
    list-style: none;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    color: var(--text-color);
    font-weight: 600;
}

.main-nav a:hover {
    color: var(--accent1);
}

.mobile-toggle {
    display: none;
}

/* Main Content Styles */
main {
    margin-top: 90px; /* To account for fixed header */
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--accent1) 0%, var(--accent2) 100%);
    color: white;
    padding: 120px 0 80px;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 30px;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 40px;
}

/* About Section */
.about {
    background-color: var(--background);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-card {
    background: linear-gradient(to bottom, var(--light-gradient-start), var(--light-gradient-end));
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--accent1);
}

/* Benefits Section */
.benefits {
    background-color: #f5f5f5;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.benefit-item {
    text-align: center;
    padding: 20px;
}

.benefit-icon {
    font-size: 2.5rem;
    color: var(--accent1);
    margin-bottom: 15px;
}

/* Process Section */
.process-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-top: 40px;
}

.process-steps:before {
    content: '';
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
    height: 3px;
    background-color: var(--accent1);
    z-index: 1;
}

.step {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 20%;
}

.step-number {
    width: 80px;
    height: 80px;
    line-height: 80px;
    border-radius: 50%;
    background-color: var(--accent1);
    color: white;
    margin: 0 auto 20px;
    font-size: 1.8rem;
    font-weight: 700;
}

/* Testimonials Section */
.testimonials {
    background: linear-gradient(to right, var(--light-gradient-start), var(--light-gradient-end));
}

.testimonial-container {
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
}

.testimonial-slide {
    display: none;
    padding: 30px;
    text-align: center;
}

.testimonial-slide.active {
    display: block;
    animation: fadeIn 1s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.testimonial-text {
    font-size: 1.1rem;
    font-style: italic;
    margin-bottom: 20px;
}

.testimonial-author {
    font-weight: 700;
}

.testimonial-nav {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.testimonial-nav form {
    margin: 0 5px;
}

.testimonial-nav button {
    background: var(--accent1);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
}

/* Contact Form */
.contact {
    background-color: var(--background);
}

.contact-container {
    max-width: 700px;
    margin: 0 auto;
}

.contact-form {
    background: linear-gradient(to bottom, var(--light-gradient-start), var(--light-gradient-end));
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 1rem;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent1);
}

.form-check {
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
}

.form-check input {
    margin-top: 5px;
    margin-right: 10px;
}

/* Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.blog-card {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.blog-card:hover {
    transform: translateY(-5px);
}

.blog-image {
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-content {
    padding: 20px;
}

.blog-date {
    color: #777;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

/* Footer */
.main-footer {
    background-color: #222;
    color: white;
    padding: 60px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.footer-grid h3 {
    color: var(--accent2);
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-grid ul {
    list-style: none;
}

.footer-grid ul li {
    margin-bottom: 10px;
}

.footer-grid a {
    color: white;
}

.footer-grid a:hover {
    color: var(--accent2);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 0.9rem;
}

/* Cookie Consent Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0,0,0,0.9);
    color: white;
    padding: 20px;
    z-index: 9999;
    display: none; /* Hidden by default, shown by JS */
}

.cookie-banner.active {
    display: block;
}

.cookie-content {
    max-width: var(--container-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-content p {
    margin: 0;
    padding-right: 20px;
}

.cookie-buttons {
    display: flex;
}

.cookie-buttons button {
    margin-left: 10px;
}

/* Policy Pages */
.policy-page {
    padding: 80px 0;
}

.policy-container {
    max-width: 900px;
    margin: 0 auto;
    background-color: white;
    padding: 50px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.policy-container h1 {
    text-align: center;
    margin-bottom: 30px;
}

.policy-logo {
    text-align: center;
    margin-bottom: 30px;
}

/* Mobile menu with PHP */
.menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--accent1);
    transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
}

/* PHP FAQ Toggle */
.faq-item {
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.faq-question {
    padding: 15px 20px;
    background-color: #f5f5f5;
    cursor: pointer;
    font-weight: 600;
    position: relative;
}

.faq-question a {
    color: var(--text-color);
    text-decoration: none;
    display: block;
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-answer.open {
    padding: 20px;
    max-height: 500px;
}

/* Thank you page */
.thank-you {
    text-align: center;
    padding: 100px 0;
}

.thank-you h1 {
    margin-bottom: 30px;
    color: var(--accent1);
}

.thank-you-box {
    background-color: white;
    border: 2px solid var(--accent1);
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--box-shadow);
    max-width: 700px;
    margin: 0 auto;
}

/* Media Queries */
@media (max-width: 992px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    .services-grid, 
    .benefits-grid,
    .blog-grid,
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .process-steps {
        flex-direction: column;
    }
    
    .process-steps:before {
        display: none;
    }
    
    .step {
        width: 100%;
        margin-bottom: 30px;
    }
}

@media (max-width: 768px) {
    .mobile-toggle {
        display: block;
    }
    
    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--background);
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        visibility: hidden; /* Hide the menu by default */
    }
    
    .main-nav.open {
        max-height: 500px;
        padding: 20px;
        visibility: visible; /* Show the menu when open */
    }
    
    .main-nav ul {
        flex-direction: column;
    }
    
    .main-nav li {
        margin: 10px 0;
        margin-left: 0;
    }
    
    .services-grid, 
    .benefits-grid,
    .blog-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .cookie-content {
        flex-direction: column;
    }
    
    .cookie-content p {
        margin-bottom: 15px;
        padding-right: 0;
    }
}

@media (max-width: 576px) {
    section {
        padding: 50px 0;
    }
    
    .hero {
        padding: 100px 0 60px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .policy-container {
        padding: 30px;
    }
}
