/* Основен стил */
body, input, select, textarea, button {
  font-family: Arial, sans-serif; margin:0; padding:0;
}

.container {
  max-width:1200px; margin:20px auto; padding:0 15px;
}

header {
  display:flex; justify-content:space-between; align-items:center; margin-bottom:20px;
}

.header-actions button { margin-left:10px; }

/* Таблица */
table {
  width:100%; border-collapse:collapse; margin-top:15px;
}
th, td {
  padding:10px; border-bottom:1px solid #ddd; text-align:left;
}
th { background:#f4f4f4; }

/* Бутон */
.btn {
  padding:8px 15px; border:none; border-radius:4px; cursor:pointer;
}
.btn-primary { background:#3498db; color:#fff; }
.btn-secondary { background:#95a5a6; color:#fff; }
.btn-success { background:#27ae60; color:#fff; }
.btn-sm { padding:5px 10px; font-size:12px; }

/* Модал */
.modal {
  display:none; position:fixed; top:0; left:0; width:100%; height:100%;
  background:rgba(0,0,0,0.5); z-index:1000;
}
.modal-content {
  background:#fff; margin:5% auto; padding:20px;
  border-radius:4px; width:90%; max-width:600px; max-height:90vh; overflow-y:auto;
}
.modal-content.large { max-width:90%; }
.close {
  float:right; font-size:24px; cursor:pointer;
}

/* Формуляри */
label {
  display:block; margin-top:10px; font-weight:500;
}
input, select, textarea {
  width:100%; padding:8px; margin-top:5px; box-sizing:border-box;
}
textarea { resize:vertical; }

/* Клауза */
.clause-item {
  display:flex; gap:10px; margin-top:10px;
}
.remove-clause {
  background:#e74c3c; color:#fff; border:none; padding:5px 10px; border-radius:4px; cursor:pointer;
}

/* Формови действия */
.form-actions {
  display:flex; gap:10px; justify-content:flex-end; margin-top:20px;
}

/* PDF viewer */
.pdf-actions {
  text-align:right; margin-bottom:10px;
}
#pdf-container {
  border:1px solid #ddd; height:600px;
}

/* Фирмено лого */
#logo-preview img {
  max-width:200px; max-height:100px; margin-top:10px;
}

/* Responsive */
@media(max-width:600px) {
  .modal-content { width:95%; }
  .header-actions { display:flex; flex-direction:column; }
  .header-actions button { margin:5px 0; }
}
