@media screen and (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }   
    .social-link {
        width: 100%;
        justify-content: center;
    }   
    .social-link:hover {
        transform: translateY(-5px);
    }    
    .footer-section h3 {
        display: block;
        text-align: center;
    }
    .footer-section p {
    line-height: 1.6;
    color: #ecf0f1;
    margin: 10px 0;
    margin-left: 15px;
}
    .footer-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 20px;
    }    
    .footer-links li {
        margin: 0;
    }
    .div-2 {
        width: 90%;
        height: auto;
        min-height: 700px;
        padding: 20px;
    }   
    .nav-menu {
        gap: 20px;
        font-size: 18px;
        flex-wrap: wrap;
        justify-content: center;
    }    
    .s1 {
        padding: 15px;
        gap: 20px;
        height: auto;
        min-height: 50px;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
    }  
    .sub1 {
        width: 22%;
        margin-left: 10px;
        margin-bottom: 0;
    }  
    .modal-card {
        width: 90%;
    }
    
    .popup-content {
        width: 80%;
        margin: 80px auto;
    }
    a{
        text-align: center;
        width: 65%;
        margin-left: 35px;
        margin-right: 35px;
    } 
}
@media screen and (max-width: 480px) {
    .nav-menu {
        display: none;
        gap: 10px;
        font-size: 16px;
        margin-left: 0;
        display: none;
    }   
    .nav-menu li {
        padding: 5px;
    }    
    .s1 {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        height: auto;
        position: relative !important;
        height: 105px !important;  /* Fixed height for 3 lines */
        padding: 5px !important;
        margin-bottom: 15px !important;
        background: snow !important;
        border-radius: 16px !important;
    }
    .s1 > :first-child {
        position: absolute !important;
        top: 8px !important;
        left: 10px !important;
        font-weight: bold !important;
    }
     #c1, #c2, #c3, #c4, #c5, #c6, #c7, #c8 {
        position: absolute !important;
        top: 40px !important;
        left: 10px !important;
        width: 42% !important;
        height: 30px !important;
        margin: 0 !important;
        border-radius: 10px !important;
        margin-bottom: 10px !important;
        font-weight: bold !important;
    }
     #m1, #m2, #m3, #m4, #m5, #m6, #m7, #m8 {
        position: absolute !important;
        top: 40px !important;
        right: 10px !important;
        width: 42% !important;
        height: 30px !important;
        margin: 0 !important;
        border-radius: 10px !important;
        font-weight: bold !important;
    }
    .gp-display {
        position: absolute !important;
        bottom: 14px !important;
        transform: translateX(-50%) !important;
        width: 60px !important;
        min-width: 60px !important;
        height: 25px !important;
        margin: 0 !important;
        padding: 2px 0 !important;
        text-align: center !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: #4CAF50 !important;
        color: white !important;
        border-radius: 15px !important;
        font-size: 14px !important;
        left: 50% !important;
        right: auto !important;
        top: auto !important;
        margin-top: 0 !important;
        padding-top: 0 !important;
    }
    .div-2 {
        width: 90%;
        padding: 10px;
        height: auto;
        margin-right: 20px;
    }  
    .main-div{
        margin-left: 16px;
        margin-right: 16px;
    }  
    .footer {
        padding: 30px 0 0 0;
    }    
    .footer-section h3 {
        font-size: 1.1rem;
    }   
    .social-links {
        align-items: center;
    }   
    .footer-bottom p {
        font-size: 0.8rem;
    }
     #footer-section-1 {
        margin-bottom: 0px !important;
        padding-bottom: 0px !important;
        gap: 0px !important;
        margin-top: 3px !important;
    }
    .footer-section{
        flex: 0 0 0px !important;
    }
    .sub1 {
        width: 100%;
        margin-left: 0;
        margin-bottom: 5px;
    }    
    button {
        width: 100%;
        max-width: 200px;
        margin: 10px auto;
    }   
    .modal-card {
        width: 95%;
    }    
    .modal-header {
        padding: 15px;
    }   
    .modal-body {
        padding: 15px;
    }    
    .popup-content {
        width: 90%;
        padding: 20px;
        margin: 50px auto;
    }   
    .result-row {
        flex-direction: column;
        gap: 5px;
    }
    a{
        text-align: center;
        width: 65%;
        margin-left: 35px;
        margin-right: 35px;
    }
    .detail-sec{
    width: 160px !important;
    margin-top: 15px;
    padding-right: 20px;
    font-size: 16px;
    padding-left: 1px;
    width: 70px;
}
#det{
    gap: 10px !important;
    margin: 1px;
    padding: 2px;
}
.result-div{
    padding-top: 0% !important;
    align-items: center ;
    margin-top: 0% !important;
    border-radius: 20px;
    border: 0px solid black;
    width: 330px;
    height: 150px;
    background-color: #ffffff;
    margin-bottom: 20px;
    box-shadow:0 5px 10px rgba(223, 217, 217, 0.5);
    gap: 2px;  
}
 .half-meter {
    padding-top: 2px;
    width: 20px !important;
    top: 20px !important;
    bottom: 50px !important;
    margin-left: 7px !important;
}
.half-reading{
    bottom: 25px !important;
    font-size: 12px !important;
}
.half-circle {
    background: #546079;
    border-radius: 250px 250px 0 0;
    width: 130px;
    height: 60px;
    margin: 0 auto;
    position: relative;
    border: 8px solid #4a5568;
    border-bottom: none;
    box-shadow: inset 0 10px 20px rgba(0,0,0,0.5);
    overflow: hidden;
    margin-right: 300px !important;
    margin-top: 10px;
}      
}  
@media screen and (max-width: 360px) {
    .s1 {
        position: relative !important;
        height: 105px !important;  /* Fixed height for 3 lines */
        padding: 10px !important;
        margin-bottom: 15px !important;
        background: snow !important;
        border-radius: 16px !important;
    }
    .s1 > :first-child {
        position: absolute !important;
        top: 8px !important;
        left: 10px !important;
        font-weight: bold !important;
    }
    #c1, #c2, #c3, #c4, #c5, #c6, #c7, #c8 {
        position: absolute !important;
        top: 40px !important;
        left: 10px !important;
        width: 42% !important;
        height: 30px !important;
        margin: 0 !important;
        border-radius: 10px !important;
        margin-bottom: 10px !important;
        font-weight: bold !important;
    }
    #m1, #m2, #m3, #m4, #m5, #m6, #m7, #m8 {
        position: absolute !important;
        top: 40px !important;
        right: 10px !important;
        width: 42% !important;
        height: 30px !important;
        margin: 0 !important;
        border-radius: 10px !important;
        font-weight: bold !important;
    }
    .gp-display {
        position: absolute !important;
        bottom: 14px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: 60px !important;
        min-width: 60px !important;
        height: 25px !important;
        margin: 0 !important;
        padding: 2px 0 !important;
        text-align: center !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: #4CAF50 !important;
        color: white !important;
        border-radius: 15px !important;
        font-size: 14px !important;
        left: 50% !important;
        right: auto !important;
        top: auto !important;
        margin-top: 0 !important;
        padding-top: 0 !important;
    }
    .footer {
        padding: 30px 0 0 0;
        margin-right: 0px;
        width: 100%;
        margin: 0px;
        margin-left: 0px;
        padding-left: 0px;
        margin-top: 60px;
    }   
    
    .footer-content {
        gap: 1px;
        padding-bottom: 0px;
    } 
    
    #footer-section-1 {
        margin-bottom: 0px !important;
        padding-bottom: 0px !important;
        gap: 0px !important;
        margin-top: 3px !important;
    }
    
    .footer-section {
        flex: 0 0 0px !important;
    }
    
    .footer-section h3 {
        font-size: 1.1rem;
    }   
    
    .social-links {
        align-items: center;
    }  
    
    a {
        text-align: center;
        width: 65%;
        margin-left: 35px;
        margin-right: 35px;
    } 
    
    .footer-bottom p {
        font-size: 0.8rem;
    }
    
    .main-div {
        margin-left: 16px;
        margin-right: 16px;
    }
    
    .div-2 {
        padding: 10px;
        margin-right: 1px !important;
    }   
    
    .nav-menu {
        flex-direction: column;
        gap: 2px;
        display: none;
    }   
    
    .nav-menu li {
        text-align: center;
    }   
    
    h1 {
        font-size: 24px;
    }
    .result-row span,
    .result-row strong {
        font-size: 13px !important;
    }
    .half-meter {
    padding-top: 2px;
    width: 20px !important;
    top: 20px !important;
    bottom: 50px !important;
    margin-left: 7px !important;
}
.half-circle {
    background: #546079;
    border-radius: 250px 250px 0 0;
    width: 130px;
    height: 60px;
    margin: 0 auto;
    position: relative;
    border: 8px solid #4a5568;
    border-bottom: none;
    box-shadow: inset 0 10px 20px rgba(0,0,0,0.5);
    overflow: hidden;
    margin-right: 300px !important;
    margin-top: 10px;
}
.result-div{
    padding-top: 0% !important;
    align-items: center ;
    margin-top: 0% !important;
    border-radius: 20px;
    border: 0px solid black;
    width: 330px;
    height: 150px;
    background-color: #a6eba0;
    margin-bottom: 20px;
    box-shadow:0 5px 10px rgba(223, 217, 217, 0.5);
    gap: 2px;  
}
.detail-sec{
    width: 160px !important;
    margin-top: 15px;
    padding-right: 20px;
    font-size: 16px;
    padding-left: 1px;
    width: 70px;
}
#det{
    gap: 10px !important;
    margin: 1px;
    padding: 2px;
}
}
.footer-bottom {
    margin-bottom: 0;
    padding-bottom: 15px;
}  

