

/* For Popup Css */
.popup-container {
    visibility: hidden;
    opacity: 0;
    transition: all 0.5s ease-in-out;
    transform: scale(1.3);
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(21, 17, 17, 0.61);
    display: flex;
    align-items: center;
    z-index: 11;
}
.popup-container .popup-content {
    background-color: #fefefe;
    margin: auto;
    padding: 20px;
    border: 1px solid #888;
    width: 50%;
}
.popup-container .popup-content.stts_chng {
  width: 30%;
  text-align: center;
}
.popup-container .popup-content p{
    font-size: 17px;
    padding: 10px;
    line-height: 20px;
}
.popup-container .popup-content a.close{
    color: #aaaaaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    background: none;
    padding: 0;
    margin: 0;
    text-decoration:none;
}

.popup-container .popup-content a.close:hover{
  color:#333;
}

.popup-container h3{
  margin:10px;
  font-weight: 600;
}
.popup-container.opened,
.popup-container.show {
  visibility: visible;
  opacity: 1;
  transform: scale(1);
}
.popup-container .popup-content.stts_chng #updatestatusform #div-success{
  background-color: #dff0d8;
  border-color: #d0e9c6;
  color: #3c763d;
}
/*End popup styles*/

/* ==================Send-receive-message=css=============== */
.chat-box {
	overflow-y: scroll;
	max-height: 70vh;
  scrollbar-width: thin;
}

/* For chrome  */
.chat-box::-webkit-scrollbar {
  /* height: 12px; */
  width: 8px;
  background: #f0f0f0;
}

.chat-box::-webkit-scrollbar-thumb {
  background: #cdcdcd;
  /* -webkit-border-radius: 0.5ex; */
  /* -webkit-box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.75); */
}

.chat-box::-webkit-scrollbar-corner {
  background: #000;
}

.chat-box .message.sent {
                                    
  border-radius: 5px 0px 5px 5px;
  float: right;
  margin-right: 1em;
}
.chat-box .message.received {
  
  border-radius: 0px 5px 5px 5px;
  float: left;
  margin-left: 0.5em;
}
.chat-box p.form-label {
  /* background: #f4ebeb; */
  /* width: fit-content; */
  padding: 0 15px;
  border-radius: 3px;
  margin-bottom: 0;
}
.chat-box .message {
  clear: both;
  max-width: 75%;
}
.chat-box .message .form-label {
  position: relative;
}
.chat-box .message.sent p.form-label {background: #e1ffc7;}
.chat-box .message.received p.form-label {background: #f4ebeb;}
.chat-box .message .form-label::after {
  position: absolute;
  content: "";
  width: 15PX;
  height: 0;
  border-style: solid;                                    
}


.chat-box .message.received .form-label::after {
  border-width: 0px 10px 10px 0;
  border-color: transparent #f4ebeb transparent transparent;
  top: 0;
  left: -12px;
}
.chat-box .message.sent .form-label::after {
  border-width: 0px 0 10px 10px;
  border-color: transparent transparent transparent #e1ffc7;
  top: 0;
  right: -12px;
}
.metadata {
	display: inline-block;
	float: right;
	padding: 0 0 0 7px;
	position: relative;
	bottom: -4px;
}
.metadata .time {
	color: rgba(0, 0, 0, .45);
	font-size: 11px;
	display: inline-block;
}
/*================ Logo Css======================= */
.nav-header .logo-abbr {
	max-width: 185px;
}
[data-sidebar-style="full"][data-layout="vertical"] .menu-toggle .nav-header .logo-abbr {
	max-width: 50px;
}
.nav-header .brand-logo {
  justify-content: center;
}
[data-nav-headerbg="color_11"][data-theme-version="dark"] .nav-header, [data-nav-headerbg="color_11"] .nav-header {
	/* background-color: #66CEA9; */
  background-color: #fff; 
}
/* ===========Application Css============= */
.profile-tab .nav-item .nav-link:hover, .profile-tab .nav-item .nav-link.active
{
  color: inherit;
}

#application-tab .app-list.card-body {
  padding: 0;
}
#application-tab .app-list.card-body .nav-tabs {
  border-bottom: 0;
}
#application-tab .app-list.card-body .nav-tabs .nav-item:not(:last-child) {
  border-bottom: 1px solid #eee;
}
#application-tab .app-list.card-body .nav-tabs .nav-item .nav-link {
  padding: 1em;
  margin: 0;
}
#application-tab .app-list.card-body .nav-tabs .nav-item .nav-link.active {
  background: #66cea93d;
}

.app-list .nav-link .course-name {
	margin: 0;
}
.app-list .nav-link .status {
	margin: 0;
}

/* ========Header Notification================================== */
.header-right .notification_dropdown .dropdown-item a {
	width: 100%;
}
.header-right .notification_dropdown a.dropdown-toggle .label:empty {
	display: none;
}
.label-danger.count{
  border-radius: 50%;
  height: 18px;
  width: 18px;
  line-height: 18px;
  padding: 0;
  position: absolute;
  top: -10px;
  right: 8px;
}
.notification_dropdown .dropdown-menu-right .media p.msg {
	margin: 0;
	font-size: 12px;
}
.notification_dropdown .dropdown-toggle::after {
  display: none;
}

/* ========== */
.hsc_group {display: none;}

/* ========== Action Column Button Styling ========== */
/* Fix button alignment in tables with large data */
table.table td:last-child {
    white-space: nowrap;
    vertical-align: middle;
    min-width: 180px;
}

table.table td:last-child button {
    margin: 2px;
    display: inline-block;
    white-space: nowrap;
}

table.table td:last-child .btn-group {
    display: flex;
    gap: 5px;
}

/* Ensure Product Name column wraps properly */
#itemsTable tbody td:first-child {
    word-break: break-word;
    max-width: 250px;
}

/* Action column buttons container */
#itemsTable tbody td:last-child {
    white-space: normal;
    min-width: 180px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 8px;
    text-align: center;
    vertical-align: middle;
}

#itemsTable tbody td:last-child button {
    margin: 0;
    flex-shrink: 0;
    white-space: nowrap;
    display: inline-block;
}

/* Action buttons group styling */
.action-buttons-group {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.action-buttons-group button {
    margin: 0;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Terms table action column - match product table styling */
.table tbody td:last-child {
    text-align: center;
    vertical-align: middle;
}

.table tbody td:nth-last-child(1) {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
}

/* ===== Mobile Unsupported Message ===== */
.mobile-unsupported-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    font-family: Arial, sans-serif;
}

.mobile-unsupported-content {
    background: white;
    padding: 40px 30px;
    border-radius: 15px;
    text-align: center;
    max-width: 300px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.mobile-unsupported-content h2 {
    color: #ff6b6b;
    margin: 0 0 15px 0;
    font-size: 28px;
}

.mobile-unsupported-content p {
    color: #333;
    margin: 10px 0;
    font-size: 14px;
    line-height: 1.6;
}

/* ===== iPad, Tablet and Desktop Responsive Fixes ===== */

/* Desktop - button wrapper margin (default for desktop) */
.button-wrapper {
    margin-left: 750px;
    margin-bottom: 10px;
}

.button-wrapper.term-button {
    margin-left: 750px;
}

/* Desktop - hide hamburger (default behavior) */
.nav-control {
    display: none !important;
}

/* Show hamburger menu on iPad and tablets*/
@media (min-width: 769px) and (max-width: 1024px) {
    .nav-control {
        display: flex !important;
        visibility: visible !important;
        align-items: center;
        padding: 10px 15px;
    }
    
    .header{
      height: 6rem;
    }

    /* Logo sizing for iPad/Tablet - smaller for better space usage */
    .nav-header .brand-logo img {
        height: auto;
        padding-left: 64px;
    }

    /* Sidebar responsive */
    .sidebar {
        position: fixed;
        left: -250px;
        top: 0;
        height: 100vh;
        width: 250px;
        transition: left 0.3s ease;
        z-index: 999;
        background-color: #1a1a2e;
        overflow-y: auto;
        box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
    }

    .sidebar.active {
        left: 0;
    }

    /* Overlay when sidebar is active */
    .sidebar.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }

    /* Navigation header padding adjustment */
    .nav-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 15px;
    }

    .nav-header .brand-logo {
        flex: 1;
    }

    /* Fix table overflow on iPad - allow horizontal scroll */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Specific fix for itemsTable */
    #itemsTable {
        width: 100% !important;
        display: table;
    }

    #itemsTable.display {
        width: 100% !important;
    }

    /* Wrap table in scrollable container */
    #itemsTable,
    .dataTables_wrapper {
        overflow-x: auto;
        display: block;
        -webkit-overflow-scrolling: touch;
        margin-top: 20px;
    }

    .table {
        width: 100%;
        min-width: 100%;
        margin-bottom: 0;
    }

    .table thead {
        background-color: #f5f5f5;
    }

    .table tbody {
        display: table-row-group;
    }

    .table tbody tr {
        display: table-row;
    }

    /* Ensure buttons are visible and not hidden */
    .btn, button, [type="button"] {
        position: relative;
        z-index: 20 !important;
        display: inline-block !important;
        visibility: visible !important;
    }

    /* Add New Item button fix - position it properly ABOVE table */
    .card-header,
    .section-header,
    #itemsTableHeader,
    [id*="Header"] {
        position: relative;
        z-index: 15;
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 15px;
        background-color: white;
        margin-bottom: 10px;
    }

    /* Fix buttons with large margin-left on iPad */
    .card-header button,
    .section-header button,
    .card-header .btn,
    .section-header .btn,
    button[style*="margin-left"],
    [style*="margin-left"] .btn,
    [style*="margin-left"] button {
        z-index: 20 !important;
        visibility: visible !important;
        display: inline-block !important;
        position: relative !important;
        margin-left: auto !important;
        margin-right: 10px !important;
    }

    /* Content area adjustments */
    .content-body {
        overflow-x: visible;
        padding: 10px;
    }

    /* Card adjustments for iPad - allow internal scroll */
    .card {
        position: relative;
        overflow: visible;
    }

    /* Section spacing fix */
    .section-box {
        padding: 10px;
        margin: 10px 0;
    }

    /* iPad/Tablet adjustments for button wrapper */
    .button-wrapper,
    .button-wrapper.term-button {
        margin-left: 245px !important;
    }
}