@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn.woff2') format('woff2'); 
    font-weight: 100 900; 
    font-style: normal;
}
@font-face {
    font-family: 'Arad';
    src: url('../fonts/AradVF.woff2') format('woff2'); 
    font-weight: 100 900; 
    font-style: normal;
}
@font-face {
    font-family: 'Lalezar';
    src: url('../fonts/Lalezar.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'IranNastaliq';
    src: url('../fonts/IranNastaliq.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Shekasteh';
    src: url('../fonts/Shekasteh.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Far-khodkar';
    src: url('../fonts/Farkhodkar.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Aban';
    src: url('../fonts/AbanLight.woff2') format('woff2');
    font-weight: 300;
}
@font-face {
    font-family: 'Aban';
    src: url('../fonts/Aban.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Aban';
    src: url('../fonts/AbanBold.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Paeez';
    src: url('../fonts/Paeez.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Nabi';
    src: url('../fonts/Nabi.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Moalla';
    src: url('../fonts/Moalla.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Estedad';
    src: url('../fonts/Estedad.woff2') format('woff2');
    font-weight: 100 900;
}
@font-face {
    font-family: 'Mikhak';
    src: url('../fonts/Mikhak.woff2') format('woff2');
    font-weight: 100 800;
}
@font-face {
    font-family: 'Sahel';
    src: url('../fonts/SahelVF.woff2') format('woff2');
    font-weight: 300 900;
}
@font-face {
    font-family: 'Rooyin';
    src: url('../fonts/RooyinRegular.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Rooyin';
    src: url('../fonts/RooyinBold.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Rooyin';
    src: url('../fonts/RooyinRegularDots2.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Sorena';
    src: url('../fonts/SorenaNormal.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Sorena';
    src: url('../fonts/SorenaPixel.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Iran-Dorandis';
    src: url('../fonts/IranDorandis.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Jomhuri';
    src: url('../fonts/Jomhuri.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Tanha';
    src: url('../fonts/Tanha.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Ayasamin';
    src: url('../fonts/Ayasamin.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Digi-shokoh';
    src: url('../fonts/Digishokoh.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Digi-farkhonde';
    src: url('../fonts/Digifarkhonde.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Digi-maryam';
    src: url('../fonts/Digimaryam.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Digi-darya';
    src: url('../fonts/Digidarya.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'titrplus';
    src: url('../fonts/DigiTitrPlusLine.woff2') format('woff2');
    font-weight: 300;
}
@font-face {
    font-family: 'titrplus';
    src: url('../fonts/DigiTitrPlusCircle.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'titrplus';
    src: url('../fonts/DigiTitrPlusRectangle.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Khandevane';
    src: url('../fonts/Khandevane.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Iphone';
    src: url('../fonts/SfArabic.woff2') format('woff2');
    font-weight: 100 900;
}
@font-face {
    font-family: 'Iphone';
    src: url('../fonts/SfPro.woff2') format('woff2');
    font-weight: 100 900;
}
.ttig-container {
    border: 1px solid #dadada;
    max-width: 800px;
    margin: 20px auto;
    font-family: 'Vazirmatn', sans-serif;
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    direction: rtl;
}
.ttig-row {
    margin-bottom: 20px;
}
.ttig-options-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.ttig-adjustments-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
}
#ttig-text {
    width: 100%;
    height: 120px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: inherit;
    font-size: 16px;
    resize: vertical;
}
.ttig-field label {
    display: block;
    font-size: 12px;
}
.ttig-field select, 
.ttig-field input[type="color"] {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    height: 40px;
}
.ttig-number-input {
    display: flex;
    height: 40px;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
}
.ttig-number-input input {
    width: 100%;
    text-align: center;
    border: none;
    -moz-appearance: textfield;
}
.ttig-number-input button {
    background: transparent;
    border: none;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-weight: bold;
}
.ttig-number-input input[type="number"]::-webkit-outer-spin-button,
.ttig-number-input input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
    display: none !important;
}
.ttig-number-input input[type="number"] {
    -moz-appearance: textfield !important;
    width: 100%;
    text-align: center;
    border: none;
    font-size: 14px;
    outline: none;
}
.ttig-btn {
    width: 100%;
    padding: 15px 20px;
    background: linear-gradient(45deg, #309255, #42b983);
    color: white;
    border: none;
    border-radius: 12px;
    font-family: inherit;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(48, 146, 85, 0.3);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.ttig-btn:hover {
    background: linear-gradient(45deg, #257a44, #3aa876);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(48, 146, 85, 0.4);
}
.ttig-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 5px rgba(48, 146, 85, 0.3);
}
.ttig-btn:disabled {
    background: #ccc;
    cursor: wait;
    box-shadow: none;
    transform: none;
}
.ttig-preview-box {
    text-align: center;
    border: 1px dashed #ccc;
    background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwgAADsIBFShKgAAAABhJREFUOE9j/P///38GKgAjkyNG04BqGgAAfL8/wW4l4rAAAAAASUVORK5CYII=');
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    display: block;
    width: -moz-fit-content;
    width: fit-content;
    margin: 20px auto;
    max-width: 100%;
}
#ttig-output-image {
    max-width: 100%;
    height: auto;
    display: block;
}
.ttig-btn-download {
    position: absolute;
    left: 5px;
    bottom: 5px;
    background: rgb(48, 146, 85);
    color: #fff !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    padding: 0;
    border-radius: 50%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    transition: all 0.2s ease;
    z-index: 10;
}
.ttig-btn-download:hover {
    background: #0e602d;
    transform: scale(1.1);
}
.ttig-btn-download svg {
    display: block;
    margin: 0 !important;
}
.ttig-btn-download:hover {
    background: #0e602d;
    transform: translateY(-2px);
}
.ttig-btn-download svg {
    width: 18px;
    height: 18px;
}
.font-dl-cta {
    display: block;
    margin-top: 25px;
    color: #525252 !important;
    font-size: 13px;
    font-weight: normal !important;
    text-decoration: none;
    transition: color 0.3s;
}
.font-dl-cta:hover {
    color: #309255 !important;
}
@media (max-width: 900px) {
    .ttig-adjustments-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 768px) {
    .ttig-options-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 600px) {
    .ttig-options-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .ttig-options-grid > .ttig-field:nth-child(3) {
        grid-column: span 2;
    }
    .ttig-adjustments-grid {
        display: grid;
        grid-template-columns: repeat(6, 1fr);
        gap: 10px;
        align-items: end;
    }
    .ttig-adjustments-grid > .ttig-field:nth-child(1),
    .ttig-adjustments-grid > .ttig-field:nth-child(2) {
        grid-column: span 3;
    }
    .ttig-adjustments-grid > .ttig-field:nth-child(3),
    .ttig-adjustments-grid > .ttig-field:nth-child(4),
    .ttig-adjustments-grid > .ttig-field:nth-child(5) {
        grid-column: span 2;
    }
    .ttig-adjustments-grid > .ttig-field:nth-child(4),
    .ttig-adjustments-grid > .ttig-field:nth-child(5) {
        text-align: center;
    }
    .ttig-adjustments-grid > .ttig-field:nth-child(4) label,
    .ttig-adjustments-grid > .ttig-field:nth-child(5) label {
        font-size: 11px;
        margin-bottom: 3px;
    }
}
