horozov86

login.css

Apr 29th, 2025
788
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 2.99 KB | None | 0 0
  1. html {
  2.   height: 100%;
  3. }
  4. body {
  5.   margin: 0;
  6.   padding: 0;
  7.   font-family: sans-serif;
  8.   background: linear-gradient(#141e30, #243b55);
  9. }
  10.  
  11. .login-box {
  12.   position: absolute;
  13.   top: 50%;
  14.   left: 50%;
  15.   width: 400px;
  16.   padding: 40px;
  17.   transform: translate(-50%, -50%);
  18.   background: rgba(0, 0, 0, 0.5);
  19.   box-sizing: border-box;
  20.   box-shadow: 0 15px 25px rgba(0, 0, 0, 0.6);
  21.   border-radius: 10px;
  22. }
  23.  
  24. .login-box h2 {
  25.   margin: 0 0 30px;
  26.   padding: 0;
  27.   color: #fff;
  28.   text-align: center;
  29. }
  30.  
  31. .login-box .user-box {
  32.   position: relative;
  33. }
  34.  
  35. .login-box .user-box input {
  36.   width: 100%;
  37.   padding: 10px 0;
  38.   font-size: 16px;
  39.   color: #fff;
  40.   margin-bottom: 30px;
  41.   border: none;
  42.   border-bottom: 1px solid #fff;
  43.   outline: none;
  44.   background: transparent;
  45. }
  46.  
  47. .login-box .user-box label {
  48.   position: absolute;
  49.   top: 0;
  50.   left: 0;
  51.   padding: 10px 0;
  52.   font-size: 16px;
  53.   color: #fff;
  54.   pointer-events: none;
  55.   transition: 0.5s;
  56. }
  57.  
  58. .login-box .user-box input:focus ~ label,
  59. .login-box .user-box input:valid ~ label {
  60.   top: -20px;
  61.   left: 0;
  62.   color: #03e9f4;
  63.   font-size: 12px;
  64. }
  65.  
  66. /* СТИЛ ЗА BUTTON */
  67. .login-button {
  68.   position: relative;
  69.   display: inline-block;
  70.   padding: 10px 20px;
  71.   color: #03e9f4;
  72.   font-size: 16px;
  73.   background: none;
  74.   border: none;
  75.   text-transform: uppercase;
  76.   overflow: hidden;
  77.   transition: 0.5s;
  78.   margin-top: 40px;
  79.   letter-spacing: 4px;
  80.   cursor: pointer;
  81. }
  82. .login-button:hover {
  83.   background: #03e9f4;
  84.   color: #fff;
  85.   border-radius: 5px;
  86.   box-shadow: 0 0 5px #B3E5FC,
  87.               0 0 25px #03e9f4,
  88.               0 0 50px #03e9f4,
  89.               0 0 100px #B3E5FC;
  90. }
  91. .login-button span {
  92.   position: absolute;
  93.   display: block;
  94. }
  95.  
  96. .login-button span:nth-child(1) {
  97.   top: 0;
  98.   left: -100%;
  99.   width: 100%;
  100.   height: 2px;
  101.   background: linear-gradient(90deg, transparent, #03e9f4);
  102.   animation: btn-anim1 1s linear infinite;
  103. }
  104.  
  105. @keyframes btn-anim1 {
  106.   0% {
  107.     left: -100%;
  108.   }
  109.   50%, 100% {
  110.     left: 100%;
  111.   }
  112. }
  113.  
  114. .login-button span:nth-child(2) {
  115.   top: -100%;
  116.   right: 0;
  117.   width: 2px;
  118.   height: 100%;
  119.   background: linear-gradient(180deg, transparent, #03e9f4);
  120.   animation: btn-anim2 1s linear infinite;
  121.   animation-delay: 0.25s;
  122. }
  123.  
  124. @keyframes btn-anim2 {
  125.   0% {
  126.     top: -100%;
  127.   }
  128.   50%, 100% {
  129.     top: 100%;
  130.   }
  131. }
  132.  
  133. .login-button span:nth-child(3) {
  134.   bottom: 0;
  135.   right: -100%;
  136.   width: 100%;
  137.   height: 2px;
  138.   background: linear-gradient(270deg, transparent, #03e9f4);
  139.   animation: btn-anim3 1s linear infinite;
  140.   animation-delay: 0.5s;
  141. }
  142.  
  143. @keyframes btn-anim3 {
  144.   0% {
  145.     right: -100%;
  146.   }
  147.   50%, 100% {
  148.     right: 100%;
  149.   }
  150. }
  151.  
  152. .login-button span:nth-child(4) {
  153.   bottom: -100%;
  154.   left: 0;
  155.   width: 2px;
  156.   height: 100%;
  157.   background: linear-gradient(360deg, transparent, #03e9f4);
  158.   animation: btn-anim4 1s linear infinite;
  159.   animation-delay: 0.75s;
  160. }
  161.  
  162. @keyframes btn-anim4 {
  163.   0% {
  164.     bottom: -100%;
  165.   }
  166.   50%, 100% {
  167.     bottom: 100%;
  168.   }
  169. }
  170.  
Advertisement
Add Comment
Please, Sign In to add comment