<!DOCTYPE html>
<html lang="bn">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>đ Afrin Marriage Media - āϏোāĻļ্āϝাāϞ āĻĒোāϏ্āĻ āĻেāύাāϰেāĻāϰ đ</title>
<style>
* { box-sizing: border-box; }
body { font-family: 'Segoe UI', Tahoma, sans-serif; background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #fecfef 100%); margin: 0; padding: 10px; color: #333; }
.container { max-width: 900px; margin: 0 auto; background: white; border-radius: 25px; box-shadow: 0 25px 50px rgba(0,0,0,0.15); overflow: hidden; }
header { background: linear-gradient(45deg, #E91E63, #9C27B0); color: white; padding: 20px; text-align: center; }
header img.logo { width: 120px; height: auto; margin-bottom: 10px; border-radius: 50%; box-shadow: 0 10px 20px rgba(0,0,0,0.3); }
h1 { margin: 0; font-size: 1.8em; }
.tabs { display: flex; background: #f8f9fa; }
.tab-btn { flex: 1; padding: 15px; border: none; background: none; cursor: pointer; font-weight: bold; transition: all 0.3s; }
.tab-btn.active { background: linear-gradient(45deg, #E91E63, #9C27B0); color: white; }
.tab-content { display: none; padding: 20px; }
.tab-content.active { display: block; }
form { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
label { font-weight: bold; color: #9C27B0; margin-bottom: 5px; display: block; font-size: 0.95em; }
input, select, textarea { width: 100%; padding: 12px; border: 2px solid #ddd; border-radius: 12px; font-size: 16px; transition: border-color 0.3s; }
input:focus, select:focus, textarea:focus { border-color: #E91E63; outline: none; }
textarea { grid-column: 1 / -1; min-height: 80px; resize: vertical; }
.preview-section { grid-column: 1 / -1; text-align: center; margin-top: 20px; }
#livePreview { width: 300px; height: 450px; border-radius: 15px; box-shadow: 0 15px 30px rgba(0,0,0,0.2); border: 3px solid #E91E63; }
.actions { grid-column: 1 / -1; display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 20px; }
.btn { padding: 12px 24px; border: none; border-radius: 25px; font-weight: bold; cursor: pointer; transition: all 0.3s; font-size: 1em; flex: 1; max-width: 200px; }
.btn-primary { background: linear-gradient(45deg, #E91E63, #9C27B0); color: white; }
.btn-primary:hover { transform: scale(1.05); }
.btn-secondary { background: #f8f9fa; color: #9C27B0; border: 2px solid #9C27B0; }
#caption { background: linear-gradient(45deg, #f8f9fa, #fff); padding: 15px; border-radius: 12px; margin-top: 15px; border-left: 5px solid #E91E63; display: none; }
#bulkForm { display: none; }
#bulkInput { width: 100%; height: 200px; font-family: monospace; }
.bulk-list { max-height: 300px; overflow-y: auto; }
.bulk-item { border: 1px solid #ddd; margin: 10px 0; padding: 10px; border-radius: 10px; }
@media (max-width: 768px) { form { grid-template-columns: 1fr; } .actions { flex-direction: column; } }
</style>
</head>
<body>
<div class="container">
<header>
<img class="logo" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg_Vx5gjWzYnNoQIgiheEED0muEzzKPti1fEJNKsjyvZOA87trLnEAm5-075oI5wprNbpOlgVIJeD4_p68kwQ5B0SZl59kUAqKS7goXckRVkAgULyjpjmUXuyIOozYaqSqTaF2YNhqD88rI2dIQRYQeHySqNTl2fi4j_SaOhVKhed0_Mp5gwRL2PgPe-3Sl/s1600/Afrin%20Marriage%20Media%20Logo.png.png" alt="Afrin Marriage Media" onload="initCanvas()" onerror="this.style.display='none'">
<h1>đ Afrin Marriage Media āĻĒোāϏ্āĻ āĻেāύাāϰেāĻāϰ đ</h1>
<p>āĻĒাāϤ্āϰ/āĻĒাāϤ্āϰী āĻĒ্āϰোāĻĢাāĻāϞ āĻĨেāĻে FB/IG āĻĒোāϏ্āĻ āϤৈāϰি āĻāϰুāύ</p>
</header>
<div class="tabs">
<button class="tab-btn active" onclick="showTab('single')">āĻāĻāĻ āĻĒ্āϰোāĻĢাāĻāϞ</button>
<button class="tab-btn" onclick="showTab('bulk')">āĻŦাāϞ্āĻ (āĻŽাāϞ্āĻি)</button>
</div>
<div id="singleTab" class="tab-content active">
<form id="form">
<div>
<label>āĻাāĻāĻĒ</label>
<select id="type"><option value="āĻĒাāϤ্āϰী āĻাāĻ">āĻĒাāϤ্āϰী āĻাāĻ (āĻĒাāϤ্āϰ)</option><option value="āĻĒাāϤ্āϰ āĻাāĻ">āĻĒাāϤ্āϰ āĻাāĻ (āĻĒাāϤ্āϰী)</option></select>
</div>
<div>
<label>āύাāĻŽ</label>
<input type="text" id="name" placeholder="āϝেāĻŽāύ: āϰাāĻšুāϞ āĻাāύ" value="āϰাāĻšুāϞ āĻাāύ">
</div>
<div>
<label>āĻŦāϝ়āϏ</label>
<input type="text" id="age" placeholder="ā§Šā§Ļ" value="ā§Šā§Ļ">
</div>
<div>
<label>āĻāĻ্āĻāϤা</label>
<input type="text" id="height" placeholder="ā§Ģ āĻĢুāĻ ā§ āĻāĻ্āĻি" value="ā§Ģ'ā§"">
</div>
<div>
<label>āĻļিāĻ্āώা</label>
<input type="text" id="education" placeholder="BUTEX" value="BUTEX">
</div>
<div>
<label>āĻĒেāĻļা</label>
<input type="text" id="profession" placeholder="āĻ
্āϝাāϏিāϏ্āĻ্āϝাāύ্āĻ āĻĄিāϰেāĻ্āĻāϰ (NSI)" value="āĻ
্āϝাāϏিāϏ্āĻ্āϝাāύ্āĻ āĻĄিāϰেāĻ্āĻāϰ (NSI)">
</div>
<div>
<label>āĻŦাāĻŦাāϰ āĻĒেāĻļা</label>
<input type="text" id="father" placeholder="āĻ
āĻŦāϏāϰāĻĒ্āϰাāĻĒ্āϤ āϏāϰāĻাāϰি āĻāϰ্āĻŽāĻāϰ্āϤা" value="āĻ
āĻŦāϏāϰāĻĒ্āϰাāĻĒ্āϤ āϏāϰāĻাāϰি āĻāϰ্āĻŽāĻāϰ্āϤা">
</div>
<div>
<label>āĻাāĻāĻŦোāύ</label>
<input type="text" id="siblings" placeholder="ā§§ āĻাāĻ, ⧍ āĻŦোāύ" value="">
</div>
<div>
<label>āĻ
āĻŦāϏ্āĻĨাāύ</label>
<input type="text" id="location" placeholder="āĻĸাāĻা" value="āĻĸাāĻা">
</div>
<div>
<label>āĻĢোāύ</label>
<input type="text" id="phone" placeholder="ā§Ļā§§ā§ā§¯ā§Ģ⧍ā§Ļā§ā§Žā§Ŧā§Ŧ" value="ā§Ļā§§ā§ā§¯ā§Ģ⧍ā§Ļā§ā§Žā§Ŧā§Ŧ">
</div>
<textarea id="desc" placeholder="āĻ
āϤিāϰিāĻ্āϤ āĻŦিāĻŦāϰāĻŖ..."></textarea>
<div>
<label>āĻেāĻŽāĻĒ্āϞেāĻ</label>
<select id="template">
<option value="1">Classic Pink</option>
<option value="2">Purple Modern</option>
<option value="3">Golden Elegant</option>
</select>
</div>
<div class="preview-section">
<h3>āϞাāĻāĻ āĻĒ্āϰিāĻিāĻ</h3>
<canvas id="livePreview"></canvas>
</div>
<div class="actions">
<button class="btn btn-primary" onclick="downloadImage()">đĨ āĻĄাāĻāύāϞোāĻĄ PNG</button>
<button class="btn btn-secondary" onclick="copyCaption()">đ āĻ্āϝাāĻĒāĻļāύ āĻāĻĒি</button>
<button class="btn btn-primary" onclick="shareSocial()">đ āĻļেāϝ়াāϰ (FB/IG)</button>
</div>
<div id="caption"></div>
</form>
</div>
<div id="bulkTab" class="tab-content">
<p>JSON āĻĢāϰāĻŽ্āϝাāĻে āĻĒ্āϰোāĻĢাāĻāϞ āϞিāϏ্āĻ āĻĒেāϏ্āĻ āĻāϰুāύ (āĻāĻĻাāĻšāϰāĻŖ āύিāĻে):</p>
<textarea id="bulkInput" placeholder='[\n {\n "type": "āĻĒাāϤ্āϰী āĻাāĻ",\n "name": "ABC",\n "age": "28",\n ... \n }\n]'></textarea>
<div class="actions">
<button class="btn btn-primary" onclick="generateBulk()">Generate All</button>
</div>
<div id="bulkList" class="bulk-list"></div>
</div>
</div>
<canvas id="mainCanvas" width="1080" height="1350" style="display:none;"></canvas>
<img id="logoImg" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg_Vx5gjWzYnNoQIgiheEED0muEzzKPti1fEJNKsjyvZOA87trLnEAm5-075oI5wprNbpOlgVIJeD4_p68kwQ5B0SZl59kUAqKS7goXckRVkAgULyjpjmUXuyIOozYaqSqTaF2YNhqD88rI2dIQRYQeHySqNTl2fi4j_SaOhVKhed0_Mp5gwRL2PgPe-3Sl/s1600/Afrin%20Marriage%20Media%20Logo.png.png" style="display:none;" crossorigin="anonymous">
<script>
let logo = null;
const mainCtx = document.getElementById('mainCanvas').getContext('2d');
const previewCtx = document.getElementById('livePreview').getContext('2d');
function initCanvas() {
logo = document.getElementById('logoImg');
drawPreview();
}
function showTab(tab) {
document.querySelectorAll('.tab-btn').forEach(btn => btn.classList.remove('active'));
document.querySelectorAll('.tab-content').forEach(content => content.classList.remove('active'));
event.target.classList.add('active');
document.getElementById(tab + 'Tab').classList.add('active');
}
function getData() {
return {
type: document.getElementById('type').value,
name: document.getElementById('name').value,
age: document.getElementById('age').value,
height: document.getElementById('height').value,
education: document.getElementById('education').value,
profession: document.getElementById('profession').value,
father: document.getElementById('father').value,
siblings: document.getElementById('siblings').value,
location: document.getElementById('location').value,
phone: document.getElementById('phone').value,
desc: document.getElementById('desc').value,
template: document.getElementById('template').value
};
}
function drawCanvas(ctx, width, height, data, scale=1) {
const temp = parseInt(data.template);
// Background gradient
let gradient;
if (temp === 1) gradient = ctx.createLinearGradient(0, 0, 0, height);
gradient.addColorStop(0, '#FFE4E1');
gradient.addColorStop(1, '#F8BBD9');
ctx.fillStyle = gradient;
ctx.fillRect(0, 0, width, height);
// Logo top center
if (logo && logo.complete) {
ctx.drawImage(logo, width/2 - 60*scale, 20*scale, 120*scale, 120*scale);
}
ctx.textAlign = 'center';
ctx.textBaseline = 'middle';
// Title
ctx.fillStyle = temp===1 ? '#E91E63' : temp===2 ? '#9C27B0' : '#FFD700';
ctx.font = `${80*scale}px bold Arial`;
ctx.fillText(data.type, width/2, 200*scale);
// Name
ctx.fillStyle = '#333';
ctx.font = `${60*scale}px bold Arial`;
ctx.fillText(data.name, width/2, 320*scale);
// Details
ctx.fillStyle = '#555';
ctx.font = `${40*scale}px Arial`;
ctx.textAlign = 'left';
let y = 420*scale;
const details = [
`āĻŦāϝ়āϏ: ${data.age}, āĻāĻ্āĻāϤা: ${data.height}`,
`āĻļিāĻ্āώা: ${data.education}`,
`āĻĒেāĻļা: ${data.profession}`,
`āĻŦাāĻŦা: ${data.father}`,
data.siblings ? `āĻাāĻāĻŦোāύ: ${data.siblings}` : '',
`āĻ
āĻŦāϏ্āĻĨাāύ: ${data.location}`
].filter(Boolean);
details.forEach(d => {
ctx.fillText(d, 100*scale, y);
y += 55*scale;
});
// Desc
if (data.desc) {
ctx.textAlign = 'center';
ctx.fillStyle = '#333';
ctx.font = `${35*scale}px italic Arial`;
ctx.fillText(data.desc, width/2, y + 50*scale);
}
// Phone box
ctx.fillStyle = temp===1 ? '#E91E63' : temp===2 ? '#9C27B0' : '#FFD700';
ctx.roundRect ? ctx.roundRect(100*scale, 900*scale, 880*scale, 120*scale, 20*scale) : drawRoundedRect(ctx, 100*scale, 900*scale, 880*scale, 120*scale, 20*scale);
ctx.fill();
ctx.fillStyle = 'white';
ctx.font = `${55*scale}px bold Arial`;
ctx.textAlign = 'left';
ctx.fillText('đ ' + data.phone, 140*scale, 960*scale);
// Heart bottom
ctx.textAlign = 'center';
ctx.font = `${200*scale}px Arial`;
ctx.fillText('đ', width/2, height - 150*scale);
// Company
ctx.fillStyle = temp===1 ? '#E91E63' : temp===2 ? '#9C27B0' : '#FFD700';
ctx.font = `${30*scale}px bold Arial`;
ctx.fillText('Afrin Marriage Media', width/2, height - 50*scale);
}
function drawRoundedRect(ctx, x, y, w, h, r) {
ctx.beginPath();
ctx.moveTo(x+r, y);
ctx.lineTo(x+w-r, y);
ctx.quadraticCurveTo(x+w, y, x+w, y+r);
ctx.lineTo(x+w, y+h-r);
ctx.quadraticCurveTo(x+w, y+h, x+w-r, y+h);
ctx.lineTo(x+r, y+h);
ctx.quadraticCurveTo(x, y+h, x, y+h-r);
ctx.lineTo(x, y+r);
ctx.quadraticCurveTo(x, y, x+r, y);
ctx.fill();
}
function drawPreview() {
const data = getData();
const pWidth = 300, pHeight = 450;
previewCtx.clearRect(0, 0, pWidth, pHeight);
previewCtx.imageSmoothingEnabled = true;
drawCanvas(previewCtx, pWidth, pHeight, data, pWidth/1080);
generateCaption(data);
}
function generateCaption(data) {
const caption = `đ ${data.type} đ\n\nđ¨đ ${data.name}\nđ āĻŦāϝ়āϏ: ${data.age} | āĻāĻ্āĻāϤা: ${data.height}\nđ ${data.education}\nđŧ ${data.profession}\nđ¨đŠđ§đĻ āĻŦাāĻŦা: ${data.father}\nđ ${data.location}\n\nđ ${data.phone}\n\n#AfrinMarriageMedia #āĻŦিāĻŦাāĻš #āĻĒাāϤ্āϰ #āĻĒাāϤ্āϰী #MatrimonyBD`;
document.getElementById('caption').innerHTML = `<strong>āĻ্āϝাāĻĒāĻļāύ (āĻāĻĒি āĻāϰুāύ):</strong><br><textarea readonly style="width:100%;height:100px;">${caption}</textarea>`;
document.getElementById('caption').style.display = 'block';
}
['type','name','age','height','education','profession','father','siblings','location','phone','desc','template'].forEach(id => {
document.getElementById(id).addEventListener('input', drawPreview);
});
function downloadImage() {
const data = getData();
const canvas = document.getElementById('mainCanvas');
const ctx = mainCtx;
ctx.clearRect(0, 0, 1080, 1350);
drawCanvas(ctx, 1080, 1350, data, 1);
const link = document.createElement('a');
link.download = `afrin_${data.type.replace(/\\s+/g,'_')}_${data.name}.png`;
link.href = canvas.toDataURL('image/png');
link.click();
}
function copyCaption() {
const data = getData();
navigator.clipboard.writeText(document.getElementById('caption').querySelector('textarea').value).then(() => alert('āĻ্āϝাāĻĒāĻļāύ āĻāĻĒি āĻšāϝ়েāĻে!'));
}
async function shareSocial() {
const data = getData();
downloadImage(); // First download
if (navigator.share) {
await navigator.share({title: data.type, text: document.getElementById('caption').innerText, files: []});
} else {
const fbUrl = `https://www.facebook.com/sharer/sharer.php?u=${encodeURIComponent(window.location.href)}`;
window.open(fbUrl, '_blank');
}
}
function generateBulk() {
try {
const profiles = JSON.parse(document.getElementById('bulkInput').value);
const list = document.getElementById('bulkList');
list.innerHTML = '';
profiles.forEach((data, i) => {
data.template = data.template || '1';
const canvas = document.createElement('canvas');
canvas.width = 1080; canvas.height = 1350;
const ctx = canvas.getContext('2d');
drawCanvas(ctx, 1080, 1350, data, 1);
const img = document.createElement('img');
img.src = canvas.toDataURL('image/png');
img.style.width = '200px';
img.onclick = () => {
const link = document.createElement('a');
link.download = `bulk_${i+1}.png`;
link.href = img.src;
link.click();
};
const div = document.createElement('div');
div.className = 'bulk-item';
div.appendChild(img);
div.innerHTML += `<p>${data.name}</p>`;
list.appendChild(div);
});
} catch(e) {
alert('JSON āĻুāϞ! āĻāĻĻাāĻšāϰāĻŖ āĻĻেāĻুāύ।');
}
}
// Init
drawPreview();
</script>
</html>
**āĻেāϏ্āĻ āĻāϰুāύ:** Local HTML āĻĢাāĻāϞ āĻŦাāύিāϝ়ে āĻেāĻ āĻāϰুāύ। Blogger-āĻ gadget size 100% āĻāϰুāύ। āϝāĻĻি āϞোāĻো āύা āϞোāĻĄ āĻšāϝ়, local image upload āĻāϰুāύ। āĻāϰāĻ āĻাāϏ্āĻāĻŽ āĻাāĻāϞে āĻŦāϞুāύ! đ✨`