@tailwind base;
@tailwind components;
@tailwind utilities;

@layer components {
    .form-input {
        @apply px-4 py-3 rounded-xl text-sm text-gray-500 border !outline-none focus:ring-primary focus:border-primary;
    }
    .btn {
        @apply inline-block font-semibold text-sm px-4 py-3 rounded-xl;
    }
    .btn-sm {
        @apply px-3 py-2 text-sm rounded-lg;
    }
    .btn-primary {
        @apply bg-primary  text-white hover:bg-primary-dark transition-all ease-in-out duration-200;
    }
    .btn-outline {
        @apply text-primary border border-primary hover:bg-primary/10 transition-all ease-in-out duration-200;
    }

    .btn-primary-cust {
        @apply bg-yellowCustom text-white hover:bg-yellowDarkCust transition-all ease-in-out duration-200;
    }
}

.slick-prev,
.slick-next {
  width: 44px;
  height: 44px;
  top: 50%;
  position: absolute;
  background: #ffffff;
  border-radius: 50%;
  -webkit-border-radius: 50%;
  -moz-border-radius: 50%;
  -ms-border-radius: 50%;
  -o-border-radius: 50%;
  box-shadow: 0px 0px 18px 0px rgba(0, 0, 0, 0.39);
  -webkit-box-shadow: 0px 0px 18px 0px rgba(0, 0, 0, 0.39);
  -moz-box-shadow: 0px 0px 18px 0px rgba(0, 0, 0, 0.39);
  z-index: 2;
  opacity: 0.5;
}

.slick-prev:hover,
.slick-prev:focus,
.slick-next:hover,
.slick-next:focus {
  color: #232d42;
  background: #f7f7f7;
  opacity: 1;
}

.slick-prev:before,
.slick-next:before {
  font-family: 'fontAwesome';
  font-size: 20px;
  line-height: 1;
  opacity: 0.75;
  color: #232d42;
}
.slick-prev:before {
  content: '\f104';
}

.slick-next:before {
  content: '\f105';
}

.slick-prev {
  left: -10px;
}

.slick-next {
  right: -10px;
}

.slick-dots {
    bottom: -40px;
}

.slick-dots li {
    width: 12px;
    height: 12px;
}
.slick-dots li button {
    width: 12px;
    height: 12px;
    border: none;
    border-radius: 100%;
    background-color: #232d42;
    text-indent: -9999px;
    opacity: 0.8;
}

.slick-dots li.slick-active button {
    background-color: #FFB60D;
    opacity: 1;
}

.slick-list {
    padding: 0 20% 0 0;
}

.product-thumb {
    width: 100%;
    padding: 4px;
}

.product-thumb .product-thumb-inner {
    margin: 0;
    padding: 0;
    width: 100%;
    line-height: 0;
    display: block;
    overflow: hidden;
    position: relative;
    padding-top: calc(100% - 2px);
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    outline: transparent solid 1px;
    cursor: pointer;
}
.product-thumb .product-thumb-inner img, .embed-players {
    position: absolute;
    line-height: 0;
    width: auto;
    height: 100%;
    padding: 0;
    left: 50%;
    top: 50%;
    -webkit-transform: translateX(-50%) translateY(-50%);
    transform: translateX(-50%) translateY(-50%);
}

.product-thumb.slick-current .product-thumb-inner {
    cursor: default;
    border: 1px solid #FFA502;
}


/*-----------------------------------------
  Filter
-------------------------------------------*/
.select2-container--default
    .select2-selection--single
    .select2-selection__arrow {
    height: 26px !important;
    position: absolute;
    top: -3px;
    right: 1px;
    width: 20px;
}

.select-header .select2-container--default .select2-selection--single {
    background-color: #fff;
    border: 1px solid #e5e7eb;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    height: 46px;
    width: 100%;
}

.select2-container--default .select2-selection--single {
    background-color: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    height: 46px;
    width: 100%;
    -webkit-border-radius: 12px;
    -moz-border-radius: 12px;
    -ms-border-radius: 12px;
    -o-border-radius: 12px;
}
.select2-dropdown {
    border: 1px solid #e5e7eb;
    font-size: 14px;
}
.select2-container--default
    .select2-selection--single
    .select2-selection__rendered {
    padding-left: 12px;
    color: #666;
    line-height: 46px;
    font-size: 14px;
}
.select2-container--default .select2-results__option--highlighted[aria-selected] {
  background-color: #FFA502 !important;
  color: #ffffff;
}
.select2-container--default .select2-results__option--selected {
  background-color: #FFA502 !important;
  color: #ffffff;
}

.select2-container--default .select2-results__option[aria-selected="true"] {
    color: #232d42;
}
.select2-container--default
    .select2-selection--single
    .select2-selection__clear {
    margin-right: 10px;
}

.select2-container--default
    .select2-results__option--highlighted[aria-selected] {
    background-color: #dddddd;
    color: #fff;
}
.select2-container--default
    .select2-selection--single
    .select2-selection__arrow {
    top: 0;
}
.select2-container--default .select2-selection--single:focus {
    outline: none;
}
.select2-container--default
    .select2-selection--single
    .select2-selection__arrow
    b {
    top: 45%;
    left: -6px;
    margin-left: 0;
    border: none;
}

.select2-container .select2-selection .select2-selection__arrow b:before {
    content: "\f078";
    font-family: FontAwesome;
    font-size: 14px;
    color: #666;
}
.select2-container.select2-container--open
    .select2-selection
    .select2-selection__arrow
    b:before {
    content: "\f077";
    font-family: FontAwesome;
    font-size: 14px;
    color: #666;
}
/* .select2-container {
    margin-bottom: 14px;
} */

.select2-container .select2-search--dropdown .select2-search__field:focus {
    outline: 2px solid #FFA502 !important;
}
.glider-next,
.glider-prev {
    line-height: 0;
    box-shadow: rgba(145, 158, 171, 0.2) 0px 0px 2px 0px,
        rgba(145, 158, 171, 0.12) 0px 12px 24px -4px;
    -webkit-box-shadow: rgba(145, 158, 171, 0.2) 0px 0px 2px 0px,
        rgba(145, 158, 171, 0.12) 0px 12px 24px -4px;
    -moz-box-shadow: rgba(145, 158, 171, 0.2) 0px 0px 2px 0px,
        rgba(145, 158, 171, 0.12) 0px 12px 24px -4px;
}

.mt-4s {
    margin-top: 16px !important;
}

div:where(.swal2-container) div:where(.swal2-popup) {
    border-radius: 1rem;
}

.swal2-confirm {
    border-radius: 0.75rem;
}

#social-links ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

#social-links ul li {
    display: inline-block;
}

#social-links ul li a {
    padding: 20px;
    margin: 6px;
    font-size: 24px;
    color: black;
    background-color: #ccc;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s, color 0.3s;
}

#social-links ul li a:hover {
    background-color: blanchedalmond;
    color: peru;
}

/* CSS untuk tombol share */
.btn-social {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    /* Ukuran tombol */
    height: 50px;
    /* Ukuran tombol */
    border-radius: 50%;
    /* Membuat tombol bulat */
    color: white;
    font-size: 20px;
    /* Ukuran ikon */
    cursor: pointer;
    transition: background-color 0.3s ease;
    border: none;
}

.btn-facebook {
    background-color: #3b5998;
}

.btn-facebook:hover {
    background-color: #344e86;
}

.btn-twitter {
    background-color: #1da1f2;
}

.btn-twitter:hover {
    background-color: #1991db;
}

.btn-whatsapp {
    background-color: #25d366;
}

.btn-whatsapp:hover {
    background-color: #1da851;
}

.btn-linkedin {
    background-color: #0077b5;
}

.btn-linkedin:hover {
    background-color: #005f91;
}

.notyf__toast {
    font-size: 14px;
    border-radius: 12px;
    max-width: 330px;
}

.navbar {
    width: 100%;
    background-color: transparent;
    transition: all 0.15s ease;
    -webkit-transition: all 0.15s ease;
    -moz-transition: all 0.15s ease;
    -ms-transition: all 0.15s ease;
    -o-transition: all 0.15s ease;
}

.navbar-inverse {
    background-color: #FFFFFF;
}

.text-wrap-title-long {
    margin-top: 4rem;
}
.text-wrap-title-middle {
    margin-top: 20px;
}
.font-long-text {
    font-size: 24px;
    line-height: 36px;
}
.font-middle-text {
    font-size: 50px;
    line-height: 64px;
}

.font-short-text {
    font-size: 64px;
}

.text-wrap-title-long .text-price {
    font-size: 1.7rem;
}

.book-synopsis-short {
    top: 0;
}

.book-synopsis-middle {
    top: 2.5rem;
}

.category-button.selected {
    background-color: #ffa502;
    color: white;
}

#next-button.active {
    background-color: #ffa502;
    cursor: pointer;
}

#header-nav,
#bottom-menu {
    transition: transform 0.5s ease-in-out;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: flex-end;
}

.modal {
    background: #fff;
    width: 100%;
    height: 75%;
    max-width: 400px;
    padding: 30px 20px 0 20px;
    border-radius: 20px 20px 0 0;
    position: fixed;
    bottom: -100%;
    left: 0;
    right: 0;
    margin: auto;
    transition: bottom 0.3s ease-in-out;
}

.modal.show {
    bottom: 0;
}

.close-btn {
    cursor: pointer;
    /* text-align: right; */
    font-size: 18px;
    color: #333;
}

.step-active {
    background-color: #ffa503;
    color: white;
}

.step-completed {
    background-color: #10b981;
    color: white;
}

@media only screen and (max-width: 480px) {
    .notyf {
        padding: 16px;
    }
}

/* Affiliator Dashboard */
#sidebar {
    transform: translateX(0);
}
@media (max-width: 768px) {
    #sidebar {
        transform: translateX(-100%);
        position: fixed;
        top: 0;
        left: 0;
        height: 100%;
        z-index: 50;
    }
    #sidebar.translate-x-0 {
        transform: translateX(0) !important;
    }
}

.active-nav {
    font-weight: 700;
    /* background-color: rgba(255, 165, 3, 0.2); */
    /* border-left: 4px solid #ffa503; */
    background: linear-gradient(45deg,rgba(255, 154, 2, 1) 0%, rgba(253, 187, 45, 1) 100%);
    color: #FFFFFF;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.tooltip {
    visibility: hidden;
    position: absolute;
    background-color: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.3s;
}

.has-tooltip:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

.stats-card {
    background: white;
    border-radius: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
}

.stats-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.link-card {
    border-left: 4px solid #ffa503;
    transition: all 0.3s ease;
}

.link-card:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.copy-btn {
    transition: all 0.2s ease;
}

.copy-btn:hover {
    background-color: #f0f0f0;
}

.copy-btn.copied {
    background-color: #10b981;
    color: white;
}

.progress-bar {
    height: 6px;
    border-radius: 3px;
    background-color: #e5e7eb;
}

.progress-fill {
    height: 100%;
    border-radius: 3px;
    background-color: #ffa503;
}

.pagination .page-item.active .page-link {
    background-color: #ffa503;
    border-color: #ffa503;
}

.pagination .page-link {
    color: #6b7280;
}

.pagination .page-link:hover {
    color: #ffa503;
}

.dataTables_wrapper .dataTables_filter {
  @apply mb-4;
}

div.dt-container .dt-length, div.dt-container .dt-search, div.dt-container .dt-info, div.dt-container .dt-processing, div.dt-container .dt-paging {
    padding: 0 24px;
}

div.dt-container .dt-search input {
    border-radius: 6px;
}

div.dt-container .dt-search input:focus {
    outline-offset: -2px;
    outline-color: #FFA502;
}

div.dt-container .dt-length, 
div.dt-container .dt-search, 
div.dt-container .dt-info, 
div.dt-container .dt-processing, 
div.dt-container .dt-paging {
    font-size: 14px;
}

.dataTables_filter input:focus {
    outline: none;
    box-shadow: none;
    border-color: #ccc; /* atau warna border normal */
}

table.dataTable thead th,
table.dataTable thead td {
  @apply py-5 px-2 text-left text-xs uppercase border-b border-b-gray-200 border-dashed bg-gray-100;
}

table.dataTable thead>tr>th.dt-orderable-asc:hover, table.dataTable thead>tr>th.dt-orderable-desc:hover, table.dataTable thead>tr>td.dt-orderable-asc:hover, table.dataTable thead>tr>td.dt-orderable-desc:hover {
    outline: 1px solid rgba(0, 0, 0, 0.05);
    outline-offset: -2px;
}

table.dataTable tbody th,
table.dataTable tbody td {
  @apply py-3 text-sm text-black;
}

table.dataTable>thead>tr>th, table.dataTable>thead>tr>td {
    padding: 10px;
    border-bottom: 1px dashed #e5e7eb;
}

div.dt-container.dt-empty-footer .dt-scroll-body {
    border-bottom: 1px dashed #e5e7eb;
}

table.dataTable tbody td {
  @apply border-b border-b-gray-200 border-dashed;
}

table.dataTable.no-footer {
  @apply border-b-0;
}

.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length {
  @apply ps-4;
}

table.dataTable thead th,
table.dataTable tfoot th {
  @apply font-medium text-gray-600;
}

.sorting,
.sorting_asc,
.sorting_desc {
  @apply bg-none !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  padding: 4px 12px;
  background: #FFA502 !important;
  border: none;
  border-radius: 8px;
  color: #ffffff !important;
  font-size: 14px;
}

.dataTables_wrapper .dataTables_filter label {
  display: none;
}

.dataTables_wrapper .dataTables_filter label input {
  display: block;
}

div.dt-container .dt-input {
    border-radius: 6px;
}

div.dt-container .dt-paging .dt-paging-button.current, div.dt-container .dt-paging .dt-paging-button.current:hover {
    color: #FFFFFF !important;
    border: none;
    background-color: #FFA502;
}

div.dt-container .dt-paging .dt-paging-button {
    border-radius: 6px;
}

div.dt-container select.dt-input {
    padding: 6px;
}

table.dataTable th.dt-type-numeric, 
table.dataTable th.dt-type-date, 
table.dataTable td.dt-type-numeric, 
table.dataTable td.dt-type-date {
    text-align: left;
}
table.dataTable th.dt-type-numeric div.dt-column-header, 
table.dataTable th.dt-type-numeric div.dt-column-footer, 
table.dataTable th.dt-type-date div.dt-column-header, 
table.dataTable th.dt-type-date div.dt-column-footer, 
table.dataTable td.dt-type-numeric div.dt-column-header, 
table.dataTable td.dt-type-numeric div.dt-column-footer, 
table.dataTable td.dt-type-date div.dt-column-header, 
table.dataTable td.dt-type-date div.dt-column-footer {
    flex-direction: row;
}

div.dt-container.dt-empty-footer tbody>tr:last-child>* {
    border-bottom: 1px dashed #e5e7eb;
}

/* Checkbox Styles */
    .checkbox-container {
        display: flex;
        align-items: center;
    }

    .custom-checkbox {
        width: 20px;
        height: 20px;
        border: 2px solid #E5E7EB;
        border-radius: 5px;
        margin-right: 1rem;
        cursor: pointer;
        transition: all 0.2s;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .custom-checkbox:hover {
        border-color: #FFA502;
    }

    .custom-checkbox.checked {
        background-color: #FFA502;
        border-color: #FFA502;
    }

    .custom-checkbox.checked::after {
        content: '✓';
        color: white;
        font-size: 12px;
    }

    /* Bulk Actions */
    .bulk-actions {
        display: none;
        padding: 0.75rem 1.5rem;
        background-color:#FFFFFF;
        border-radius: 0.75rem;
        margin-bottom: 1.5rem;
        align-items: center;
        justify-content: space-between;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
        border: 1px solid #E5E7EB;
    }

    .bulk-actions.active {
        display: flex;
        animation: fadeIn 0.3s ease;
    }

    .selection-count {
        font-size: 0.875rem;
        color: #FFA502;
        font-weight: 500;
    }

@media screen and (max-width: 767px) {
    div.dt-container div.dt-layout-row:not(.dt-layout-table) {
        display: flex;
    }
}