/* ===== ОБЩИЕ ===== */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: #f0f2f5;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: #1c1e21;
  line-height: 1.6;
  padding: 0;
  margin: 0;
}
a { color: #1a73e8; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ===== КОНТЕЙНЕР ===== */
.container {
  max-width: 700px;
  margin: 0 auto;
  padding: 16px;
}

/* ===== КАРТОЧКА ПОСТА (mtr) ===== */
.mtr {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  padding: 16px 20px;
  margin-bottom: 16px;
  border: 1px solid #e4e6eb;
  transition: 0.2s;
}
.mtr:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }

.mtr table { width: 100%; border-collapse: collapse; }
.mtr table td { padding: 0; vertical-align: top; }

.mtravatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  background: #e4e6eb;
  margin-right: 14px;
  flex-shrink: 0;
}
.mtravatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.userinfo {
  font-size: 14px;
  color: #65676b;
  margin-bottom: 6px;
}
.userinfo a {
  color: #1c1e21;
  font-weight: 600;
}
.userinfo a:hover { text-decoration: none; color: #1a73e8; }

.userinfotext {
  font-size: 15px;
  color: #1c1e21;
  word-wrap: break-word;
}
.userinfotext .photo_message {
  margin-top: 10px;
}
.userinfotext .photo_message img {
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid #e4e6eb;
}

.userinfoadd {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.userinfoadd .i_icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.userinfoadd .uiatext a {
  color: #1a73e8;
}
.userinfoadd .uiatext a:hover { text-decoration: underline; }

/* Рейтинг (лайки) */
.over_rate {
  margin-top: 8px;
  display: flex;
  justify-content: flex-end;
}
.rate {
  background: #f0f2f5;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 13px;
  color: #65676b;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: 0.2s;
  border: 1px solid transparent;
}
.rate:hover {
  background: #e4e6eb;
  border-color: #1a73e8;
}
.rate_n {
  background: #f0f2f5;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 13px;
  color: #65676b;
}

/* ===== ПРОФИЛЬ ===== */
.userindex {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  padding: 20px;
  margin-bottom: 20px;
  border: 1px solid #e4e6eb;
}
.userindex table { width: 100%; border-collapse: collapse; }
.userindex td { padding: 0; vertical-align: top; }
.useravatar .avtr {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  overflow: hidden;
  background: #e4e6eb;
}
.useravatar .avtr img { width: 100%; height: 100%; object-fit: cover; }
.namer {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 4px;
}
.usernamer {
  font-size: 14px;
  color: #65676b;
}
.sub { font-size: 14px; color: #1c1e21; margin-top: 6px; }
.urler { margin-top: 6px; }
.urler a { color: #1a73e8; }

.usercounter {
  background: #f0f2f5;
  border-radius: 12px;
  padding: 10px 12px;
  margin-top: 8px;
  text-align: center;
}
.usercounter .u_num { font-size: 18px; font-weight: 600; color: #1c1e21; }
.usercounter .u_line {
  width: 1px;
  background: #d0d2d6;
  height: 30px;
  margin: 0 10px;
}

.u_follow, .u_disfollow, .u_set {
  display: block;
  margin-top: 10px;
  background: #1a73e8;
  color: white;
  padding: 10px;
  border-radius: 30px;
  text-align: center;
  font-weight: 600;
  transition: 0.2s;
}
.u_follow a, .u_disfollow a, .u_set a {
  color: white;
  display: block;
}
.u_follow:hover { background: #1557b0; }
.u_disfollow { background: #e41e3f; }
.u_disfollow:hover { background: #b71c1c; }

/* ===== КОММЕНТАРИИ ===== */
.comment-item {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 12px;
  border: 1px solid #e4e6eb;
}
.comment-item .userinfo { font-size: 13px; }
.comment-item .userinfotext { font-size: 14px; }

/* ===== ФОРМЫ ===== */
input, textarea, button {
  font-family: inherit;
  font-size: 15px;
}
input[type="text"], input[type="password"], input[type="email"], textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #dadde1;
  border-radius: 8px;
  background: #ffffff;
  transition: 0.2s;
}
input:focus, textarea:focus {
  border-color: #1a73e8;
  outline: none;
  box-shadow: 0 0 0 3px rgba(26,115,232,0.2);
}
button, .btn {
  background: #1a73e8;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 30px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s;
}
button:hover, .btn:hover { background: #1557b0; }

/* ===== АДАПТИВ ===== */
@media (max-width: 600px) {
  .container { padding: 10px; }
  .mtr { padding: 12px 14px; }
  .userindex { padding: 14px; }
  .useravatar .avtr { width: 70px; height: 70px; }
  .namer { font-size: 18px; }
  .usercounter .u_num { font-size: 16px; }
}
