.af-loading-overlay {
    opacity: 0.38;
    background-color: #f7faf7;
}

.af-loading-container {
    top: 30%;
}

.af-loading-card {
    position: relative;
    overflow: hidden;
    min-width: 210px;
    padding: 12px 18px 12px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    border-radius: 8px;
    background: linear-gradient(to bottom, #67b9e7 0%, #67b9e7 56%, #8c6037 58%, #76502d 100%);
    background-clip: padding-box;
    color: #fff;
    text-align: center;
    box-shadow: 0 12px 18px -10px rgba(0, 0, 0, 0.24);
    font-size: 13px;
    font-weight: 600;
}

.af-loading-card::before,
.af-loading-card::after {
    content: "";
    position: absolute;
    top: 12px;
    left: -48px;
    width: 34px;
    height: 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow:
        10px -5px 0 1px rgba(255, 255, 255, 0.86),
        20px 0 0 2px rgba(255, 255, 255, 0.82);
    animation: af-cloud-move 6.8s linear infinite;
    pointer-events: none;
}

.af-loading-card::after {
    top: 28px;
    width: 26px;
    height: 8px;
    opacity: 0.78;
    animation-duration: 9.2s;
    animation-delay: 1.2s;
}

.af-orchard-loader {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 4px;
    height: 68px;
    margin: 0 auto 8px;
}

.af-orchard-loader::before {
    content: "";
    position: absolute;
    z-index: 0;
    left: 18px;
    right: 18px;
    bottom: 8px;
    height: 2px;
    border-radius: 3px;
    background: rgba(126, 210, 237, 0.9);
    box-shadow: 0 0 5px rgba(126, 210, 237, 0.55);
    animation: af-irrigation-line 3.8s ease-in-out infinite;
}

.af-orchard-loader::after {
    content: "";
    position: absolute;
    z-index: 0;
    left: 36px;
    bottom: 8px;
    width: 10px;
    height: 3px;
    border-radius: 6px;
    background: #c7efff;
    box-shadow:
        22px 0 0 rgba(199, 239, 255, 0.9),
        46px 0 0 rgba(199, 239, 255, 0.8),
        84px 0 0 rgba(199, 239, 255, 0.9),
        108px 0 0 rgba(199, 239, 255, 0.8),
        142px 0 0 rgba(199, 239, 255, 0.9);
    opacity: 0;
    animation: af-irrigation-drip 3.8s ease-in-out infinite;
}

.af-growing-tree {
    position: relative;
    z-index: 1;
    width: 72px;
    height: 72px;
    flex: 0 0 58px;
    margin: 0;
    transform-origin: bottom center;
    --af-tree-delay: 0s;
    --af-fruit-color: #f28c28;
    --af-leaf-dark: #4f8f5b;
    --af-leaf-light: #5fb463;
}

.af-growing-tree::before,
.af-growing-tree::after {
    content: "";
    position: absolute;
    display: none;
}

.af-growing-tree-main {
    transform: scale(1);
}

.af-growing-tree-small {
    transform: scale(0.82);
}

.af-crop-cherry {
    --af-tree-delay: 0.12s;
    --af-fruit-color: #c9343c;
    --af-leaf-dark: #4c8757;
    --af-leaf-light: #68a85e;
}

.af-crop-walnut {
    --af-tree-delay: 0s;
    --af-fruit-color: #a8c95a;
    --af-leaf-dark: #4f8b4f;
    --af-leaf-light: #6aaa58;
}

.af-crop-grape {
    --af-tree-delay: 0.24s;
    --af-fruit-color: #7c4aa5;
    --af-leaf-dark: #4a8b54;
    --af-leaf-light: #68ad61;
}

.af-crop-grape::before {
    display: block;
    left: 12px;
    top: 23px;
    width: 48px;
    height: 2px;
    border-radius: 2px;
    background: #8a6a41;
    opacity: 0;
    animation: af-vine-wire 3.8s ease-in-out infinite;
    animation-delay: calc(var(--af-tree-delay) + 0.18s);
}

.af-crop-grape::after {
    display: block;
    left: 33px;
    top: 24px;
    width: 7px;
    height: 25px;
    border-left: 3px solid #6f8a38;
    border-bottom: 3px solid #6f8a38;
    border-radius: 0 0 0 14px;
    opacity: 0;
    transform: scaleY(0.35);
    transform-origin: top center;
    animation: af-vine-cane 3.8s ease-in-out infinite;
    animation-delay: calc(var(--af-tree-delay) + 0.28s);
}

.af-growing-tree span {
    position: absolute;
    display: block;
}

.af-growing-tree-soil {
    left: 14px;
    bottom: 8px;
    width: 44px;
    height: 8px;
    border-radius: 50%;
    background: #513216;
    transform-origin: center;
    animation: af-soil-pulse 3.2s ease-in-out infinite;
}

.af-growing-tree-trunk {
    left: 33px;
    bottom: 14px;
    width: 7px;
    height: 32px;
    border-radius: 6px 6px 2px 2px;
    background: #4b2d16;
    transform: scaleY(0);
    transform-origin: bottom center;
    animation: af-tree-grow 3.2s ease-in-out infinite;
    animation-delay: var(--af-tree-delay);
}

.af-growing-tree-leaf {
    border-radius: 50%;
    background: var(--af-leaf-dark);
    opacity: 0;
    transform: scale(0.2);
    animation: af-leaf-grow 3.2s ease-in-out infinite;
}

.af-growing-tree-leaf-left {
    left: 14px;
    top: 23px;
    width: 34px;
    height: 28px;
    animation-delay: calc(var(--af-tree-delay) + 0.25s);
}

.af-growing-tree-leaf-right {
    right: 12px;
    top: 23px;
    width: 34px;
    height: 28px;
    animation-delay: calc(var(--af-tree-delay) + 0.35s);
}

.af-growing-tree-leaf-top {
    left: 22px;
    top: 8px;
    width: 30px;
    height: 32px;
    background: var(--af-leaf-light);
    animation-delay: calc(var(--af-tree-delay) + 0.45s);
}

.af-growing-tree-fruit {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--af-fruit-color);
    box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.18);
    opacity: 0;
    transform: scale(0.2);
    animation: af-fruit-pop 3.2s ease-in-out infinite;
}

.af-crop-cherry .af-growing-tree-fruit {
    width: 6px;
    height: 6px;
    box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.18), 5px 3px 0 #b92835;
}

.af-crop-walnut .af-growing-tree-fruit {
    width: 9px;
    height: 9px;
    background: #a8c95a;
    border: 1px solid #5d7f28;
    box-shadow: inset 0 -2px 0 rgba(47, 85, 29, 0.28), 0 1px 1px rgba(0, 0, 0, 0.22);
}

.af-crop-grape .af-growing-tree-trunk {
    left: 34px;
    width: 5px;
    height: 28px;
    background: #4b2d16;
}

.af-crop-grape .af-growing-tree-fruit {
    width: 6px;
    height: 6px;
    background: #7d4aa7;
    box-shadow:
        -5px 5px 0 #8a57b5,
        5px 5px 0 #6d3f98,
        -8px 10px 0 #75469c,
        0 10px 0 #8a57b5,
        8px 10px 0 #7d4aa7,
        -5px 15px 0 #6d3f98,
        3px 15px 0 #8a57b5,
        11px 15px 0 #75469c,
        -2px 20px 0 #7d4aa7,
        6px 20px 0 #6d3f98,
        2px 25px 0 #75469c;
}

.af-crop-grape .af-growing-tree-fruit::before {
    content: "";
    position: absolute;
    left: 3px;
    top: -7px;
    width: 8px;
    height: 9px;
    border-left: 2px solid #6f8a38;
    border-radius: 0 0 0 8px;
}

.af-crop-grape .af-growing-tree-fruit-one {
    left: 29px;
    top: 25px;
}

.af-crop-grape .af-growing-tree-fruit-two,
.af-crop-grape .af-growing-tree-fruit-three,
.af-crop-grape .af-growing-tree-fruit-four {
    display: none;
}

.af-growing-tree-fruit-one {
    left: 24px;
    top: 30px;
    animation-delay: calc(var(--af-tree-delay) + 0.7s);
}

.af-growing-tree-fruit-two {
    left: 38px;
    top: 22px;
    animation-delay: calc(var(--af-tree-delay) + 0.82s);
}

.af-growing-tree-fruit-three {
    right: 22px;
    top: 35px;
    animation-delay: calc(var(--af-tree-delay) + 0.94s);
}

.af-growing-tree-fruit-four {
    left: 31px;
    top: 42px;
    width: 7px;
    height: 7px;
    animation-delay: calc(var(--af-tree-delay) + 1.02s);
}

.af-loading-text {
    position: relative;
    z-index: 1;
    display: inline-block;
    margin-top: 1px;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
    white-space: nowrap;
    transform-origin: center;
    animation: af-loading-text-motion 1.15s ease-in-out infinite;
}

@keyframes af-tree-grow {
    0%,
    10% {
        transform: scaleY(0);
    }
    34%,
    82% {
        transform: scaleY(1);
    }
    94% {
        transform: scaleY(0.72);
    }
    100% {
        transform: scaleY(0);
    }
}

@keyframes af-leaf-grow {
    0%,
    16% {
        opacity: 0;
        transform: scale(0.2);
    }
    38%,
    82% {
        opacity: 1;
        transform: scale(1);
    }
    94% {
        opacity: 0.55;
        transform: scale(0.82);
    }
    100% {
        opacity: 0;
        transform: scale(0.55);
    }
}

@keyframes af-fruit-pop {
    0%,
    38% {
        opacity: 0;
        transform: scale(0.2);
    }
    52%,
    84% {
        opacity: 1;
        transform: scale(1);
    }
    94% {
        opacity: 0.55;
        transform: scale(0.82);
    }
    100% {
        opacity: 0;
        transform: scale(0.55);
    }
}

@keyframes af-soil-pulse {
    0%,
    100% {
        transform: scaleX(0.9);
        opacity: 0.65;
    }
    34%,
    84% {
        transform: scaleX(1);
        opacity: 1;
    }
    94% {
        transform: scaleX(0.96);
        opacity: 0.85;
    }
}

@keyframes af-loading-text-motion {
    0%,
    100% {
        opacity: 0.82;
        transform: translateY(0) scale(1);
    }
    35% {
        opacity: 1;
        transform: translateY(-3px) scale(1.04);
    }
    70% {
        opacity: 0.92;
        transform: translateY(1px) scale(0.99);
    }
}

@keyframes af-irrigation-line {
    0%,
    18%,
    100% {
        transform: scaleX(0.18);
        opacity: 0;
    }

    32%,
    78% {
        transform: scaleX(1);
        opacity: 1;
    }
}

@keyframes af-irrigation-drip {
    0%,
    24%,
    100% {
        transform: scaleX(0.35);
        opacity: 0;
    }

    38%,
    72% {
        transform: scaleX(1);
        opacity: 0.95;
    }
}

@keyframes af-cloud-move {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(310px);
    }
}

@keyframes af-vine-wire {
    0%,
    18% {
        opacity: 0;
        transform: scaleX(0.4);
    }
    40%,
    84% {
        opacity: 1;
        transform: scaleX(1);
    }
    100% {
        opacity: 0;
        transform: scaleX(0.75);
    }
}

@keyframes af-vine-cane {
    0%,
    22% {
        opacity: 0;
        transform: scaleY(0.35);
    }
    42%,
    84% {
        opacity: 1;
        transform: scaleY(1);
    }
    100% {
        opacity: 0;
        transform: scaleY(0.72);
    }
}
