

label {
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
}

input[type="file"],
input[type="number"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
}

/* ========================= */
/* IMAGE TOOL BUTTON STYLE  */
/* ========================= */

.app {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 22px;
    border: none;
    border-radius: 4px;
    background: linear-gradient(135deg, #0a3d62, #07517d);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.35s ease;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

/* Text & Icon */
.app .text {
    transition: 0.3s ease;
}

.app .iconn {
    display: flex;
    align-items: center;
    transition: 0.35s ease;
}

/* Hover Effect */
.app:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
    background: linear-gradient(135deg, #07517d, #0a3d62);
}

/* Icon Slide Animation */
.app:hover .iconn {
    transform: translateX(6px);
}

/* Click Effect */
.app:active {
    transform: scale(0.96);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Shine Effect */
.app::before {
    content: "";
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transform: skewX(-20deg);
    transition: 0.6s;
}

.app:hover::before {
    left: 120%;
}

/* Preview Layout */

.canvases {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.preview-box {
    flex: 1;
    min-width: 300px;
}

.preview-title {
    font-weight: 700;
    margin-bottom: 8px;
    text-align: center;
}

.canvas-wrapper {
    width: 100%;
    height: 260px;
    background: #fafafa;
    border: 1px solid #ddd;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

canvas {
    max-width: 100%;
    max-height: 100%;
}

/* Cropped Preview Overlay */

.cropped-wrapper {
    position: relative;
}

.progress-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.progress-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.loader-box {
    text-align: center;
    color: #fff;
}

.spinner {
    width: 45px;
    height: 45px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 12px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.progress-text {
    font-size: 14px;
    letter-spacing: 0.5px;
}

/* Beautiful Info Boxes */

.crop-inputs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 10px;
}

label {
    font-weight: bold;
    display: block;
    margin-top: 10px;
    margin-bottom: 6px;
}

input[type="file"],
input[type="number"] {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    font-size: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
}

.info-boxes {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.info-card {
    flex: 1;
    min-width: 140px;
    background: #f1f6fb;
    border: 1px solid #d8e6f7;
    padding: 10px 12px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.info-icon {
    font-size: 16px;
}

.info-label {
    font-weight: 600;
    font-size: 12px;
    color: #555;
}

.info-value {
    font-weight: 700;
    color: #0a3d62;
}

/* Cropper */

#cropper-section {
    margin-top: 20px;
    display: none;
}

#cropper-image {
    max-width: 100%;
    max-height: 500px;
    border-radius: 8px;
}

#result {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.btn-area {
    text-align: right;
}

/* =========================
   FULL RESPONSIVE DESIGN
========================= */

@media (max-width: 992px) {
    .tool-box {
        max-width: 100%;
    }

    .canvases {
        flex-direction: column;
    }

    .canvas-wrapper {
        height: 240px;
    }

    #cropper-image {
        max-height: 350px;
    }
}

@media (max-width: 600px) {
    .header h1 {
        font-size: 20px;
    }

    .header p {
        font-size: 13px;
    }

    .canvas-wrapper {
        height: 200px;
    }

    .crop-inputs {
        grid-template-columns: 1fr 1fr;
    }

    .app {
        width: 100%;
    }

    #result {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }

    .btn-area {
        text-align: center;
    }
}

@media (max-width: 400px) {
    .preview-box {
        max-width: 100% !important;
    }

    .content {
        padding: 10px;
    }

    .tool-detail-textarea-box {
        padding: 0px;
    }
}