/*
Theme Name: Sinhalawal
Theme URI: https://example.com
Author: Morris
Author URI:
Description: Sinhalawal dark, rounded UI re-skin for Videoclub. 4-column grid, mobile menu, Wal Katha & Join pages.
Version: 2.0.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: sinhalawal
Requires at least: 6.0
Tested up to: 6.6
*/

/*--------------------------------------------------------------
0. Reset
--------------------------------------------------------------*/
.one-line,
.two-lines,
.content-loop .entry-title,
.widget-posts-thumbnail .entry-wrap a,
.three-lines,
.four-lines {
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical; }

.one-line {
  -webkit-line-clamp: 1; }

.two-lines, .content-loop .entry-title, .widget-posts-thumbnail .entry-wrap a {
  -webkit-line-clamp: 2; }

.three-lines {
  -webkit-line-clamp: 3; }

.four-lines {
  -webkit-line-clamp: 4; }

html {
  -webkit-text-size-adjust: 100%; }

*,
*:before,
*:after {
  box-sizing: border-box; }

html, body, div, span, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
abbr, address, cite, code,
del, dfn, em, img, ins, kbd, q, samp,
small, strong, sub, sup, var,
b, i,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, figcaption, figure,
footer, header, hgroup, menu, nav, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  font-size: 100%;
  vertical-align: baseline;
  background: transparent;
  word-wrap: break-word; }

body {
  line-height: 1; }

article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section, main {
  display: block; }

nav ul {
  list-style: none; }

blockquote, q {
  quotes: none; }

blockquote:before, blockquote:after,
q:before, q:after {
  content: '';
  content: none; }

a {
  margin: 0;
  padding: 0;
  font-size: 100%;
  vertical-align: baseline;
  background: transparent; }

ins {
  color: #222;
  text-decoration: none; }

mark {
  background-color: #ff9;
  color: #222;
  font-style: italic;
  font-weight: bold; }

del {
  text-decoration: line-through; }

abbr[title], dfn[title] {
  border-bottom: 1px dotted;
  cursor: help; }

table {
  border-collapse: collapse;
  border-spacing: 0; }

hr {
  display: block;
  height: 1px;
  border: 0;
  border-top: 1px solid #e9e9e9;
  margin: 1em 0;
  padding: 0; }

input, select {
  vertical-align: middle; }

sup {
  top: -.5em; }

sub, sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline; }

.no-list-style {
  list-style: none;
  margin: 0;
  padding: 0; }

figure > img {
  display: block; }

img {
  height: auto;
  max-width: 100%; }

img[class*="align"],
img[class*="attachment-"] {
  height: auto; }

embed,
iframe,
object {
  max-width: 100%;
  width: 100%; }

/*--------------------------------------------------------------
# Accessibility
--------------------------------------------------------------*/
/* Text meant only for screen readers. */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
  /* Many screen reader and browser combinations announce broken words as they would appear visually. */ }

.screen-reader-text:focus {
  background-color: #f1f1f1;
  border-radius: 3px;
  box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
  clip: auto !important;
  clip-path: none;
  color: #21759b;
  display: block;
  font-size: 14px;
  font-size: 0.875rem;
  font-weight: bold;
  height: auto;
  right: 5px;
  line-height: normal;
  padding: 15px 23px 14px;
  text-decoration: none;
  top: 5px;
  width: auto;
  z-index: 100000;
  /* Above WP toolbar. */ }

/* Do not show the outline on the skip link target. */
/* Skip Link --------------------------------- */
.skip-link {
  left: -9999rem;
  top: 2.5rem;
  z-index: 999999999;
  text-decoration: underline; }

.skip-link:focus {
  display: block;
  left: 6px;
  top: 7px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  line-height: normal;
  padding: 15px 23px 14px;
  z-index: 100000;
  right: auto; }

/*--------------------------------------------------------------
# Media
--------------------------------------------------------------*/
.page-content .wp-smiley,
.entry-content .wp-smiley,
.comment-content .wp-smiley {
  border: none;
  margin-bottom: 0;
  margin-top: 0;
  padding: 0; }

/* Make sure embeds and iframes fit their containers. */
embed,
iframe,
object {
  max-width: 100%; }

/*--------------------------------------------------------------
## Captions
--------------------------------------------------------------*/
.wp-caption {
  margin-bottom: 1.5em;
  max-width: 100%; }

.wp-caption img[class*="wp-image-"] {
  display: block;
  margin-left: auto;
  margin-right: auto; }

.wp-caption .wp-caption-text {
  margin: 0.5075em 0; }

.wp-caption-text {
  text-align: center; }

/*--------------------------------------------------------------
## Galleries
--------------------------------------------------------------*/
.gallery {
  margin-bottom: 1.5em; }

.gallery-item {
  display: inline-block;
  text-align: center;
  vertical-align: top;
  width: 100%; }

.gallery-columns-2 .gallery-item {
  max-width: 50%; }

.gallery-columns-3 .gallery-item {
  max-width: 33.33%; }

.gallery-columns-4 .gallery-item {
  max-width: 25%; }

.gallery-columns-5 .gallery-item {
  max-width: 20%; }

.gallery-columns-6 .gallery-item {
  max-width: 16.66%; }

.gallery-columns-7 .gallery-item {
  max-width: 14.28%; }

.gallery-columns-8 .gallery-item {
  max-width: 12.5%; }

.gallery-columns-9 .gallery-item {
  max-width: 11.11%; }

.gallery-caption {
  display: block; }

/*--------------------------------------------------------------
1. Defaults
--------------------------------------------------------------*/
h1, h2, h3, h4, h5, h6 {
  color: #222;
  font-weight: bold; }

strong,
b {
  font-weight: bold; }

input,
textarea,
select {
  -moz-box-sizing: border-box;
  -webkit-box-sizing: border-box;
  box-sizing: border-box; }

input,
textarea {
  -webkit-appearance: none; }

input,
input[type="text"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="password"],
input[type="tel"],
textarea {
  font-size: 15px;
  font-weight: normal;
  background-color: #fff;
  border: 1px solid #e9e9e9;
  color: #222; }
  input:focus,
  input[type="text"]:focus,
  input[type="email"]:focus,
  input[type="url"]:focus,
  input[type="search"]:focus,
  input[type="password"]:focus,
  input[type="tel"]:focus,
  textarea:focus {
    outline: thin solid #f9f9f9; }

input[type="file"] {
  -webkit-box-shadow: none;
  box-shadow: none; }

textarea {
  padding: 10px 15px; }

input[type="text"],
input[type="email"],
input[type="url"],
input[type="search"],
input[type="password"],
input[type="tel"] {
  height: 40px;
  line-height: 40px;
  padding: 0 15px; }

button,
.btn,
input[type="submit"],
input[type="reset"],
input[type="button"] {
  background-color: #fff;
  border: 1px solid #ddd;
  padding: 0 15px;
  white-space: nowrap;
  vertical-align: middle;
  cursor: pointer;
  color: #222;
  font-size: 16px;
  font-weight: 600;
  height: 40px;
  line-height: 40px;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-appearance: none;
  -webkit-backface-visibility: hidden; }

button:hover,
.btn:hover,
input[type="reset"]:hover,
input[type="submit"]:hover,
input[type="button"]:hover {
  background-color: #444;
  border-color: #444;
  color: #fff;
  text-decoration: none; }

table {
  color: #222;
  border-width: 1px;
  border-color: #e9e9e9;
  border-collapse: collapse;
  width: 100%; }

table th {
  border-width: 1px;
  padding: 8px 20px;
  border-style: solid;
  border-color: #e9e9e9; }

table td {
  border-width: 1px;
  padding: 8px 20px;
  border-style: solid;
  border-color: #e9e9e9; }

.alignleft {
  float: left;
  margin: 0 20px 20px 0; }

.alignright {
  float: right;
  margin: 0 0 20px 20px; }

.aligncenter {
  display: block;
  margin: 0 auto;
  text-align: center;
  clear: both; }

.alignnone {
  display: block; }

/* Clear Floats */
.clear:before,
.clear:after {
  content: "";
  display: table; }

.clear:after {
  clear: both; }

.clear {
  clear: both; }

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px);
  position: absolute; }

.sticky,
.bypostauthor {
  background: inherit;
  color: inherit; }

/* CSS3 Effects */
.box-shadow {
  box-shadow: rgba(190, 190, 190, 0.45882) 0px 1px 5px;
  -webkit-box-shadow: rgba(190, 190, 190, 0.45882) 0px 1px 5px; }

body {
  background-color: #fff;
  color: #222;
  font-style: normal;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7em; }

a {
  text-decoration: none; }
  a:hover {
    text-decoration: none; }
  a:visited {
    color: #222; }

.container {
  margin: 0 auto;
  width: 90%;
  max-width: 2100px; }

/* =Genericons, thanks to FontSquirrel.com for conversion!
-------------------------------------------------------------- */
@font-face {
  font-family: 'Genericons';
  src: url("genericons/font/genericons-regular-webfont.eot");
  src: url("genericons/font/genericons-regular-webfont.eot?#iefix") format("embedded-opentype"), url("genericons/font/genericons-regular-webfont.woff") format("woff"), url("genericons/font/genericons-regular-webfont.ttf") format("truetype"), url("genericons/font/genericons-regular-webfont.svg#genericonsregular") format("svg");
  font-weight: normal;
  font-style: normal; }
/* Genericons */
.bypostauthor > article .fn:before,
.comment-edit-link:before,
.comment-reply-link:before,
.comment-reply-login:before,
.comment-reply-title small a:before,
.comment-list .children li:before,
.contributor-posts-link:before,
.menu-toggle:before,
.search-toggle:before,
.slider-direction-nav a:before,
.widget_wpenjoy_ephemera .widget-title:before {
  -webkit-font-smoothing: antialiased;
  display: inline-block;
  font: normal 16px/1 Genericons;
  text-decoration: inherit;
  vertical-align: text-bottom; }

.page-title {
  font-size: 1.6em;
  margin-bottom: 25px;
  line-height: 1.2; }

.entry-content iframe,
.entry-content video,
.page-content iframe,
.page-content video {
  aspect-ratio: 16/9; }

/* Entry Content */
.page-content .wp-post-image,
.entry-content .wp-post-image {
  margin-bottom: 10px;
  width: 100%; }
.page-content a,
.entry-content a {
  text-decoration: underline; }
  .page-content a:hover,
  .entry-content a:hover {
    text-decoration: none; }
.page-content h1,
.page-content h2,
.page-content h3,
.page-content h4,
.page-content h5,
.page-content h6,
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
  margin-bottom: 25px;
  line-height: 1.35; }
.page-content h1,
.entry-content h1 {
  font-size: 30px; }
.page-content h2,
.entry-content h2 {
  font-size: 26px; }
.page-content h3,
.entry-content h3 {
  font-size: 22px; }
.page-content h4,
.entry-content h4 {
  font-size: 18px; }
.page-content h5, .page-content h6,
.entry-content h5,
.entry-content h6 {
  font-size: 16px; }
.page-content p,
.entry-content p {
  line-height: 1.7;
  margin-bottom: 25px; }
.page-content ul,
.page-content ol,
.entry-content ul,
.entry-content ol {
  margin: 0 0 25px 0; }
  .page-content ul ul,
  .page-content ul ol,
  .page-content ol ul,
  .page-content ol ol,
  .entry-content ul ul,
  .entry-content ul ol,
  .entry-content ol ul,
  .entry-content ol ol {
    margin: 8px 0 0 25px; }
.page-content ul li,
.entry-content ul li {
  list-style: disc inside;
  margin: 0 0 10px 0;
  position: relative; }
.page-content ol li,
.entry-content ol li {
  list-style: inside decimal;
  margin: 0 0 10px 0; }
.page-content select,
.entry-content select {
  padding: 0 5px; }
.page-content dl,
.entry-content dl {
  margin-bottom: 20px; }
.page-content fieldset,
.entry-content fieldset {
  border: 1px solid #e9e9e9;
  margin: 0 2px 20px 2px;
  padding: 0.35em 0.625em 0.75em; }
.page-content input[type="radio"],
.entry-content input[type="radio"] {
  -webkit-appearance: radio; }
.page-content input[type="checkbox"],
.entry-content input[type="checkbox"] {
  -webkit-appearance: checkbox; }
.page-content ::-webkit-file-upload-button,
.entry-content ::-webkit-file-upload-button {
  -webkit-appearance: button;
  font: inherit; }
.page-content label,
.entry-content label {
  display: inline-block;
  font-weight: bold; }
.page-content table,
.entry-content table {
  margin-bottom: 20px; }
.page-content select,
.entry-content select {
  border: 1px solid #e9e9e9;
  font-size: 1em;
  height: 2em;
  max-width: 100%;
  -webkit-appearance: menulist; }
.page-content input[type="text"],
.page-content input[type="email"],
.page-content input[type="url"],
.page-content input[type="search"],
.page-content input[type="password"],
.entry-content input[type="text"],
.entry-content input[type="email"],
.entry-content input[type="url"],
.entry-content input[type="search"],
.entry-content input[type="password"] {
  width: 300px; }
.page-content input[type="file"],
.entry-content input[type="file"] {
  border: none; }
.page-content textarea,
.entry-content textarea {
  width: 100%;
  height: 200px; }
.page-content .wp-caption,
.entry-content .wp-caption {
  background-color: #f7f7f7;
  padding: 0 0 1px 0; }
.page-content .wp-caption-text,
.entry-content .wp-caption-text {
  font-size: 13px;
  font-style: italic;
  color: #999; }
.page-content pre,
.page-content .wp-block-preformatted,
.entry-content pre,
.entry-content .wp-block-preformatted {
  background: #f5f5f5;
  color: #555;
  padding: 10px 15px;
  margin: 0 0 25px 0;
  white-space: pre-wrap; }

blockquote {
  color: #999999;
  font-size: 18px;
  font-style: italic;
  padding: 0.25em 50px;
  line-height: 1.45;
  position: relative; }
  blockquote cite {
    color: #333333;
    display: block;
    margin-top: 10px; }
    blockquote cite:before {
      content: "\2014 \2009"; }
  blockquote p:last-child {
    margin-bottom: 0; }

#primary p,
.widget p {
  line-height: 1.7em; }

/*--------------------------------------------------------------
5. Archive/Search Page
--------------------------------------------------------------*/
.search-no-results .content-loop {
  margin-left: 0;
  margin-right: 0; }
.search-no-results .page-title {
  font-size: 24px;
  margin-bottom: 10px; }
.search-no-results .page-content label,
.search-no-results .entry-content label {
  display: inline-block; }

.archive .no-results .page-content label,
.archive .no-results .entry-content label {
  display: inline-block; }

/*--------------------------------------------------------------
6. Comments
--------------------------------------------------------------*/
.comments-area {
  border-top: 1px solid #e9e9e9;
  margin-top: 20px;
  padding-top: 20px; }
  .comments-area.no-content {
    border-top: none;
    margin-top: 0;
    padding-top: 0; }

.comment-respond,
.comment-list {
  width: 100%;
  max-width: 720px; }

.comments-title {
  font-size: 20px;
  margin-bottom: 15px; }

.comment-reply-title {
  font-size: 20px;
  margin-bottom: 15px; }

.comment-list {
  list-style: none; }

.comment-author {
  font-size: 14px; }

.comment-meta {
  margin-bottom: 4px; }

.comment-list .reply,
.comment-metadata {
  font-size: 13px; }

.comment-list .reply {
  margin-top: 10px; }

.comment-author .fn {
  font-weight: bold; }

.comment-author a {
  color: #222;
  text-decoration: underline; }

.comment-list .trackback a,
.comment-list .trackback a:visited,
.comment-list .pingback a,
.comment-list .pingback a:visited,
.comment-metadata a,
.comment-metadata a:visited,
.comment-list .reply a,
.comment-list .reply a:visited {
  color: #999; }

.comment-list .trackback a:hover,
.comment-list .pingback a:hover,
.comment-metadata a:hover,
.comment-list .reply a:hover {
  color: #222; }

.comment-author a:hover {
  color: #222; }

.comment-list article,
.comment-list .pingback,
.comment-list .trackback {
  margin: 0 0 20px 0; }

.comment-list > li:first-child > article,
.comment-list > .pingback:first-child,
.comment-list > .trackback:first-child {
  border-top: 0; }

.comment-author {
  position: relative; }

.comment-author .avatar {
  border-radius: 50%;
  position: absolute;
  top: 0;
  left: 0;
  width: 48px;
  height: auto; }

.bypostauthor > article .fn:before {
  color: #fbb034;
  content: "\f408";
  margin: 0 2px 0 -2px;
  position: relative;
  top: -1px; }

.says {
  display: none; }

.comment-author,
.comment-awaiting-moderation,
.comment-content,
.comment-list .reply {
  padding-left: 64px; }

.comment-author {
  display: inline; }

.comment-metadata {
  display: inline;
  margin-left: 7px; }

.comment-edit-link {
  margin-left: 10px; }
  .comment-edit-link:hover {
    text-decoration: none; }

#cancel-comment-reply-link:hover {
  text-decoration: none; }

.comment-edit-link:before {
  content: "\f411"; }

.comment-reply-link:hover {
  text-decoration: none; }

.comment-reply-link:before,
.comment-reply-login:before {
  content: '\f467';
  color: #999;
  margin-right: 2px; }

.comment-content {
  -webkit-hyphens: auto;
  -moz-hyphens: auto;
  -ms-hyphens: auto;
  hyphens: auto;
  word-wrap: break-word; }
  .comment-content a:hover {
    text-decoration: underline; }

.comment-content ul,
.comment-content ol {
  margin: 0 0 24px 22px; }

.comment-content li > ul,
.comment-content li > ol {
  margin-bottom: 0; }

.comment-content > :last-child {
  margin-bottom: 0; }

.comment-list .children {
  list-style: none;
  margin-left: 64px; }

.comment-respond:after {
  clear: both;
  content: " ";
  display: block; }

.comment .comment-respond {
  margin: 25px 0; }

.comment-respond h3 {
  margin-top: 0; }

.comment-notes,
.comment-awaiting-moderation,
.logged-in-as,
.no-comments,
.form-allowed-tags,
.form-allowed-tags code {
  color: #999; }
  .comment-notes a,
  .comment-notes a:visited,
  .comment-awaiting-moderation a,
  .comment-awaiting-moderation a:visited,
  .logged-in-as a,
  .logged-in-as a:visited,
  .no-comments a,
  .no-comments a:visited,
  .form-allowed-tags a,
  .form-allowed-tags a:visited,
  .form-allowed-tags code a,
  .form-allowed-tags code a:visited {
    color: #999;
    text-decoration: underline; }
    .comment-notes a:hover,
    .comment-notes a:visited:hover,
    .comment-awaiting-moderation a:hover,
    .comment-awaiting-moderation a:visited:hover,
    .logged-in-as a:hover,
    .logged-in-as a:visited:hover,
    .no-comments a:hover,
    .no-comments a:visited:hover,
    .form-allowed-tags a:hover,
    .form-allowed-tags a:visited:hover,
    .form-allowed-tags code a:hover,
    .form-allowed-tags code a:visited:hover {
      color: #222;
      text-decoration: none; }

.comment-notes,
.comment-awaiting-moderation,
.logged-in-as {
  font-size: 14px;
  margin-bottom: 10px; }

.comments-area .no-comments {
  font-size: 16px;
  font-weight: 900;
  line-height: 1.5;
  margin-top: 24px;
  text-transform: uppercase; }

.comment-form .comment-form-comment,
.comment-form .comment-form-author,
.comment-form .comment-form-email,
.comment-form .comment-form-url {
  margin-bottom: 20px; }
.comment-form textarea {
  width: 100%; }
.comment-form .comment-form-author {
  float: left;
  width: 48.5%; }
.comment-form .comment-form-email {
  float: right;
  width: 48.5%; }
.comment-form .comment-form-url {
  width: 100%;
  clear: left; }
.comment-form:after {
  content: '';
  display: block;
  clear: both; }
.comment-form .submit {
  font-size: 14px;
  padding: 0 18px;
  margin-bottom: 10px; }

.comment-form-cookies-consent {
  margin: 0 0 20px 0; }

.comment-form-cookies-consent label {
  font-weight: normal !important; }

.comment-form label {
  font-size: 14px;
  font-weight: bold; }

input[type="checkbox"] {
  -webkit-appearance: checkbox;
  -moz-appearance: checkbox;
  -ms-appearance: checkbox;
  -o-appearance: checkbox;
  appearance: checkbox; }

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] {
  width: 100%; }

.form-allowed-tags,
.form-allowed-tags code {
  font-size: 12px;
  line-height: 1.5; }

.required {
  color: #c0392b; }

.comment-reply-title small a {
  color: #2b2b2b;
  float: right;
  height: 24px;
  overflow: hidden;
  width: 24px; }

.comment-reply-title small a:before {
  content: "\f405";
  font-size: 20px; }

.comment-navigation {
  font-size: 12px;
  line-height: 2;
  margin-bottom: 48px;
  text-transform: uppercase; }

.comment-navigation .nav-next,
.comment-navigation .nav-previous {
  display: inline-block; }

.comment-navigation .nav-previous a {
  margin-right: 10px; }

#comment-nav-above {
  margin-top: 36px;
  margin-bottom: 0; }


/* === Wal Katha Grid === */
.wal-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

@media (min-width: 1024px) {
  .wal-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 768px) {
  .wal-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .wal-grid { grid-template-columns: 1fr; }
}

.wal-grid .card {
  transition: transform .2s ease, box-shadow .2s ease;
}
.wal-grid .card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0,0,0,.45);
}

/* === Join With Us / Contact Cards === */
.contact-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  justify-items: center;
  margin-top: 32px;
}

.contact-card {
  background: var(--sin-card);
  border: 1px solid var(--sin-border);
  border-radius: var(--sin-radius);
  box-shadow: var(--shadow-lg);
  padding: 24px;
  text-align: center;
  width: 100%;
  max-width: 320px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.contact-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.45);
}

.contact-title {
  font-family: "Inter", system-ui, sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 8px;
  color: var(--sin-text);
}

.contact-desc {
  color: var(--sin-muted);
  margin-bottom: 12px;
  font-size: 0.95rem;
}

/* === Sinhalawal hard overrides (force dark) === */
:root{
  --sin-bg:#0b0f14; --sin-surface:#0f141b; --sin-card:#121821;
  --sin-text:#e6edf3; --sin-muted:#cbd5e1; --sin-border:#1d2733;
  --sin-primary:#3b82f6; --sin-radius:12px; --radius-sm:10px;
  --shadow-lg:0 12px 30px rgba(0,0,0,.45);
}

/* 1) Background + text color */
html, body{
  background: var(--sin-bg) !important;
  color: var(--sin-text) !important;
}

/* 2) Container backgrounds → transparent (stop whites) */
.site, .site-content, .content-area, .site-main, .container, .wrap,
#page, #content, .site-start, .hentry, .entry-content{
  background: transparent !important;
}

/* 3) Header + footer strip */
.site-header, header[role="banner"]{
  background: var(--sin-surface) !important;
  border-bottom:1px solid var(--sin-border) !important;
}
.site-footer, footer[role="contentinfo"]{
  background: var(--sin-surface) !important;
  border-top:1px solid var(--sin-border) !important;
  color: var(--sin-muted) !important;
}

/* 4) Links (visible on dark) */
a{ color: var(--sin-text) !important; }
a:hover{ color: #ef4444 !important; }

/* 5) Home grid cards (if not added earlier) */
#recent-content .card{
  background: var(--sin-card) !important;
  border:1px solid var(--sin-border) !important;
  border-radius: var(--sin-radius) !important;
  box-shadow: var(--shadow-lg) !important;
}

/* --- Aluth SinhalaWal Video Section Eka --- */

.sw-video-section-wrapper {
    max-width: 80rem; /* 1280px */
    margin-left: auto;
    margin-right: auto;
    margin-top: 2rem;
    margin-bottom: 2rem;
    padding-left: 1rem;
    padding-right: 1rem;
}

.sw-section-title {
    font-size: 2.25rem; /* 36px */
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 2rem;
    line-height: 2.5rem;
}

.sw-title-highlight {
    color: #ef4444; /* red-500 */
}

.sw-video-grid {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 1.5rem; /* 24px */
}

/* Tablet (Small screens) */
@media (min-width: 640px) {
    .sw-video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Desktop (Large screens) */
@media (min-width: 1024px) {
    .sw-video-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.sw-video-card {
    background-color: #1f2937; /* gray-800 */
    border-radius: 1rem; /* 16px */
    overflow: hidden;
    border: 1px solid #374151; /* gray-700 */
    transition: all 0.3s ease;
    cursor: pointer;
}

.sw-video-card:hover {
    transform: scale(1.05);
    border-color: rgba(239, 68, 68, 0.5); /* red-500 with 50% opacity */
}

.sw-card-thumbnail {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background-color: #374151; /* gray-700 */
}

.sw-card-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.sw-video-card:hover .sw-card-thumbnail img {
    transform: scale(1.1);
}

.sw-card-duration {
    position: absolute;
    bottom: 0.5rem;
    right: 0.5rem;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    font-size: 0.75rem; /* 12px */
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem; /* 6px */
}

.sw-card-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(239, 68, 68, 0.8); /* red-500 */
    color: white;
    border-radius: 9999px;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sw-video-card:hover .sw-card-play-icon {
    opacity: 1;
}

.sw-card-content {
    padding: 1rem; /* 16px */
}

.sw-card-title {
    font-size: 1.125rem; /* 18px */
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    line-height: 1.5;
    /* Title eka line 2kata limit karanna */
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.sw-video-card:hover .sw-card-title {
    color: #f87171; /* red-400 */
}

.sw-card-meta {
    display: flex;
    align-items: center;
    font-size: 0.875rem; /* 14px */
    color: #9ca3af; /* gray-400 */
    gap: 0.5rem; /* 8px */
}

/* Make the video section full width */
.container,
.wp-block-group__inner-container,
.site-main,
.content-area {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
}

/* Video grid fix: make 4 columns on desktop */
.videos-list,
.latest-videos,
.row {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 25px !important;
}

/* Tablet - 2 columns */
@media (max-width: 992px) {
    .videos-list,
    .latest-videos,
    .row {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* Mobile - 1 column */
@media (max-width: 576px) {
    .videos-list,
    .latest-videos,
    .row {
        grid-template-columns: repeat(1, 1fr) !important;
    }
}

/* --- /Aluth Style Iwarai --- */

/* --- Aluth Pagination Styles (FIXED) --- */

/* Me wrapper eken mulu pagination eka center karanawa */
.sw-pagination-wrapper {
    margin-top: 3rem; /* 48px */
    margin-bottom: 2rem; /* 32px */
    display: flex; 
    justify-content: center; 
}

/* Me rule eken page nommara tika harahata (horizontal) gannawa */
.sw-pagination-wrapper .page-numbers {
    display: flex; 
    flex-wrap: wrap; /* Mobile walata */
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 0.5rem; /* 8px - Batan athara hidaasa */
}

.sw-pagination-wrapper .page-numbers li {
    margin: 0; /* Parana theme eke margin eka override karanna */
}

/* Batan wala look eka */
.sw-pagination-wrapper .page-numbers a,
.sw-pagination-wrapper .page-numbers span {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem; /* 8px 16px */
    border-radius: 0.5rem; /* 8px */
    font-weight: 500;
    font-size: 0.875rem; /* 14px */
    color: #d1d5db; /* gray-300 */
    background-color: #1f2937; /* gray-800 */
    border: 1px solid #374151; /* gray-600 */
    transition: all 0.3s ease;
    text-decoration: none;
    cursor: pointer;
    margin: 0; /* Parana margin eka override karanna */
}

.sw-pagination-wrapper .page-numbers a:hover {
    background-color: #374151; /* gray-700 */
    color: #ffffff;
    border-color: #4b5563; /* gray-500 */
}

.sw-pagination-wrapper .page-numbers .current {
    background-color: #dc2626; /* red-600 */
    color: #ffffff;
    border-color: #ef4444; /* red-500 */
    font-weight: 700;
    cursor: default;
}

/* Disabled Previous/Next buttons */
.sw-pagination-wrapper .page-numbers span.prev,
.sw-pagination-wrapper .page-numbers span.next {
     background-color: #374151; /* gray-700 */
     color: #6b7280; /* gray-500 */
     cursor: not-allowed;
     opacity: 0.5;
}
/* --- /Aluth Pagination Iwarai --- */

/* === SinhalaWal FIX: Prevent global layout override === */

/* Stop .row grid override (breaks menu/search) */
.sw-video-grid,
.videos-list,
.latest-videos {
    display: grid !important;
}

.row {
    display: block !important;
    grid-template-columns: unset !important;
    gap: unset !important;
}

/* Site layout restore */
.site-main,
.content-area {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Keep video wrapper nice */
.sw-video-section-wrapper {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    max-width: 80rem !important;
    margin: auto !important;
}

/* Search + Menu stacking FIX */
#sw-search-bar,
#sw-mobile-menu {
    position: relative;
    z-index: 60;
    background: #0f141b;
}

/* Ensure mobile menu full width */
#sw-mobile-menu nav a {
    display: block !important;
    width: 100% !important;
}

/* Fix header not pushing down content */
#content.site-content {
    margin-top: 80px !important;
}

/*

/* --- Mobile Menu & Icon Button Background FIX --- */

/* Meken parana theme eke `button` style eka override karala
  aluth header eke icon buttons walata transparent background ekak denawa.
*/
header[class*="bg-gray-800/95"] button#sw-search-toggle,
header[class*="bg-gray-800/95"] button#sw-menu-toggle {
    background-color: transparent !important;
    border: none !important;
    color: #d1d5db; /* text-gray-300 */
}

/* Hover kalama aluth CSS file eken (index-C-azaxDQ.css) ena style eka
*/
header[class*="bg-gray-800/95"] button#sw-search-toggle:hover,
header[class*="bg-gray-800/95"] button#sw-menu-toggle:hover {
    background-color: rgb(55, 65, 81) !important; /* bg-gray-700 */
    color: #ffffff !important; /* text-white */
}

/*

/* --- Search Bar Style FIX (Desktop & Mobile) --- */

/* 1. Meken parana theme eke search bar <input> style eka override karanawa */
header #sw-search-bar input[type="text"] {
    background-color: #374151 !important; /* Original design eke dark gray paata */
    color: #ffffff !important; /* Sudu paata akuru */
    border: none !important;
    box-shadow: none !important; /* Parana theme eke shadows ain karanawa */
    padding-left: 2.5rem !important; /* Icon ekata ida denna */
}

/* 2. Meken placeholder eke paata hari gassawanawa */
header #sw-search-bar input[type="text"]::placeholder {
    color: #9ca3af !important; /* Light gray paata */
    opacity: 1; 
}

/* 3. Meken search icon eka original design eke wage pennanawa */
header #sw-search-bar svg {
    color: #9ca3af !important; /* Light gray paata */
    fill: none !important;
    stroke: currentColor !important;
}

/*/

/* Match mobile menu background to header bg-gray-800/95 */
#sw-mobile-menu {
    background: rgba(31, 41, 55, 0.95) !important; /* same as header */
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border-bottom: 1px solid rgba(55, 65, 81, 0.8) !important;
}

/* Match search dropdown to header color */
#sw-search-bar {
    background: rgba(31, 41, 55, 0.95) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
}

/* Ensure header also keeps same look */
header.fixed {
    background: rgba(31, 41, 55, 0.95) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
}

/*404

/* --- 404 Dark Glitch Theme (Site Colors Matched) --- */

.sw-error-page {
    background-color: #111827; /* Header eke thiyena Dark background eka */
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #ffffff;
    font-family: inherit;
    overflow: hidden;
}

.sw-error-content {
    padding: 2rem;
    max-width: 600px;
    z-index: 10;
}

/* --- Glitch 404 Text Animation --- */
.sw-glitch-wrapper {
    position: relative;
    margin-bottom: 1rem;
}

.sw-glitch-text {
    font-size: 8rem;
    font-weight: 900;
    line-height: 1;
    color: #ffffff;
    letter-spacing: -5px;
    position: relative;
    margin: 0;
    text-shadow: 2px 2px 0px #ef4444, -2px -2px 0px #3b82f6; /* Red & Blue split */
    animation: sw-shake 3s infinite linear alternate-reverse;
}

.sw-glitch-text::before,
.sw-glitch-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #111827; /* Background color ekama */
}

.sw-glitch-text::before {
    left: 2px;
    text-shadow: -2px 0 #ef4444; /* Red Shadow */
    clip: rect(24px, 550px, 90px, 0);
    animation: sw-glitch-anim-2 3s infinite linear alternate-reverse;
}

.sw-glitch-text::after {
    left: -2px;
    text-shadow: -2px 0 #3b82f6; /* Blue Shadow */
    clip: rect(85px, 550px, 140px, 0);
    animation: sw-glitch-anim 2.5s infinite linear alternate-reverse;
}

/* --- Title & Description --- */
.sw-error-title {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.sw-error-desc {
    color: #9ca3af; /* Gray text */
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

/* --- Home Button (Red Theme) --- */
.sw-error-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background-color: #ef4444; /* Theme Red Color */
    color: #ffffff !important;
    padding: 12px 32px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.sw-error-btn:hover {
    background-color: #dc2626;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5);
}

.sw-error-btn svg {
    width: 20px;
    height: 20px;
}

/* --- Mobile Responsive --- */
@media (max-width: 768px) {
    .sw-glitch-text {
        font-size: 6rem;
    }
    .sw-error-title {
        font-size: 1.5rem;
    }
}

/* --- Animations --- */
@keyframes sw-shake {
    0% { transform: skewX(-5deg); }
    5% { transform: skewX(5deg); }
    10% { transform: skewX(-5deg); }
    15% { transform: skewX(5deg); }
    20% { transform: skewX(0deg); }
    100% { transform: skewX(0deg); }
}

@keyframes sw-glitch-anim {
    0% { clip: rect(12px, 9999px, 56px, 0); }
    20% { clip: rect(100px, 9999px, 15px, 0); }
    40% { clip: rect(25px, 9999px, 85px, 0); }
    60% { clip: rect(65px, 9999px, 120px, 0); }
    80% { clip: rect(10px, 9999px, 135px, 0); }
    100% { clip: rect(95px, 9999px, 55px, 0); }
}

@keyframes sw-glitch-anim-2 {
    0% { clip: rect(65px, 9999px, 100px, 0); }
    20% { clip: rect(15px, 9999px, 35px, 0); }
    40% { clip: rect(120px, 9999px, 15px, 0); }
    60% { clip: rect(5px, 9999px, 85px, 0); }
    80% { clip: rect(95px, 9999px, 145px, 0); }
    100% { clip: rect(20px, 9999px, 70px, 0); }
}

/* --- 404 Page Full Screen FIX --- */

/* 1. 404 Page එකේ මුළු Body එකේම Background එක Dark කරන්න */
body.error404 {
    background-color: #111827 !important;
}

/* 2. Theme එකෙන් එන අමතර Margins සහ Padding අයින් කරන්න */
body.error404 #primary,
body.error404 .site-main,
body.error404 .content-area,
body.error404 #content {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    background-color: transparent !important;
}

/* 3. 404 Section එක Screen එකේ ඉතුරු ඉඩ සම්පූර්ණයෙන්ම ගන්න විදිහට හදන්න */
.sw-error-page {
    /* Header එකේ උස (80px) අඩු කරලා ඉතුරු ටික ගන්න */
    min-height: calc(100vh - 80px) !important; 
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- FINAL SINGLE VIDEO PAGE STYLES (With Active State) --- */

/* 1. BACKGROUND FIX */
html, body, #page, #content, .site-content, .sw-single-video-page, .site-header, .site-footer {
    background-color: #111827 !important;
}

/* 2. Video Player Fix */
.sw-video-wrapper iframe,
.sw-video-wrapper video,
.sw-video-wrapper object,
.sw-video-wrapper embed {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%; border: none;
}

/* 3. ACTION BUTTONS (Height Reduced to 40px) */
.sw-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 20px;
    border-radius: 20px !important;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    
    height: 42px !important; 
    
    background-color: #374151 !important; 
    color: #ffffff !important;
    border: none !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sw-action-btn:hover {
    background-color: #4b5563 !important;
    transform: translateY(-1px);
}

/* --- NEW: ACTIVE STATE (Click Effect) --- */
.sw-action-btn.active {
    background-color: #ef4444 !important; /* Red Background */
    color: #ffffff !important;
    border-color: #ef4444 !important;
}

/* --- NEW: CLICK ANIMATION --- */
.clicked-anim {
    animation: button-pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes button-pop {
    0% { transform: scale(1); }
    50% { transform: scale(0.95); }
    100% { transform: scale(1); }
}

/* Specific Colors */
.sw-single-video-page .bg-red-600 {
    background-color: #ef4444 !important;
}
.sw-single-video-page .bg-red-600:hover {
    background-color: #dc2626 !important;
}

.sw-single-video-page .bg-green-600 {
    background-color: #16a34a !important;
}
.sw-single-video-page .bg-green-600:hover {
    background-color: #15803d !important;
}

/* 4. Tags Styling */
.sw-single-video-page a[href*="/tag/"] {
    background-color: #1f2937 !important;
    color: #d1d5db !important;
    padding: 6px 16px !important;
    border-radius: 9999px !important;
    font-size: 0.85rem !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    border: 1px solid #374151 !important;
    display: inline-block !important;
    margin-right: 8px !important;
    margin-bottom: 8px !important;
    transition: all 0.2s ease-in-out !important;
}
.sw-single-video-page a[href*="/tag/"]:hover {
    background-color: #374151 !important;
    border-color: #ef4444 !important;
    color: #ffffff !important;
}

/* 5. Comment Box & Email Styling */
.sw-single-video-page textarea,
.sw-single-video-page input[type="text"],
.sw-single-video-page input[type="email"] {
    background-color: #374151 !important; 
    border: 1px solid #4b5563 !important;
    color: #ffffff !important; 
    border-radius: 12px !important;
    padding: 12px !important;
    width: 100% !important;
    font-size: 0.95rem !important;
    margin-bottom: 12px !important;
    box-sizing: border-box !important;
    display: block !important;
    resize: none !important;
    outline: none;
}
.sw-single-video-page textarea:focus,
.sw-single-video-page input[type="email"]:focus {
    border-color: #ef4444 !important;
}

/* Hide unwanted elements */
.sw-single-video-page .comment-reply-title, 
.sw-single-video-page .logged-in-as,
.sw-single-video-page .comment-notes,
.sw-single-video-page label {
    display: none !important;
}
.comment-form-comment, .comment-form-email {
    margin: 0 !important; padding: 0 !important; width: 100% !important;
}

/* 6. Post Comment Button */
.sw-single-video-page input[type="submit"],
.sw-single-video-page .submit,
#submit {
    background-color: #ef4444 !important;
    color: white !important;
    border: none !important;
    border-radius: 20px !important;
    padding: 0 !important;
    height: 40px !important;
    font-size: 1rem !important;
    font-weight: 600 !important;
    cursor: pointer;
    margin-top: 5px !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    line-height: 1 !important;
    transition: background-color 0.2s ease-in-out;
}
.sw-single-video-page input[type="submit"]:hover {
    background-color: #dc2626 !important;
}

/* 7. Share Buttons */
.sw-share-buttons button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 40px !important;
    padding: 0 !important;
    line-height: 1 !important;
    font-weight: 600 !important;
    width: 100% !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    border-radius: 20px !important;
}

/* 8. Header Border Remove */
header.fixed {
    border-bottom: none !important;
}

/* 9. Title Gap */
.sw-single-video-page h1 {
    margin-bottom: 40px !important;
    margin-top: 20px !important;
    display: block !important;
}

/* 10. Comment List */
.sw-single-video-page .comment-body {
    color: #d1d5db !important;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #374151;
}
.sw-single-video-page .fn {
    color: #ffffff !important;
    font-weight: bold;
}
.sw-single-video-page .comment-metadata a {
    color: #9ca3af !important;
    font-size: 0.75rem;
    text-decoration: none;
}
.sw-single-video-page .reply a {
    color: #ef4444 !important;
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
}

/* 11. Related Videos Grid */
.sw-related-videos {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 1.5rem;
}
@media (min-width: 640px) {
    .sw-related-videos { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}
@media (min-width: 1024px) {
    .sw-related-videos { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}

/* 12. Button Grid Layout (FORCED FIX - 3 Columns) */

.sw-actions-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr !important; 
    gap: 8px !important;
    width: 100% !important;
}

/* --- MOBILE SETTINGS (දුරකථන සඳහා) --- */
.sw-action-btn, 
.sw-single-video-page .bg-red-600 {
    width: 100% !important;
    grid-column: span 1 !important;
    padding: 0 2px !important;
    
    /* 1. MOBILE FONT SIZE (මොබයිල් අකුරු ප්‍රමාණය) */
    /* 12px මදි නම් 13px හෝ 14px දමා බලන්න */
    font-size: 16px !important; 

    /* 2. MOBILE BUTTON HEIGHT (මොබයිල් බොත්තමේ උස) */
    /* 40px මදි නම් 45px හෝ 50px දමා බලන්න */
    height: 45px !important; 

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Request to Remove Button (Mobile) */
.sw-single-video-page .bg-green-600 {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    margin-top: 5px !important;
    
    /* Green Button එකට වෙනම උසක් අවශ්‍ය නම් මෙතනට height එකක් දාන්න පුළුවන් */
    /* height: 45px !important; */
}

/* --- DESKTOP SETTINGS (පරිගණක සඳහා) --- */
@media (min-width: 768px) {
    .sw-actions-grid {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 10px !important;
        grid-template-columns: none !important;
    }
    .sw-action-btn,
    .sw-single-video-page .bg-red-600 {
        width: auto !important;
        padding: 0 24px !important;
        grid-column: auto !important;

        /* 3. DESKTOP FONT SIZE (ඩෙස්ක්ටොප් අකුරු ප්‍රමාණය) */
        font-size: 1rem !important; /* 1rem = 16px */

        /* 4. DESKTOP BUTTON HEIGHT (ඩෙස්ක්ටොප් බොත්තමේ උස) */
        /* ඔබට ඩෙස්ක්ටොප් එකේදී බොත්තම ලොකු කරන්න ඕන නම් මෙය වෙනස් කරන්න */
        height: 45px !important; 
    }
    .sw-single-video-page .bg-green-600 {
        width: auto !important;
        margin-top: 0 !important;
        grid-column: auto !important;
        
        /* Request Button එක Desktop එකේදී වෙනස් කරන්න ඕන නම් */
        height: 45px !important;
    }
}

/* 13. General Reset */
.sw-single-video-page button {
    border: none !important;
    outline: none !important;
}

/*************************************

/* --- FOOTER & AGE VERIFICATION STYLES (Fixed Line Width & Position) --- */

/* 1. HIDE UNWANTED THEME CREDITS */
.site-info, .copyright, .footer-credits, .powered-by {
    display: none !important;
}

/* 2. FOOTER CONTAINER (Reset) */
.site-footer {
    background-color: #111827 !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
    border: none !important;
    position: relative !important;
}

/* Remove the full-width pseudo-element if it exists */
.site-footer::before {
    display: none !important;
}

/* 3. Footer Grid Layout (WITH THE NEW LINE) */
.sw-footer-grid {
    /* මෙන්න ඔයා ඉල්ලපු ඉර (දැන් මේක බොක්ස් එක ඇතුලේ විතරයි) */
    border-top: 1px solid #1f2937 !important; 
    
    /* ඉර සහ උඩ කන්ටෙන්ට් එක අතර පරතරය (Move line down) */
    margin-top: 50px !important; 
    
    /* ඉර සහ Footer Text එක අතර පරතරය */
    padding-top: 50px !important; 
    
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

/* Footer Links */
.sw-footer-link {
    color: #9ca3af !important;
    text-decoration: none !important;
    transition: 0.2s;
}
.sw-footer-link:hover {
    color: #ef4444 !important;
    padding-left: 5px;
}

/* Disclaimer Section */
.sw-footer-disclaimer {
    border-top: 1px solid #1f2937; 
    padding-top: 30px;
    margin-bottom: 30px;
    font-size: 13px;
    text-align: center;
    color: #6b7280;
}

/* 4. AGE VERIFICATION POPUP STYLES */
.sw-age-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.96);
    backdrop-filter: blur(8px);
    z-index: 9999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.sw-age-modal {
    background-color: #111827;
    border: 2px solid #ef4444;
    border-radius: 16px;
    padding: 35px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    box-shadow: 0 0 50px rgba(239, 68, 68, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* POPUP LOGO */
.sw-age-logo-box {
    margin-bottom: 10px;
    text-align: center;
    width: 100%;
}
.sw-age-site-name {
    color: #ffffff;
    font-size: 36px; 
    font-weight: 900;
    letter-spacing: -1px;
}
.sw-text-red {
    color: #ef4444 !important;
}

.sw-age-title {
    color: #d1d5db;
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.sw-age-text {
    color: #9ca3af;
    font-size: 15px;
    line-height: 1.5;
    margin-bottom: 25px;
    text-align: center;
    width: 100%;
}

.sw-age-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

/* BUTTONS */
.sw-btn-enter, .sw-btn-exit {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    width: 100%;
    border-radius: 8px;
    cursor: pointer;
    border: none;
    padding: 0 !important;
    height: 54px !important;
}

.sw-btn-enter {
    background-color: #ef4444;
    color: white;
    font-size: 18px;
    font-weight: 800;
    text-transform: uppercase;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
    transition: transform 0.2s;
}
.sw-btn-enter:hover { transform: scale(1.02); background-color: #dc2626; }

.sw-btn-exit {
    background-color: #374151;
    color: #9ca3af;
    font-size: 15px;
    font-weight: 600;
}
.sw-btn-exit:hover { color: #fff; background-color: #4b5563; }

/* Popup Footer Text */
.sw-age-footer {
    margin-top: 20px;
    margin-bottom: 0;
    font-size: 12px;
    color: #6b7280;
    text-align: center;
    width: 100%;
}
.sw-age-footer a { color: #ef4444; }

/* Mobile Adjustments */
@media (max-width: 600px) {
    .sw-age-modal { padding: 25px 20px; }
    .sw-age-site-name { font-size: 30px; }
    .sw-btn-enter { font-size: 16px; height: 48px !important; }
    .sw-btn-exit { height: 48px !important; }
}

/************************************

/* ==========================================================================
   1. STANDARD POSTS (For normal video uploads)
   ========================================================================== */

/* Add gap between videos/images/text */
.sw-content-body > * {
    margin-bottom: 40px !important;
    display: block;
}

/* SMART VIDEO STYLING 
   This applies 16:9 ratio ONLY to standard videos.
   It IGNORES your custom HTML grid videos (.media-item).
*/
.sw-content-body iframe:not(.media-item iframe), 
.sw-content-body video:not(.media-item video), 
.sw-content-body embed, 
.sw-content-body object {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 16 / 9; 
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.5); 
    background-color: #000;
}

/* Standard Image Styling */
.sw-content-body img:not(.media-item img) {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 0 auto 30px auto;
    display: block;
}

/* ==========================================================================
   2. FIX FOR YOUR ORIGINAL CUSTOM HTML GRID
   ========================================================================== */

/* Ensure the grid works without theme interference */
.media-grid {
    display: grid !important;
    gap: 80px !important;
    padding: 20px !important;
    width: 100% !important;
}

/* Reset item container */
.media-item {
    position: relative !important;
    overflow: hidden !important;
    border-radius: 10px !important;
    background: #000 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Force images/videos inside your grid to fit correctly */
.media-item img,
.media-item iframe {
    width: 100% !important;
    height: auto !important;
    display: block !important;
    border: none !important;
    box-shadow: none !important;
    /* Important: Remove aspect-ratio force so your code controls height */
    aspect-ratio: auto !important; 
}

/* ==========================================================================
   3. COMMENT BOX STYLING (Dark Theme)
   ========================================================================== */

.sw-comments-wrapper textarea,
.sw-comments-wrapper input[type="text"],
.sw-comments-wrapper input[type="email"],
.sw-comments-wrapper input[type="url"] {
    background-color: #374151 !important; /* Dark Gray */
    border: 1px solid #4b5563 !important;
    color: #ffffff !important; /* White Text */
    border-radius: 8px !important;
    padding: 16px !important;
    width: 100% !important;
    font-size: 0.95rem !important;
    margin-bottom: 16px !important;
    box-sizing: border-box !important;
    outline: none !important;
}

.sw-comments-wrapper textarea:focus,
.sw-comments-wrapper input:focus {
    border-color: #ef4444 !important;
}

/* Hide Default Labels */
.comment-form-comment label,
.comment-form-email label {
    display: none !important;
}

/* Submit Button */
.sw-submit-btn, 
input[name="submit"],
#submit {
    background-color: #ef4444 !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    border: none !important;
    padding: 14px 0 !important;
    border-radius: 99px !important;
    width: 100% !important;
    cursor: pointer;
    margin-top: 10px !important;
}

.sw-submit-btn:hover, 
input[name="submit"]:hover,
#submit:hover {
    background-color: #dc2626 !important;
}

/*************************************************
*************************************************

/* --- SINGLE VIDEO PAGE FIXES --- */

/* 1. Main Video Aspect Ratio Fix */
.sw-raw-content iframe, 
.sw-raw-content video,
.sw-raw-content embed,
.sw-raw-content object {
    width: 100% !important;
    aspect-ratio: 16 / 9 !important; /* වීඩියෝ එකේ උස සහ පළල අනුපාතය නිවැරදි කරයි */
    height: auto !important;
}

/* 2. Main Content Container Width */
.sw-raw-content {
    width: 100% !important;
    max-width: 100% !important;
}

/**********************************************

/* --- Button Icons Styling --- */
.sw-action-btn svg {
    width: 18px; /* අයිකනයේ පළල */
    height: 18px; /* අයිකනයේ උස */
    margin-right: 8px; /* අයිකනය සහ වචනය අතර පරතරය */
    fill: currentColor; /* අකුරු වල පාටම අයිකනයටත් ගන්නවා */
    display: inline-block;
    vertical-align: middle;
}

/* Mobile එකේදී අයිකනය පොඩ්ඩක් කුඩා කරමු */
@media (max-width: 768px) {
    .sw-action-btn svg {
        width: 16px;
        height: 16px;
        margin-right: 5px;
    }
}


/* =========================================
   WAL KATHA PAGE STYLES (New Grid Design)
   ========================================= */

/* Main Page Background & Spacing */
.wk-header-area {
    text-align: center;
    margin-bottom: 3rem;
    padding-top: 1rem;
}
.wk-subtitle {
    color: #9ca3af;
    font-size: 1.1rem;
    margin-top: 0.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Grid Layout (Responsive) */
.wk-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}
@media (min-width: 640px) {
    .wk-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
    .wk-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Card Style */
.wk-card {
    background-color: #1f2937; /* Dark Gray Card Bg */
    border: 1px solid #374151;
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    height: 100%;
}

.wk-card:hover {
    transform: translateY(-5px);
    border-color: #ef4444; /* Red border on hover */
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* Category Badge */
.wk-badge {
    background-color: rgba(239, 68, 68, 0.15);
    color: #f87171;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 1rem;
    letter-spacing: 0.5px;
}

/* Title */
.wk-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 0.75rem;
    color: #ffffff;
}
.wk-card-title a {
    color: #ffffff !important;
    text-decoration: none;
    transition: color 0.2s;
}
.wk-card:hover .wk-card-title a {
    color: #ef4444 !important;
}

/* Excerpt */
.wk-excerpt {
    color: #9ca3af;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Meta Data (Views, Time) */
.wk-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: #6b7280;
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #374151;
}
.wk-meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.wk-date {
    margin-left: auto; /* Push date to right */
    font-size: 0.8rem;
}

/* Read More Footer */
.wk-footer {
    margin-top: auto;
}
.wk-read-more {
    color: #ef4444;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: gap 0.2s;
}
.wk-card:hover .wk-read-more {
    gap: 0.5rem;
}

/* Pagination Adjustments for this page */
.sw-pagination-wrapper {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
}