/* =============================================================
   Mergeable Apps — Shared Stylesheet
   Used by all apps.mergeable.io app pages and sub-pages
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,400;0,500;0,700;1,400&display=swap');

/* ----- Design tokens ----- */
:root {
    --mg-background: #FAFCF0;
    --mg-black:      #17333F;
    --mg-green:      #008D9D;
    --mg-green-dark: #01707e;
    --mg-yellow:     #EDAD5D;
    --mg-red:        #B65F7F;
    --mg-gray:       #383f42;
    --mg-gray-light: #d0dde2;
}

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

/* ----- Base ----- */
body {
    background-color: var(--mg-background);
    font-family: 'Roboto', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    color: var(--mg-black);
}

a {
    color: var(--mg-green);
    text-decoration: none;
}

a:hover {
    color: var(--mg-green-dark);
    text-decoration: underline;
}

/* ----- Page containers ----- */

/* Index / landing pages (wide) */
.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 24px;
    flex: 1;
}

/* Sub-pages: privacy, help, etc. (narrow) */
.page-container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 24px;
    flex: 1;
}

/* ----- App header ----- */
.header {
    text-align: center;
    margin-bottom: 48px;
}

.app-icon {
    width: 120px;
    height: 120px;
    border-radius: 26px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    margin: 0 auto 32px;
    display: block;
}

.title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
    color: var(--mg-black);
}

.tagline {
    font-size: 21px;
    font-weight: 500;
    color: var(--mg-black);
    margin-bottom: 16px;
}

.description {
    font-size: 17px;
    line-height: 1.6;
    color: var(--mg-gray);
    max-width: 700px;
    margin: 0 auto 32px;
}

/* ----- Lists inside description ----- */
ul {
    list-style-type: disc;
    padding-left: 20px;
    text-align: left;
    margin-top: 24px;
}

li {
    margin-bottom: 12px;
}

/* ----- Download buttons ----- */
.download-section {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.download-button {
    transition: opacity 0.2s ease;
}

.download-button:hover {
    opacity: 0.8;
}

.download-button img {
    height: 54px;
    width: auto;
}

/* ----- Screenshots / media ----- */
.images-container {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 38px;
}

.screenshot {
    width: 100%;
    max-width: 350px;
    height: auto;
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

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

.footer-text {
    font-size: 14px;
    color: rgba(250, 252, 240, 0.6);
}

.footer-text a {
    color: var(--mg-green);
    text-decoration: none;
}

.footer-text a:hover {
    color: var(--mg-green-dark);
    text-decoration: underline;
}

/* ----- Sub-page typography (privacy, help, etc.) ----- */
.page-container-narrow h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 32px;
    letter-spacing: -0.02em;
    color: var(--mg-black);
}

.page-container-narrow h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    margin-top: 32px;
    color: var(--mg-black);
}

.page-container-narrow p {
    font-size: 16px;
    line-height: 1.7;
    color: var(--mg-gray);
    margin-bottom: 24px;
}

.page-container-narrow ul {
    list-style-type: disc;
    padding-left: 24px;
    color: var(--mg-gray);
    line-height: 1.7;
    margin-bottom: 24px;
    text-align: left;
    margin-top: 0;
}

.page-container-narrow li {
    margin-bottom: 8px;
}

.back-link {
    display: inline-block;
    margin-bottom: 24px;
    font-size: 14px;
}

/* ----- Help page specifics ----- */
.help-section {
    border-bottom: 1px solid var(--mg-gray-light);
    padding-bottom: 16px;
    margin-bottom: 0;
}

.help-section summary {
    font-size: 18px;
    font-weight: 500;
    padding: 20px 0;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--mg-black);
}

.help-section summary::-webkit-details-marker {
    display: none;
}

.help-section summary::after {
    content: "+";
    font-size: 24px;
    font-weight: 300;
    color: var(--mg-gray-light);
    flex-shrink: 0;
    margin-left: 16px;
}

.help-section[open] summary::after {
    content: "−";
}

.help-content {
    padding-bottom: 24px;
}

.help-content ol {
    padding-left: 20px;
    color: var(--mg-gray);
    font-size: 16px;
    line-height: 1.7;
}

.help-content ol li {
    margin-bottom: 12px;
}

.help-content p {
    font-size: 16px;
    line-height: 1.7;
    color: var(--mg-gray);
    margin-bottom: 16px;
}

.tip-box {
    background-color: #e6f4f5;
    border-left: 4px solid var(--mg-green);
    padding: 12px 16px;
    border-radius: 4px;
    margin: 16px 0;
    font-size: 15px;
    color: var(--mg-black);
    line-height: 1.6;
}

.warning-box {
    background-color: #fef6e4;
    border-left: 4px solid var(--mg-yellow);
    padding: 12px 16px;
    border-radius: 4px;
    margin: 16px 0;
    font-size: 15px;
    color: var(--mg-black);
    line-height: 1.6;
}

/* ----- Responsive ----- */
@media (min-width: 900px) {
    .images-container {
        flex-wrap: nowrap;
    }

    .screenshot {
        width: calc(33.333% - 16px);
        max-width: none;
    }
}

@media (max-width: 600px) {
    .page-container,
    .page-container-narrow {
        padding: 40px 16px;
    }

    .app-icon {
        width: 100px;
        height: 100px;
        border-radius: 22px;
    }

    .title {
        font-size: 32px;
    }

    .tagline {
        font-size: 18px;
    }

    .description {
        font-size: 15px;
    }

    .screenshot {
        border-radius: 16px;
    }

    .page-container-narrow h1 {
        font-size: 24px;
    }

    .help-section summary {
        font-size: 16px;
    }
}
