body {
    font-family: sans-serif;
    margin: 0;
    padding: 0;
     display: flex;
    flex-direction: column;
    min-height: 100vh; /* This ensures the body is at least the height of the viewport */
	background: url(https://cdn.tamilbookshelf.in/flash/images/bg_down_menu.png) left top repeat;
    color: #333;
}

.content {
    flex: 1; /* This makes the content area grow to fill the available space */
}
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background-image: linear-gradient(180deg, #5b1e1e 0%, #451107 100%) !important; color: #5b1e1e;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 50;
	height: 35px;
}
header h1 {
	color: #d7cec1;
    font-size: 24px;
}
@media screen and (max-width: 920px) {
header h1 {
    display: none;
}
}
.logo {
    max-width: 100px; /* Ensures the logo is not too big */
    height: auto; /* Maintains the aspect ratio */
}
.search-container {
    padding: 1rem;
   background-color: #230806;
    text-align: center;
}

#search-input {
    width: 80%;
    padding: 10px;
    border-radius: 20px;
    border: 1px solid #ccc;
    font-size: 1rem;
}

#card-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
}

.card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    text-align: center;
    padding: 20px;
}

.card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
}

.card img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 10px;
}

.card-title {
    font-size: 1.2rem;
    margin: 0 0 5px;
}

.card-description {
    font-size: 0.9rem;
    color: #666;
    margin: 0;
	word-break: break-all;
}

/* Off-canvas Menus */
.off-canvas-menu {
    position: fixed;
    top: 0;
    width: 250px;
    height: 100%;
    background-image: linear-gradient(180deg, #671c0e 0%, #000000 100%) !important; color: #5b1e1e;
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.5);
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    z-index: 100;
}

#left-menu {
    left: 0;
    transform: translateX(-100%);
}

#left-menu.open {
    transform: translateX(0);
}

#right-menu {
    right: 0;
    transform: translateX(100%);
}

#right-menu.open {
    transform: translateX(0);
}
#menu-left-btn {
	cursor: pointer;
    padding: 5px 10px;
    color: #5b1e1e;
    border: none;
    margin-left: 15px;
    font-size: 18px;
    font-weight: 777;
    width: 36px;
    height: 36px;
    text-align: center;
    line-height: 28px;
    background-color: #d4cabd;
    border-radius: 50%;
    display: inline-flex;
}
#menu-right-btn {
	cursor: pointer;
    padding: 5px 10px;
    color: #5b1e1e;
    border: none;
    margin-left: 15px;
    font-size: 18px;
    font-weight: 777;
    width: 36px;
    height: 36px;
    text-align: center;
    line-height: 28px;
    background-color: #d4cabd;
    border-radius: 50%;
    display: inline-flex;
}
.off-canvas-menu h2 {
	color: #a7a394;
}
.off-canvas-menu li {
	padding: 10px;
    background-color: #d4cabd;
	color: #5b1e1e;
    border-bottom: 1px solid #555;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    justify-content: start;
    align-items: center;
}
.off-canvas-menu a {
	color: #5b1e1e;
	text-decoration:none;
}
.off-canvas-menu .close-btn {
    background: none;
    border: none;
    color: #ecf0f1;
    font-size: 2rem;
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 200;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    overflow: hidden;
}

.modal-content {
    height: 100vh;
	width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 20px;
	margin-left: auto;
    margin-right: auto;
}

.modal-close-btn {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    background: none;
    border: none;
    cursor: pointer;
}

.modal-header {
    text-align: center;
    color: #fff;
    margin-bottom: 20px;
}

#modal-favicon {
    width: 100px;
    height: 100px;
    border-radius: 50%;
}

#modal-title {
    font-size: 2rem;
}

#webamp-container {
    width: 100%;
    max-width: 400px;
    height: 250px;
    margin: 80px;
}

.modal-footer {
    margin-top: 100px;
	text-align: center;
    color: #edeae1;
}

.social-icon {
    width: 40px;
    height: 40px;
    margin: 0 10px;
    border-radius: 50%;
	background: #ffffff;
}
#left-menu {
	height: 98vh;
    overflow-y: scroll;
}
#left-menu ul {
	padding-left:10px;
}

.footer {
    padding: 1rem;
    background-image: linear-gradient(180deg, #5b1e1e 0%, #451107 100%) !important; color: #5b1e1e;
    color: white;
    text-align: center;
}
body.modal-open {
    height: 100%; /* Ensures the elements fill the entire viewport */
    margin: 0; /* Removes default browser margin */
    padding: 0; /* Removes default browser padding */
    overflow: hidden; /* This is the key property that disables all scrolling */
}
.radio-icon-button {
    /* Remove default button styles */
    background: none;
    border: 2px solid #d4cabd;
    padding: 0.3rem;
    cursor: pointer;
    
    /* Center the icon using Flexbox */
    display: flex;
    justify-content: center;
    align-items: center;

    /* Add hover effect */
    transition: background-color 0.3s ease;
    border-radius: 50%;
}

.radio-icon-button:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.icon {
    font-size: 24px;
    color: #d4cabd; /* Default icon color */
    transition: color 0.3s ease;
}

.radio-icon-button:hover .icon {
    color: #02b32a;
}
.like-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
}

.like-button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 20px;
    color: #ccc;
    transition: color 0.3s ease;
}

.like-button.liked .fas.fa-heart {
    color: #ff0000; /* Red color for a "liked" state */
}

.like-count {
    font-size: 16px;
    font-weight: bold;
    color: #555;
    margin-left: 5px;
}
.time-box {
    text-align: center;
    padding: 5px 10px;
    background-color: #d4cabd;
    border: 1px solid #ccc;
    border-radius: 5px;
}

h6 {
    margin: 0;
    font-size: 1rem;
    color: #4d160f;
}
#webamp-container {
	z-index: 1000 !important;
}
#webamp {
	z-index: 1001 !important;
}
#webamp-context-menu {
    z-index: 1003 !important;
}
/* Basic styling for layout and components */
        :root {
            --bg-color: #5b1e1e;
            --text-color: #f0f0f0;
            --card-bg: #3c3c3c;
            --accent-color: #ff4500;
        }

        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            background-color: var(--bg-color);
            color: var(--text-color);
            overflow-x: hidden;
        }

        header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 1rem;
            background-color: #1a1a1a;
            position: sticky;
            top: 0;
            z-index: 1000;
        }

        #search-input {
            width: 60%;
            padding: 0.5rem;
            border: 1px solid #555;
            background-color: #444;
            color: var(--text-color);
            border-radius: 5px;
        }

        button {
            background: none;
            border: none;
            color: var(--text-color);
            font-size: 1.5rem;
            cursor: pointer;
        }

        .off-canvas-menu {
            position: fixed;
            top: 0;
            width: 250px;
            height: 100%;
            background-color: #1a1a1a;
            background-image: linear-gradient(to top, #1a0107 0%, #83423a 100%) !important;
            transform: translateX(-100%);
            transition: transform 0.3s ease-in-out;
            z-index: 1001;
            padding: 1rem;
            box-sizing: border-box;
            overflow-y: auto;
        }
        .off-canvas-menu.open {
            transform: translateX(0);
        }
        #right-menu {
            right: 0;
            left: auto;
            transform: translateX(100%);
        }
        #right-menu.open {
            transform: translateX(0);
        }

        .close-btn {
            position: absolute;
            top: 10px;
            right: 10px;
            font-size: 2rem;
        }
        
      

        #card-container {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 1.5rem;
            padding: 2rem;
        }

        .card {
            background-color: var(--card-bg);
            background-image: linear-gradient(to top, #1a0107 0%, #83423a 100%) !important;
            border-radius: 10px;
            overflow: hidden;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
            text-align: center;
            cursor: pointer;
            transition: transform 0.2s, box-shadow 0.2s;
        }
        .card:hover {
            transform: translateY(-5px);
            box-shadow: 0 6px 12px rgba(0, 0, 0, 0.5);
        }
        .card img {
            width: 100%;
            height: 150px;
            object-fit: contain;
            background-color: #dfd5c8;
        }
        .card-title {
            margin: 0.5rem 0;
            font-size: 1.2rem;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            padding: 0 1rem;
        }
        .card-description {
            font-size: 0.9rem;
            color: #ccc;
            padding: 0 1rem;
            min-height: 2.7em; /* Ensure consistent height for cards */
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }
        .like-container {
            display: flex;
            justify-content: center;
            align-items: center;
            padding-bottom: 1rem;
        }
        .like-button {
            font-size: 1.2rem;
            color: #888;
            transition: color 0.2s;
            margin-right: 0.5rem;
        }
        .like-button:hover, .like-button.liked {
            color: var(--accent-color);
        }
        .like-count {
            font-size: 1rem;
            color: #ccc;
        }

        .modal {
            display: none;
            position: fixed;
            z-index: 1000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.8);
            justify-content: center;
            align-items: center;
        }
        .modal-content {
            background-color: #1a1a1a;
            background: url('bgglobe.mp4');
            background-size: cover;
            padding: 2rem;
            border-radius: 10px;
            max-width: 90%;
            max-height: 90%;
            overflow-y: auto;
            position: relative;
        }
        .modal-close-btn {
            position: absolute;
            top: 10px;
            right: 15px;
            color: var(--text-color);
            font-size: 2rem;
            cursor: pointer;
        }
        .modal-header {
            backdrop-filter: blur(10px);
            background: #00000057;
            padding: 10px 20px;
            border: 1px solid #ffffff91;
            border-radius:20px;
            display: flex;
            align-items: center;
            margin-bottom: 1rem;
        }
        #modal-favicon {
            width: 50px;
            height: 50px;
            margin-right: 1rem;
        }
        #modal-title {
            margin: 0;
        }
#myVideo {
  position: fixed; /* Positions the video relative to the viewport */
  right: 0;
  bottom: 0;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  z-index: -100; /* Pushes the video behind other content */
  object-fit: cover; /* Ensures the video covers the entire space without distortion */
}

/* Optional: Styling for the content on top of the video */
.content {
  position: relative; /* Places content above the video */
  z-index: 1; /* Ensures content is visible */
  color: white; /* Makes text readable on a dark video */
  text-align: center;
}

/* Optional: Add a semi-transparent overlay to improve text readability */
.content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4); /* Adjust opacity as needed */
  z-index: -1;
}
 /* Styles for the container div */
        .control-button.row {
            display: flex;
            gap: 10px; /* Adds space between buttons */
            flex-wrap: wrap; /* Allows buttons to wrap to the next line on smaller screens */
            justify-content: center;
        }

        /* Styles for the button links */
        .button {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px; /* Space between icon and text */
            padding: 10px 15px;
            font-size: 16px;
            text-decoration: none;
            color: #333;
            background-color: #f0f0f0;
            border: 1px solid #ccc;
            border-radius: 5px;
            transition: background-color 0.3s ease;
        }

        .button:hover {
            background-color: #e0e0e0;
        }

        /* Styles for the icons */
        .button i {
            font-size: 1.2em; /* Slightly larger icons */
        }
        .btn-outline-focus {
            color: #444054;
            border-color: #444054;
            background: #dfd5c8;
            box-shadow: 0 .125rem .625rem rgba(68, 64, 84, .4), 0 .0625rem .125rem rgba(68, 64, 84, .5);
        }
        .btn-outline-focus.btn-shadow:hover {
            box-shadow: 0px 5px 15px 2px rgba(68, 64, 84, .19);
        }
        .btn-outline-focus:hover {
            color: #dfd5c8;
            background-image: linear-gradient(to top, #1a0107 0%, #83423a 100%) !important;
            border-color: #a8a8a8
        }
#history-list li {
        background-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    color: #dfd5c8;
    border-radius: 0.5rem;
    margin-bottom:5px;
    }

    /* Button Styling */
#help-button {
  font-size: 24px;
  border: none;
  color: #333;
  cursor: pointer;
}
#help-button:hover {
  color: #dfd5c8;
}

/* Popup Container */
.popup {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent overlay */
  display: none; /* Hidden by default */
  justify-content: center;
  align-items: center;
  z-index: 100; /* Ensure it's on top of other content */
}

/* Popup Content Box */
.popup-content {
  background: #dfd5c8;
  color:#000;
  padding: 20px;
  border-radius: 8px;
  width: 80%;
  max-width: 500px;
  position: relative;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Close Button Styling */
.close-button {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  cursor: pointer;
  color: #aaa;
}

