/* =============================================
   MOBILE-FIRST STYLES
   Base = mobile, then scale up with min-width
   ============================================= */

/* === Reset & Variables === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --coral: #F06449;
    --coral-light: #FF8A73;
    --teal: #1A535C;
    --teal-light: #4ECDC4;
    --sun: #FFE066;
    --dark: #1a1a2e;
    --text: #3d3d5c;
    --bg: #fbfcfd;
    --cream: #faf0dc;
    --azure: #e2f1fa;
    --peach: #fcf0eb;
    --blush: #fbe5e1;
    --white: #FFFFFF;
    --gray: #5e5e73;
    --radius: 12px;
    --shadow: 0 4px 24px rgba(26,26,46,.06);
}

html { scroll-behavior: smooth; }

/* === Skip link (accessibility) === */
.skip-link {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--coral);
    color: var(--white);
    padding: .6rem 1.5rem;
    border-radius: 0 0 var(--radius) var(--radius);
    font-weight: 700;
    font-size: .85rem;
    z-index: 200;
    transition: top .2s;
}
.skip-link:focus {
    top: 0;
    color: var(--white);
}

/* === Focus styles (accessibility) === */
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--coral);
    outline-offset: 2px;
}

/* === Reduced motion === */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    html { scroll-behavior: auto; }
}

body {
    font-family: 'DM Sans', 'Segoe UI', sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.75;
    font-size: 15px;
}

a { color: var(--coral); text-decoration: none; transition: color .25s; }
a:hover { color: var(--teal-light); }
img { max-width: 100%; height: auto; display: block; }
main { margin-top: 5.5rem; }

/* === Navigation (mobile base) === */
nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    background: rgba(251,252,253,.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 100;
    border-bottom: 1px solid rgba(0,0,0,.04);
}
nav .nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: .8rem 1.2rem;
}
nav .logo {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-weight: 700;
    font-size: 1rem;
    color: var(--dark);
    letter-spacing: -.3px;
}
nav .logo img {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    object-fit: cover;
}
.logo-text {
    display: none;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: .8rem;
}

/* Language toggle */
.lang-toggle {
    display: flex;
    gap: .3rem;
    background: rgba(0,0,0,.04);
    border-radius: 50px;
    padding: .2rem;
}
.lang-toggle a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    min-height: 36px;
    padding: .25rem .6rem;
    font-size: .72rem;
    font-weight: 700;
    color: var(--gray);
    border-radius: 50px;
    transition: background .2s, color .2s;
    letter-spacing: .5px;
}
.lang-toggle a.active {
    background: var(--coral);
    color: var(--white);
}
.lang-toggle a:hover:not(.active) {
    color: var(--dark);
}

nav ul {
    display: none;
    list-style: none;
    width: 100%;
    flex-direction: column;
    padding: .8rem 0 .4rem;
    gap: .6rem;
}
nav ul.open { display: flex; }
nav ul li a {
    display: inline-block;
    color: var(--text);
    font-size: .82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .8px;
    transition: color .25s;
    position: relative;
    padding: .5rem 0;
}
nav ul li a:hover { color: var(--coral); }

/* Hamburger (visible on mobile by default) */
.hamburger {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    padding: .5rem;
}
.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--dark);
    margin: 5px 0;
    border-radius: 1px;
    transition: .3s;
}

/* === Sections (mobile base) === */
section {
    padding: 3rem 1.2rem 2rem;
}

/* Section backgrounds — soft gradients flowing into each other */
#home          { background: linear-gradient(180deg, var(--bg) 0%, var(--cream) 100%); }
#despre        { background: linear-gradient(180deg, var(--cream) 0%, var(--azure) 100%); }
#proiecte      { background: linear-gradient(180deg, var(--azure) 0%, var(--peach) 100%); }
#doneaza       { background: linear-gradient(180deg, var(--peach) 0%, var(--blush) 100%); }
#parteneri     { background: linear-gradient(180deg, var(--blush) 0%, var(--bg) 100%); }
#beneficiari   { background: linear-gradient(180deg, var(--bg) 0%, var(--cream) 100%); }
#contact       { background: linear-gradient(180deg, var(--cream) 0%, var(--bg) 100%); }

.section-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: .5rem;
    color: var(--dark);
    letter-spacing: -.3px;
}
.section-accent {
    display: inline-block;
    width: 36px;
    height: 3px;
    background: linear-gradient(90deg, var(--coral), var(--sun));
    border-radius: 2px;
    margin-bottom: 1.2rem;
}
.section-subtitle {
    font-size: .95rem;
    color: var(--gray);
    margin-bottom: 2rem;
}

/* === Hero (mobile base) === */
.hero-wrap {
    background: linear-gradient(135deg, var(--teal) 0%, #2d6a6a 50%, var(--teal-light) 100%);
    min-height: 40vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 2rem 1.2rem;
}
.hero-wrap::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: var(--sun);
    opacity: .08;
    border-radius: 50%;
}
.hero-wrap::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 350px;
    height: 350px;
    background: var(--coral);
    opacity: .1;
    border-radius: 50%;
}
.hero {
    text-align: center;
    padding: 1rem 1.2rem;
    position: relative;
    z-index: 1;
}
.hero h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.15;
    color: var(--white);
    letter-spacing: -.5px;
}
.hero h1 .hero-accent {
    color: var(--sun);
}
.hero .motto {
    font-size: 1rem;
    color: rgba(255,255,255,.85);
    margin-bottom: 2rem;
}
.hero .cta {
    display: inline-block;
    background: var(--coral);
    color: var(--white);
    padding: .85rem 2rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: .9rem;
    letter-spacing: .3px;
    transition: transform .25s, box-shadow .25s;
    box-shadow: 0 4px 16px rgba(240,100,73,.3);
}
.hero .cta:hover {
    color: var(--white);
    transform: translateY(-3px);
    box-shadow: 0 8px 28px rgba(240,100,73,.35);
}

/* Wave */
.wave-divider { margin-top: -2px; line-height: 0; }
.wave-divider svg { display: block; width: 100%; height: auto; }

/* === Grids (mobile: single column) === */
.home-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
}

.cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.2rem;
    margin-top: 1.2rem;
}

.stories {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.2rem;
    margin-top: 1.2rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.2rem;
    margin-top: 1.2rem;
}

/* === Cards === */
.info-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    border-top: 3px solid transparent;
    transition: border-color .3s, transform .25s;
}
.info-card:hover {
    border-top-color: var(--coral);
    transform: translateY(-2px);
}
.info-card h3 {
    font-size: .95rem;
    font-weight: 700;
    color: var(--teal);
    margin-bottom: .4rem;
}
.info-card p { color: var(--gray); font-size: .9rem; }

.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
    transition: transform .25s, box-shadow .25s;
}
.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 3px;
    background: linear-gradient(90deg, var(--coral), var(--teal-light));
}
.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(26,26,46,.1);
}
.card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    border-radius: 10px;
    font-size: 1.3rem;
    margin-bottom: .8rem;
}
.card-icon.coral { background: rgba(240,100,73,.1); }
.card-icon.teal  { background: rgba(78,205,196,.1); }
.card-icon.sun   { background: rgba(255,224,102,.15); }

.card h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: .4rem;
    color: var(--dark);
}
.card p { color: var(--gray); font-size: .9rem; }

.btn-pill {
    display: inline-block;
    margin-top: 1rem;
    padding: .55rem 1.3rem;
    border: 2px solid var(--coral);
    border-radius: 50px;
    color: var(--coral);
    font-weight: 700;
    font-size: .78rem;
    letter-spacing: .3px;
    transition: background .25s, color .25s;
}
.btn-pill:hover { background: var(--coral); color: var(--white); }
.btn-pill.teal { border-color: var(--teal); color: var(--teal); }
.btn-pill.teal:hover { background: var(--teal); color: var(--white); }

/* === Donate highlight === */
.donate-highlight {
    background: linear-gradient(135deg, var(--blush) 0%, #fff 100%);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(240,100,73,.12);
    text-align: center;
}
.donate-highlight h3 {
    color: var(--coral);
    font-size: 1.15rem;
    margin-bottom: .4rem;
}
.donate-highlight p {
    color: var(--gray);
    font-size: .9rem;
}

/* === Partners === */
.partners-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    margin-top: 2rem;
}
.partner-logo {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.2rem 1.6rem;
    box-shadow: var(--shadow);
    font-weight: 700;
    color: var(--gray);
    font-size: .9rem;
    transition: transform .25s, box-shadow .25s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.partner-logo:hover {
    transform: scale(1.06);
    box-shadow: 0 8px 28px rgba(26,26,46,.08);
}
.partner-logo img {
    max-width: 140px;
    max-height: 60px;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* === Stories === */
.story {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--teal-light);
    transition: transform .25s;
}
.story:hover { transform: translateY(-2px); }
.story h3 {
    margin-bottom: .4rem;
    font-size: 1rem;
    color: var(--dark);
}
.story p { color: var(--gray); font-size: .9rem; }
.story .tag {
    display: inline-block;
    margin-top: .6rem;
    padding: .2rem .7rem;
    background: rgba(78,205,196,.1);
    color: var(--teal);
    border-radius: 50px;
    font-size: .72rem;
    font-weight: 700;
}

/* === Contact cards === */
.contact-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform .25s;
}
.contact-card:hover { transform: translateY(-2px); }
.contact-card .contact-icon { font-size: 1.5rem; margin-bottom: .6rem; }
.contact-card h3 {
    font-size: .9rem;
    font-weight: 700;
    color: var(--teal);
    margin-bottom: .3rem;
}
.contact-card p { color: var(--gray); font-size: .85rem; }

/* === Footer === */
footer {
    background: var(--dark);
    color: rgba(255,255,255,.72);
    padding: 2rem 1.2rem;
    font-size: .8rem;
}
footer .footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}
footer a { color: rgba(255,255,255,.72); }
footer a:hover { color: var(--white); }

.footer-links {
    display: flex;
    flex-direction: column;
    gap: .4rem;
}

.social-links {
    display: flex;
    gap: .8rem;
}
.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px; height: 36px;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 50%;
    font-size: .85rem;
    transition: border-color .25s, color .25s, background .25s;
}
.social-links a:hover {
    border-color: var(--coral);
    color: var(--coral);
    background: rgba(240,100,73,.08);
}

/* =============================================
   TABLET  (min-width: 600px)
   ============================================= */
@media (min-width: 600px) {
    body { font-size: 16px; }

    section { padding: 4rem 1.5rem 3rem; }
    .page-header { padding: 2.5rem 1.5rem 1.5rem; }
    .page-section { padding: 2.5rem 1.5rem; }

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

    .home-grid     { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
    .cards         { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
    .stories       { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
    .contact-grid  { grid-template-columns: 1fr 1fr 1fr; gap: 1.5rem; }

    .hero h1 { font-size: 2.6rem; }
    .hero { padding: 1rem 2rem; }

    .info-card, .card { padding: 2rem; }

    .donate-highlight { padding: 2rem; }
    .donate-highlight h3 { font-size: 1.25rem; }

    .logo-text { display: inline; }

    .partner-logo img { max-width: 160px; max-height: 70px; }

    .footer-inner { flex-direction: row; justify-content: space-between; text-align: left; }
    .footer-links { flex-direction: row; gap: 1.5rem; }
}

/* =============================================
   DESKTOP (min-width: 960px)
   ============================================= */
@media (min-width: 960px) {
    section {
        padding: 5rem 2rem 4rem;
        max-width: 1140px;
        margin: 0 auto;
    }
    .page-header { padding: 3rem 2rem 2rem; }
    .page-section { padding: 3rem 2rem; }

    .section-title { font-size: 2.2rem; letter-spacing: -.5px; }
    .section-accent { width: 40px; height: 4px; margin-bottom: 1.5rem; }
    .section-subtitle { font-size: 1.05rem; margin-bottom: 2.5rem; }

    /* Nav: show full menu, hide hamburger */
    .hamburger { display: none; }
    nav .nav-inner {
        max-width: 1140px;
        margin: 0 auto;
        padding: .9rem 2rem;
        flex-wrap: nowrap;
    }
    nav .logo { font-size: 1.15rem; }
    nav .logo img { width: 60px; height: 60px; }
    nav ul {
        display: flex;
        width: auto;
        flex-direction: row;
        gap: 1.8rem;
        padding: 0;
    }
    nav ul li a::after {
        content: '';
        position: absolute;
        bottom: -4px;
        left: 0; right: 0;
        height: 2px;
        background: var(--coral);
        transform: scaleX(0);
        transition: transform .25s;
        border-radius: 1px;
    }
    nav ul li a:hover::after { transform: scaleX(1); }

    /* Hero */
    .hero-wrap { min-height: 50vh; }
    .hero-wrap::before { width: 600px; height: 600px; }
    .hero-wrap::after  { width: 500px; height: 500px; }
    .hero {
        max-width: 760px;
        padding: 1rem 2rem;
    }
    .hero h1 { font-size: 3.2rem; letter-spacing: -.8px; }
    .hero .motto { font-size: 1.15rem; }
    .hero .cta { padding: .95rem 2.5rem; font-size: .95rem; }

    /* Cards */
    .cards { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
    .stories { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
    .contact-grid { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

    .card { padding: 2.2rem; }
    .card-icon { width: 48px; height: 48px; font-size: 1.4rem; border-radius: 12px; margin-bottom: 1rem; }
    .card h3 { font-size: 1.1rem; }

    .story { padding: 2rem; }
    .contact-card { padding: 2rem; }

    .donate-highlight { padding: 2.5rem; }
    .donate-highlight h3 { font-size: 1.3rem; }
    .donate-highlight p { max-width: 500px; margin: 0 auto; }

    .partner-logo { padding: 1.4rem 2.2rem; font-size: .95rem; }
    .partner-logo img { max-width: 180px; max-height: 80px; }

    footer { padding: 2.5rem 2rem; font-size: .83rem; }
    footer .footer-inner { max-width: 1140px; margin: 0 auto; }
}

/* === CMS Content: responsive tables === */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* === CMS Content: page header for inner pages === */
.page-header { text-align: center; padding: 2rem 1.2rem 1.5rem; max-width: 1140px; margin: 0 auto; }
.page-header .section-title { font-size: 1.6rem; color: var(--teal); }
.page-header .section-accent { width: 60px; height: 3px; background: var(--coral); margin: .6rem auto 0; border-radius: 2px; }

/* === CMS Content: inner page sections === */
.page-section { padding: 2rem 1.2rem; max-width: 1140px; margin: 0 auto; }
.page-section + .page-section { border-top: 1px solid rgba(0,0,0,.06); }
.page-section h2 { font-size: 1.4rem; color: var(--teal); margin-bottom: 1rem; }
.page-section h3 { font-size: 1.1rem; color: var(--teal); margin: 1.2rem 0 .5rem; }
.page-section p { margin-bottom: .8rem; line-height: 1.7; color: var(--text); }
.page-section ul { margin: .5rem 0 1rem 1.5rem; }
.page-section li { margin-bottom: .4rem; line-height: 1.6; color: var(--text); }

/* Action areas (Despre page) */
.action-areas { margin-top: 1rem; }
.action-item { display: flex; gap: .8rem; align-items: flex-start; margin-bottom: .8rem; padding: .8rem; background: var(--bg); border-radius: var(--radius); }
.action-icon { font-size: 1.2rem; flex-shrink: 0; }
.action-item p { margin: 0; }

/* Impact list */
.impact-list { list-style: none; margin-left: 0; padding: 0; }
.impact-list li { padding: .4rem 0 .4rem 1.8rem; position: relative; }
.impact-list li::before { content: '✔'; position: absolute; left: 0; color: var(--teal); font-weight: 700; }

/* Testimonials */
.testimonials { display: grid; gap: 1rem; margin-top: 1rem; }
.testimonials blockquote { background: var(--bg); border-left: 3px solid var(--coral); padding: 1rem 1.2rem; margin: 0; border-radius: 0 var(--radius) var(--radius) 0; font-style: italic; color: var(--text); line-height: 1.6; }
.testimonials blockquote::before { content: '💬 '; }

/* Story card (Beneficiari page) */
.story-card { background: var(--bg); border-left: 3px solid var(--teal); border-radius: 0 var(--radius) var(--radius) 0; padding: 1.5rem; margin-top: 1.5rem; }
.story-card h3 { color: var(--teal); margin-bottom: .5rem; }
.story-quote { font-size: 1.15rem; color: var(--coral); margin-bottom: 1rem; }
.story-note { font-size: .85rem; color: var(--gray); margin-top: 1rem; }

/* Donate page specifics */
.donate-cta-text { text-align: center; font-size: 1.1rem; margin-top: 1rem; }
.donate-final { text-align: center; }

@media (min-width: 768px) {
    .testimonials { grid-template-columns: 1fr 1fr 1fr; }
    .page-section h2 { font-size: 1.6rem; }
}
