/*
  style.css
  Theme: Servicios y aplicaciones para учёta de gastos
  Design System: Modern with Volumetric UI
  Color Scheme: Bright
*/

/* ===== 1. CSS Variables (Root) ===== */
:root {
    --primary-color: #00A9B7; /* Vibrant Teal */
    --primary-color-dark: #008C9E;
    --secondary-color: #FF6F61; /* Living Coral */
    --accent-color: #FFC75F; /* Sunny Yellow */
    --background-color: #F8F9FA;
    --background-highlight: #FFFFFF;
    --text-color: #343A40;
    --text-light-color: #FFFFFF;
    --border-color: #DEE2E6;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --shadow-color-hover: rgba(0, 0, 0, 0.2);

    --font-family-headings: 'Roboto', sans-serif;
    --font-family-body: 'Lato', sans-serif;
    
    --header-height: 80px;
}

/* ===== 2. Global Styles & Resets ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-family-body);
    color: var(--text-color);
    background-color: var(--background-color);
    line-height: 1.7;
    overflow-x: hidden;
}

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

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

ul {
    list-style: none;
}

/* ===== 3. Utility Classes ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

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

.section {
    padding: 5rem 1.5rem;
}

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

.reveal {
    visibility: hidden;
}

/* ===== 4. Layout System (Flexbox Columns) ===== */
.columns {
    display: flex;
    flex-wrap: wrap;
    margin: -0.75rem;
}

.column {
    display: block;
    flex-basis: 0;
    flex-grow: 1;
    flex-shrink: 1;
    padding: 0.75rem;
}
.is-one-third { flex: none; width: 33.333%; }
.is-half { flex: none; width: 50%; }
.is-two-thirds { flex: none; width: 66.666%; }
.is-one-quarter { flex: none; width: 25%; }
.is-vcentered { align-items: center; }
.is-centered { justify-content: center; }
.is-multiline { flex-wrap: wrap; }


/* ===== 5. Typography ===== */
h1, h2, h3, h4 {
    font-family: var(--font-family-headings);
    font-weight: 900;
    color: #222222;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    position: relative;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto 3rem auto;
    color: #6c757d;
}

.content-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* ===== 6. UI Components ===== */

/* --- Buttons --- */
.button {
    display: inline-block;
    font-family: var(--font-family-headings);
    font-size: 1rem;
    font-weight: 700;
    padding: 12px 30px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.button-volumetric {
    box-shadow: 0 4px 15px var(--shadow-color), inset 0 -2px 0 rgba(0,0,0,0.15);
    transform: translateY(0);
}

.button-volumetric:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--shadow-color-hover), inset 0 -2px 0 rgba(0,0,0,0.1);
}

.button-volumetric:active {
    transform: translateY(1px);
    box-shadow: 0 2px 8px var(--shadow-color), inset 0 -1px 0 rgba(0,0,0,0.15);
}

.button-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--primary-color-dark));
    color: var(--text-light-color);
}

.button-secondary {
    background-color: var(--background-highlight);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

/* --- Cards --- */
.card {
    background-color: var(--background-highlight);
    border-radius: 15px;
    box-shadow: 0 10px 30px var(--shadow-color);
    overflow: hidden;
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    text-align: center;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px var(--shadow-color-hover);
}

.card-image {
    width: 100%;
    height: 200px; /* Fixed height for consistency */
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
}

.info-card {
    padding: 2rem;
    background: linear-gradient(135deg, var(--background-highlight), var(--background-color));
}

/* --- Forms --- */
.contact-form .form-field {
    position: relative;
    margin-bottom: 2rem;
}

.form-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-family-body);
    font-size: 1rem;
    background-color: var(--background-highlight);
    transition: border-color 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.06);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 169, 183, 0.25);
}

.form-label {
    position: absolute;
    top: 12px;
    left: 15px;
    color: #6c757d;
    pointer-events: none;
    transition: all 0.2s ease;
}

.form-input:focus + .form-label,
.form-input:not(:placeholder-shown) + .form-label {
    top: -10px;
    left: 10px;
    font-size: 0.8rem;
    background-color: var(--background-color);
    padding: 0 5px;
    color: var(--primary-color);
}

/* --- Progress Bars --- */
.progress-indicator {
    margin-top: 1rem;
}
.progress-indicator label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}
.progress-bar {
    width: 100%;
    height: 10px;
    appearance: none;
    border-radius: 5px;
    overflow: hidden;
}
.progress-bar::-webkit-progress-bar {
    background-color: #e9ecef;
}
.progress-bar::-webkit-progress-value {
    background-color: var(--secondary-color);
    transition: width 0.5s ease;
}

/* ===== 7. Site Structure ===== */

/* --- Header & Navigation --- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px var(--shadow-color);
    transition: top 0.3s ease;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: var(--header-height);
}

.navbar-brand {
    font-family: var(--font-family-headings);
    font-weight: 900;
    font-size: 1.8rem;
    color: var(--primary-color);
}

.nav-link {
    color: var(--text-color);
    font-weight: 700;
    margin: 0 1rem;
    position: relative;
    padding: 5px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.navbar-burger {
    display: none;
    cursor: pointer;
    background: transparent;
    border: none;
}

.navbar-menu-mobile {
    display: none;
}

/* --- Footer --- */
.site-footer {
    background-color: var(--text-color);
    color: #adb5bd;
    padding: 4rem 1.5rem 2rem;
}

.footer-title {
    color: var(--text-light-color);
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.site-footer ul li {
    margin-bottom: 0.5rem;
}

.site-footer a {
    color: #adb5bd;
}

.site-footer a:hover {
    color: var(--text-light-color);
}

.footer-bottom {
    border-top: 1px solid #495057;
    margin-top: 2rem;
    padding-top: 2rem;
    text-align: center;
    font-size: 0.9rem;
}

/* ===== 8. Page Sections ===== */

/* --- Hero Section --- */
.hero-section {
    color: var(--text-light-color);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.hero-content {
    max-width: 800px;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: var(--text-light-color);
    text-shadow: 2px 2px 8px rgba(0,0,0,0.7);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* --- Projects Section --- */
.statistical-widgets-container {
    display: flex;
    justify-content: space-around;
    text-align: center;
    margin-top: 4rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    padding: 2rem;
    border-radius: 15px;
    color: var(--text-light-color);
}

.stat-widget .stat-number {
    font-size: 3rem;
    font-weight: 900;
}
.stat-widget .stat-label {
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- Team Section --- */
.team-card img {
    border-radius: 50%;
    width: 150px;
    height: 150px;
    object-fit: cover;
    margin: 1.5rem auto 1rem;
    border: 5px solid var(--background-highlight);
    box-shadow: 0 5px 15px var(--shadow-color);
}

.team-name {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}
.team-role {
    color: #6c757d;
    font-weight: 700;
}

/* --- Pricing Section --- */
.pricing-card {
    border: 2px solid transparent;
}
.pricing-card.featured {
    border-color: var(--secondary-color);
    transform: scale(1.05);
}
.pricing-plan-name {
    font-size: 1.5rem;
    color: var(--primary-color);
}
.pricing-plan-price {
    font-size: 3rem;
    font-weight: 900;
    margin: 1rem 0;
}
.pricing-features {
    text-align: left;
    margin: 2rem auto;
    width: fit-content;
}
.pricing-features li {
    margin-bottom: 0.75rem;
}
.pricing-features li::before {
    content: '✔';
    color: var(--secondary-color);
    margin-right: 10px;
}

/* --- News Section --- */
.news-date {
    font-size: 0.8rem;
    color: #6c757d;
    margin-bottom: 0.5rem;
}

/* --- Media Section --- */
.media-logos {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}
.media-logo {
    filter: grayscale(100%);
    opacity: 0.7;
    transition: filter 0.3s ease, opacity 0.3s ease;
}
.media-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* --- External Resources Section --- */
.external-links-list {
    list-style-type: disc;
    padding-left: 20px;
    max-width: 800px;
    margin: 0 auto;
}
.external-links-list li {
    margin-bottom: 1rem;
}
.external-links-list a {
    font-weight: 700;
}

/* ===== 9. Specific Pages ===== */

/* --- success.html --- */
.success-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 100vh;
    padding: 2rem;
    background-color: var(--background-color);
}
.success-page h1 {
    color: var(--primary-color);
    font-size: 3rem;
}
.success-page p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* --- privacy.html, terms.html, about.html, contacts.html --- */
.static-page-content {
    padding-top: calc(var(--header-height) + 4rem); /* Header height + extra space */
    padding-bottom: 4rem;
}
.static-page-content h1 {
    text-align: center;
    margin-bottom: 3rem;
}
.static-page-content h2 {
    margin-top: 2rem;
    color: var(--primary-color);
}

/* ===== 10. Responsive Design (Media Queries) ===== */
@media (max-width: 768px) {
    .navbar-menu-desktop {
        display: none;
    }

    .navbar-burger {
        display: flex;
        flex-direction: column;
        justify-content: space-around;
        width: 30px;
        height: 30px;
    }

    .navbar-burger span {
        display: block;
        width: 25px;
        height: 3px;
        background-color: var(--text-color);
        border-radius: 3px;
        transition: all 0.3s ease;
    }
    
    .navbar-burger.is-active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .navbar-burger.is-active span:nth-child(2) {
        opacity: 1;
    }
    .navbar-burger.is-active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .navbar-menu-mobile {
        display: none; /* Initially hidden */
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background-color: var(--background-highlight);
        flex-direction: column;
        align-items: center;
        padding: 1rem 0;
        box-shadow: 0 5px 10px var(--shadow-color);
    }

    .navbar-menu-mobile.is-active {
        display: flex;
    }

    .navbar-menu-mobile .nav-link {
        margin: 0.5rem 0;
        width: 100%;
        text-align: center;
    }

    .columns {
        margin: -0.5rem;
    }
    .column {
        width: 100%;
        padding: 0.5rem;
        flex: none;
    }
    
    .section {
        padding: 3rem 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .statistical-widgets-container {
        flex-direction: column;
        gap: 2rem;
    }

    .columns.is-vcentered {
        flex-direction: column-reverse;
    }
}