/* Estilos responsive generales */

.container-img-mobile{
    display: none;
}

@media (max-width: 1367px) {
.history{
    height: 480px;
}



.history-title {
    position: absolute;
    top: 5%;
    width: 234px;
    left: 20%;
    left: calc(100% - 15px);
}
    .timeline-years{
        right: 8%;
    }


    .main-content {
        
        top: 12.5%;
        left: calc(100% - 15px);
    }
    .main-content.active {
        opacity: 1;
        visibility: visible;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 12.5%;
        left: calc(100% - 15px);
    }
    .history-img{
        left: 46%;
    }
}

@media (max-width: 1200px) {
    .main-content {
        opacity: 1;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        left: calc(100% - 71px);
    }
    .main-content.active {
        opacity: 1;
        visibility: visible;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        left: calc(100% - 71px);
    }    

    .history-title {
    
        left: calc(100% - 66px);
    }
}
/* Tablets y dispositivos medianos */
@media (max-width: 991px) {
    
    .navbar-header{
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    #nGp52 > ol > li:nth-child(1) {
        height: 14px!important;
        overflow: hidden;
    }
    #nGp52 > ol > li:nth-child(2) {
        height: 14px!important;
        overflow: hidden;
    }
    #nGp52 > ol > li:nth-child(3) {
        height: 14px!important;
        overflow: hidden;
    }

    .navbar-brand{
        width: 300px;
    }
    .section-slider {
        height: 100vh !important;
    }

    .section-slider h1 {
        font-size: 35px;
    }

    .section-slider p {
        font-size: 16px;
    }

    .overlay-content {
        padding: 30px 15px;
    }

    .section-slider .bg-cover {
        display: flex;
        justify-content: flex-end;
        overflow: hidden;
    }

    .section-slider .bg-cover img {
        object-position: right center;
        min-width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .section-two-blocks {
        height: auto !important;
        padding: 0px 0!important;
        background-position: right center !important;
    }

    .section-two-blocks[data-parallax="scroll"] {
        background-attachment: scroll !important;
        background-position: right center !important;
    }
    .section-two-blocks .row > [class*="col-"] {
        min-height: 500px;
    }
  
    .section-two-blocks .row > div {
        width: 100%;
    }

    .section-two-blocks .content {
        padding: 30px 15px;
        text-align: center;
        background: rgba(255,255,255,0.9);
    }
    .parallax-slider{
        left: unset!important;
        width: 100%!important;
        object-fit: cover!important;
        object-position: 86% 100%!important;
        transform: translateX(0)!important;
    }

    .tractor-section {
        padding: 60px 5%;
    }

    .tractor-section h2 {
        font-size: 24px;
        padding: 0 20px;
        margin-bottom: 40px;
    }

    .tractor-container {
        flex-direction: column;
        gap: 30px;
    }

    .tractor-info {
        flex-direction: row;
        max-width: 100%;
        gap: 30px;
        justify-content: center;
    }

    .tractor-info .info {
        max-width: 250px;
    }

    .tractor-image img {
        max-width: 400px;
    }

    /* Ajustes de las líneas de conexión para tablet */
    .tractor-info.left .info::after,
    .tractor-info.right .info::after {
        width: 100px;
    }

    .tractor-info.left .info::before,
    .tractor-info.right .info::before {
        display: none;
    }

    .tractor-info.left .info:nth-child(2)::after,
    .tractor-info.right .info:nth-child(2)::after {
        width: 100px;
        bottom: 0;
    }
    .main-content {
        opacity: 1;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 35%;
        left: 60%;
    }
    .main-content.active {
        opacity: 1;
        visibility: visible;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 35%;
        left: 60%;
    }

    .grid-table-xxs-12 {
        margin: 30px 0;
        width: 100%!important;
    }
    
    .grid-table-xxs-12 .icon-box {
        padding: 20px;
        display: flex;
        align-items: center;
    }
    
    .grid-table-xxs-12 .icon-box-cell {
        padding-right: 15px;
    }
    
    .grid-table-xxs-12 .icon-box-cell:last-child {
        max-width: calc(100% - 55px);
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-m {
        font-size: 16px;
        margin-bottom: 5px;
        display: block;
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-s {
        font-size: 14px;
        line-height: 1.4;
        display: block;
    }
    
    .grid-table-xxs-12 .icon-box-cell i {
        font-size: 32px !important;
    }

    .contact-section {
        padding: 40px 20px;
    }

    .contact-container {
        width: 95%;
        gap: 20px;
    }

    .contact-img {
        max-width: 280px;
    }

    .contact-content {
        font-size: 15px;
    }

    .contact-logo {
        max-width: 160px;
    }

    .services {
        height: auto;
        min-height: 70vh;
        padding: 60px 0;
    }

    .services-content {
        max-width: 90%;
    }

    .services-content h2 {
        font-size: 26px;
        margin-bottom: 15px;
    }

    .services-content p {
        font-size: 16px;
        margin-bottom: 15px;
    }

    .services-stats {
        gap: 40px;
        flex-wrap: wrap;
        margin-top: 25px;
    }

    .services-stats .stat {
        flex: 0 0 calc(33.333% - 30px);
    }

    .services-stats .stat i {
        font-size: 32px;
    }

    .services-stats .stat .label {
        font-size: 15px;
    }

    .footer-base {
        padding: 40px 20px;
        text-align: center;
    }

    .footer-base .logo {
        max-width: 200px;
        margin: 0 auto;
    }

    .footer-base .social-group {
        justify-content: center !important;
    }

    .footer-base .text-black {
        margin-top: 30px;
    }

    .footer-base .ul-squares {
        padding-left: 0;
    }

    .footer-base .ul-squares li {
        list-style: none !important;
        margin-bottom: 8px;
        text-align: center;
    }

    .footer-base .footer-menu {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }

    .footer-base .truck {
        max-width: 200px;
        margin: 20px auto 0;
    }

    .history-title {
        font-size: 2rem;
        margin-bottom: 1.5rem;
    }
}

/* Móviles y dispositivos pequeños */
@media (max-width: 769px) {
    #marcas > ul > div.panel.active > div.row > table > tbody > tr > td{
        width: 100%;
    }

    #marcas-table > tbody > tr:nth-child(2) > td:nth-child(1){
        padding-top: 0;
    }

    .navbar-header{
        display: flex!important;
        align-items: center!important;
        justify-content: space-between!important;
    }
    .navbar-right-custom{
        display: flex!important;
    }   
    .navbar-logo-container{
        display: none;
    
    }  

    .container-img-mobile{
        display: block;
        height: 70vh;
        position: relative;
    }
   .img-mobile{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url(../images/seccion3_op1.jpg);
    background-size: cover;
    background-position: 80% 100%;
    background-repeat: no-repeat;
   }
   body > div.section-two-blocks.blocks-right > div > div:nth-child(1){
    display: none;
   }
  
    .history-img{
        display: none;
    }
    .section-slider {
        height: 100vh !important;
    }

    .section-slider h1 {
        font-size: 28px;
        line-height: 1.3;
    }

    .section-slider p {
        font-size: 14px;
    }

    .overlay-content {
        padding: 20px 10px;
    }

    .col-md-6 {
        width: 100%;
        padding: 0 15px;
    }

    .space-250 {
        height: 150px !important;
    }

    .section-slider .bg-cover {
        display: flex;
        justify-content: flex-end;
        overflow: hidden;
    }

    .section-slider .bg-cover img {
        min-width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: 100% 100%!important;
    }

    .section-two-blocks {
        padding: 40px 0;
        background-position: right center !important;
    }

    .section-two-blocks .content {
        padding: 20px 15px;
        margin: 0 15px;
        background: rgba(255,255,255,0.9);
    }

    .tractor-section {
        padding: 40px 20px;
    }

    .tractor-section h2 {
        font-size: 20px;
        margin-bottom: 30px;
    }

    .tractor-container {
        gap: 20px;
    }

    .tractor-info {
        flex-direction: column;
        gap: 20px;
    }

    .tractor-info .info {
        max-width: 100%;
        text-align: center !important;
        padding: 15px;
    }

    .tractor-image img {
        max-width: 300px;
    }

    /* Ocultar líneas de conexión en móvil */
    .tractor-info .info::after,
    .tractor-info .info::before {
        display: none;
    }

    .tractor-info.left,
    .tractor-info.right {
        text-align: center;
    }

    .tractor-info p {
        font-size: 13px;
    }

    .main-content {
        opacity: 1;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 8.5%;
        left: 28%;
        width: 75%;
    }
    
    .main-content.active {
        opacity: 1;
        visibility: visible;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 8.5%;
        left: 28%;
        width: 75%;
    }

    .history-title {
        position: absolute;
        top: 1%;
        width: 312px;
        left: 20%;
        left: calc(100% - 339px);
        font-size: 2.8rem !important;
    }

    .timeline-years {
      
        transform: translateY(-56%);
    }
    .history-content {
        width: 90%;

    }
    .main-content p {
        color: #4C4C4C;
        line-height: 1.6;
        margin-bottom: 0.5rem;
        max-width: 100%;
        font-size: .95rem;
        text-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
        text-align: right;
    }

    .grid-table-xxs-12 tr {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }
    
    .grid-table-xxs-12 td {
        width: 100%;
        display: block;
        border: none !important;
        padding: 0;
    }
    
    .grid-table-xxs-12 .icon-box {
        padding: 15px;
        justify-content: flex-start;
        border-bottom: 1px solid rgba(0,0,0,0.1);
    }
    
    .grid-table-xxs-12 .icon-box-cell:last-child {
        max-width: calc(100% - 45px);
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-m {
        font-size: 15px;
        margin-bottom: 4px;
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-s {
        font-size: 13px;
        line-height: 1.4;
    }

    .contact-section {
        padding: 30px 15px;
    }

    .contact-container {
        flex-direction: column;
        width: 100%;
        text-align: center;
    }

    .contact-img {
        max-width: 250px;
        margin-right:  0;
        margin-bottom: 20px;
    }

    .contact-content {
        font-size: 14px;
        padding: 0 15px;
    }

    .contact-content p {
        margin-bottom: 8px;
    }

    .contact-logo {
        max-width: 140px;
        margin-left: 0;
        margin-top: 20px;
    }

    .services {
        min-height: 80vh;
        padding: 40px 0;
    }

    .services-content {
        max-width: 95%;
        padding: 15px;
    }

    .services-content h2 {
        font-size: 22px;
        margin-bottom: 12px;
    }

    .services-content p {
        font-size: 14px;
        margin-bottom: 12px;
        padding: 0 10px;
    }

    .services-stats {
        gap: 25px;
        margin-top: 20px;
        justify-content: center;
    }

    .services-stats .stat {
        flex: 0 0 calc(50% - 20px);
        text-align: center;
    }

    .services-stats .stat i {
        font-size: 28px;
        margin-bottom: 8px;
    }

    .services-stats .stat .label {
        font-size: 14px;
        line-height: 1.3;
    }

    .footer-base {
        padding: 30px 15px;
    }

    .footer-base .logo {
        max-width: 180px;
    }

    .footer-base .col-md-3 {
        margin-bottom: 30px;
    }

    .footer-base .text-black {
        margin-top: 20px;
        font-size: 18px;
    }

    .footer-base .text-s {
        font-size: 14px;
    }

    .footer-base .space-30 {
        height: 15px !important;
    }

    .footer-base .footer-menu a {
        padding: 5px 0;
    }

    .history-title {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }

}
/* Dispositivos muy pequeños */
@media (max-width: 500px) {
    .section-slider {
        height: 100vh !important;
    }

    .section-slider h1 {
        font-size: 24px;
    }

    .section-slider p {
        font-size: 13px;
    }

    .space-250 {
        height: 100px !important;
    }

    .section-slider .bg-cover {
        display: flex;
        justify-content: flex-end;
        overflow: hidden;
    }

    .section-slider .bg-cover img {
        object-position: right center;
        min-width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .section-two-blocks {
        padding: 30px 0;
        background-position: right center !important;
    }

    .section-two-blocks .content {
        padding: 15px;
        margin: 0 10px;
    }

    .tractor-section {
        padding: 30px 15px;
    }

    .tractor-section h2 {
        font-size: 18px;
        margin-bottom: 25px;
    }

    .tractor-image img {
        max-width: 250px;
    }

    .tractor-info .info {
        padding: 10px;
    }

    .tractor-info p {
        font-size: 12px;
        line-height: 1.4;
    }

    .timeline-years {
        transform: translateY(-50%);
    }

    .grid-table-xxs-12 .icon-box {
        padding: 12px;
    }
    
    .grid-table-xxs-12 .icon-box-cell i {
        font-size: 28px !important;
    }
    
    .grid-table-xxs-12 .icon-box-cell:last-child {
        max-width: calc(100% - 40px);
        display: flex ;
            flex-direction: column;
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-m {
        font-size: 14px;
        margin-bottom: 3px;
    }
    
    .grid-table-xxs-12 .icon-box-cell .text-s {
        font-size: 12px;
        line-height: 1.3;
    }
    .main-content {
        height: 377px;
        top: 12.5%;
        left: 7%;
    }
    

    .main-content.active {
        opacity: 1;
        height: 377px;
        visibility: visible;
        transform: translateX(0);
        transition: opacity 0.8s ease, transform 0.8s ease;
        top: 12.5%;
        left: 7%;
    }

    .history-title {
        position: absolute;
        top: 6%;
        width: 312px;
        left: 20%;
        left: calc(100% - 211px);
        font-size: 2.8rem !important;
    }


.timeline-years {
  
    top: 52%;
    height: 377px;
}

    .contact-section {
        padding: 25px 10px;
    }

    .contact-container {
        gap: 15px;
    }

    .contact-img {
        max-width: 200px;
        margin-bottom: 15px;
    }

    .contact-content {
        font-size: 13px;
    }

    .contact-content p {
        margin-bottom: 6px;
        line-height: 1.4;
    }

    .contact-logo {
        max-width: 120px;
        margin-top: 15px;
    }

    .services {
        min-height: 90vh;
        padding: 30px 0;
    }

    .services-content {
        max-width: 100%;
        padding: 10px;
    }

    .services-content h2 {
        font-size: 20px;
        margin-bottom: 10px;
        padding: 0 15px;
    }

    .services-content p {
        font-size: 13px;
        margin-bottom: 10px;
        padding: 0 15px;
        line-height: 1.4;
    }

    .services-stats {
        flex-direction: column;
        gap: 20px;
        margin-top: 15px;
        align-items: center;
    }

    .services-stats .stat {
        flex: 0 0 100%;
        max-width: 200px;
    }

    .services-stats .stat i {
        font-size: 24px;
        margin-bottom: 6px;
    }

    .services-stats .stat .label {
        font-size: 13px;
        line-height: 1.2;
    }

    .counter-box-icon{
        display: flex;
        justify-content: center;
        flex-direction: column;
        align-items: center;
        margin: 0;
        padding: 0;
    }

    .icon-box-cell{
        margin: 0!important;
        padding: 0!important;
    }
    .counter-box-icon .counter {
        text-align: center;
        padding: 0;
    }
    .counter-text{
        padding: 0!important;
        margin: 0!important;
    }

    body > div.section-two-blocks.blocks-right > div > div:nth-child(2) > div > table > tbody > tr > td:nth-child(1){
        width: 100vw;
        margin-bottom: 20px;
    }
    .footer-base {
        padding: 25px 10px;
    }

    .footer-base .logo {
        max-width: 160px;
    }

    .footer-base .text-black {
        font-size: 16px;
    }

    .footer-base .text-s {
        font-size: 13px;
    }

    .footer-base .social-group {
        flex-direction: column;
        gap: 10px;
    }

    .footer-base .social-group a {
        margin: 0 !important;
    }

    .footer-base .truck {
        max-width: 160px;
    }

    .history-title {
        font-size: 1.5rem;
        margin-bottom: 0.8rem;
    }
} 


@media (max-width: 360px) {
    .history-title {
   
    
        left: calc(100% - 197px);
    }
}