/* ==========================================================
   cini-comment.css
   Styles for: comment.php ONLY
   Requires : cini-common.css

   Link on every page that includes comment.php:
     detail.php → <link rel="stylesheet" href="cini-comment.css">
     video.php  → <link rel="stylesheet" href="cini-comment.css">

   Article / detail styles are in cini-detail.css — NOT here.
   ========================================================== */

/* ========================================
   Section Title Bar
======================================== */
.cmntdmr {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 12px;
    padding-bottom: 0;
    font-size: 1.15rem;
    font-weight: 700;
    border: none;
    font-family: 'Anek Tamil', sans-serif;
}

.cmntdmr h4 {
    color: #000;
    margin: 0;
    padding: 0;
}

.zox-dark .cmntdmr h4 {
    color: #fff;
}

/* ========================================
   Comment List
======================================== */
#comments {
    background: transparent;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    margin: 0 0 12px;
}

.commentlist {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-right: 0;
}

.commentlist li {
    list-style: none;
}

/* ========================================
   Comment Row
======================================== */
.comment-wrapper {
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    margin-bottom: 0;
    transition: all 0.2s ease;
    display: flex;
    align-items: flex-start;
    margin-left: 0;
}

.comment-inner {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    flex-direction: row;
    margin-top: 0;
}

/* ========================================
   Avatar
======================================== */
.comment-avatar {
    flex-shrink: 0;
    margin-top: 4px;
}

.comment-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e0e0e0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.zox-dark .comment-avatar img {
    border-color: #444;
}

.comment-wrapper:hover .comment-avatar img {
    transform: scale(1.05);
}

/* ========================================
   Comment Content
======================================== */
.comment-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.commentmeta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    padding: 0;
    flex-wrap: wrap;
}

.comment-meta-1 {
    margin: 0;
    padding: 0;
    font-size: 15px;
    font-weight: 700;
    color: #000;
    line-height: 1;
}

.zox-dark .comment-meta-1 {
    color: #fff;
}

.comment-meta-1 .fn {
    color: #aa092f;
    font-weight: 700;
}

.comment-meta-2 {
    margin: 0;
    padding: 0;
    font-size: 12px;
    color: #000;
    line-height: 1;
    font-weight: 600;
}

.zox-dark .comment-meta-2 {
    color: #fff;
}

/* ========================================
   Message Bubble
======================================== */
.text {
    display: inline-block;
    background: #f4f6f8;
    border-radius: 14px;
    padding: 12px 16px;
    max-width: min(100%, 760px);
    width: fit-content;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
    margin: 0;
}

.zox-dark .text {
    background: #374151;
}

.text:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

.text p {
    margin: 0;
    padding: 0;
    font-size: 17px;
    color: #333;
    line-height: 1.7;
    word-wrap: break-word;
}

.zox-dark .text p {
    color: #ddd;
}

/* Even comment — green bubble */
.comment.even .text {
    background: #dcf8c6;
    color: #000;
}

.zox-dark .comment.even .text {
    background: #056162;
}

.comment.even .text p {
    color: #000;
}

.zox-dark .comment.even .text p {
    color: #fff;
}

/* ========================================
   Rating Row
======================================== */
.rating-position {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 8px;
    margin-top: 4px;
    margin-bottom: 6px;
    width: 100%;
}

.rating-row {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    margin-top: 6px;
}

/* ========================================
   Reply Button
======================================== */
.reply a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 4px 10px;
    background: #aa092f;
    color: #fff;
    text-decoration: none;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(170, 9, 47, 0.2);
}

.reply a:hover {
    background: #aa092f;
    transform: translateY(-1px);
}

.reply a:active {
    transform: scale(0.98);
}

.reply a svg {
    width: 14px;
    height: 14px;
    color: #fff !important;
}

/* ========================================
   Star Rating
======================================== */
.rating-container {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.rating-container h3 {
    display: none;
}

.rating {
    display: inline-flex;
    gap: 6px;
    align-items: center;
}

.rating i {
    font-size: 22px;
    cursor: pointer;
    color: #ddd;
    transition: all 0.15s ease;
    transform-origin: center;
}

.zox-dark .rating i {
    color: #555;
}

.rating i:hover,
.rating i.selected {
    color: #ffc107;
    transform: scale(1.18);
}

.rating .label {
    display: none;
}

.members {
    display: none;
}

.message {
    display: none;
}

/* ========================================
   Comment Form
======================================== */
#respond {
    margin-top: 8px;
    padding-top: 16px;
    border-top: 1px solid #e0e0e0;
    margin-left: 0;
}

.zox-dark #respond {
    border-top-color: #333;
}


#reply-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 16px;
}

#reply-title h4 {
    font-size: 1rem;
    font-weight: 700;
}

#cancel-comment-reply-link {
    color: #aa092f;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
    padding: 4px 8px;
}

#cancel-comment-reply-link:hover {
    color: #78001c;
    text-decoration: underline;
}

.comment-form-comment {
    margin: 0 0 16px 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.comment-guidelines {
    margin: 0;
    padding: 10px 12px;
    width: 100%;
    box-sizing: border-box;
    background: #fff8f0;
    border-left: 1px solid #eadfcb;
    border-right: 1px solid #eadfcb;
    border-top: 1px solid #f2e7d6;
    color: #6b5a43;
    font-size: 12px;
    line-height: 1.5;
}

.zox-dark .comment-guidelines {
    background: #26211b;
    border-left-color: #42372b;
    border-right-color: #42372b;
    border-top-color: #42372b;
    color: #d6c2a6;
}

.comment-auth-cta {
    margin: 0;
    padding: 18px;
    border-radius: 16px;
    background: linear-gradient(180deg, #f8fafc 0%, #eef3f9 100%);
    border: 1px solid #d7e0ec;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    text-align: left;
    box-shadow: 0 10px 30px rgba(17, 24, 39, 0.06);
}

.comment-auth-copy {
    margin: 0;
    color: #465468;
    font-size: 14px;
    line-height: 1.7;
}

.comment-compose-box {
    display: flex;
    align-items: stretch;
    width: 100%;
    border: 1px solid #8ea0b8;
    border-radius: 8px;
    overflow: hidden;
    background: #24303d;
}

.comment-compose-field {
    flex: 1;
    min-width: 0;
    padding: 14px 16px;
    color: #d3d9e1;
    font-size: 17px;
    line-height: 1.3;
    background: #24303d;
}

.comment-compose-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 134px;

    border-left: 1px solid rgba(255, 255, 255, 0.16);
    background: linear-gradient(180deg, #c30b37 0%, #aa092f 100%);
    color: #fff !important;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.2s ease, transform 0.2s ease;
}

.comment-auth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 160px;
    padding: 10px 20px;
    border-radius: 999px;
    background: #25D366;
    color: #fff !important;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.24);
    transition: all 0.2s ease;
}

.comment-auth-btn:hover {
    background: #20BA58;
    transform: translateY(-1px);
}

.zox-dark .comment-auth-cta {
    background: linear-gradient(180deg, #1f2328 0%, #171a1f 100%);
    border-color: #2f3845;
}

.zox-dark .comment-auth-copy {
    color: #c9d1db;
}

.zox-dark .comment-compose-box {
    border-color: #546274;
    background: #222d39;
}

.zox-dark .comment-compose-field {
    background: #222d39;
    color: #dde5ef;
}

.zox-dark .comment-compose-btn {
    background: linear-gradient(180deg, #c30b37 0%, #aa092f 100%);
}

.comment-compose-btn:hover {
    background: linear-gradient(180deg, #d10d3b 0%, #b10831 100%);
}

.comment-compose-btn:active {
    transform: translateY(1px);
}

.text-and-reply {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

#input_tool_helper {
    width: 100%;
    margin-bottom: 8px;
}

/* Tamil / English toggle bar */
#selText2 {
    background: linear-gradient(135deg, #f5e8dd 0%, #f9f3ed 100%);
    border-radius: 12px 12px 0 0;
    padding: 8px 12px !important;
    margin: 0 !important;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 10px;
    border: none;
    transition: all 0.2s ease;
}

.zox-dark #selText2 {
    background: linear-gradient(135deg, #333 0%, #2a2a2a 100%);
}

#selText {
    font-size: 12px;
    color: #666;
    margin: 0;
    font-weight: 500;
    width: 100%;
    text-align: center;
    line-height: 1.45;
    word-wrap: break-word;
    word-break: break-word;
    white-space: normal;
}

.zox-dark #selText {
    color: #aaa;
}

#selTranss {
    padding: 4px 8px !important;
    background: #aa092f !important;
    color: #fff !important;
    border: none !important;
    border-radius: 6px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    white-space: nowrap;
    transition: all 0.2s ease !important;
    display: inline-block !important;
    width: auto !important;
    margin: 0 auto !important;
    flex-shrink: 0;
    align-self: center;
}

#selTranss:hover {
    background: #78001c !important;
    transform: translateY(-1px);
}

/* Textarea */
#cmnts {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    display: block;
    border: none;
    border-radius: 0 0 12px 12px;
    padding: 12px !important;
    margin: 0 !important;
    font-family: 'Mukta Malar', sans-serif;
    font-size: 13px;
    line-height: 1.5;
    color: #333;
    background: #fff;
    resize: vertical;
    min-height: 100px;
    max-height: 250px;
    transition: all 0.2s ease;
    outline: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.zox-dark #cmnts {
    background: #2a2a2a;
    color: #ddd;
}

#cmnts:focus {
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.15);
    border: 1px solid #25D366;
}

#cmnts::placeholder {
    color: #999;
}

.zox-dark #cmnts::placeholder {
    color: #777;
}

/* Submit button */
.form-submit {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}

.form-submit .submit {
    padding: 8px 20px !important;
    background: #25D366 !important;
    color: #fff !important;
    border: none !important;
    border-radius: 20px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 2px 6px rgba(37, 211, 102, 0.2);
}

.form-submit .submit:hover {
    background: #20BA58 !important;
    transform: translateY(-2px);
}

.form-submit .submit:active {
    transform: translateY(0);
}

/* ========================================
   Mobile Responsive
======================================== */
@media (max-width: 768px) {
    .text {
        max-width: 100%;
        padding: 11px 14px;
    }

    .text p {
        font-size: 16px;
        line-height: 1.65;
    }

    .rating-position,
    .rating-row {
        width: 100%;
        align-items: flex-start !important;
        justify-content: flex-start !important;
        gap: 8px;
    }

    .comment-inner {
        gap: 8px;
    }

    .comment-meta-1 {
        font-size: 14px;
    }

    .comment-avatar img {
        width: 32px;
        height: 32px;
    }

    .commentmeta {
        gap: 4px 8px;
    }

    #cmnts {
        font-size: 13px;
    }

    .rating i {
        font-size: 18px;
    }

    .reply a {
        font-size: 11px;
        padding: 3px 8px;
    }

    .cmntdmr {
        font-size: 1rem;
    }

    .comment-auth-cta {
        padding: 14px;
    }

    .comment-compose-box {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
    }

    .comment-compose-field {
        padding: 14px;
        font-size: 16px;
    }

    .comment-compose-btn {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        min-width: 0 !important;
        height: 50px !important;
        min-height: 50px !important;
        border-left: none !important;
        border-top: 1px solid rgba(255, 255, 255, 0.12) !important;
        text-align: center !important;
        line-height: 50px !important;
        vertical-align: middle !important;
    }
}

@media (max-width: 767px) {
  #selText2 {
    flex-direction: column;
    align-items: center;
  }

  #selText {
    width: 100%;
    flex-basis: auto;
    text-align: center;
    line-height: 1.4;
  }
}

@media (max-width: 480px) {
    .comment-content {
        gap: 8px;
    }

    .comment-meta-2 {
        font-size: 10px;
    }

    #reply-title {
        align-items: flex-start;
    }

    .form-submit {
        justify-content: stretch;
    }

    .form-submit .submit {
        width: 100%;
        border-radius: 12px !important;
    }

    #cmnts {
        min-height: 80px;
        max-height: 200px;
    }
}
