/* =======================================
   STYLES.CSS - FRANCESCRIERA.COM
   Versió humana i directa
   ======================================= */

/* Colors */
:root {
    --primary: #2a3449;
    --secondary: #295d6f;
    --accent: #c0ca33;
    --highlight: #09f0c2;
    --bg: #f5f5f5;
    --text: #333;
    --white: #ffffff;
    --black: #0D0D1A;

/* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;
  --space-4xl: 8rem;

  /* Transicions */
  --transition-fast: 0.15s ease-out;
  --transition-normal: 0.3s ease-out;
  --transition-slow: 0.5s ease-out;
  
  /* Radius */
  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 50px;
  
  /* Ombres */
  --shadow-sm: 0 2px 8px rgba(41, 93, 111, 0.08);
  --shadow-md: 0 4px 20px rgba(41, 93, 111, 0.12);
  --shadow-lg: 0 10px 40px rgba(41, 93, 111, 0.15);
  --shadow-xl: 0 20px 60px rgba(41, 93, 111, 0.2);
  --shadow-2xl: 0 25px 80px rgba(41, 93, 111, 0.25);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    color: var(--text);
    line-height: 1.6;
    background: var(--white);
}

/* Header simple */
header {
    background: var(--primary);
    padding: 0.6rem 2rem;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    border-bottom: 3px solid var(--accent);
}

header .header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 70px;
    width: auto;
}

/* Botó hamburguesa - ocult per defecte */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 101;
}

.menu-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background: var(--white);
    border-radius: 3px;
    transition: all 0.3s ease;
}

/* Animació del botó hamburguesa quan està actiu */
.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-menu a {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 17px;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--highlight);
}

.btn-agendar {
    background: var(--accent);
    color: var(--primary) !important;
    padding: 0.6rem 1.4rem;
    border-radius: 6px;
    font-weight: 600;
    text-decoration: none !important;
    transition: all 0.3s;
}

.btn-agendar:hover {
    background: #a8b329;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(192, 202, 51, 0.3);
}

/* Hero nou amb imatge de fons */
.hero {
    margin-top: 88px;
    position: relative;
    height: 600px;
    background-image: url('home-image.jpg');
    background-size: cover;
    background-position: bottom center;
    background-repeat: no-repeat;
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(42, 52, 73, 0.35);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    padding: 0 3rem 3rem 2rem;
    text-align: left;
}

.hero-text {
    color: var(--white);
}

.hero-text h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    white-space: nowrap;
}

.hero-subtitle {
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
    line-height: 1.5;
    font-weight: 400;
    white-space: nowrap;
}

.hero-subtitle-2 {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    font-weight: 300;
    white-space: nowrap;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: flex-start;
    flex-wrap: wrap;
}

/* Botons */
.btn {
    display: inline-block;
    padding: 0.9rem 1.8rem;
    text-decoration: none;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s;
    font-size: 1.05rem;
}

.btn i {
    margin-right: 0.5rem;
}

.btn-primary {
    background: var(--accent);
    color: var(--primary);
}

.btn-primary:hover {
    background: #a8b329;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(192, 202, 51, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--primary);
}

/* Seccions */
section {
    padding: 60px 2rem;
}

.container {
    max-width: 900px;
    margin: 0 auto;
}

.container-wide {
    max-width: 1300px;
    margin: 0 auto;
}

h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

h3 {
    font-size: 1.4rem;
    color: var(--primary);
    margin-bottom: 0.8rem;
}

/* Qui sóc - amb foto rectangular */
.qui-soc {
    background: var(--white);
    border-top: 4px solid var(--accent);
}

.qui-soc-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
    align-items: start;
    margin-bottom: 3rem;
}

.qui-soc-image {
    position: relative;
    width: 280px;
    height: 350px;
}

.qui-soc-image::before {
    content: '';
    position: absolute;
    inset: -4px;
    background: linear-gradient(135deg, var(--primary), var(--accent), var(--highlight));
    border-radius: 12px;
    z-index: 0;
}

.qui-soc-image img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    z-index: 1;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    transition: all 0.4s ease;
}

.qui-soc-image:hover img {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}

.qui-soc-text {
    flex: 1;
}

.qui-soc p {
    margin-bottom: 1.2rem;
    font-size: 1.05rem;
}

.qui-soc strong {
    color: var(--primary);
}

.highlight {
    background: var(--bg);
    padding: 1.5rem;
    border-left: 4px solid var(--highlight);
    margin: 2rem 0;
}

.highlight p {
    margin-bottom: 0.8rem;
}

.highlight ul {
    list-style: none;
    padding: 0;
}

.highlight li {
    padding: 0.4rem 0;
}

/* Serveis - targetes amb cantonada doblegada */
.serveis {
    background: var(--secondary);
}

.serveis h2 {
    color: var(--accent);
    text-align: center;
    margin-bottom: 3rem;
}

.serveis-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.servei-item {
    background: var(--white);
    padding: 2rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

/* Icona de casa dins d'un cercle */
.servei-icon {
    width: 70px;
    height: 70px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: all 0.3s ease;
}

.servei-icon i {
    font-size: 32px;
    color: var(--primary);
}

.servei-item:hover .servei-icon {
    transform: scale(1.1);
}

/* Cantonada doblegada - efecte 3D */
.servei-item::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 50px 50px 0;
    border-color: transparent var(--bg) transparent transparent;
    transition: all 0.3s ease;
}

.servei-item::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 50px 50px 0;
    border-color: transparent var(--accent) transparent transparent;
    opacity: 0;
    transition: all 0.3s ease;
}

.servei-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.servei-item:hover::before {
    border-width: 0 60px 60px 0;
}

.servei-item:hover::after {
    opacity: 0.8;
    border-width: 0 60px 60px 0;
}

.servei-item h3 {
    margin-bottom: 1rem;
    color: var(--primary);
    font-size: 1.25rem;
    text-align: center;
    line-height: 1.3;
}

.servei-item p {
    margin-bottom: 1rem;
    color: var(--text);
    line-height: 1.5;
    text-align: center;
}

.servei-item ul {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
    flex: 1;
}

.servei-item li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    font-size: 0.95rem;
    text-align: left;
}

.servei-item li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

.servei-item .btn {
    width: 100%;
    text-align: center;
    margin-top: auto;
}

/* Valors - cercles amb ombra interior */
.per-que {
    background: var(--white);
}

.per-que h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.valors-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.valor-item {
    background: var(--white);
    border-radius: 50%;
    width: 280px;
    height: 280px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: inset 0 4px 12px rgba(0,0,0,0.08);
    border: 2px solid var(--bg);
    transition: all 0.3s ease;
}

.valor-item:hover {
    box-shadow: inset 0 6px 16px rgba(0,0,0,0.12);
    border-color: var(--highlight);
    transform: scale(1.05);
}

/* Icona handshake dins d'un cercle */
.valor-icon {
    width: 60px;
    height: 60px;
    background: var(--highlight);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.valor-icon i {
    font-size: 28px;
    color: var(--primary);
}

.valor-item:hover .valor-icon {
    transform: scale(1.1) rotate(5deg);
}

.valor-item h4 {
    color: var(--primary);
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
    font-weight: 600;
}

.valor-item p {
    color: var(--text);
    font-size: 0.95rem;
    line-height: 1.4;
}

/* Sticky buttons */
.contact-sticky {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 99;
}

.sticky-btn {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.sticky-btn.whatsapp {
    background: #25D366;
}

.sticky-btn.phone {
    background: var(--highlight);
}

.sticky-btn.email {
    background: #EA4335;
}

/* ===================================
   FOOTER
=================================== */

.footer-area {
    background-color: var(--black);
    color: var(--white);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    padding: 40px 0 0;
    margin-top: 40px;
}

.footer-bottom {
    background: var(--black);
    padding: 40px 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
    gap: 40px;
}

.footer-section {
    flex: 1;
    min-width: 200px;
}

.footer-section img {
    max-height: 80px;
    width: auto;
    filter: brightness(0.9);
    transition: all 0.3s;
    margin-bottom: 10px;
}

.footer-section img:hover {
    filter: brightness(1.1);
    transform: scale(1.05);
}

.footer-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--white);
    position: relative;
}

.footer-section h4::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
}

.footer-section p {
    font-size: 0.9rem;
    margin: 8px 0;
    opacity: 0.9;
    line-height: 1.6;
}

/* Links amb efectes moderns */
.contacte-legal a {
  color: var(--white);
  text-decoration: none;
  transition: all var(--transition-normal);
  position: relative;
}

.contacte-legal a:visited {
  color: var(--white);
}

.contacte-legal a:hover {
  color: var(--accent);
  transform: translateX(4px);
  text-decoration: none;
}

.contacte-legal a:active {
  color: var(--white);
}

/* Efecte subratllat en hover */
.contacte-legal a::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width var(--transition-normal);
}

.contacte-legal a:hover::before {
  width: 100%;
}

/* Social icons */
.social-icons {
    display: flex;
    gap: 12px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.social-icons i {
    background: var(--white);
    color: var(--secondary);
    border: 2px solid var(--secondary);
    padding: 0;
    width: 44px;
    height: 44px;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
}

.social-icons i:hover {
    background: var(--accent);
    color: var(--black);
    border-color: var(--accent);
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 4px 12px rgba(192, 202, 51, 0.4);
}

/* Footer copyright */
.footer-copyright {
    text-align: center;
    padding: 20px 0;
    background: var(--black);
}

.footer-copyright hr {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    width: 80%;
    margin: 0 auto 15px auto;
}

.footer-copyright p {
    margin: 0;
    opacity: 0.8;
    font-size: 0.85rem;
    color: var(--white);
}

/* Responsive */
@media (max-width: 1200px) {
    .serveis-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .valors-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero {
        height: 500px;
        margin-top: 88px;
        align-items: center;
        justify-content: center;
    }

    .hero-content {
        text-align: center;
        padding: 0 2rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-text h1 {
        font-size: 2rem;
        white-space: normal;
    }

    .hero-subtitle {
        font-size: 1.1rem;
        white-space: normal;
    }

    .hero-subtitle-2 {
        font-size: 1rem;
        white-space: normal;
    }

    .qui-soc-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-bottom: 2rem;
    }

    .qui-soc-image {
        margin: 0 auto;
        width: 220px;
        height: 280px;
    }

    .serveis-grid {
        grid-template-columns: 1fr;
    }

    .valors-grid {
        grid-template-columns: 1fr;
    }

    .valor-item {
        width: 260px;
        height: 260px;
        padding: 2rem 1.2rem;
    }

    /* Header amb menú hamburguesa */
    .header-container {
        flex-direction: row;
        justify-content: space-between;
        gap: 0;
    }

    .logo img {
        height: 55px;
    }

    /* Mostrar botó hamburguesa */
    .menu-toggle {
        display: flex;
    }

    /* Menú desplegable vertical */
    .nav-menu {
        position: fixed;
        top: 88px;
        left: 0;
        right: 0;
        background: var(--primary);
        flex-direction: column;
        gap: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
        z-index: 100;
    }

    /* Menú obert */
    .nav-menu.active {
        max-height: 500px;
        padding: 1rem 0;
    }

    /* Enllaços del menú */
    .nav-menu a {
        width: 100%;
        text-align: center;
        padding: 1rem 2rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        font-size: 1.1rem;
    }

    .nav-menu a:last-child {
        border-bottom: none;
    }

    .btn-agendar {
        margin: 0.5rem 1rem;
        width: calc(100% - 2rem);
        text-align: center;
    }

    /* Evitar scroll quan el menú està obert */
    body.menu-open {
        overflow: hidden;
    }

    .zona-info ul {
        columns: 1;
    }

    .contacte-methods {
        flex-direction: column;
        gap: 1.5rem;
    }

    section {
        padding: 40px 1.5rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }

    .footer-section {
        min-width: auto;
        text-align: center;
    }

    .footer-section h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .social-icons {
        justify-content: center;
    }

    .footer-bottom {
        padding: 30px 20px;
    }

    .btn {
        padding: 0.8rem 1.4rem;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .footer-area {
        margin-top: 40px;
    }

    .footer-section img {
        max-height: 60px;
    }

    .footer-section h4 {
        font-size: 1rem;
    }

    .footer-section p {
        font-size: 0.8rem;
    }
}