/* ==================== iOS POLISH - GLOBAL STYLES ==================== */

/* Global box-sizing reset - prevents width overflow */
*, *::before, *::after {
    box-sizing: border-box;
}

/* Ensure screens don't overlap during transitions */
section[id$="-screen"],
section#plant-info {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

:root {
    --safe-area-top: env(safe-area-inset-top, 0px);
    --safe-area-bottom: env(safe-area-inset-bottom, 0px);
    --safe-area-left: env(safe-area-inset-left, 0px);
    --safe-area-right: env(safe-area-inset-right, 0px);
    
    /* iOS-style spring easing */
    --ios-ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ios-spring: cubic-bezier(0.175, 0.885, 0.32, 1.275);
    --ios-decel: cubic-bezier(0, 0, 0.2, 1);
    
    /* Consistent border radius */
    --radius-sm: 6px;
    --radius-md: 9px;
    --radius-lg: 14px;
    --radius-xl: 20px;
    
    /* Colors */
    --color-bg: #302231;
    --color-card: #19101A;
    --color-cream: #FCF0D9;
    --color-green: #95DB59;
    --color-muted: #6F5D71;
}

html {
    margin: 0;
    padding: 0;
    overflow: hidden;
    overflow-x: hidden;
    height: 100vh;
    height: 100dvh;
    width: 100%;
    max-width: 100vw;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--color-bg);
    overflow: hidden;
    overflow-x: hidden;
    height: 100vh;
    height: 100dvh;
    width: 100%;
    max-width: 100vw;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    overscroll-behavior: none;
}

/* iOS-style button press states */
button, .btn, [role="button"] {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    transition: transform 0.1s var(--ios-ease), opacity 0.1s var(--ios-ease);
    cursor: pointer;
}

button:active, .btn:active, [role="button"]:active {
    transform: scale(0.97);
    opacity: 0.9;
}

/* Smooth momentum scrolling */
.scrollable, [class*="overflow-y-scroll"], [style*="overflow-y: scroll"] {
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
}

/* Better focus states */
button:focus-visible, input:focus-visible, select:focus-visible {
    outline: 2px solid var(--color-green);
    outline-offset: 2px;
}

/* Disable text selection on interactive elements */
button, .plant-card, .reminder-card, .day-reminder-card {
    -webkit-user-select: none;
    user-select: none;
}

.dm-light {
  font-family: "DM Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
}

.dm-reg {
  font-family: "DM Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

.dm-xtra {
  font-family: "DM Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 800;
  font-style: normal;
}

.dm-black {
  font-family: "DM Sans", sans-serif;
  font-optical-sizing: auto;
  font-weight: 900;
  font-style: normal;
}

.sherika {
    font-family: 'Sherika', sans-serif;
}


@media (max-width: 460px) {
    #load-screen {
        display: grid;
        grid-template-columns: 100%;
        grid-template-rows: 1fr min-content min-content;
        justify-items: center;

        width: 100vw;
        height: 100vh;
        opacity: 1;
        transition: all 0.7s ease;
        div {
            width: 93%;
            min-height: 160px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            /* gap: 14px; */
            margin-bottom: 50px;
            transition: all 1s ease;
        }
    }
    #leaf-bg-svg {
        /* margin-top: 80px; */
        width: 100vw;
        height: auto;
    }
    #canopy-text-svg {
        width: 100%;
        height: auto;
        padding-bottom: 0px;
        transition: all 0.7s ease;
        transform: translateY(0);
    }
    #start-btn {
        display: block;
        opacity: 0;
        transform: translateY(20px);
        transition: all 0.5s ease;
    }
    .logo-up #canopy-text-svg {
        transform: translateY(-15px);
    }
    .logo-up #start-btn {
        opacity: 1;
        transform: translateY(0);
    }
    .maroon-btn {
        width: 100%;
        border-radius: 9px;
        background-color: #19101A;
        border: none;
        color: #FCF0D9;
        width: 100%;
        height: 60px;
        #get-started {
            font-size: 24px;
            padding: 0;
            margin: 0;
        }
    }
    .maroon-btn:active {
        background-color: #95DB59;
        color: #19101A;
    }
    #title-bar {
        display: none;
        grid-template-columns: 1fr 1fr 1fr;
        align-items: center;
        padding: 0px 30px 0 30px;
        padding-top: var(--safe-area-top);
        color: var(--color-cream);
        opacity: 0;
        transition: opacity 0.3s var(--ios-ease);
        #grid-btn {
            background: transparent;
            border: none;
            width: min-content;
            justify-self: start;
            .grid-svg {
                width: 20px;
            }
        }
        h1 {
            justify-self: center;
            font-size: 30px;
            padding: 0;
            margin: 0;
        }
        #gear-btn {
            background: transparent;
            border: none;
            width: min-content;
            justify-self: end;
            .gear-svg {
                width: 20px;
            }
        }
    }
    #home-screen {
        display: none;
        /* height: calc(100dvh - 100px - var(--safe-area-top)); */
        margin: 0 30px;
        padding-bottom: var(--safe-area-bottom);
        opacity: 0;
        transition: opacity 0.3s var(--ios-ease);
        overflow-y: hidden;
        overflow-x: hidden;
        max-width: calc(100vw - 60px);
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    #home-screen::-webkit-scrollbar {
        display: none;
    }

    #home-screen #reminders-home {
            width: 100%;
            display: grid;
            grid-template-columns: 1fr min-content;
            grid-template-rows: 1fr min-content;
            column-gap: 6px;
            row-gap: 8px;
            #recent-reminders {
                anchor-name: --recent-reminders;
                display: flex;
                width: 100%;
                flex-direction: column;
                gap: 6px;
                height: 180px;
                grid-column: 1 / -1;
                grid-row: 1;
                margin-top: 10px;
                overflow-y: scroll;
                scrollbar-width: none;
                h2 {
                    font-size: 13px;
                    color: #FCF0D9;
                    margin: 0;
                    padding: 0;
                }
                .reminder-card {
                    height: 50px;
                    width: 100%;
                    background-color: #19101A;
                    display: grid;
                    grid-template-columns: min-content 1fr min-content;
                    grid-template-rows: 1fr 1fr;
                    column-gap: 8px;
                    border-radius: 9px;
                    img {
                        height: 42px;
                        width: auto;
                        aspect-ratio: 1 / 1;
                        object-fit: cover;
                        grid-column: 1;
                        grid-row: 1 / -1;
                        border-radius: 6px;
                        margin-left: 4px;
                        align-self: center;
                        justify-self: start;
                    }
                    h1 {
                        grid-column: 2;
                        grid-row: 1;
                        color: #FCF0D9;
                        margin: 0;
                        padding: 0;
                        justify-self: start;
                        align-self: end;
                        margin-bottom: -6px;
                        font-size: 25px;
                    }
                    p {
                        grid-column: 2;
                        grid-row: 2;
                        color: #95DB59;
                        margin: 0;
                        padding: 0;
                        justify-self: start;
                        align-self: start;
                    }
                    div {
                        grid-column: 3;
                        grid-row: 1 / -1;
                        width: 42px;
                        height: 50px;
                        display: grid;
                        .checkbox-wrapper {
                            display: inline-flex;
                            align-items: center;
                            cursor: pointer;
                            position: relative;
                        }

                        .checkbox-wrapper input[type="checkbox"] {
                            position: absolute;
                            opacity: 0;
                            width: 0;
                            height: 0;
                        }

                        .custom-box {
                            align-self: center;
                            justify-self: center;
                            width: 30px;
                            height: 30px;
                            background: #302231;
                            border-radius: 6px;
                            display: flex;
                            align-items: center;
                            justify-content: center;
                            position: relative;
                            transition: background 0.2s ease;
                        }

                        .custom-box svg {
                            position: absolute;
                            margin-right: -12px;
                            margin-top: -5px;
                            width: 28px;
                            height: 28px;
                            fill: none;
                            stroke: white;
                            stroke-width: 3;
                            stroke-linecap: round;
                            stroke-linejoin: round;
                            opacity: 0;
                            transform: scale(0.8);
                            transition: opacity 0.2s ease, transform 0.2s ease;
                        }

                        .checkbox-wrapper input[type="checkbox"]:checked + .custom-box svg {
                            opacity: 1;
                            transform: scale(1);
                        }
                    }
                }
            }
            #all-reminders-btn {
                height: 42px;
                border-radius: 9px;
                background-color: #19101A;
                border: none;
                color: #FCF0D9;
                grid-column: 1;
                grid-row: 2;
                p {
                    font-size: 21px;
                    padding: 0;
                    margin: 0;
                }
            }
            #add-reminder-btn {
                display: flex;
                align-items: center;
                justify-content: center;
                height: 42px;
                width: 42px;
                background-color: #19101A;
                border: none;
                border-radius: 9px;
                grid-column: 2;
                grid-row: 2;
                svg {
                    width: 18px;
                }
            }
        }
        #plants-home {
            display: grid;
            grid-template-columns: 1fr 1fr;
            grid-template-rows: auto auto;
            column-gap: 10px;
            row-gap: 10px;
            padding-top: 14px;
            .plant-card {
                display: grid;
                grid-template-columns: 1fr;
                grid-template-rows: min-content min-content 1fr;
                width: 100%;
                max-height: 230px;
                border-radius: 9px;
                background-color: #FCF0D9;
                h1 {
                    justify-self: start;
                    align-self: center;
                    margin: 0;
                    padding: 0;
                    font-size: 34px;
                    color: #302231;
                    margin: 6px 0 0 7px;
                }
                p {
                    justify-self: start;
                    align-self: center;
                    margin: 0;
                    margin-top: -7px;
                    padding: 0;
                    font-size: 12px;
                    color: #6F5D71;
                    margin-left: 7px;
                    padding-bottom: 5px;
                }
                img {
                    width: calc(100% - 6px);
                    height: 166px;
                    object-fit: cover;
                    justify-self: center;
                    align-self: end;
                    border-radius: 6px;
                    margin-bottom: 3px;
                }
            }
            .template-card {
                opacity: 0;
            }
            .plant-btns {
                display: grid;
                grid-template-columns: 1fr min-content;
                grid-template-rows: 1fr min-content;
                column-gap: 6px;
                row-gap: 10px;
                #plant-number-card {
                    width: 100%;
                    height: 100%;
                    display: grid;
                    grid-template-columns: 1fr;
                    grid-template-rows: 1fr;
                    width: 100%;
                    border-radius: 9px;
                    background-color: #FCF0D9;
                    grid-column: 1 / -1;
                    grid-row: 1;
                    img {
                        width: calc(100% - 6px);
                        height: 172px;
                        object-fit: cover;
                        justify-self: center;
                        align-self: center;
                        border-radius: 6px;
                        margin-left: 0px;
                        z-index: 1;
                        grid-column: 1;
                        grid-row: 1;
                    }
                    #plant-number-overlay {
                        background-color: #19101aa9;
                        width: calc(100% - 6px);
                        height: 172px;
                        justify-self: center;
                        align-self: center;
                        border-radius: 6px;
                        margin-left: 0px;
                        display: grid;
                        z-index: 2;
                        grid-column: 1;
                        grid-row: 1;
                        border: none;
                        h1 {
                            align-self: center;
                            justify-self: center;
                            margin: 0;
                            padding: 0;
                            font-size: 34px;
                            color: #FCF0D9;
                        }
                    }
                }
                #all-plants-btn {
                    height: 42px;
                    border-radius: 9px;
                    background-color: #FCF0D9;
                    border: none;
                    color: #19101A;
                    grid-column: 1;
                    grid-row: 2;
                    p {
                        font-size: 21px;
                        padding: 0;
                        margin: 0;
                        text-wrap: nowrap;
                    }
                }
                #add-plants-btn {
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    height: 42px;
                    width: 42px;
                    background-color: #95DB59;
                    border: none;
                    border-radius: 9px;
                    grid-column: 2;
                    grid-row: 2;
                    svg {
                        width: 18px;
                    }
                }
            }
        }
    }
    #plant-screen {
        display: none;
        margin: 0 30px;
        opacity: 0;
        transition: opacity 0.3s var(--ios-ease);
        height: calc(100dvh - 97px - var(--safe-area-top));
        padding-bottom: var(--safe-area-bottom);
        overflow-y: scroll;
        overflow-x: hidden;
        max-width: calc(100vw - 60px);
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        #plants-list {
            display: grid;
            grid-template-columns: 1fr 1fr;
            grid-template-rows: min-content;
            column-gap: 10px;
            row-gap: 10px;
            padding-top: 14px;
            padding-bottom: 20px;
            .plant-card {
                display: grid;
                grid-template-columns: 1fr;
                grid-template-rows: min-content min-content 1fr;
                width: 100%;
                max-height: 230px;
                border-radius: 9px;
                background-color: #FCF0D9;
                h1 {
                    justify-self: start;
                    align-self: center;
                    margin: 0;
                    padding: 0;
                    font-size: 34px;
                    color: #302231;
                    margin: 6px 0 0 7px;
                }
                p {
                    justify-self: start;
                    align-self: center;
                    margin: 0;
                    margin-top: -7px;
                    padding: 0;
                    font-size: 12px;
                    color: #6F5D71;
                    margin-left: 7px;
                    padding-bottom: 5px;
                }
                img {
                    width: calc(100% - 6px);
                    height: 166px;
                    object-fit: cover;
                    justify-self: center;
                    align-self: end;
                    border-radius: 6px;
                    margin-bottom: 3px;
                }
            }
        }
        #all-plant-bottom {
            position: absolute;
            bottom: 0;
            left: 0;
            width: 100%;
            height: 46px;
            background: #302231;
            background: linear-gradient(180deg, rgba(48, 34, 49, 0) 0%, rgba(48, 34, 49, 1) 100%);
            display: flex;
            justify-content: end;
            align-items: end;
            #plant-screen-add-btn {
                -webkit-box-shadow: 0px 0px 24px 0px rgba(38,28,39,0.83); 
                box-shadow: 0px 0px 24px 0px rgba(38,28,39,0.83);
                margin-bottom: 42px;
                margin-right: 24px;
                display: flex;
                align-items: center;
                justify-content: center;
                height: 58px;
                width: 58px;
                background-color: #95DB59;
                border: none;
                border-radius: 16px;
                grid-column: 2;
                grid-row: 2;
                svg {
                    width: 100px;
                }
            }
        }

    }
    #plant-info {
        display: none;
        grid-template-rows: min-content min-content min-content;
        height: calc(100dvh - var(--safe-area-top));
        margin: 0px 35px 35px 35px;
        max-width: calc(100vw - 70px);
        padding-top: var(--safe-area-top);
        padding-bottom: calc(35px + var(--safe-area-bottom));
        opacity: 0;
        transition: opacity 0.3s var(--ios-ease);
        overflow-y: auto;
        overflow-x: hidden;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        #plant-img {
            width: 100%;
            aspect-ratio: 1 / 1;
            max-height: 300px;
            border-radius: 35px;
            background-image: url("/images/template-plant.webp");
            background-size: cover;
            display: flex;
            justify-content: space-between;
            #plant-grid-cont {
                margin-top: 16px;
                margin-left: 16px;
                width: 43px;
                height: 43px;
                border-radius: 14px;
                display: flex;
                justify-content: center;
                align-items: center;
                background-color: #19101A;
                #plant-grid-btn {
                    margin: 2px 0 0 1px;
                    background: transparent;
                    border: none;
                    width: min-content;
                    justify-self: start;
                    .grid-svg {
                        fill: #95DB59;
                    }
                }
            }
            #plant-delete-cont {            
                margin-top: 16px;
                margin-right: 16px;
                width: 43px;
                height: 43px;
                border-radius: 14px;
                display: flex;
                justify-content: center;
                align-items: center;
                background-color: #95DB59;
                #plant-delete-btn {
                    margin: 2px 0 0 1px;
                    background: transparent;
                    border: none;
                    width: min-content;
                    justify-self: end;
                    .delete-svg {
                        fill: #19101A;
                    }
                }
            }
        }
        #plant-text {
            margin-top: 10px;
            #plant-name {
                display: grid;
                grid-template-rows: min-content min-content min-content;
                grid-template-columns: 1fr min-content;
                column-gap: 10px;
                row-gap: 10px;
                h1 {
                    color: #FCF0D9;
                    font-size: 50px;
                    grid-row: 1;
                    grid-column: 1;
                    margin: 0;
                    padding: 0;
                    margin-bottom: -18px;
                }
                #health-check {
                    grid-row: 1 / 3;
                    grid-column: 2;
                    align-self: end;
                    justify-self: center;
                    background-color: transparent;
                    border: none;
                    width: auto;
                    height: 100%;
                    aspect-ratio: 1 / 1;
                    background-color: #19101A;
                    border-radius: 9px;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    svg {
                        width: 45px;
                        fill: #95DB59;
                    }
                }
                p {
                    color: #95DB59;
                    font-size: 14px;
                    grid-row: 2;
                    grid-column: 1 / -1;
                    margin: 0;
                    padding: 0;
                }
                #plant-journal {
                    width: 100%;
                    height: 42px;
                    background-color: #19101A;
                    border: none;
                    border-radius: 9px;
                    grid-row: 3;
                    grid-column: 1 / -1;
                    display: flex;
                    gap: 10px;
                    align-items: center;
                    justify-content: center;
                    padding-top: 3px;
                    svg {
                        fill: #95DB59;
                        width: 16px;
                    }
                    h2 {
                        font-size: 21px;
                        color: #FCF0D9;
                        margin: 0;
                        padding: 0;
                    }
                }
            }
            #plant-care {
                display: grid;
                grid-template-columns: 1fr min-content;
                grid-template-rows: min-content 1fr;
                row-gap: 10px;
                column-gap: 16px;
                margin-top: 15px;
                h1 {
                    font-size: 18px;
                    color: #95DB59;
                    margin: 0;
                    padding: 0;
                    grid-column: 1 / -1;
                    grid-row: 1;
                }
                p {
                    font-size: 13px;
                    color: #FCF0D9;
                    margin: 0;
                    padding: 0;
                    grid-column: 1;
                    grid-row: 2;
                }
                button {
                    background-color: #95DB59;
                    border: none;
                    border-radius: 9px;
                    width: 28px;
                    display: flex;
                    justify-content: center;
                    align-items: center;
                    grid-column: 2;
                    grid-row: 2;
                    svg {
                        margin-left: 2px;
                        width: 16px;
                        fill: #302231;
                    }
                }
            }
        }
        #plant-reminders-sect {
            display: grid;
            grid-template-columns: 1fr;
            grid-template-rows: auto;
            row-gap: 8px;
            margin-top: 20px;
            .plant-reminder {
                width: 100%;
                background-color: #19101A;
                height: 42px;
                display: flex;
                justify-content: center;
                align-items: center;
                gap: 10px;
                border-radius: 9px;
                p {
                    color: #FCF0D9;
                    font-size: 18px;
                    margin: 0;
                    padding: 0;
                }
                div {
                    width: 45px;
                    height: 28px;
                    display: flex;
                    justify-content: center;
                    align-items: center;
                    border-radius: 9px;
                    background-color: #302231;
                    h1 {
                        color: #95DB59;
                        font-size: 21px;
                        margin: 0;
                        padding: 0;
                        margin-bottom: -5px;
                    }
                }
            }
        }
    }
    #add-plant-card {
        display: none;
        z-index: 4000;
        opacity: 0;
        position: fixed;
        top: 100dvh;
        left: 0;
        right: 0;
        bottom: auto;
        width: 100%;
        max-width: 100vw;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        background-color: var(--color-card);
        height: auto;
        padding-bottom: var(--safe-area-bottom);
        transition: transform 0.35s var(--ios-spring), opacity 0.25s var(--ios-ease);
        -webkit-box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
        box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
        max-height: calc(65dvh + var(--safe-area-bottom));
        overflow-x: hidden;
        #add-plant-close {
            margin-top: 10px;
            align-self: center;
            justify-self: center;
            /* margin: 18px 24px 42px 24px; */
            width: calc(100% - 44px);
            display: flex;
            justify-content: flex-end;
            button {
                background-color: transparent;
                border: none;
                right: 24px;
                top: 18px;
            }
        }
        #add-plant-image {
            justify-self: center;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            gap: 10px;
            width: calc(100% - 194px);
            margin-bottom: 45px;
            transition: all .18s ease;
            opacity: 1;
                button {
                    width: 208px;
                    height: 42px;
                    background-color: #302231;
                    border: none;
                    border-radius: 9px;
                    display: flex;
                    gap: 10px;
                    align-items: center;
                    justify-content: center;
                    padding-top: 3px;
                    svg {
                        fill: #95DB59;
                        width: 21px;
                    }
                    h2 {
                        height: 23px;
                        font-size: 21px;
                        color: #FCF0D9;
                        margin: 0;
                        padding: 0;
                    }
                }
                #add-camera {

                }
                #add-photo {

                }
        }
        #plant-loading {
            display: none;
            opacity: 0;
            transition: all .2s ease;
            justify-items: center;
            padding-bottom: 30px;
            div {
                display: grid;
                justify-items: center;
            }
            p {
                color: #FCF0D9;
            }
        }
        #add-plant-info {
            justify-self: center;
            display: none;
            opacity: 0;
            width: calc(100% - 120px);
            transition: all .18s ease;
            row-gap: 14px;
            #plant-type-sect {
                display: grid;
                grid-template-columns: min-content 1fr;
                grid-template-rows: min-content min-content;
                /* row-gap: 8px; */
                column-gap: 10px;
                #user-photo {
                    background-color: #302231;
                    width: 62px;
                    height: 62px;
                    border-radius: 11px;
                    grid-column: 1;
                    grid-row: 1 / -1;
                    display: grid;
                    img {
                        justify-self: center;
                        align-self: center;
                        border-radius: 6px;
                        width: 80%;
                        height: auto;
                        aspect-ratio: 1 / 1;
                    }
                }
                h2 {
                    font-size: 18px;
                    color: #95DB59;
                    margin: 0;
                    padding: 0;
                    grid-column: 2;
                    grid-row: 1;
                    align-self: end;
                }
                p {
                    font-size: 14px;
                    color: #6F5D71;
                    margin: 0;
                    padding: 0;
                    text-decoration: underline;
                    grid-column: 2;
                    grid-row: 2;
                    align-self: start;
                }
            }
            #plant-name {
                display: flex;
                justify-content: center;
                align-items: center;
                gap: 8px;
                svg {

                }
                input {
                    background-color: #302231;
                    border: none;
                    font-size: 21px;
                    color: #FCF0D9;
                    width: 100%;
                    border-radius: 9px;
                    height: 30px;
                    padding: 6px 15px;
                    text-transform: lowercase;
                }
                input::placeholder {
                    color: #FCF0D9;
                    opacity: 1;
                }
            }
            #plant-care-text {
                display: grid;
                row-gap: 8px;
                width: 100%;
                h2 {
                    font-size: 18px;
                    color: #95DB59;
                    margin: 0;
                    padding: 0;
                }
                p {
                    font-size: 12px;
                    color: #FCF0D9;
                    margin: 0;
                    padding: 0;
                }
                button {
                    margin-top: 10px;
                    margin-bottom: 45px;
                    background-color: #95DB59;
                    border: none;
                    width: 100%;
                    border-radius: 9px;
                    height: 42px;
                    display: grid;
                    h1 {
                        justify-self: center;
                        align-self: center;
                        font-size: 21px;
                        color: #302231;
                        height: 23px;
                        padding: 0;
                        margin: 0;
                    }
                }
            }
        }
    }
    #reminders-screen {
        display: none;
        #recent-reminders-page {
            anchor-name: --recent-reminders-page;
            display: flex;
            width: 82%;
            justify-self: center;
            flex-direction: column;
            gap: 6px;
            height: 210px;
            grid-column: 1 / -1;
            grid-row: 1;
            margin-top: 10px;
            overflow-y: scroll;
            scrollbar-width: none;
            h2 {
                font-size: 13px;
                color: #FCF0D9;
                margin: 0;
                padding: 0;
            }
            .reminder-card {
                height: 50px;
                width: 100%;
                background-color: #19101A;
                display: grid;
                grid-template-columns: min-content 1fr min-content;
                grid-template-rows: 1fr 1fr;
                column-gap: 8px;
                border-radius: 9px;
                img {
                    height: 42px;
                    width: auto;
                    aspect-ratio: 1 / 1;
                    object-fit: cover;
                    grid-column: 1;
                    grid-row: 1 / -1;
                    border-radius: 6px;
                    margin-left: 4px;
                    align-self: center;
                    justify-self: start;
                }
                h1 {
                    grid-column: 2;
                    grid-row: 1;
                    color: #FCF0D9;
                    margin: 0;
                    padding: 0;
                    justify-self: start;
                    align-self: end;
                    margin-bottom: -6px;
                    font-size: 25px;
                }
                p {
                    grid-column: 2;
                    grid-row: 2;
                    color: #95DB59;
                    margin: 0;
                    padding: 0;
                    justify-self: start;
                    align-self: start;
                }
                div {
                    grid-column: 3;
                    grid-row: 1 / -1;
                    width: 42px;
                    height: 50px;
                    display: grid;
                    .checkbox-wrapper {
                        display: inline-flex;
                        align-items: center;
                        cursor: pointer;
                        position: relative;
                    }

                    .checkbox-wrapper input[type="checkbox"] {
                        position: absolute;
                        opacity: 0;
                        width: 0;
                        height: 0;
                    }

                    .custom-box {
                        align-self: center;
                        justify-self: center;
                        width: 30px;
                        height: 30px;
                        background: #302231;
                        border-radius: 6px;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        position: relative;
                        transition: background 0.2s ease;
                    }

                    .custom-box svg {
                        position: absolute;
                        margin-right: -12px;
                        margin-top: -5px;
                        width: 28px;
                        height: 28px;
                        fill: none;
                        stroke: white;
                        stroke-width: 3;
                        stroke-linecap: round;
                        stroke-linejoin: round;
                        opacity: 0;
                        transform: scale(0.8);
                        transition: opacity 0.2s ease, transform 0.2s ease;
                    }

                    .checkbox-wrapper input[type="checkbox"]:checked + .custom-box svg {
                        opacity: 1;
                        transform: scale(1);
                    }
                }
            }
        }
        #calendar-header {
            justify-self: center;
            width: 82%;
            display: flex;
            justify-content: space-between;
            align-items: center;
            color: #95DB59;
            button {
                background-color: transparent;
                border: none;
            }
        }
        #calendar-weekdays, #calendar-days {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            text-align: center;
            color: #FCF0D9;
            width: 82%;
            justify-self: center;
        }
        hr {
            background-color: #19101A;
            border: none;
            height: 3.5px;
            border-radius: 10px;
            width: 82%;
        }
        #calendar-weekdays div {
            font-weight: bold;
            padding: 5px 0;
            font-size: 12px;
        }
        .calendar-day {
            aspect-ratio: 1 / 1;
            cursor: pointer;
            position: relative;
            color: #FCF0D9;
            font-size: 18px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            .dots-container {
                display: flex;
                align-items: center;
                justify-content: center;
                height: 10px;
                margin-top: -14px;
                .dot {
                    margin-top: 25px;
                }
            }
        }
        .calendar-day.selected {
            background-color: #95DB59;
            border-radius: 50%;
            color: #19101A;
            .dots-container {
                .dot {
                    display: none;
                }
            }
        }
        .dot {
            height: 6px;
            width: 6px;
            background-color: #95DB59;
            border-radius: 50%;
            display: inline-block;
            margin: 0 1px;
        }
        .dots-container {
            margin-top: 4px;
        }
        #add-event-btn {
            height: 42px;
            border-radius: 9px;
            background-color: #19101A;
            border: none;
            color: #FCF0D9;
            font-size: 21px;
            width: 82%;
            justify-self: center;
            padding-top: 6px;
        }
        #day-reminders {
            margin: 10px 0 20px;
            width: 100%;
            justify-self: center;
            overflow-x: hidden;
            #day-reminder-cont {
                display: flex;
                gap: 12px;
                overflow-x: scroll;
                padding-left: 9%;
                padding-right: 9%;
                scrollbar-width: none;
                .day-reminder-card {
                    display: grid;
                    min-width: 170px;
                    background-color: #19101A;
                    border-radius: 9px;
                    h1 {
                        margin: 0;
                        padding: 5px 0;
                        justify-self: center;
                        font-size: 18px;
                        color: #FCF0D9;
                    }
                    div {
                        display: grid;
                        background-color: #302231;
                        margin: 0 7px 7px 7px;
                        border-radius: 5px;
                        h1 {
                            margin: 0;
                            padding: 8px 0 2px;
                            font-size: 21px;
                            color: #95DB59;
                            justify-self: center;
                        }
                    }
                }
            }
        }
    }
    #add-reminder-card {
        display: none;
        z-index: 4000;
        opacity: 0;
        position: fixed;
        top: 100dvh;
        left: 0;
        right: 0;
        bottom: auto;
        width: 100%;
        max-width: 100vw;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        background-color: var(--color-card);
        height: auto;
        padding-bottom: var(--safe-area-bottom);
        transition: transform 0.35s var(--ios-spring), opacity 0.25s var(--ios-ease);
        -webkit-box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
        box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
        max-height: calc(60dvh + var(--safe-area-bottom));
        overflow-x: hidden;
        #add-reminder-close {
            margin-top: 10px;
            align-self: center;
            justify-self: center;
            /* margin: 18px 24px 42px 24px; */
            width: calc(100% - 44px);
            display: flex;
            justify-content: flex-end;
            button {
                background-color: transparent;
                border: none;
                right: 24px;
                top: 18px;
            }
        }
        #event-list {
            margin-top: 15px;
        }
        #add-event-form {
            width: 100%;
            max-width: 250px;
            display: flex;
            flex-direction: column;
            margin: 20px auto 50px auto;
            gap: 20px;
            #event-type {
                display: grid;
                grid-template-columns: 1fr 1fr 1fr;
                column-gap: 2px;
                button {
                    background-color: #302231;
                    color: #FCF0D9;
                    border: none;
                    font-size: 16px;
                    padding: 12px 0;
                }
                button.selected {
                    background-color: #95DB59 !important;
                    color: #19101A;
                }
                button:first-child {
                    border-radius: 8px 0 0 8px;
                }
                button:last-child {
                    border-radius: 0px 8px 8px 0px;
                }
            }
            select {
                border: none;
                background-color: #FCF0D9;
                padding: 10px 0 8px 10px;
                font-size: 20px;
                border-radius: 8px;
                appearance: none;
                option {
                    font-size: 16px;
                    hyphens: none;
                }
                option:default {
                    hyphens: none;
                }
            }
            input {
                margin-left: -15px;
                background-color: #302231;
                border: none;
                font-size: 21px;
                color: #FCF0D9;
                width: 100%;
                border-radius: 9px;
                height: 30px;
                padding: 6px 15px;
                text-transform: lowercase;
            }
            input::placeholder {
                color: #FCF0D9;
                opacity: 1;
            }
            #save-event-btn {
                width: 100%;
                height: 42px;
                background-color: #95DB59;
                border: none;
                border-radius: 9px;
                display: flex;
                gap: 10px;
                align-items: center;
                justify-content: center;
                padding-top: 3px;
                font-size: 21px;
                color: #19101A;
                margin-top: 10px;
            }
        }
    }
    #full-instructions {
        display: none;
        opacity: 0;
        background-color: #19101A;
        width: 100%;
        height: 85%;
        max-width: 320px;
        position: absolute;
        justify-self: center;
        align-self: center;
        top: 10%;
        z-index: 4500;
        border-radius: 15px;
        grid-template-columns: 1fr min-content;
        grid-template-rows: min-content 1fr;
        transition: all .15s ease;
        margin-left: calc(50vw - 160px);
        h1 {
            color: #FCF0D9;
            font-size: 24px;
            text-decoration: underline;
            margin: 0;
            align-self: center;
            padding: 15px 20px;
        }
        #full-overlay {
            z-index: 4000;
            position: absolute;
            width: 100%;
            height: 100%;
            border-radius: 15px;
            background: linear-gradient(0deg, rgba(25, 16, 26, 1) 2%, rgba(25, 16, 26, 0) 30%);
            pointer-events: none;
        }
        #full-instructions-cont {
            overflow-y: scroll;
            grid-column: 1 / -1;
            grid-row: 2;
            padding: 0 20px;
            padding-bottom: 120px;
            #full-instructions-content {
                color: #FCF0D9;
                margin: 0;
            }
        }
        #full-close {
            background-color: transparent;
            width: min-content;
            height: min-content;
            border: none;
            grid-column: 2;
            grid-row: 1;
            align-self: center;
            padding-right: 15px;
        }
    }
    #screen-blur {
        position: absolute;
        display: none;
        opacity: 0;
        width: 100%;
        height: 100%;
        top: 0;
        z-index: 4200;
        backdrop-filter: blur(6px);
        transition: all .35s ease;
    }
    #plant-delete-card {
        display: none;
        opacity: 0;
        width: 100%;
        max-width: 280px;
        position: absolute;
        align-self: center;
        justify-self: center;
        top: 50%;
        /* margin-left: calc(50vw - 142px); */
        background-color: #19101A;
        color: #FCF0D9;
        justify-items: center;
        row-gap: 15px;
        column-gap: 15px;
        border-radius: 16px;
        padding: 27px 30px;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 1fr min-content;
        z-index: 4500;
        transition: all .2s ease;
        p {
            margin: 0;
            font-size: 18px;
            padding-bottom: 5px;
            grid-column: 1 / -1;
            grid-row: 1;
        }
        button {
            width: 100px;
            border: none;
            font-size: 16px;
            padding: 9px 0;
            border-radius: 6px;
            margin: 0;
            letter-spacing: 0.8px;
        }
        #no-delete-btn {
            background-color: #FCF0D9;
            color: #19101A;
        }
        #yes-delete-btn {
            background-color: rgb(184, 23, 76);
            color: #FCF0D9;
        }
    }
    #reminder-edit-card {
        display: none;
        opacity: 0;
        width: 100%;
        max-width: 280px;
        position: absolute;
        align-self: center;
        justify-self: center;
        top: 50%;
        /* margin-left: calc(50vw - 142px); */
        background-color: #19101A;
        color: #FCF0D9;
        justify-items: center;
        row-gap: 15px;
        column-gap: 15px;
        border-radius: 16px;
        padding: 27px 30px;
        grid-template-columns: 1fr 1fr;
        z-index: 4500;
        transition: all .2s ease;
        button {
            width: 100px;
            border: none;
            font-size: 16px;
            padding: 9px 0;
            border-radius: 6px;
            margin: 0;
            letter-spacing: 0.8px;
        }
        #reminder-card-close {
            background-color: #FCF0D9;
            color: #19101A;
        }
        #reminder-delete-btn {
            background-color: rgb(184, 23, 76);
            color: #FCF0D9;
        }
    }

input[type="time"]::-webkit-calendar-picker-indicator {
    opacity: 0;
}

input[type="time"] {
    background-image: url("../images/clock.svg");
    background-repeat: no-repeat;
    background-position: calc(100% - 10px);
    background-size: 30px;
    padding-right: 30px;
}

#fade-overlay-1 {
  position: absolute;
  align-self: start;
  justify-self: center;
  position-anchor: --recent-reminders;
  margin-top: calc(anchor-size(height) - 39px);
  margin-bottom: 50px;
  width: 100%;
  height: 50px;
  z-index: 4000;
  pointer-events: none;
  background: linear-gradient(0deg,rgba(48, 34, 49, 1) 0%, rgba(48, 34, 49, 0) 46%);
}

#fade-overlay-2 {
  position: absolute;
  align-self: start;
  justify-self: center;
  position-anchor: --recent-reminders-page;
  margin-top: calc(anchor-size(height) - 39px);
  width: 100%;
  height: 50px;
  z-index: 4000;
  pointer-events: none;
  background: linear-gradient(0deg,rgba(48, 34, 49, 1) 0%, rgba(48, 34, 49, 0) 46%);
}

.dot-number {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background-color: #95DB59;
    color: #19101A;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.calendar-day.selected .dot-number {
  display: none;
}

.completed-dot {
    background-color: #19101A;
    color: #95DB59;
}

#settings-icon {
    fill: var(--color-cream);
    transition: fill 0.32s var(--ios-ease);
}

/* ==================== iOS SCREEN TRANSITIONS ==================== */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    will-change: transform, opacity;
}

/* Slide transition states */
.screen-slide-enter {
    transform: translateX(100%);
    opacity: 1;
}

.screen-slide-enter-active {
    transform: translateX(0);
    transition: transform 0.35s var(--ios-ease);
}

.screen-slide-exit {
    transform: translateX(0);
    opacity: 1;
}

.screen-slide-exit-active {
    transform: translateX(-30%);
    opacity: 0.7;
    transition: transform 0.35s var(--ios-ease), opacity 0.35s var(--ios-ease);
}

/* Swipe gesture indicator */
.swipe-indicator {
    position: fixed;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 80px;
    background: var(--color-green);
    border-radius: 0 4px 4px 0;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
    z-index: 9999;
}

.swipe-indicator.active {
    opacity: 0.6;
}

/* Bottom sheet drag handle */
.sheet-handle {
    width: 36px;
    height: 5px;
    background: var(--color-muted);
    border-radius: 3px;
    margin: 8px auto 4px;
}

/* Plant card hover/press states */
.plant-card {
    transition: transform 0.15s var(--ios-ease), box-shadow 0.15s var(--ios-ease);
    cursor: pointer;
}

.plant-card:active {
    transform: scale(0.97);
}

/* Reminder card states */
.reminder-card {
    transition: transform 0.15s var(--ios-ease), background-color 0.2s ease;
}

.reminder-card:active:not(.completed) {
    transform: scale(0.98);
}

.reminder-card.highlight {
    animation: highlight-pulse 0.5s ease 2;
}

@keyframes highlight-pulse {
    0%, 100% { background-color: var(--color-card); }
    50% { background-color: #2a1e2b; }
}

/* Loading spinner enhancement */
.loader {
    width: 40px;
    height: 40px;
    border: 3px solid var(--color-bg);
    border-top-color: var(--color-green);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* PWA Install screen styles */
#install-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    height: 100dvh;
    background: var(--color-bg);
    z-index: 10000;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 30px;
    padding: var(--safe-area-top) var(--safe-area-right) var(--safe-area-bottom) var(--safe-area-left);
    overflow: hidden;
    img {
        max-width: 200px;
        -webkit-box-shadow: 0px 0px 39px 6px #19101A; 
        box-shadow: 0px 0px 39px 6px #19101A;
        border-radius: 35px;
    }
    svg {
        width: 200px !important;
    }
}

#install-screen .logo-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

#install-screen .logo-container svg {
    width: 120px;
    height: auto;
}

#install-screen .install-btn {
    background: var(--color-green);
    color: var(--color-card);
    border: none;
    padding: 14px 40px;
    border-radius: var(--radius-md);
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    text-wrap: nowrap;
    width: 200px;
}

#install-screen .install-instructions {
    color: var(--color-cream);
    text-align: center;
    padding: 0 40px;
    line-height: 1.6;
    max-width: 300px;
}

#install-screen .install-instructions strong {
    color: var(--color-green);
}

/* Settings screen styles */
#settings-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    height: 100dvh;
    background: var(--color-bg);
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.3s var(--ios-ease);
    padding: var(--safe-area-top) 30px var(--safe-area-bottom);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

#settings-screen.active {
    display: block;
    opacity: 1;
}

.settings-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    border-bottom: 1px solid rgba(252, 240, 217, 0.1);
    margin-bottom: 20px;
}

.settings-header h1 {
    color: var(--color-cream);
    font-size: 28px;
    margin: 0;
}

.settings-back-btn {
    background: transparent;
    border: none;
    color: var(--color-green);
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.settings-section {
    margin-bottom: 25px;
}

.settings-section h2 {
    color: var(--color-green);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 12px 0;
}

.settings-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--color-card);
    padding: 14px 16px;
    border-radius: var(--radius-md);
    margin-bottom: 8px;
}

.settings-item span {
    color: var(--color-cream);
    font-size: 16px;
}

.settings-item .toggle {
    width: 50px;
    height: 30px;
    background: var(--color-bg);
    border-radius: 15px;
    position: relative;
    cursor: pointer;
    transition: background 0.2s ease;
}

.settings-item .toggle.active {
    background: var(--color-green);
}

.settings-item .toggle::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    background: var(--color-cream);
    border-radius: 50%;
    top: 3px;
    left: 3px;
    transition: transform 0.2s var(--ios-spring);
}

.settings-item .toggle.active::after {
    transform: translateX(20px);
}

.settings-item select {
    background: var(--color-bg);
    color: var(--color-cream);
    border: none;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    font-size: 14px;
}

.settings-danger-btn {
    width: 100%;
    background: rgba(184, 23, 76, 0.2);
    color: rgb(184, 23, 76);
    border: 1px solid rgb(184, 23, 76);
    padding: 14px;
    border-radius: var(--radius-md);
    font-size: 16px;
    margin-top: 8px;
}

.settings-version {
    text-align: center;
    color: var(--color-muted);
    font-size: 12px;
    margin-top: 30px;
    padding-bottom: 20px;
}

/* ==================== JOURNAL SCREEN STYLES ==================== */
#journal-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    height: 100dvh;
    background: var(--color-bg);
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.3s var(--ios-ease);
    padding: var(--safe-area-top) 20px var(--safe-area-bottom);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

.journal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    border-bottom: 1px solid rgba(252, 240, 217, 0.1);
    margin-bottom: 20px;
}

.journal-header h1 {
    color: var(--color-cream);
    font-size: 28px;
    margin: 0;
}

.journal-back-btn {
    background: transparent;
    border: none;
    color: var(--color-green);
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.journal-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.add-journal-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--color-card);
    border: 2px dashed var(--color-muted);
    border-radius: var(--radius-md);
    padding: 16px;
    color: var(--color-green);
    width: 100%;
}

.journal-entries {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.journal-entry {
    background: var(--color-card);
    border-radius: var(--radius-md);
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.journal-entry-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.journal-entry-date {
    color: var(--color-green);
    font-size: 14px;
}

.journal-entry-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.journal-edit-btn,
.journal-delete-btn {
    background: var(--color-bg);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.journal-edit-btn:active,
.journal-delete-btn:active {
    transform: scale(0.92);
}

.journal-edit-btn:hover,
.journal-edit-btn:focus {
    color: var(--color-green);
    background: rgba(149, 219, 89, 0.15);
}

.journal-delete-btn:hover,
.journal-delete-btn:focus {
    color: rgb(184, 23, 76);
    background: rgba(184, 23, 76, 0.15);
}

.journal-entry-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.journal-entry-tag {
    background: var(--color-bg);
    color: var(--color-cream);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
}

.journal-entry-image {
    width: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: var(--radius-sm);
}

.journal-entry-note {
    color: var(--color-cream);
    font-size: 14px;
    line-height: 1.5;
}

/* Add Journal Entry Bottom Sheet */
#add-journal-card {
    display: none;
    z-index: 6000;
    opacity: 0;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    background-color: var(--color-card);
    padding-bottom: calc(20px + var(--safe-area-bottom));
    transition: transform 0.35s var(--ios-spring), opacity 0.25s var(--ios-ease);
    -webkit-box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
    box-shadow: 0px -4px 30px 0px rgba(0,0,0,0.4);
    max-height: 85dvh;
    overflow-y: auto;
    overflow-x: hidden;
    touch-action: pan-y;
    -webkit-overflow-scrolling: auto;
}

.add-journal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid rgba(252, 240, 217, 0.1);
    position: sticky;
    top: 0;
    z-index: 1;
    background-color: var(--color-card);
    touch-action: manipulation;
}

#save-journal-entry-btn,
#journal-entry-close-btn {
    touch-action: manipulation;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    /* Increase tap target size without changing visual size */
    padding: 12px 16px;
    margin: -12px -16px;
}

.add-journal-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.journal-photo-section {
    display: flex;
    justify-content: center;
}

.journal-photo-preview {
    width: 150px;
    height: 150px;
    border-radius: var(--radius-md);
    background: var(--color-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--color-muted);
    cursor: pointer;
    overflow: hidden;
}

.journal-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.journal-date-section input {
    width: 100%;
    background: var(--color-bg);
    border: none;
    color: var(--color-cream);
    padding: 12px;
    border-radius: var(--radius-sm);
    font-size: 16px;
    margin-top: 8px;
}

.journal-tags-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.journal-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.journal-tag {
    background: var(--color-bg);
    color: var(--color-cream);
    border: none;
    padding: 8px 14px;
    border-radius: 16px;
    font-size: 13px;
    transition: all 0.2s ease;
}

.journal-tag.selected {
    background: var(--color-green);
    color: var(--color-card);
}

.journal-note-section textarea {
    width: 100%;
    background: var(--color-bg);
    border: none;
    color: var(--color-cream);
    padding: 12px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    resize: none;
    margin-top: 8px;
    font-family: inherit;
}

.journal-note-section textarea::placeholder {
    color: var(--color-muted);
}

/* ==================== HEALTH CHECK SCREEN STYLES ==================== */
#health-screen {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    height: 100dvh;
    background: var(--color-bg);
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.3s var(--ios-ease);
    padding: var(--safe-area-top) 20px var(--safe-area-bottom);
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}

.health-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
    border-bottom: 1px solid rgba(252, 240, 217, 0.1);
    margin-bottom: 20px;
}

.health-header h1 {
    color: var(--color-cream);
    font-size: 28px;
    margin: 0;
}

.health-back-btn {
    background: transparent;
    border: none;
    color: var(--color-green);
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.health-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 0;
}

.health-capture {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
}

.health-icon {
    color: var(--color-green);
    margin-bottom: 20px;
}

.health-action-btn {
    background: var(--color-green);
    color: var(--color-card);
    border: none;
    padding: 14px 30px;
    border-radius: var(--radius-md);
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.health-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 20px;
}

.health-results {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.health-status {
    display: flex;
    align-items: center;
    gap: 15px;
    background: var(--color-card);
    padding: 20px;
    border-radius: var(--radius-md);
}

.health-status-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
}

.health-status-icon.healthy {
    background: rgba(149, 219, 89, 0.2);
    color: var(--color-green);
}

.health-status-icon.unhealthy {
    background: rgba(184, 23, 76, 0.2);
    color: rgb(184, 23, 76);
}

.health-status-text h3 {
    color: var(--color-cream);
    margin: 0 0 5px 0;
    font-size: 18px;
}

.health-status-text p {
    color: var(--color-muted);
    margin: 0;
    font-size: 14px;
}

.health-issue-card {
    background: var(--color-card);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.health-issue-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    cursor: pointer;
}

.health-issue-name {
    color: var(--color-cream);
    font-size: 16px;
}

.health-issue-probability {
    color: var(--color-green);
    font-size: 14px;
}

.health-issue-details {
    padding: 0 15px 15px;
    border-top: 1px solid rgba(252, 240, 217, 0.1);
}

.health-issue-details h4 {
    color: var(--color-green);
    font-size: 14px;
    margin: 15px 0 8px 0;
}

.health-issue-details p {
    color: var(--color-cream);
    font-size: 13px;
    line-height: 1.5;
    margin: 0;
}

.health-action-buttons {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.health-action-buttons button {
    flex: 1;
    padding: 12px;
    border-radius: var(--radius-md);
    font-size: 14px;
}

.health-new-check-btn {
    background: var(--color-card);
    border: 1px solid var(--color-green);
    color: var(--color-green);
}

.health-save-btn {
    background: var(--color-green);
    border: none;
    color: var(--color-card);
}

/* ==================== FULL CARE INSTRUCTIONS POPUP ==================== */
#full-instructions {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 88vw;
    max-width: 100vw;
    max-height: 80dvh;
    background: var(--color-card);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    z-index: 6000;
    opacity: 0;
    transition: opacity 0.3s var(--ios-ease);
    overflow: hidden;
    box-sizing: border-box;
    margin: 0;
}

#full-instructions > h1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    margin: 0;
    color: var(--color-cream);
    font-size: 22px;
    border-bottom: 1px solid rgba(252, 240, 217, 0.1);
}

#full-overlay {
    display: none;
}

#full-instructions-cont {
    padding: 20px;
    padding-bottom: calc(20px + var(--safe-area-bottom));
    overflow-y: auto;
    overflow-x: hidden;
    max-height: calc(80dvh - 70px);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    box-sizing: border-box;
}

#full-instructions-cont::-webkit-scrollbar {
    display: none;
}

#full-instructions-content {
    color: var(--color-cream);
    font-size: 16px;
    line-height: 1.7;
    margin: 0;
    white-space: pre-wrap;
}

/* Care instruction sections - will be generated by JS */
.care-section {
    background: var(--color-card);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 12px;
}

.care-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.care-section-icon {
    width: 36px;
    height: 36px;
    background: var(--color-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-green);
    flex-shrink: 0;
}

.care-section-title {
    color: var(--color-green);
    font-size: 16px;
    margin: 0;
}

.care-section-content {
    color: var(--color-cream);
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

/* Quick tips at the top */
.care-quick-tips {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: none;
}

.care-quick-tips::-webkit-scrollbar {
    display: none;
}

.care-tip {
    background: var(--color-card);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 80px;
    flex-shrink: 0;
}

.care-tip-icon {
    color: var(--color-green);
    font-size: 20px;
}

.care-tip-label {
    color: var(--color-muted);
    font-size: 11px;
    text-transform: uppercase;
}

.care-tip-value {
    color: var(--color-cream);
    font-size: 13px;
    text-align: center;
}

#full-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 36px;
    height: 36px;
    background: var(--color-bg);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
}

#full-close svg {
    width: 18px;
    height: 18px;
}
