/* File: app/code/Threedadv/Subscription/view/frontend/web/css/style.css */

/* -------------------------------- */
/*             PESTAÑAS            */
/* -------------------------------- */
.tabs {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
    border-bottom: 3px solid var(--Palettes-Primary-5, #111111);
    background: var(--Neutral-0, #FFFFFF);
}
.tabs .tab-item {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px 0;
    cursor: pointer;
    color: var(--Neutral-70, #5F5E5E);
    background: var(--Neutral-0, #FFFFFF);
    font-family: Inter, sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 24px;
    transition: background 0.2s, color 0.2s;
}
.tabs .tab-item:not(.active):hover {
    background: var(--Neutral-10, #F5F5F5);
}
.tabs .tab-item.active {
    margin-bottom: -3px; /* “Levanta” la pestaña sobre la línea */
    color: var(--Palettes-Primary-90, #111111);
    font-weight: 600;
}
.tabs .tab-item .tab-icon {
    width: 24px;
    height: 24px;
    margin-right: 8px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
.tabs .tab-item .tab-icon.factura {
    background-image: url('../images/icon-factura.svg');
}
.tabs .tab-item .tab-icon.suscripcion {
    background-image: url('../images/icon-suscripcion.svg');
}

/* -------------------------------- */
/*            ENCABEZADO           */
/* -------------------------------- */
.invoice-header {
    margin: 32px 0 8px;
}
.invoice-header-title {
    font-family: Inter, sans-serif;
    font-size: 28px;
    font-weight: 700;
    line-height: 36px;
    color: var(--Palettes-Primary-90, #111111);
    margin: 0 0 4px;
}
.invoice-header-subtitle {
    font-family: Inter, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
    color: var(--Neutral-70, #5F5E5E);
    margin: 0;
}

/* -------------------------------- */
/*         FORMULARIO DE BÚSQUEDA   */
/* -------------------------------- */
.invoice-search-form {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
    max-width: 100%;
}
.invoice-search-input,
.invoice-search-button {
    box-sizing: border-box;
    height: 56px !important;
    font-family: Inter, sans-serif;
}
.invoice-search-input {
    flex: 1;
    padding: 0 16px 0 44px !important;
    font-size: 14px !important;
    line-height: 20px !important;
    color: var(--Neutral-900, #333333);
    background: var(--Neutral-0, #FFFFFF) url('../images/icon-search.svg') no-repeat 16px center;
    background-size: 16px;
    border: 1px solid var(--Neutral-20, #E0E0E0);
    border-radius: 8px;
    outline: none;
}
.invoice-search-input::placeholder {
    color: var(--Neutral-40, #CCCCCC);
}
.invoice-search-button {
    flex: 0 0 160px;
    min-width: 160px;
    padding: 0 24px;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: var(--Neutral-0, #FFFFFF);
    background: var(--Palettes-Primary-5, #111111);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}
.invoice-search-button:hover {
    background: var(--Palettes-Primary-7, #333333);
}

/* -------------------------------- */
/*          CONTENIDO AJAX         */
/* -------------------------------- */
.tab-content {
    padding: 24px;
    border: 1px solid var(--Neutral-20, #E0E0E0);
    border-top: none;
    border-radius: 0 0 8px 8px;
    background: var(--Neutral-0, #FFFFFF);
}

/* -------------------------------- */
/*         TABLA DE RESULTADOS      */
/* -------------------------------- */
.tab-content .data.table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--Neutral-20, #E0E0E0);
    border-radius: 8px;
    overflow: hidden;
    background: var(--Neutral-0, #FFFFFF);
    table-layout: fixed;
}
.tab-content .data.table thead {
    background: var(--Palettes-Primary-5, #111111);
}
.tab-content .data.table thead th {
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--Neutral-0, #FFFFFF);
    text-transform: uppercase;
    padding: 16px;
    text-align: left;
    border-bottom: none;
    white-space: nowrap;
}
.tab-content .data.table tbody tr:nth-child(odd) {
    background: var(--Neutral-0, #FFFFFF);
}
.tab-content .data.table tbody tr:nth-child(even) {
    background: var(--Neutral-10, #F5F5F5);
}
.tab-content .data.table tbody td {
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: var(--Neutral-900, #333333);
    padding: 12px 16px;
    border-bottom: 1px solid var(--Neutral-20, #E0E0E0);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* Sin borde en la última fila */
.tab-content .data.table tbody tr:last-child td {
    border-bottom: none;
}
/* Anchos de columnas */
.tab-content .data.table th:nth-child(1),
.tab-content .data.table td:nth-child(1) { width: 5%; }
.tab-content .data.table th:nth-child(2),
.tab-content .data.table td:nth-child(2) { width: 10%; }
.tab-content .data.table th:nth-child(3),
.tab-content .data.table td:nth-child(3) { width: 25%; white-space: normal; word-break: break-word; }
.tab-content .data.table th:nth-child(4),
.tab-content .data.table td:nth-child(4) { width: 15%; }
.tab-content .data.table th:nth-child(5),
.tab-content .data.table td:nth-child(5),
.tab-content .data.table th:nth-child(8),
.tab-content .data.table td:nth-child(8) {
    width: 15%;
    text-align: center;
}

.subscription-restaurant_listhistory-index .table:not(.cart):not(.totals) > thead > tr > th,
.subscription-restaurant_listhistory-index .table:not(.cart):not(.totals) > thead > tr > td {
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap !important;
}



.subscription-restaurant_listhistory-index .modal-header{
    display: none !important;
}

.subscription-restaurant_listhistory-index .modal-content{
    width: 100% !important;
}

.subscription-restaurant_listhistory-index .modal-inner-wrap{
    max-width: 600px;
    border-radius: 28px;
    background:  #111111 !important;
}

.subscription-restaurant_listhistory-index .form-actions{
    margin-top: 18px;
    justify-self: right;
}

.subscription-restaurant_listhistory-index .saved-cards__editform-btn{
    display: flex;
    align-items: center;
    border-radius: 4px;
    border: solid 2px white !important;
    background: #111111;
    padding: 5px 16;
    height: 35px;
}
.custom-modal-header-content-suscription {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0px;
}

@media only screen and (max-width: 768px) {
    .subscription-restaurant_listhistory-index .add-card-popups.modal-slide{
        left: 0px !important;
        border-radius: 0;
    }

    .subscription-restaurant_listhistory-index .modal-inner-wrap,
    .subscription-restaurant_listhistory-index .modal-content{
        width: 100% !important;
        max-width: 1200px;
        border-radius: 0;
    }
}


.tab-content .data.table th:nth-child(6),
.tab-content .data.table td:nth-child(6) {
    width: 15%;
    text-align: right;
}
.tab-content .data.table th:nth-child(7),
.tab-content .data.table td:nth-child(7) {
    width: 10%;
    text-align: center;
}
.tab-content .data.table th:nth-child(9),
.tab-content .data.table td:nth-child(9) {
    width: 10%;
    text-align: center;
}

/* -------------------------------- */
/*            PAGINADOR            */
/* -------------------------------- */
.pager {
    margin-top: 24px;
    text-align: center;
    overflow: auto;
}
.pager .pagination {
    list-style: none;
    display: inline-flex;
    gap: 8px;
    padding: 0;
    margin: 0;
}
.pager .pagination li a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    font-family: Inter, sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: var(--Neutral-900, #111111);
    background: var(--Neutral-0, #FFFFFF);
    border: 1px solid var(--Neutral-20, #E0E0E0);
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}
.pager .pagination li a:hover {
    background: var(--Neutral-10, #F5F5F5);
}
.pager .pagination li.active a {
    background: var(--Palettes-Primary-5, #111111);
    color: var(--Neutral-0, #FFFFFF);
    border-color: var(--Palettes-Primary-5, #111111);
}
.pager .pagination li.disabled a {
    color: var(--Neutral-40, #CCCCCC);
    border-color: var(--Neutral-20, #E0E0E0);
    cursor: default;
    opacity: 0.6;
}
/* Flechas prev/next */
.pager .pagination li a[data-page="prev"]::before {
    content: '«';
    margin-right: 4px;
}
.pager .pagination li a[data-page="next"]::after {
    content: '»';
    margin-left: 4px;
}

/* -------------------------------- */
/*           RESPONSIVE            */
/* -------------------------------- */
@media (max-width: 768px) {
    .tabs .tab-item {
        padding: 12px 0;
        font-size: 14px;
        line-height: 20px;
    }
    .invoice-header-title {
        font-size: 24px;
        line-height: 32px;
    }
    .invoice-header-subtitle {
        font-size: 14px;
        line-height: 20px;
    }
    .invoice-search-input,
    .invoice-search-button {
        height: 40px;
        font-size: 13px;
        line-height: 18px;
    }
    .tab-content .data.table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .tab-content .data.table thead,
    .tab-content .data.table tbody {
        display: table;
        width: 100%;
        table-layout: fixed;
    }
    .tab-content .data.table th,
    .tab-content .data.table td {
        white-space: nowrap;
    }
    .pager .pagination {
        flex-wrap: wrap;
        justify-content: center;
        gap: 4px;
    }
}

@media (max-width: 480px) {
    .tabs {
        flex-direction: column;
        border-bottom: none;
    }
    .tabs .tab-item {
        justify-content: flex-start;
        padding: 12px;
        border-bottom: 1px solid var(--Neutral-20, #E0E0E0);
        margin-bottom: 0;
    }
    .tabs .tab-item.active {
        border-left: 3px solid var(--Palettes-Primary-5, #111111);
    }
    .invoice-search-form {
        flex-direction: column;
    }
    .invoice-search-button {
        width: 100%;
        flex: 0 0 50px !important;
    }
    .tab-content .data.table {
        font-size: 12px;
    }
    .tab-content .data.table th,
    .tab-content .data.table td {
        padding: 8px 12px;
    }
    .pager .pagination li a {
        padding: 6px 8px;
        font-size: 12px;
    }
}

/* cabezeras sortables */
.tab-content th.sortable {
    cursor: pointer;
    position: relative;
    user-select: none;
}
.tab-content .sort-icon {
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 6px;
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
    opacity: 0.6;
}
/* icono ascendente */
.tab-content .sort-icon.asc {
    background-image: url('../images/icon-sort-asc.svg');
}
/* resaltar al hover */
.tab-content th.sortable:hover .sort-icon {
    opacity: 1;
}
.invoice-search-label {
    font-family: Inter;
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    letter-spacing: 0.15px;
    vertical-align: middle;
}
/* Override label solo en esta página */
body.subscription-restaurant-listhistory-index .invoice-search .invoice-search-label {
    display: block !important;
    font-family: Inter, sans-serif !important;
    font-weight: bold !important;
    font-size: 16px !important;
    line-height: 24px !important;
    letter-spacing: 0.15px !important;
    color: var(--Neutral-900, #333333) !important;
    margin-bottom: 8px !important;
}


.modal-overlay{
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6)!important;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.modal-content {
    background: #111111 /*#fff  */;
    border-radius: 8px;
    overflow: hidden;
    width: 90%; max-width: 600px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    position: relative;
    padding: 24px;
}
.modal-close {
    position: absolute;
    top: 12px; right: 12px;
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

.modal-close-invoice {
    background: #111111 !important;
}
.invoice-modal .modal-header-content{
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.invoice-modal .modal-body .modal-header{
    color: #FFFFFF;
    font-family: 'Inter';
}

@media screen and (max-width: 456px) {
    .invoice-modal .three-columns-fieldset {
        display: flex !important;
        flex-direction: column;
    }
    
}

.modal-body {
    margin-top: 16px;
}
.icon-detalle, .icon-download, .icon-email, .icon-edit {
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 12px;
    cursor: pointer;
}
.icon-detalle { background: url('../images/icon-detalle.svg') center center no-repeat; }
.icon-download{ background: url('../images/icon-download.svg') center center no-repeat; }
.icon-email   { background: url('../images/icon-email.svg') center center no-repeat; }
.icon-edit   { background: url('../images/icon-edit.svg') center center no-repeat; }
.tab-content .data.table th:nth-child(9), .tab-content .data.table td:nth-child(9) {
    width: 15%;
    text-align: center;
}

.three-columns-fieldset {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    border: none;
    padding: 0;
}
.three-columns-fieldset {
    color: #ffffff;
}
.lab-select {
    color: #ffffff !important;
    font-size: 15px !important;
}


/* estilos de el select modal virtualproduct */
.custom-modal-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between !important;
}
.modal-fact__title {
    color: #ffffff !important;
}

.select-card-lab {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 400px; 
  margin-bottom: 5px;
}

.select-card-lab label {
  font-size: 16px;
  margin-bottom: 6px;
  color: #333;
}

.slecstyle {
  width: 100%;
  padding: 0px 5px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fff;
  transition: border-color 0.3s;
}

.slecstyle:focus {
  outline: none;
}

@media (max-width: 768px) {
  .select-card-lab {
    max-width: 100%;
  }

  .slecstyle {
    font-size: 14px;
    padding: 6px 10px;
  }
}
/* estilos para buttons modal virtualproduct */
.sty-custm-b {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 800px;
  margin: 0 auto;
}
.sty-custm-b2 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 800px;
  margin: 0 auto;
}

.open-card-cust,
.pay-pending-cust {
  border-radius: 4px;
  padding: 5px 16px;
  font-size: 16px;
  cursor: pointer;
  background-color: #111;
  border: 2px solid white !important;
  color: white;
}

.open-card-cust {
  margin-right: auto;
}

.pay-pending-cust {
  margin-left: auto;
}

@media (max-width: 480px) {
  .sty-custm-b {
    flex-direction: column;
    align-items: stretch;
  }

  .open-card-cust,
  .pay-pending-cust {
    width: 100%;
    margin: 0;
  }
}



.table-scroll {
    overflow-x: auto;
    width: 100%;
    margin-bottom: 1rem;
}

.table-scroll .data.table {
    min-width: 1000px;
    width: auto;
    table-layout: auto;
}

.table-scroll .data.table th,
.table-scroll .data.table td {
    white-space: nowrap;
}
.suscription-new-form-custm {
    margin-top: 5% !important;
}
.title-subs {
    color: #ffffff;
}
.field-group-subsc {
    color: #ffffff;
}
.field.card-suscription label {
    margin-top: 5% !important;
}

.field-group-subsc select,
.field-group-subsc input {
  min-height: 35px !important;
  height: 35px !important;
  line-height: 15px !important;
  padding: 0px 12px !important;
  border-radius: 6px !important;
  box-sizing: border-box !important;
  color: #555 !important; 
  appearance: none;
}

.field-group-subsc select {
  color: #555 !important;
}
.field-group-subsc select option {
  color: #555 !important;
}
.field-group-subsc select:valid {
  color: #555 !important;
}


.suscription-new-btn {
    flex: 0 0 160px;
    min-width: 160px;
    padding: 0 24px;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: var(--Neutral-0, #FFFFFF);
    background: var(--Palettes-Primary-5, #111111);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}

div.suscription-new {
    text-align: right;
}

.pay-now-button {
    flex: 0 0 160px;
    min-width: 160px;
    padding: 0 24px;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    color: var(--Neutral-0, #FFFFFF);
    background: var(--Palettes-Primary-5, #767676);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}
.pay-now-button:hover {
    background: var(--Palettes-Primary-7, #bdbcbc);
}