*,
*::before,
*::after {
    box-sizing: border-box; }
@media (prefers-reduced-motion: no-preference) {
    :root {
        scroll-behavior: smooth; }
}

body {
    margin: 0;
    font-size: 1rem;
    font-weight: 400;
    font-family: 'Microsoft JhengHei';
    color: #5a5a5a;
    background-color: #F7E8C7; /* #cef1ff  #f5dbec */
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

.wrapper {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0 auto;
    background-color: #f2f2f7;

    & header {
        background-color: #ffffff;
        padding: 24px;
    }

    & main {
        flex-grow: 1;
        display: flex;
        padding: 24px;
    }
}

.title {
    font-size: 2.25rem;
    color: #262626;
    font-weight: 700;
    margin: 20px 0;

    &:has(+.sub-title) {
        margin-bottom: 8px;
    }
}

.sub-title {
    font-size: 1.125rem;
}

.custom-center {
    width: 100%;
    margin-left: auto;
    margin-right: auto;

    &:has(.entry) {
        margin: auto;
    }
}

.entry {
    display: flex;
    flex-direction: column;
}

.entry-item {
    position: relative;
    width: 100%;
    border-radius: 12px;
    background-color: white;
    text-decoration: none;
    /* text-align: center; */
    padding: 1rem;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
    white-space: nowrap;

    color: #262626;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.25);

    overflow: hidden;

    &:visited {
        color: inherit;
    }

    &:not(:last-child) {
        margin-bottom: 1.5vh;
    }

    &::before {
        position: absolute;
        content: "";
        left: 0px;
        bottom: calc(50% - (52px / 2));
        width: 8px;
        height: 52px;
        transition: height 0.25s ease;
        z-index: 1;
    }

    &::after {
        position: absolute;
        content: "";
        left: 0px;
        bottom: 0;
        width: 8px;
        height: 50%;
    }

    &:hover::before {
        height: calc(50% + (52px / 2));
    }

    &:first-child::before {
        background-color: #f09e4a;
    }

    &:nth-child(2)::before {
        background-color: #c69aad;
    }

    &:last-child::before {
        background-color: #a6be96;
    }

    &:first-child::after {
        background-color: #f5f1f0;
    }

    &:nth-child(2)::after {
        background-color: #f6f2f7;
    }

    &:last-child::after {
        background-color: #f5f1f0;
    }
}

.entry-item:first-child .fake-btn {
    color: #ffffff;
    background-color: #f09e4a;
    border: 1px solid #f09e4a;
}
.entry-item:nth-child(2) .fake-btn {
    color: #ffffff;
    background-color: #c69aad;
    border: 1px solid #c69aad;
}
.entry-item:last-child .fake-btn {
    color: #ffffff;
    background-color: #a6be96;
    border: 1px solid #a6be96;
}


.entry-item .text {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    display: inline;
    white-space: initial;
    width: 240px;
}

.entry-item .img-region {
    display: inline-flex;
    padding: 4px;
    background-color: rgba(255, 255, 255, 0.87);
    border-radius: 4px;
    /* min-width: 102.3px; */
    width: 102.3px;
    flex-grow: 1;
    margin-left: auto;
}

.entry-item .img {
    width: 100%;
    border-radius: 2px;
}

.fake-btn-region {
    padding: 4px;
    width: 100%;

    & .fake-btn {
        font-size: 1.5rem;
        font-weight: 700;

        text-align: center;
        border-radius: 8px;
        padding: 8px 4px;
        margin-top: 12px;
    }
}

.footer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background-color: #f0f0f5;
    border-top: 2px solid #fff;
    padding: 24px;
    z-index: 1;

    &  .item {
        display: flex;
        align-items: center;
        justify-content: end;

        & img {
            min-width: 148px;
            width: 148px;
        }
    }
}

@media (min-width: 512px) {
    .title {
        font-size: 3rem;
    
        & .icon-logo-pic {
            height: 64px;
            min-height: 64px;
            margin-right: -4px;
        }
    }
    .entry-item .text {
        font-size: 2rem;
        width: 320px;
        text-align: center;
    }
}

@media (min-width: 576px) {
    .custom-center{
        max-width: 540px;
    }
}

@media (min-width: 768px) {
    .custom-center {
        max-width: 720px;
    }
    .entry {
        flex-direction: row; }
    .entry-style-2 {
        justify-content: center; }
    .entry-item {
        flex-direction: column;
        align-items: center;
        max-width: 541.69px; }
    .entry-item .text {
        font-size: 1.75rem;
        display: flex;
        flex-direction: column;
        text-align: center;
        justify-content: center;
        margin-bottom: 12px;
        width: unset;
    }
    .entry-item:not(:last-child) {
        margin-right: 2vw;
        margin-bottom: 0; }
    .entry-item .img-region {
        padding: 6px;
        border-radius: 6px;
        width: 100%;
        margin-top: auto; }
    .entry-item .img {
        width: 100%;
        border-radius: 3px; }

    .fake-btn-region {
        padding: 6px;

        & .fake-btn {
            border-radius: 6px;
        }
    }
}

@media (min-width: 992px) {
    .custom-center {
        max-width: 960px; }
    .entry-item .text {
        line-height: 1.3; }
    .entry-item .img-region {
        padding: 8px;
        border-radius: 8px; }
    .entry-item .img {
        border-radius: 4px; }
    
    .fake-btn-region {
        padding: 8px;

        & .fake-btn {
            border-radius: 8px;
        }
    }
}

@media (min-width: 1200px) {
    .custom-center {
        max-width: 1140px;
    }
    .entry-item .text {
        flex-direction: row; }
}

@media (min-width: 1400px) {
    .custom-center {
        max-width: 1320px;
    }
}



/* 沒套 bs 時，常用排版項目 */
.d-flex {
    display: flex !important; }
.align-items-stretch {
    align-items: stretch !important; }
.align-items-center {
    align-items: center !important; }
.align-content-center {
    align-content: center !important; }
.text-center {
    text-align: center !important; }
@media (min-width: 768px) {
    .text-md-center {
        text-align: center !important; }
}