503 lines
12 KiB
HTML
503 lines
12 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>LinkedIn Job Analyzer — Settings</title>
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap" rel="stylesheet">
|
|
<style>
|
|
:root {
|
|
--bg-primary: #0a0a0f;
|
|
--bg-secondary: #12121a;
|
|
--bg-card: #1a1a26;
|
|
--accent: #6c63ff;
|
|
--accent-hover: #7c74ff;
|
|
--accent-glow: rgba(108, 99, 255, 0.3);
|
|
--text-primary: #ffffff;
|
|
--text-secondary: #a0a0b8;
|
|
--text-muted: #606078;
|
|
--border: rgba(108, 99, 255, 0.2);
|
|
--border-hover: rgba(108, 99, 255, 0.5);
|
|
--success: #00d67e;
|
|
--error: #ff4d6d;
|
|
--warning: #ffb347;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
body {
|
|
font-family: 'Inter', -apple-system, sans-serif;
|
|
background: var(--bg-primary);
|
|
color: var(--text-primary);
|
|
width: 420px;
|
|
min-height: 500px;
|
|
max-height: 650px;
|
|
overflow-y: auto;
|
|
scrollbar-width: thin;
|
|
scrollbar-color: var(--accent) transparent;
|
|
}
|
|
|
|
body::-webkit-scrollbar { width: 4px; }
|
|
body::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 2px; }
|
|
|
|
/* Header */
|
|
.header {
|
|
background: linear-gradient(135deg, #0a0a0f 0%, #12101e 100%);
|
|
border-bottom: 1px solid var(--border);
|
|
padding: 18px 20px 14px;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 12px;
|
|
position: sticky;
|
|
top: 0;
|
|
z-index: 10;
|
|
}
|
|
|
|
.header-icon {
|
|
width: 36px;
|
|
height: 36px;
|
|
background: linear-gradient(135deg, var(--accent), #9b5de5);
|
|
border-radius: 10px;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 18px;
|
|
box-shadow: 0 0 20px var(--accent-glow);
|
|
}
|
|
|
|
.header-text h1 {
|
|
font-size: 14px;
|
|
font-weight: 700;
|
|
color: var(--text-primary);
|
|
letter-spacing: 0.3px;
|
|
}
|
|
|
|
.header-text p {
|
|
font-size: 11px;
|
|
color: var(--text-secondary);
|
|
margin-top: 1px;
|
|
}
|
|
|
|
/* Content */
|
|
.content {
|
|
padding: 16px 18px;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 14px;
|
|
}
|
|
|
|
/* Section */
|
|
.section {
|
|
background: var(--bg-card);
|
|
border: 1px solid var(--border);
|
|
border-radius: 12px;
|
|
padding: 14px 16px;
|
|
transition: border-color 0.2s;
|
|
}
|
|
|
|
.section:hover {
|
|
border-color: var(--border-hover);
|
|
}
|
|
|
|
.section-header {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
margin-bottom: 12px;
|
|
}
|
|
|
|
.section-title {
|
|
font-size: 12px;
|
|
font-weight: 600;
|
|
color: var(--text-secondary);
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.8px;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
}
|
|
|
|
/* Labels & Inputs */
|
|
label {
|
|
display: block;
|
|
font-size: 12px;
|
|
font-weight: 500;
|
|
color: var(--text-secondary);
|
|
margin-bottom: 6px;
|
|
}
|
|
|
|
.input-wrapper {
|
|
position: relative;
|
|
}
|
|
|
|
input[type="password"],
|
|
input[type="text"],
|
|
select {
|
|
width: 100%;
|
|
background: var(--bg-secondary);
|
|
border: 1px solid var(--border);
|
|
border-radius: 8px;
|
|
color: var(--text-primary);
|
|
font-family: 'Inter', sans-serif;
|
|
font-size: 13px;
|
|
padding: 9px 38px 9px 12px;
|
|
outline: none;
|
|
transition: border-color 0.2s, box-shadow 0.2s;
|
|
}
|
|
|
|
input:focus, select:focus {
|
|
border-color: var(--accent);
|
|
box-shadow: 0 0 0 3px var(--accent-glow);
|
|
}
|
|
|
|
select {
|
|
padding-right: 12px;
|
|
cursor: pointer;
|
|
appearance: none;
|
|
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23a0a0b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
|
|
background-repeat: no-repeat;
|
|
background-position: right 10px center;
|
|
}
|
|
|
|
.toggle-btn {
|
|
position: absolute;
|
|
right: 10px;
|
|
top: 50%;
|
|
transform: translateY(-50%);
|
|
background: none;
|
|
border: none;
|
|
color: var(--text-muted);
|
|
cursor: pointer;
|
|
font-size: 15px;
|
|
padding: 2px;
|
|
transition: color 0.2s;
|
|
}
|
|
|
|
.toggle-btn:hover { color: var(--text-secondary); }
|
|
|
|
textarea {
|
|
width: 100%;
|
|
background: var(--bg-secondary);
|
|
border: 1px solid var(--border);
|
|
border-radius: 8px;
|
|
color: var(--text-primary);
|
|
font-family: 'Inter', monospace;
|
|
font-size: 11.5px;
|
|
line-height: 1.6;
|
|
padding: 10px 12px;
|
|
outline: none;
|
|
resize: vertical;
|
|
min-height: 130px;
|
|
max-height: 220px;
|
|
transition: border-color 0.2s, box-shadow 0.2s;
|
|
}
|
|
|
|
textarea:focus {
|
|
border-color: var(--accent);
|
|
box-shadow: 0 0 0 3px var(--accent-glow);
|
|
}
|
|
|
|
/* Buttons */
|
|
.btn {
|
|
border: none;
|
|
border-radius: 8px;
|
|
cursor: pointer;
|
|
font-family: 'Inter', sans-serif;
|
|
font-weight: 600;
|
|
transition: all 0.2s;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
gap: 6px;
|
|
}
|
|
|
|
.btn-primary {
|
|
background: linear-gradient(135deg, var(--accent), #9b5de5);
|
|
color: white;
|
|
padding: 10px 20px;
|
|
font-size: 13px;
|
|
width: 100%;
|
|
letter-spacing: 0.3px;
|
|
}
|
|
|
|
.btn-primary:hover {
|
|
transform: translateY(-1px);
|
|
box-shadow: 0 6px 20px var(--accent-glow);
|
|
}
|
|
|
|
.btn-primary:active { transform: translateY(0); }
|
|
|
|
.btn-sm {
|
|
background: var(--bg-secondary);
|
|
border: 1px solid var(--border);
|
|
color: var(--text-secondary);
|
|
padding: 6px 12px;
|
|
font-size: 11px;
|
|
}
|
|
|
|
.btn-sm:hover {
|
|
border-color: var(--accent);
|
|
color: var(--accent);
|
|
}
|
|
|
|
.btn-danger {
|
|
background: transparent;
|
|
border: 1px solid rgba(255, 77, 109, 0.3);
|
|
color: var(--error);
|
|
padding: 7px 14px;
|
|
font-size: 11px;
|
|
}
|
|
|
|
.btn-danger:hover {
|
|
background: rgba(255, 77, 109, 0.1);
|
|
border-color: var(--error);
|
|
}
|
|
|
|
/* Status badge */
|
|
.status-badge {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 5px;
|
|
font-size: 11px;
|
|
font-weight: 500;
|
|
padding: 3px 10px;
|
|
border-radius: 20px;
|
|
}
|
|
|
|
.status-badge.success {
|
|
background: rgba(0, 214, 126, 0.12);
|
|
color: var(--success);
|
|
border: 1px solid rgba(0, 214, 126, 0.25);
|
|
}
|
|
|
|
.status-badge.error {
|
|
background: rgba(255, 77, 109, 0.12);
|
|
color: var(--error);
|
|
border: 1px solid rgba(255, 77, 109, 0.25);
|
|
}
|
|
|
|
.status-badge.checking {
|
|
background: rgba(255, 179, 71, 0.12);
|
|
color: var(--warning);
|
|
border: 1px solid rgba(255, 179, 71, 0.25);
|
|
}
|
|
|
|
.status-dot {
|
|
width: 6px;
|
|
height: 6px;
|
|
border-radius: 50%;
|
|
background: currentColor;
|
|
}
|
|
|
|
/* API Key row */
|
|
.api-key-row {
|
|
display: flex;
|
|
gap: 8px;
|
|
align-items: flex-start;
|
|
margin-top: 4px;
|
|
}
|
|
|
|
.api-key-row .input-wrapper { flex: 1; }
|
|
|
|
/* Usage bar */
|
|
.usage-bar {
|
|
margin-top: 10px;
|
|
}
|
|
|
|
.usage-label {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
font-size: 11px;
|
|
color: var(--text-secondary);
|
|
margin-bottom: 5px;
|
|
}
|
|
|
|
.usage-track {
|
|
height: 4px;
|
|
background: var(--bg-secondary);
|
|
border-radius: 2px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.usage-fill {
|
|
height: 100%;
|
|
background: linear-gradient(90deg, var(--accent), #9b5de5);
|
|
border-radius: 2px;
|
|
transition: width 0.5s ease;
|
|
}
|
|
|
|
/* Info link */
|
|
.info-link {
|
|
font-size: 11px;
|
|
color: var(--accent);
|
|
text-decoration: none;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 3px;
|
|
margin-top: 6px;
|
|
transition: opacity 0.2s;
|
|
}
|
|
|
|
.info-link:hover { opacity: 0.75; }
|
|
|
|
/* Row helpers */
|
|
.row {
|
|
display: flex;
|
|
gap: 8px;
|
|
margin-top: 4px;
|
|
}
|
|
|
|
.row .btn { flex: 1; }
|
|
|
|
/* Divider */
|
|
.divider {
|
|
height: 1px;
|
|
background: var(--border);
|
|
margin: 6px 0;
|
|
}
|
|
|
|
/* Footer */
|
|
.footer {
|
|
padding: 10px 18px 14px;
|
|
text-align: center;
|
|
font-size: 10.5px;
|
|
color: var(--text-muted);
|
|
border-top: 1px solid var(--border);
|
|
}
|
|
|
|
.footer span { color: var(--accent); }
|
|
|
|
/* Notification toast */
|
|
.toast {
|
|
position: fixed;
|
|
bottom: 16px;
|
|
left: 50%;
|
|
transform: translateX(-50%) translateY(20px);
|
|
background: var(--bg-card);
|
|
border: 1px solid var(--border);
|
|
color: var(--text-primary);
|
|
padding: 9px 18px;
|
|
border-radius: 20px;
|
|
font-size: 12px;
|
|
font-weight: 500;
|
|
opacity: 0;
|
|
transition: all 0.3s;
|
|
pointer-events: none;
|
|
white-space: nowrap;
|
|
z-index: 100;
|
|
}
|
|
|
|
.toast.show {
|
|
opacity: 1;
|
|
transform: translateX(-50%) translateY(0);
|
|
}
|
|
|
|
.toast.success { border-color: var(--success); color: var(--success); }
|
|
.toast.error { border-color: var(--error); color: var(--error); }
|
|
</style>
|
|
</head>
|
|
<body>
|
|
|
|
<div class="header">
|
|
<div class="header-icon">🔍</div>
|
|
<div class="header-text">
|
|
<h1>LinkedIn Job Analyzer</h1>
|
|
<p>Powered by Gemini 3.1 Flash-Lite Latest</p>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="content">
|
|
|
|
<!-- API KEY SECTION -->
|
|
<div class="section">
|
|
<div class="section-header">
|
|
<span class="section-title">🔑 API Key</span>
|
|
<span id="key-status" class="status-badge" style="display:none;"></span>
|
|
</div>
|
|
|
|
<label for="api-key-input">Gemini API Key</label>
|
|
<div class="api-key-row">
|
|
<div class="input-wrapper">
|
|
<input type="password" id="api-key-input" placeholder="AIzaSy..." autocomplete="off" spellcheck="false">
|
|
<button class="toggle-btn" id="toggle-key" title="Show/Hide">👁</button>
|
|
</div>
|
|
<button class="btn btn-sm" id="test-key-btn">Test</button>
|
|
</div>
|
|
|
|
<a class="info-link" href="https://aistudio.google.com/apikey" target="_blank">
|
|
🔗 Get free API key (no credit card needed)
|
|
</a>
|
|
|
|
<!-- Usage -->
|
|
<div class="divider" style="margin-top:12px;"></div>
|
|
<div class="usage-bar">
|
|
<div class="usage-label">
|
|
<span>Daily Usage</span>
|
|
<span id="usage-count">0 / 1,000 requests</span>
|
|
</div>
|
|
<div class="usage-track">
|
|
<div class="usage-fill" id="usage-fill" style="width:0%;"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- PROFILE SECTION -->
|
|
<div class="section">
|
|
<div class="section-header">
|
|
<span class="section-title">👤 My Profile</span>
|
|
<button class="btn btn-sm" id="reset-profile-btn">Reset</button>
|
|
</div>
|
|
<label for="profile-textarea">Your CV / Experience (used in all AI prompts)</label>
|
|
<textarea id="profile-textarea" placeholder="Paste your CV or experience here..."></textarea>
|
|
</div>
|
|
|
|
<!-- PREFERENCES SECTION -->
|
|
<div class="section">
|
|
<div class="section-header">
|
|
<span class="section-title">⚙️ Preferences</span>
|
|
</div>
|
|
|
|
<label for="lang-select">Response Language</label>
|
|
<select id="lang-select">
|
|
<option value="auto">🌐 Auto-detect (match job language)</option>
|
|
<option value="english">🇬🇧 Always English</option>
|
|
<option value="arabic">🇯🇴 Always Arabic</option>
|
|
</select>
|
|
</div>
|
|
|
|
<!-- SAVE BUTTON -->
|
|
<button class="btn btn-primary" id="save-btn">
|
|
💾 Save Settings
|
|
</button>
|
|
|
|
<!-- DANGER ZONE -->
|
|
<div class="section">
|
|
<div class="section-header">
|
|
<span class="section-title">🗑️ Data Management</span>
|
|
</div>
|
|
<div class="row">
|
|
<button class="btn btn-danger" id="clear-cache-btn">Clear Cache</button>
|
|
<button class="btn btn-danger" id="clear-all-btn">Clear All Data</button>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="footer">
|
|
LinkedIn Job Analyzer v1.0 — Personal Use Only<br>
|
|
<span>gemini-flash-lite-latest</span> · Free Tier
|
|
</div>
|
|
|
|
<div class="toast" id="toast"></div>
|
|
|
|
<script src="profile.js"></script>
|
|
<script src="popup.js"></script>
|
|
</body>
|
|
</html>
|