#description {
        display: block; /* Явно показываем элемент */
        max-width: 400px;    /* Занимает всю ширину контейнера */
        height: auto;    /* Высота автоматически регулируется содержимым */
        margin-top: 10px; /* Небольшой отступ сверху */
    }
#preview {
        max-width: 600px;
        max-height: 600px;
        object-fit: contain;
        display: inline-block;
    }
/* ~~~~~~~~~~~~~~~~~~~~~~~~ стиль кнопки принять участие ~~~~~~~~~~~~~~~~~~~~~~~~ */
div.button_contest a:link,
div.button_contest a:visited 
{
    display: block;
    max-width:16em;
    padding: 0.3em 0.6em 0.3em 0.6em;
    line-height: 120%;
    margin: 0 auto; 
    font-size: 1.2em;
    text-align: center;
    color: #717100;
    background: #00ff00;
    border: 2px solid #47A76A;
    border-radius: 20px;
    -moz-border-radius: 20px;
    cursor: pointer;
    behavior: url(/static/css/pie/PIE.htc); /* IE fix */
    position: relative; /* IE fix */
    
}
div.button_contest a:hover,
div.button_contest a:active {
    background: rgba(255, 165, 0, 1) !important;
}


/* ~~~~~~~~~~~~~~~~~~~~~~~~ новый спойлер с кнопкой ~~~~~~~~~~~~~~~~~~~~~~~~ */
input[id^="spoiler"]{
 display: none;
}
input[id^="spoiler"] + label {
  display: block;
    max-width:16em;
    padding: 0.3em 0.6em 0.3em 0.6em;
    line-height: 120%;
    margin: 0 auto; 
    font-size: 1.2em;
    text-align: center;
    color: #717100;
    background: #00ff00;
    border: 2px solid #47A76A;
    border-radius: 20px;
    -moz-border-radius: 20px;
    cursor: pointer;
    behavior: url(/static/css/pie/PIE.htc); /* IE fix */
    position: relative; /* IE fix */
}
input[id^="spoiler"]:checked + label {
  color: #333;
  background: #ccc;
}
input[id^="spoiler"] ~ .spoiler {
  width: 90%;
  height: 0;
  overflow: hidden;
  opacity: 0;
  margin: 10px auto 0; 
  padding: 10px; 
  background: #eee;
  border: 1px solid #ccc;
  border-radius: 8px;
  transition: all .6s;
}
input[id^="spoiler"]:checked + label + .spoiler{
  height: auto;
  opacity: 1;
  padding: 10px;
}

.cell {
  padding: 0 1em; 
  vertical-align: middle;
  text-align: center;
  border: 1px solid #ccc;
  border-radius: 8px;
}


.ava_small /* круглая ава */
{
    width: 3em;
    height: 3em;
    border-radius: 50%; /* Радиус скругления */
    box-shadow: 0 0 0 1px green, 0 0 3px #333; /*здесь был зеленый ободок в 3 пикселя */
    object-fit: cover; /* Не даем изменить пропорции изображений */
}


/* ~~~~~~~~~~~~~~~~~~~~~~~~ кнопка вперед к победе ~~~~~~~~~~~~~~~~~~~~~~~~ */

div.button_winner a:link,
div.button_winner a:visited 
{
    display: block;
    width: 8em;
    padding: 0.6em 1.3em .8em 1.3em;
    line-height: 120%;
    margin: 0 auto; */
    color: white;
/*    text-shadow: 1px 1px 1px black; */
    font-weight: bold;
    font-size: 0.8em;
    background: #FFD700;
/*    background: rgba(154, 128, 83, .7); 
/*    border: 0; */
    border: 2px solid #717100;
    border-radius: 20px;
    -moz-border-radius: 20px;
    box-shadow: 0 0 2px #2A2A2A;
    -moz-box-shadow: 0 0 2px #2A2A2A;
    -webkit-box-shadow: 0 0 2px #2A2A2A;
    behavior: url(/static/css/pie/PIE.htc); /* IE fix */
    position: relative; /* IE fix */
    
}
div.button_winner a:hover,
div.button_winner a:active {
	background: #00ff00 !important; 
/*    background: rgba(154, 128, 83, 1) !important; */
}

/* ~~~~~~~~~~~~~~~~~~~~~~~~ кнопка перехода на ресурс организатора ~~~~~~~~~~~~~~~~~~~~~~~~ */

div.button_sponsor a:link,
div.button_sponsor a:visited 
{
    display: block;
    width: 16em;
    padding: 0.6em 1.3em .8em 1.3em;
    line-height: 120%;
    margin: 0 auto; */
    color: white;
/*    text-shadow: 1px 1px 1px black; */
/*    font-weight: bold; */
    font-size: 0.8em;
    background: #D5D5D5;
/*    background: rgba(154, 128, 83, .7); 
/*    border: 0; */
    border: 2px solid #717100;
    border-radius: 20px;
    -moz-border-radius: 20px;
    box-shadow: 0 0 2px #2A2A2A;
    -moz-box-shadow: 0 0 2px #2A2A2A;
    -webkit-box-shadow: 0 0 2px #2A2A2A;
    behavior: url(/static/css/pie/PIE.htc); /* IE fix */
    position: relative; /* IE fix */
    
}
div.button_sponsor a:hover,
div.button_sponsor a:active {
	background: #00ff00 !important; 
/*    background: rgba(154, 128, 83, 1) !important; */
}


/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .tableEditProfile */

table.tableEditProfile
{
	width: 640px;
}

table.tableEditProfile tr td:first-child
{
    width: 48%;
}

table.tableEditProfile tr td input[type="text"]
{
	width: 97%; /* ширина строковых полей ввода текста  */
}

table.tableEditProfile tr td input[type="file"]
{
	width: 100%;
}

table.tableEditProfile tr td textarea
{
	width: 97%;
	height: 60px; /* высота поля textarea */
}

table.tableEditProfile tr td select
{
	width: 100%;
}

/* $$$ END $$$ */




/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .profileTable */

table.profileTable
{
	border-spacing: 1px;
	border-collapse: separate;
    margin: 0 auto;
}

table.profileTable tr td
{
	padding: .4em .5em;
	background: #FFFF99;
	line-height: 110%;
    min-width: 8.5em;
}

table.profileTable tr td:first-child
{
	background: #9DFF6C;
}

/* $$$ END $$$ */



/* ~~~~~~~~~~~~~~~~~~~~~~~~ показ превью загруженной картинки нужным размером ~~~~~~~~~~~~~~~~~~~~~~~~ */   

		.file-upload input[type="file"]{ 
			display: none;/* скрываем input file */ 
		} 
		.file-form-wrap{
			width:260px; 
			margin:auto;
		} 
		.file-upload { 
			position: relative; 
			overflow: hidden; 
			width: 250px; /* длина кнопки */
			height:50px;  /* высота кнопки */
			line-height:50px;
			background: #4169E1; 
			border-radius: 10px; 
			color: #fff; 
			text-align: center; 
		} 
		.file-upload:hover { 
			background: #1E90FF; 
		} 
		/* Растягиваем label на всю область блока .file-upload */ 
		.file-upload label { 
			display: block; 
			position: absolute; 
			top: 0; 
			left: 0; 
			width: 100%; 
			height: 100%; 
			cursor: pointer; 
		} 
		/* стиль текста на кнопке*/ 
		.file-upload span { 
			font-weight:bold; 
		}
		.preview-img{ 
			max-width:200px; /* ширина превьюшки */
			max-height:200px; 
			margin:5px; 
		}
		@media (max-width: 300px){
            .file-form-wrap{
			width:220px; 
			}
			.file-upload { 
		    width: 210px;
			}
		}
		
		
/* ~~~~~~~~~~~~~~~~~~~~~~~~стиль картинки конкурса ~~~~~~~~~~~~~~~~~~~~~~~~ */
      .img_prize {
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
      }
      .img_prize img {
        height: auto;
        width: 400px;
      } 
     			
		
/* ~~~~~~~~~~~~~~~~~~~~~~~~стиль картинки приза ~~~~~~~~~~~~~~~~~~~~~~~~ */
      .wrapper_code {
        width: 200px;
        height: 200px;
        border: 3px solid #FFD700;   
        background: white; 
	    border-radius: 10px; 
      }
      .img_code {
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
      }
      .img_code img {
        height: auto;
        width: 200px;
      } 
     		
     
/* ~~~~~~~~~~~~~~~~~~~~~~~~ стиль текста - выравниевание по ширине с переносами ~~~~~~~~~~~~~~~~~~~~~~~~ */      
      .text_info {
      max-width: 600px;
      text-align:justify;  
      overflow-wrap: break-word; /* перенос длинного названия, но длинные ссылки не переносит */
/*      word-break: break-all; /* перенос длинного названия без дефисов и как попало*/
      }

      

/* ~~~~~~~~~~~~~~~~~~~~~~~~ стиль для сообщений на стр. конкурса ~~~~~~~~~~~~~~~~~~~~~~~~ */   
.bubble_to { 
/*    width: 300px; */
 	width: fit-content;  
    width: -moz-fit-content;
    margin: 35px auto 35px 0; /* здесь рамка с текстом смещены влево */
    font-size: 1em;
    text-align: left;
    border-radius: 15px;
/*    border: 3px solid #1AA0D2; */
 	border: 3px solid #717100; 
/*    display: inline-block; */
    position: relative;
}
.bubble_to::after {
    content: '';
    width: 29px;
    height: 20px;
/*    border-left: 3px solid #1AA0D2; */
	border-left: 3px solid #717100;
/*    border-bottom: 5px solid #1AA0D2; */
  	border-bottom: 5px solid #717100;
    position: absolute;
    bottom: 0px;
    left: 20px;
/*    background: white;  */
    background: #ffff99;
    transform: skewX(-30deg) skewY(-48deg);
}
.bubble_to-in {
    border-radius: 12px;
    padding: 5px 20px;
/*    background: white;  */
    background: #ffff99;
    position: relative;
    z-index: 2; 
}
.bubble_simple {
	border-radius: 12px;
    padding: 5px 20px;
    background: #ffff99;
    border: 3px solid #717100; 
    position: relative;
    z-index: 2; 
}

/* ~~~~~~~~~~~~~~~~~~~~~~~~ стиль круга для номера участника ~~~~~~~~~~~~~~~~~~~~~~~~ */  

.circle 
{
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background-color: #ffff99;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 36px;
    color: #607d8b;
    box-shadow: inset 0 0 0 5px #ffa500; /* Цвет и толщина ободка */
}


/* ~~~~~~~~~~~~~~~~~~~~~~~~ стиль для стр. конкурса ~~~~~~~~~~~~~~~~~~~~~~~~ */   

.offer-header
{
    height: 63px;
    background: url(/static/img/mcerts/header-bg.png) repeat-x;
    border-radius: 25px 25px 0 0;
    margin: 0;
}

.offer-header .offer-header-col
{
    float: left;
    width: 33%;
    text-align: center;
}

.offer-header .offer-header-col input
{
    display: block;
    width: 249px;
    margin: 15px auto 0 auto;
    padding: 10px 0 12px 0;
    background: transparent url(/static/img/mcerts/button.png);
    border: 0;
    color: white;
    text-transform: uppercase;
    cursor: pointer;
}

.offer-header .offer-header-col input::-moz-focus-inner
{
    padding: 0;
    border: 0;
}

.offer-body
{
    padding: 20px;
    background: #A9A9A9;
/*  background: #B8860B;
    background: #DAA520;
	background: #FFD700;
    background: #EDF1E8; */
    margin: 0;
}

.offer-body-green
{
    padding: 20px;
    background: #433719;
    /* background: #9DFF6C; */
    max-width: 560px;
    margin: 0;
}

.offer-body .offer-body-item
{
    display: table;
    width: 100%;
    margin: 0 0 10px 0;
    background: white;
    border: 1px solid #D3D7CF;
    border-radius: 6px;
    box-shadow: 0 0 8px #B9C1AE;
}

.offer-body .offer-body-row
{
    display: table-row;
}

.offer-body .offer-body-item .offer-photo 
{
    display: table-cell;
    width: 400px;
    padding: 1em 1em .5em 1em;
}

.offer-body .offer-body-item .offer-photo img
{
    border-radius: 10px;
}

.offer-body .offer-body-item .offer-info
{
    display: table-cell;
    vertical-align: top;
    padding: 1em 1em 0 0;
}

.offer-body .offer-body-item .offer-info .offer-short-text
{
    margin: .5em 0 1em 0;
    font-size: 1.5em;
    font-weight: bold;
}

.offer-body .offer-body-item .offer-info .offer-short-text p
{
    margin: 0;
}

.offer-body .offer-body-item .offer-info .offer-price
{
    background: url(/static/img/mcerts/bag.png) 0 center no-repeat;
    margin-left: 20px;
    padding-left: 40px;
    font-size: 1.1em;
}

.offer-body .offer-body-item .offer-info .offer-description
{
    font-size: 1.5em;
    line-height: 130%;
}

.offer-body .offer-body-item .offer-info .offer-lottery
{
    margin: 1em 0;
    font-size: 1.1em;
    color: red;
}

.offer-body .offer-body-item .offer-info .offer-lottery div
{
    background: url(/static/img/mcerts/cube.png) no-repeat;
    margin-left: 20px;
    padding-left: 40px;
}


.offer-body .offer-body-item .offer-info .offer-date
{
    margin-bottom: 1em;
    background: url(/static/img/mcerts/clock.png) no-repeat;
    margin-left: 20px;
    padding-left: 40px;
    font-size: .9em;
}

.offer-body .offer-body-item .offer-info .offer-date .offer-countdown
{
    text-transform: lowercase;
}

.offer-body .offer-body-item .offer-info .offer-more-link
{
    text-align: right;
    margin: 0 1em 0 0;
}

.offer-body .offer-body-item .offer-info .offer-more-link a
{
    display: inline-block;
    width: 125px;
    height: 46px;
    padding: 0;
    background: url(/static/img/mcerts/button-2.png);
    border: 0;
    color: white;
    text-decoration: none;
    text-transform: lowercase;
    text-align: center;
    font-size: 1.1em;
    font-family: Verdana, sans-serif;
}

.offer-body .offer-body-item .offer-info .offer-get-cert-link
{
    margin-top: 5em;
    text-align: center;
}

.offer-body .offer-body-item .offer-info .offer-get-cert-link input
{
    display: inline-block;
    width: 159px;
    height: 45px;
    background: transparent url(/static/img/mcerts/button-3.png);
    border: 0;
    text-indent: -9999px;
    cursor: pointer;
}

.offer-body .offer-body-item .offer-address
{
    display: table-cell;
    padding: 1em;
}

.offer-body .offer-body-item .offer-address #offer-map
{
    width: 600px;
    height: 400px;
}

.offer-body .offer-body-item .offer-question-link
{
    text-align: center;
}

.offer-body .offer-body-item .offer-questions b.label
{
    font-size: .9em;
    font-style: italic;
}

/* ~~~~~~~~~~~~~~~~~~~~~~~~ серый фильтр для неактивыных кнопок ~~~~~~~~~~~~~~~~~~~~~~~~ */   
.grey
{  
    z-index: 9999;
    -webkit-filter: grayscale(1); /* Webkit браузеры */  
    filter: gray; /* для IE6-9 */  
    filter: grayscale(1); /* W3C */  
}


/* Стили модального окна и содержания 
-------------------------------------------------------------------------------*/
 
/* слой затемнения */
 
.dm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.85); /* фон вокруг окна */
    display: none;
    overflow: auto;
    width: 100%;
    height: 100%;
    z-index: 1000;
}
/* активируем модальное окно */
 
.dm-overlay:target {
    display: block;
    -webkit-animation: fade 2.6s;  /* время раскрывания окна */
    -moz-animation: fade 2.6s;
    animation: fade 2.6s;
}
/* блочная таблица */
 
.dm-table {
    display: table;
    width: 100%;
    height: 100%;
}
/* ячейка блочной таблицы */
 
.dm-cell {
    display: table-cell;
    padding: 0 1em;
    vertical-align: middle;
    text-align: center;
}
/* модальный блок */
 
.dm-modal {
    display: inline-block;
    padding: 20px;  /* ширина границы между картинкой и рамкой */
    max-width: 50em;
 /*   background: #607d8b; */ /* фон внутри окна */
 	background: #e8e6e1;  /* фон внутри окна */
 	border: 10px solid #607d8b; /* рамка модального окна */
 	border-radius: 7px; /* скругление рамки */
    -webkit-box-shadow: 0px 15px 20px rgba(0, 0, 0, 0.22), 0px 19px 60px rgba(0, 0, 0, 0.3);
    -moz-box-shadow: 0px 15px 20px rgba(0, 0, 0, 0.22), 0px 19px 60px rgba(0, 0, 0, 0.3);
    box-shadow: 0px 15px 20px rgba(0, 0, 0, 0.22), 0px 19px 60px rgba(0, 0, 0, 0.3);
    color: #cfd8dc;
    text-align: center;
}
/* подстраиает ширину окна под размер картинки - новое я добавил, ширина и высота увеличилась */ 
.dm-modal div {
	width: 200px; /* при таком значении ширина окна большая, а картинки уменьшились */
 /*   width: auto; *//* при таком значении ширина картинок и окна большие */
    height: 100%;  
}

/* изображения в модальном окне */
 
.dm-modal img {
    width: 100%;
    height: auto;
}
/* миниатюры изображений */
 
.pl-left,
.pl-right {
    width: 25%;
    height: auto;
}
/* миниатюра справа */
 
.pl-right {
    float: right;
    margin: 5px 0 5px 15px;
}
/* миниатюра слева */
 
.pl-left {
    float: left;
    margin: 5px 15px 5px 0;
}
/* встраиваемое видео в модальном окне */
 
.video {
    position: relative;
    overflow: hidden;
    padding-bottom: 56.25%;
    height: 0;
}
.video iframe,
.video object,
.video embed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
/* рисуем кнопку закрытия */
 
.close {
    z-index: 9999;
/*    float: right;   */
    float: center; /* размещаем кнопку по центру */
    width: 30px; /* ширина круга кнопки */
    height: 17px; /* расстояние от кнопки до черточки */
    color: #cfd8dc;
    text-align: center;
    text-decoration: none;
    line-height: 10px; /* высота кнопки */
    cursor: pointer;
}
.close:after {
    display: block;
 /*   border: 2px solid #cfd8dc;  */ /* рамка вокруг кнопки закрытия */
    -webkit-border-radius: 50%;
    -moz-border-radius: 50%;
    border-radius: 50%;
    content: 'ЗАКРЫТЬ';
    -webkit-transition: all 0.6s;
    -moz-transition: all 0.6s;
    transition: all 0.6s;
    -webkit-transform: scale(0.85);
    -moz-transform: scale(0.85);
    -ms-transform: scale(0.85);
    transform: scale(0.85);
}
/* кнопка закрытия при наведении */
 
.close:hover:after {
    border-color: red;  /* цвет рамки кнопки при наведении на неё курсора */
    color: red; 		/* цвет текста кнопки при наведении на неё курсора */
    -webkit-transform: scale(1);
    -moz-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
}
/* варианты фоновой заливки модального блока */
 
.green {
    background: #388e3c!important;
}
.cyan {
    background: #0097a7!important;
}
.teal {
    background: #00796b!important;
}
/* движуха при появлении блоков с содержанием */
 
@-moz-keyframes fade {
    from {
        opacity: 0;
    }
    to {
        opacity: 1
    }
}
@-webkit-keyframes fade {
    from {
        opacity: 0;
    }
    to {
        opacity: 1
    }
}
@keyframes fade {
    from {
        opacity: 0;
    }
    to {
        opacity: 1
    }
}
/* ------------------------------------------- конец стиля модального окна */
      