/* =================================================================
   ICGL Rudraksha Certificate Verifier — Frontend CSS
   Front LEFT (57%) | Back RIGHT (43%)
   ================================================================= */

.irud-wrap *, .irud-wrap *::before, .irud-wrap *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.irud-wrap {
    font-family: Arial, Helvetica, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 16px;
    color: #111;
}

/*
 * KEY CLASS — used on all <img> elements while src = transparent pixel.
 * Uses opacity:0 NOT display:none.
 * opacity:0 keeps the element in layout → certificate never collapses.
 * display:none is overridden by themes with !important → images never re-appear.
 */
.irud-blank {
    opacity: 0 !important;
}

/* =================================================================
   VERIFY FORM
   ================================================================= */
.irud-form-section {
    display: flex;
    justify-content: center;
    padding: 20px 0 40px;
}

.irud-form-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 28px rgba(0,0,0,.10);
    padding: 38px 42px 42px;
    width: 100%;
    max-width: 500px;
}

.irud-form-badge {
    display: inline-block;
    background: #e0e9fb;
    color: #1a3a8c;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.2px;
    padding: 5px 16px;
    border-radius: 50px;
    margin-bottom: 18px;
    text-transform: uppercase;
}

.irud-form-title {
    font-size: 24px !important;
    font-weight: 700 !important;
    color: #111 !important;
    margin: 0 0 7px !important;
    padding: 0 !important;
    border: none !important;
    line-height: 1.25 !important;
}

.irud-form-sub {
    font-size: 13px;
    color: #1a3a8c;
    margin-bottom: 24px;
    line-height: 1.5;
}

.irud-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #111;
    margin-bottom: 9px;
}

.irud-input {
    display: block;
    width: 100%;
    border: 1.5px solid #d1d9e6;
    border-radius: 8px;
    padding: 13px 15px;
    font-size: 14px;
    color: #444;
    outline: none;
    margin-bottom: 10px;
    background: #fafbff;
    transition: border-color .2s;
}
.irud-input:focus { border-color: #1a3a8c; background: #fff; }

.irud-err {
    color: #c0392b;
    font-size: 13px;
    padding: 9px 14px;
    background: #fdf2f2;
    border-radius: 5px;
    border-left: 3px solid #c0392b;
    margin-bottom: 10px;
}

.irud-verify-btn {
    display: block;
    width: 100%;
    background: #1a3a8c;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 14px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    cursor: pointer;
    margin-top: 14px;
    transition: background .2s;
}
.irud-verify-btn:hover { background: #152f70; }

/* =================================================================
   PRODUCT IMAGE — centred above both cert cards
   ================================================================= */
.irud-product-top {
    text-align: center;
    margin-bottom: 20px;
}

.irud-product-top-img {
    display: block;
    width: 200px;
    height: 165px;
    object-fit: contain;
    margin: 0 auto 8px;
    transition: opacity .3s;
}

.irud-product-title {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #111;
}

/* =================================================================
   CARDS ROW — FRONT left (57%) | BACK right (43%)
   flex-direction: row is ALWAYS enforced on desktop
   ================================================================= */
.irud-cards-row {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    width: 100%;
    gap: 0;
}

.irud-card {
    position: relative;
    overflow: hidden;
}

/* =================================================================
   FRONT CERTIFICATE (left)
   ================================================================= */
.irud-front {
    flex: 0 0 57%;
    max-width: 57%;
    background: #f4f4f4;
    border: 1px solid #c8c8c8;
    border-right: none;
    border-radius: 6px 0 0 6px;
    display: flex;
    flex-direction: column;
    box-shadow: -2px 0 10px rgba(0,0,0,.07);
}

/* Header */
.irud-front-header {
    background: #0e2a6e;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.irud-logo-img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    flex-shrink: 0;
    background: transparent; /* PNG transparency preserved on navy */
    display: block;
    transition: opacity .3s;
}

.irud-header-text {
    font-size: 17px;
    font-weight: 800;
    color: #fff;
    line-height: 1.3;
}

/* Sub-title */
.irud-front-subtitle {
    text-align: center;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 1px;
    color: #111;
    padding: 13px 14px 9px;
    background: #f4f4f4;
    position: relative;
    z-index: 2;
    flex-shrink: 0;
}

/* Body */
.irud-front-body {
    display: flex;
    flex-direction: row;
    padding: 0 14px 18px;
    position: relative;
    z-index: 2;
    flex: 1;
}

/* Data table — left column */
.irud-front-data {
    flex: 1;
    padding-right: 12px;
    min-width: 0;
}

.irud-tbl {
    width: 100%;
    border-collapse: collapse;
}
.irud-tbl tr { border: none; }

.irud-tbl .lbl {
    font-size: 11.5px;
    font-weight: 700;
    color: #111;
    padding: 3.5px 7px 3.5px 0;
    vertical-align: top;
    white-space: nowrap;
    width: 46%;
}

.irud-tbl .val {
    font-size: 11.5px;
    color: #111;
    padding: 3.5px 0;
    vertical-align: top;
}

/* Species / Remarks box */
.irud-sp-box {
    border: 1.5px solid #444;
    border-radius: 2px;
    margin-top: 9px;
}
.irud-sp-box .lbl { padding-left: 6px; }
.irud-sp-box .val  { padding-right: 6px; }

/* Right column */
.irud-front-right {
    width: 178px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.irud-img-qr-row {
    display: flex;
    flex-direction: row;
    gap: 5px;
    width: 100%;
}

.irud-prod-img-box {
    flex: 1;
    border: 1px solid #ccc;
    background: #fff;
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.irud-prod-img {
    width: 100%;
    height: 82px;
    object-fit: contain;
    display: block;
    transition: opacity .3s;
}

.irud-qr-box {
    flex-shrink: 0;
    width: 82px;
    height: 82px;
    border: 1px solid #ccc;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.irud-qr-img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    display: block;
    transition: opacity .3s;
}

.irud-prod-lbl {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    text-align: center;
    color: #111;
    margin-top: 2px;
}

.irud-sig-area {
    width: 100%;
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.irud-sig-img {
    width: 120px;
    height: 44px;
    object-fit: contain;
    display: block;
    transition: opacity .3s;
}

.irud-sig-line {
    width: 100%;
    border-top: 1.5px solid #333;
    margin: 5px 0 2px;
}

.irud-sig-text {
    font-size: 10px;
    font-weight: 600;
    color: #111;
    text-align: center;
}

/* Watermark */
.irud-watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: .07;
    pointer-events: none;
    z-index: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.irud-wm-img {
    width: 180px;
    height: 180px;
    object-fit: contain;
    display: block;
    filter: grayscale(100%);
}

.irud-wm-text {
    font-size: 38px;
    font-weight: 900;
    color: #555;
    letter-spacing: 6px;
    display: block;
    margin-top: 4px;
}

/* =================================================================
   BACK CERTIFICATE (right)
   ================================================================= */
.irud-back {
    flex: 0 0 43%;
    max-width: 43%;
    background: #e6e6e6;
    border: 1px solid #c8c8c8;
    border-radius: 0 6px 6px 0;
    display: flex;
    flex-direction: column;
    padding: 30px 28px 24px;
    box-shadow: 2px 0 10px rgba(0,0,0,.07);
}

.irud-back-title {
    font-size: 18px;
    font-weight: 900;
    color: #111;
    text-align: center;
    margin-bottom: 12px;
    line-height: 1.2;
}

.irud-back-line {
    width: 100%;
    height: 1.5px;
    background: #aaa;
    margin-bottom: 18px;
    flex-shrink: 0;
}

.irud-back-list {
    flex: 1;
    list-style: disc;
    padding-left: 20px;
}

.irud-back-list li {
    font-size: 12.5px;
    color: #111;
    line-height: 1.75;
    margin-bottom: 14px;
    padding-left: 2px;
}
.irud-back-list li:last-child { margin-bottom: 0; }

.irud-back-web {
    text-align: center;
    font-size: 13px;
    color: #333;
    margin-top: 20px;
    flex-shrink: 0;
}

/* =================================================================
   VERIFY AGAIN — exact colour #0557BC
   ================================================================= */
.irud-again-wrap {
    text-align: center;
    margin-top: 28px;
}

.irud-again-btn {
    background: #0557BC;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 13px 34px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s;
}
.irud-again-btn:hover { background: #044fa8; }

/* =================================================================
   RESPONSIVE
   ================================================================= */
@media (max-width: 900px) {
    .irud-cards-row { flex-direction: column; }
    .irud-front {
        flex: none; max-width: 100%;
        border-right: 1px solid #c8c8c8;
        border-bottom: none;
        border-radius: 6px 6px 0 0;
    }
    .irud-back {
        flex: none; max-width: 100%;
        border-top: 1px solid #aaa;
        border-radius: 0 0 6px 6px;
    }
}

@media (max-width: 640px) {
    .irud-form-card       { padding: 26px 20px 30px; }
    .irud-form-title      { font-size: 20px !important; }
    .irud-front-header    { padding: 8px 10px; gap: 8px; }
    .irud-logo-img        { width: 46px; height: 46px; }
    .irud-header-text     { font-size: 13px; }
    .irud-front-subtitle  { font-size: 12px; padding: 10px 10px 8px; }
    .irud-front-body      { flex-direction: column; padding: 0 10px 14px; }
    .irud-front-data      { padding-right: 0; }
    .irud-front-right     { width: 100%; margin-top: 14px; flex-direction: row; flex-wrap: wrap; justify-content: center; }
    .irud-img-qr-row      { width: auto; }
    .irud-sig-area        { width: 100%; margin-top: 12px; }
    .irud-tbl .lbl,
    .irud-tbl .val        { font-size: 10.5px; }
    .irud-back            { padding: 20px 16px 18px; }
    .irud-back-title      { font-size: 15px; }
    .irud-back-list li    { font-size: 12px; margin-bottom: 11px; }
    .irud-product-top-img { width: 140px; height: 115px; }
}

@media (max-width: 380px) {
    .irud-header-text     { font-size: 11px; }
    .irud-tbl .lbl,
    .irud-tbl .val        { font-size: 10px; }
    .irud-back-title      { font-size: 13px; }
}
