/* General Layout */
html, body {
    margin: 0;
    padding: 0;
    min-height: 100%;
}

body {
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    font-family: Arial, sans-serif;
    overflow-x: hidden;
}

.main-content {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 420px));
    justify-content: center;
    align-content: center;
    align-items: stretch;
    text-align: center;
    gap: 20px;
    width: min(100% - 32px, 980px);
    margin: 0 auto;
    padding: 24px 16px 40px;
    box-sizing: border-box;
}

footer {
    text-align: center;
    padding: 10px 16px;
    background-color: #3a3a3a;
    color: #616161;
    flex-shrink: 0;
}

/* Light and Dark Mode */
.light {
    background-color: #f2f4f7;
    color: #111827;
}

.dark {
    background-color: #282828;
    color: white;
}

/* Light Mode - Default */
.light .content-container {
    background-color: #ffffff;
    color: #111827;
    border: 1px solid #d8dee8;
    box-shadow: 0px 8px 24px rgba(17, 24, 39, 0.12);
}

.light footer {
    background-color: #f2f4f7;
    color: #374151;
}

.dark .content-container {
    background-color: #3a3a3a;
    color: white;
    border: 1px solid transparent;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.5);
}

.dark footer {
    background-color: #3a3a3a;
    color: #616161;
}

.light .examples-title {
    background-color: #ffffff;
    border: 1px solid #d8dee8;
    color: #111827;
    box-shadow: 0px 8px 24px rgba(17, 24, 39, 0.12);
}

.dark .examples-title {
    background-color: #3a3a3a;
    border: 1px solid transparent;
    color: #ffffff;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.5);
}

/* Dark/Light Mode Toggle */
.display-flex {
    position: fixed;
    top: max(10px, env(safe-area-inset-top));
    right: max(10px, env(safe-area-inset-right));
    z-index: 10;
}

.display-mode-container {
    background-color: #111827;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50px;
    height: 50px;
    border-radius: 10px;
    cursor: pointer;
    box-sizing: border-box;
    box-shadow: 0px 4px 14px rgba(17, 24, 39, 0.22);
}

.light .display-mode-container {
    background-color: #ffffff;
    border: 1px solid #d8dee8;
}

.dark .display-mode-container {
    background-color: #3f3f3f;
    border: 1px solid transparent;
}

.display-mode-container img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

/* Title */
.title-flex {
    text-align: center;
    margin: 0;
    padding: 68px 64px 8px;
}

.title-container {
    font-size: clamp(2rem, 5vw, 2.8rem);
    line-height: 1.2;
    margin: 0;
}

/* Content */
.content-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 100%;
    min-height: 146px;
    background-color: #3a3a3a;
    border-radius: 8px;
    padding: 20px;
    gap: 20px;
    box-sizing: border-box;
}

/* Left Column - Icon */
.app-icon{
    flex: 0 0 80px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.app-icon img{
    width: 80px;
    height: 80px;
    object-fit: contain;
}


/* Right Column - Content */
.content-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    min-width: 0;
}

.content-box h2 {
    font-size: clamp(1.25rem, 4vw, 1.5rem);
    line-height: 1.2;
    margin: 0;
}

.content-box p {
    font-size: 1rem;
    line-height: 1.35;
    margin: 0;
}

.light .content-box h2,
.light .content-box p {
    color: #111827;
}

.light .content-box p {
    color: #4b5563;
}

.dark .content-box h2 {
    color: #ffffff;
}

.dark .content-box p {
    color: #d3d3d3;
}

.cta-button {
    padding: 10px 20px;
    background-color: #2f8f46;
    color: #ffffff;
    text-decoration: none;
    border-radius: 20px;
    font-size: 1rem;
    line-height: 1.2;
    transition: background-color 0.3s;
    display: inline-block;
    white-space: nowrap;
}

.cta-button:hover {
    background-color: #237238;
}

.dark .cta-button {
    background-color: #8FCD84;
    color: #102016;
}

.dark .cta-button:hover {
    background-color: #76B76A;
}

.examples-section {
    grid-column: 1 / -1;
    width: 100%;
}

.examples-title {
    width: min(420px, 100%);
    margin: 0 auto;
    padding: 16px 20px;
    border-radius: 8px;
    box-sizing: border-box;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.2;
    list-style-position: inside;
    text-align: left;
}

.examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 420px));
    justify-content: center;
    gap: 20px;
    padding-top: 20px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .title-flex {
        padding: 72px 72px 8px 20px;
        text-align: left;
    }

    .main-content {
        grid-template-columns: 1fr;
        align-content: start;
        width: 100%;
        gap: 14px;
        padding: 18px 16px 32px;
    }

    .content-container {
        min-height: 132px;
        padding: 16px;
        gap: 16px;
    }

    .app-icon,
    .app-icon img {
        flex-basis: 64px;
        width: 64px;
        height: 64px;
    }

    .content-box {
        align-items: flex-start;
        text-align: left;
    }

    .examples-title {
        width: 100%;
    }

    .examples-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        padding-top: 14px;
    }
}

@media (max-width: 420px) {
    .display-mode-container {
        width: 44px;
        height: 44px;
    }

    .display-mode-container img {
        width: 26px;
        height: 26px;
    }

    .title-flex {
        padding-right: 64px;
    }

    .content-container {
        align-items: flex-start;
    }

    .app-icon,
    .app-icon img {
        flex-basis: 54px;
        width: 54px;
        height: 54px;
    }

    .cta-button {
        width: 100%;
        max-width: 180px;
        text-align: center;
        box-sizing: border-box;
    }
}

.hidden {
    display: none;
}

.active {
    display: flex;
}

